minerender 2.1.0-alpha.41 → 2.1.0-alpha.42

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/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 p14 = 0;
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[p14++] = encoded1 << 2 | encoded2 >> 4;
3069
- bytes[p14++] = (encoded2 & 15) << 4 | encoded3 >> 2;
3070
- bytes[p14++] = (encoded3 & 3) << 6 | encoded4 & 63;
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 p14 = Promise.reject(error);
11095
+ const p13 = Promise.reject(error);
11096
11096
  error = null;
11097
- return p14;
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 p14 in m4) if (p14 !== "default" && !Object.prototype.hasOwnProperty.call(exports14, p14)) __createBinding(exports14, m4, p14);
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 p14 in s4) if (Object.prototype.hasOwnProperty.call(s4, p14))
11535
- t5[p14] = s4[p14];
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 p14 = Promise.reject(error);
11814
+ const p13 = Promise.reject(error);
11815
11815
  error = null;
11816
- return p14;
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, p14 = ["{", "}"];
12053
- (pe(t5) && (s4 = true, p14 = ["[", "]"]), we(t5)) && (c4 = " [Function" + (t5.name ? ": " + t5.name : "") + "]");
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, p14)) : p14[0] + c4 + p14[1];
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 p14 = true, c4 = 0; c4 < s4; c4++) if (h5(t5, o4 + c4) !== h5(r5, c4)) {
12815
- p14 = false;
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 (p14) return o4;
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, p14 = h5 > 239 ? 4 : h5 > 223 ? 3 : h5 > 191 ? 2 : 1;
12863
- if (i4 + p14 <= e6) switch (p14) {
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, p14 = 1) : a4 > 65535 && (a4 -= 65536, n4.push(a4 >>> 10 & 1023 | 55296), a4 = 56320 | 1023 & a4), n4.push(a4), i4 += p14;
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 p14 = this.head;
14943
- var ret = "" + p14.data;
14944
- while (p14 = p14.next) {
14945
- ret += s4 + p14.data;
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 p14 = this.head;
14954
+ var p13 = this.head;
14955
14955
  var i4 = 0;
14956
- while (p14) {
14957
- copyBuffer(p14.data, ret, i4);
14958
- i4 += p14.data.length;
14959
- p14 = p14.next;
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 p14 = this.head;
14987
+ var p13 = this.head;
14988
14988
  var c4 = 1;
14989
- var ret = p14.data;
14989
+ var ret = p13.data;
14990
14990
  n4 -= ret.length;
14991
- while (p14 = p14.next) {
14992
- var str = p14.data;
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 (p14.next) this.head = p14.next;
15000
+ if (p13.next) this.head = p13.next;
15001
15001
  else this.head = this.tail = null;
15002
15002
  } else {
15003
- this.head = p14;
15004
- p14.data = str.slice(nb);
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 p14 = this.head;
15018
+ var p13 = this.head;
15019
15019
  var c4 = 1;
15020
- p14.data.copy(ret);
15021
- n4 -= p14.data.length;
15022
- while (p14 = p14.next) {
15023
- var buf = p14.data;
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 (p14.next) this.head = p14.next;
15030
+ if (p13.next) this.head = p13.next;
15031
15031
  else this.head = this.tail = null;
15032
15032
  } else {
15033
- this.head = p14;
15034
- p14.data = buf.slice(nb);
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 p14 = this._readableState.buffer.head;
16324
+ var p13 = this._readableState.buffer.head;
16325
16325
  var content = "";
16326
- while (p14 !== null) {
16327
- content += decoder.write(p14.data);
16328
- p14 = p14.next;
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, p14 = 8 * h5 - r5 - 1, w4 = (1 << p14) - 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 += p14; i4 > 0; M4 = 256 * M4 + a4[t5 + N4], N4 += n4, i4 -= 8) ;
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, p14, 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 ? (p14 = 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 ? (p14 = 0, f4 = i4) : f4 + N4 >= 1 ? (p14 = (t5 * w4 - 1) * Math.pow(2, h5), f4 += N4) : (p14 = t5 * Math.pow(2, N4 - 1) * Math.pow(2, h5), f4 = 0)); h5 >= 8; a4[o4 + u4] = 255 & p14, u4 += l4, p14 /= 256, h5 -= 8) ;
17083
- for (f4 = f4 << h5 | p14, e6 += h5; e6 > 0; a4[o4 + u4] = 255 & f4, u4 += l4, f4 /= 256, e6 -= 8) ;
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), p14 = 0; p14 < s4; ++p14) if (h5[p14] !== a4[p14]) {
17188
- o4 = h5[p14], f4 = a4[p14];
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 p14(t6, arguments, h5(this).constructor);
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 p14(t5, e6, n5) {
17805
- return (p14 = s4() ? Reflect.construct : function(t6, e7, n6) {
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"), p15 = 0, g5 = "";
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][p15] === s5[0][p15]; ) p15++;
17852
- p15 > 2 && (g5 = "\n ".concat(function(t6, e7) {
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
- }(" ", p15), "^"), p15 = 0);
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 && (p15++ < 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];
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
- p15 > 3 && (i4 = "\n".concat(m4, "...").concat(S4).concat(i4), u4 = true), "" !== o5 && (i4 = "\n ".concat(o5).concat(i4), o5 = "");
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 (p15 = 0; p15 < O5; p15++) {
17871
- var _4 = p15 - a5;
17872
- if (f5.length < p15 + 1) _4 > 1 && p15 > 2 && (_4 > 4 ? (c5 += "\n".concat(m4, "...").concat(S4), u4 = true) : _4 > 3 && (c5 += "\n ".concat(s5[p15 - 2]), R5++), c5 += "\n ".concat(s5[p15 - 1]), R5++), a5 = p15, o5 += "\n".concat(w4, "-").concat(S4, " ").concat(s5[p15]), R5++;
17873
- else if (s5.length < p15 + 1) _4 > 1 && p15 > 2 && (_4 > 4 ? (c5 += "\n".concat(m4, "...").concat(S4), u4 = true) : _4 > 3 && (c5 += "\n ".concat(f5[p15 - 2]), R5++), c5 += "\n ".concat(f5[p15 - 1]), R5++), a5 = p15, c5 += "\n".concat(E4, "+").concat(S4, " ").concat(f5[p15]), R5++;
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[p15], P5 = f5[p15], 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 && p15 > 2 && (_4 > 4 ? (c5 += "\n".concat(m4, "...").concat(S4), u4 = true) : _4 > 3 && (c5 += "\n ".concat(f5[p15 - 2]), R5++), c5 += "\n ".concat(f5[p15 - 1]), R5++), a5 = p15, c5 += "\n".concat(E4, "+").concat(S4, " ").concat(P5), o5 += "\n".concat(w4, "-").concat(S4, " ").concat(T5), R5 += 2) : (c5 += o5, o5 = "", 1 !== _4 && 0 !== p15 || (c5 += "\n ".concat(P5), R5++));
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 && p15 < O5 - 2) return "".concat(A4).concat(k4, "\n").concat(c5, "\n").concat(m4, "...").concat(S4).concat(o5, "\n") + "".concat(m4, "...").concat(S4);
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 p15 = j4[i5], g5 = x4(l4).split("\n");
17893
- if ("notStrictEqual" === i5 && "object" === y5(l4) && null !== l4 && (p15 = 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(p15, " ").concat(g5[0]))) : c4(this, h5(e6).call(this, "".concat(p15, "\n\n").concat(g5.join("\n"), "\n")));
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 p14 = v$1(e6);
18048
- if (0 !== p14.length && 0 !== z3(e6, p14).length) return false;
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, p14 = 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;
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 p14("expected", ["Function", "RegExp"], e6);
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 p14("fn", "Function", t5);
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 p14("promiseFn", ["Function", "Promise"], t5);
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 p14("error", ["Object", "Error", "Function", "RegExp"], n4);
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 p14("error", ["Object", "Error", "Function", "RegExp"], n4);
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, p14, 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;
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
- }, p14 = { $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() {
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 (!p14["$" + t5] && n4.call(window, t5) && null !== window[t5] && "object" == typeof window[t5]) try {
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), p15 = e6 && "[object String]" === o4.call(t5), y5 = [];
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 (p15 && t5.length > 0 && !n4.call(t5, 0)) for (var g4 = 0; g4 < t5.length; ++g4) y5.push(String(g4));
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 p14, i4 = n$22.call(arguments, 1), c4 = function() {
18501
- if (this instanceof p14) {
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 (p14 = Function("binder", "return function (" + l4.join(",") + "){ return binder.apply(this,arguments); }")(c4), e6.prototype) {
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, p14.prototype = new y5(), y5.prototype = null;
18510
+ y5.prototype = e6.prototype, p13.prototype = new y5(), y5.prototype = null;
18511
18511
  }
18512
- return p14;
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 p14 in source) {
19122
- if (_has(source, p14)) {
19123
- obj[p14] = source[p14];
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 p14, n4, m4, more, str;
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
- p14 = n4;
20076
+ p13 = n4;
20077
20077
  do {
20078
- m4 = s4.head[--p14];
20079
- s4.head[p14] = m4 >= _w_size ? m4 - _w_size : 0;
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
- p14 = n4;
20082
+ p13 = n4;
20083
20083
  do {
20084
- m4 = s4.prev[--p14];
20085
- s4.prev[p14] = m4 >= _w_size ? m4 - _w_size : 0;
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 p14 = URI.parse(ref), refPath = _getFullPath(p14), baseId = getFullPath(this._getId(root.schema));
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, p14);
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, p14, baseId, root.schema, root);
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 p14 = URI.parse(id);
26224
- return _getFullPath(p14);
26223
+ var p13 = URI.parse(id);
26224
+ return _getFullPath(p13);
26225
26225
  }
26226
- function _getFullPath(p14) {
26227
- return URI.serialize(p14).split("#")[0] + "#";
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(p14) {
29116
- return p14 !== "__proto__";
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 p14 = loadMetaSchemaOf(schema).then(function() {
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
- p14.then(
30056
+ p13.then(
30057
30057
  function(v5) {
30058
30058
  callback(null, v5);
30059
30059
  },
30060
30060
  callback
30061
30061
  );
30062
30062
  }
30063
- return p14;
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 cached = this._cache.get(cacheKey);
30874
- if (cached) return cached;
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, p14) {
33132
- _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o5, p15) {
33133
- o5.__proto__ = p15;
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, p14);
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, p14) {
33488
- _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o5, p15) {
33489
- o5.__proto__ = p15;
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, p14);
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(p14, originalValidator, path) {
35981
+ function validateTypes(p13, originalValidator, path) {
35982
35982
  const v5 = new _Validator(originalValidator.typesSchemas);
35983
- Object.keys(p14).forEach((k4) => {
35983
+ Object.keys(p13).forEach((k4) => {
35984
35984
  if (k4 == "types") {
35985
- Object.keys(p14[k4]).forEach((typeName) => v5.addType(typeName));
35986
- Object.keys(p14[k4]).forEach((typeName) => {
35985
+ Object.keys(p13[k4]).forEach((typeName) => v5.addType(typeName));
35986
+ Object.keys(p13[k4]).forEach((typeName) => {
35987
35987
  try {
35988
- v5.validateType(p14[k4][typeName], path + "." + k4 + "." + typeName);
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(p14[k4], v5, path + "." + k4);
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 p14 = this.head;
39374
- let ret = "" + p14.data;
39375
- while ((p14 = p14.next) !== null) ret += s4 + p14.data;
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 p14 = this.head;
39381
+ let p13 = this.head;
39382
39382
  let i4 = 0;
39383
- while (p14) {
39384
- TypedArrayPrototypeSet(ret, p14.data, i4);
39385
- i4 += p14.data.length;
39386
- p14 = p14.next;
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 p14 = this.head; p14; p14 = p14.next) {
39408
- yield p14.data;
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 p14 = this.head;
39414
+ let p13 = this.head;
39415
39415
  let c4 = 0;
39416
39416
  do {
39417
- const str = p14.data;
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 (p14.next) this.head = p14.next;
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 = p14;
39430
- p14.data = StringPrototypeSlice(str, n4);
39429
+ this.head = p13;
39430
+ p13.data = StringPrototypeSlice(str, n4);
39431
39431
  }
39432
39432
  break;
39433
39433
  }
39434
39434
  ++c4;
39435
- } while ((p14 = p14.next) !== null);
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 p14 = this.head;
39443
+ let p13 = this.head;
39444
39444
  let c4 = 0;
39445
39445
  do {
39446
- const buf = p14.data;
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 (p14.next) this.head = p14.next;
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 = p14;
39459
- p14.data = buf.slice(n4);
39458
+ this.head = p13;
39459
+ p13.data = buf.slice(n4);
39460
39460
  }
39461
39461
  break;
39462
39462
  }
39463
39463
  ++c4;
39464
- } while ((p14 = p14.next) !== null);
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, p14) {
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 p14 = this.lastTotal - this.lastNeed;
39752
- var r5 = utf8CheckExtraBytes(this, buf, p14);
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, p14, 0, this.lastNeed);
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, p14, 0, buf.length);
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, p14, m4) {
45445
- var o4 = p14 / 8 | 0;
45446
- return (d4[o4] | d4[o4 + 1] << 8) >> (p14 & 7) & m4;
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, p14) {
45449
- var o4 = p14 / 8 | 0;
45450
- return (d4[o4] | d4[o4 + 1] << 8 | d4[o4 + 2] << 16) >> (p14 & 7);
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(p14) {
45453
- return (p14 + 7) / 8 | 0;
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, p14, v5) {
45631
- v5 <<= p14 & 7;
45632
- var o4 = p14 / 8 | 0;
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, p14, v5) {
45637
- v5 <<= p14 & 7;
45638
- var o4 = p14 / 8 | 0;
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, p14) {
45765
- wbits(out, p14++, final);
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, p14, dat.subarray(bs, bs + bl));
45784
+ return wfblk(out, p13, dat.subarray(bs, bs + bl));
45785
45785
  var lm, ll, dm, dl;
45786
- wbits(out, p14, 1 + (dtlen < ftlen)), p14 += 2;
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, p14, nlc - 257);
45791
- wbits(out, p14 + 5, ndc - 1);
45792
- wbits(out, p14 + 10, nlcc - 4);
45793
- p14 += 14;
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, p14 + 3 * i4, lct[clim[i4]]);
45796
- p14 += 3 * nlcc;
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, p14, llm[len]), p14 += lct[len];
45802
+ wbits(out, p13, llm[len]), p13 += lct[len];
45803
45803
  if (len > 15)
45804
- wbits(out, p14, clct[i4] >> 5 & 127), p14 += clct[i4] >> 12;
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, p14, lm[len + 257]), p14 += ll[len + 257];
45814
+ wbits16(out, p13, lm[len + 257]), p13 += ll[len + 257];
45815
45815
  if (len > 7)
45816
- wbits(out, p14, sym >> 23 & 31), p14 += fleb[len];
45816
+ wbits(out, p13, sym >> 23 & 31), p13 += fleb[len];
45817
45817
  var dst = sym & 31;
45818
- wbits16(out, p14, dm[dst]), p14 += dl[dst];
45818
+ wbits16(out, p13, dm[dst]), p13 += dl[dst];
45819
45819
  if (dst > 3)
45820
- wbits16(out, p14, sym >> 5 & 8191), p14 += fdeb[dst];
45820
+ wbits16(out, p13, sym >> 5 & 8191), p13 += fdeb[dst];
45821
45821
  } else {
45822
- wbits16(out, p14, lm[sym]), p14 += ll[sym];
45822
+ wbits16(out, p13, lm[sym]), p13 += ll[sym];
45823
45823
  }
45824
45824
  }
45825
- wbits16(out, p14, lm[256]);
45826
- return p14 + ll[256];
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 p14 = a4 + b4 - c4;
46800
- const pa = Math.abs(p14 - a4);
46801
- const pb = Math.abs(p14 - b4);
46802
- const pc = Math.abs(p14 - c4);
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, p14 = 30 * a4, q3 = document.createElement("canvas");
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, p14);
48052
+ b4.fillRect(d4, m4, n4, p13);
48053
48053
  b4.fillStyle = l4;
48054
48054
  b4.globalAlpha = 0.9;
48055
- b4.fillRect(d4, m4, n4, p14);
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, p14, d4, m4, n4 - a4, p14);
48065
- b4.fillRect(d4 + n4 - a4, m4, a4, p14);
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) * p14));
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 p14 = 1 / (far - near);
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) * p14;
52452
- zInv = -2 * p14;
52454
+ z4 = (far + near) * p13;
52455
+ zInv = -2 * p13;
52453
52456
  } else if (coordinateSystem === WebGPUCoordinateSystem) {
52454
- z4 = near * p14;
52455
- zInv = -1 * p14;
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(p14, target) {
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(p14, a4);
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(p14, b4);
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(p14, c4);
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(p14, q3, t5) {
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 p14 + (q3 - p14) * 6 * t5;
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 p14 + (q3 - p14) * 6 * (2 / 3 - t5);
53570
- return p14;
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 p14 = l4 <= 0.5 ? l4 * (1 + s4) : l4 + s4 - l4 * s4;
53624
- const q3 = 2 * l4 - p14;
53625
- this.r = hue2rgb(q3, p14, h5 + 1 / 3);
53626
- this.g = hue2rgb(q3, p14, h5);
53627
- this.b = hue2rgb(q3, p14, h5 - 1 / 3);
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 p14 in src[u4]) {
55366
- const property = src[u4][p14];
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][p14] = null;
55373
+ dst[u4][p13] = null;
55371
55374
  } else {
55372
- dst[u4][p14] = property.clone();
55375
+ dst[u4][p13] = property.clone();
55373
55376
  }
55374
55377
  } else if (Array.isArray(property)) {
55375
- dst[u4][p14] = property.slice();
55378
+ dst[u4][p13] = property.slice();
55376
55379
  } else {
55377
- dst[u4][p14] = property;
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 p14 in tmp) {
55388
- merged[p14] = tmp[p14];
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 cached = buffers.get(attribute);
56241
- if (!cached || cached.version < attribute.version) {
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 p14 = 0, pl = programs.length; p14 < pl; p14++) {
60727
- const preexistingProgram = programs[p14];
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(p14, colorSpace = NoColorSpace) {
63441
+ function convert(p13, colorSpace = NoColorSpace) {
63439
63442
  let extension;
63440
63443
  const transfer = ColorManagement.getTransfer(colorSpace);
63441
- if (p14 === UnsignedByteType) return gl.UNSIGNED_BYTE;
63442
- if (p14 === UnsignedShort4444Type) return gl.UNSIGNED_SHORT_4_4_4_4;
63443
- if (p14 === UnsignedShort5551Type) return gl.UNSIGNED_SHORT_5_5_5_1;
63444
- if (p14 === ByteType) return gl.BYTE;
63445
- if (p14 === ShortType) return gl.SHORT;
63446
- if (p14 === UnsignedShortType) return gl.UNSIGNED_SHORT;
63447
- if (p14 === IntType) return gl.INT;
63448
- if (p14 === UnsignedIntType) return gl.UNSIGNED_INT;
63449
- if (p14 === FloatType) return gl.FLOAT;
63450
- if (p14 === HalfFloatType) {
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 (p14 === AlphaFormat) return gl.ALPHA;
63460
- if (p14 === RGBAFormat) return gl.RGBA;
63461
- if (p14 === LuminanceFormat) return gl.LUMINANCE;
63462
- if (p14 === LuminanceAlphaFormat) return gl.LUMINANCE_ALPHA;
63463
- if (p14 === DepthFormat) return gl.DEPTH_COMPONENT;
63464
- if (p14 === DepthStencilFormat) return gl.DEPTH_STENCIL;
63465
- if (p14 === _SRGBAFormat) {
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 (p14 === RedFormat) return gl.RED;
63474
- if (p14 === RedIntegerFormat) return gl.RED_INTEGER;
63475
- if (p14 === RGFormat) return gl.RG;
63476
- if (p14 === RGIntegerFormat) return gl.RG_INTEGER;
63477
- if (p14 === RGBAIntegerFormat) return gl.RGBA_INTEGER;
63478
- if (p14 === RGB_S3TC_DXT1_Format || p14 === RGBA_S3TC_DXT1_Format || p14 === RGBA_S3TC_DXT3_Format || p14 === RGBA_S3TC_DXT5_Format) {
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 (p14 === RGB_S3TC_DXT1_Format) return extension.COMPRESSED_SRGB_S3TC_DXT1_EXT;
63483
- if (p14 === RGBA_S3TC_DXT1_Format) return extension.COMPRESSED_SRGB_ALPHA_S3TC_DXT1_EXT;
63484
- if (p14 === RGBA_S3TC_DXT3_Format) return extension.COMPRESSED_SRGB_ALPHA_S3TC_DXT3_EXT;
63485
- if (p14 === RGBA_S3TC_DXT5_Format) return extension.COMPRESSED_SRGB_ALPHA_S3TC_DXT5_EXT;
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 (p14 === RGB_S3TC_DXT1_Format) return extension.COMPRESSED_RGB_S3TC_DXT1_EXT;
63493
- if (p14 === RGBA_S3TC_DXT1_Format) return extension.COMPRESSED_RGBA_S3TC_DXT1_EXT;
63494
- if (p14 === RGBA_S3TC_DXT3_Format) return extension.COMPRESSED_RGBA_S3TC_DXT3_EXT;
63495
- if (p14 === RGBA_S3TC_DXT5_Format) return extension.COMPRESSED_RGBA_S3TC_DXT5_EXT;
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 (p14 === RGB_PVRTC_4BPPV1_Format || p14 === RGB_PVRTC_2BPPV1_Format || p14 === RGBA_PVRTC_4BPPV1_Format || p14 === RGBA_PVRTC_2BPPV1_Format) {
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 (p14 === RGB_PVRTC_4BPPV1_Format) return extension.COMPRESSED_RGB_PVRTC_4BPPV1_IMG;
63505
- if (p14 === RGB_PVRTC_2BPPV1_Format) return extension.COMPRESSED_RGB_PVRTC_2BPPV1_IMG;
63506
- if (p14 === RGBA_PVRTC_4BPPV1_Format) return extension.COMPRESSED_RGBA_PVRTC_4BPPV1_IMG;
63507
- if (p14 === RGBA_PVRTC_2BPPV1_Format) return extension.COMPRESSED_RGBA_PVRTC_2BPPV1_IMG;
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 (p14 === RGB_ETC1_Format) {
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 (p14 === RGB_ETC2_Format || p14 === RGBA_ETC2_EAC_Format) {
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 (p14 === RGB_ETC2_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ETC2 : extension.COMPRESSED_RGB8_ETC2;
63524
- if (p14 === RGBA_ETC2_EAC_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ETC2_EAC : extension.COMPRESSED_RGBA8_ETC2_EAC;
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 (p14 === RGBA_ASTC_4x4_Format || p14 === RGBA_ASTC_5x4_Format || p14 === RGBA_ASTC_5x5_Format || p14 === RGBA_ASTC_6x5_Format || p14 === RGBA_ASTC_6x6_Format || p14 === RGBA_ASTC_8x5_Format || p14 === RGBA_ASTC_8x6_Format || p14 === RGBA_ASTC_8x8_Format || p14 === RGBA_ASTC_10x5_Format || p14 === RGBA_ASTC_10x6_Format || p14 === RGBA_ASTC_10x8_Format || p14 === RGBA_ASTC_10x10_Format || p14 === RGBA_ASTC_12x10_Format || p14 === RGBA_ASTC_12x12_Format) {
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 (p14 === RGBA_ASTC_4x4_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_4x4_KHR : extension.COMPRESSED_RGBA_ASTC_4x4_KHR;
63533
- if (p14 === RGBA_ASTC_5x4_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_5x4_KHR : extension.COMPRESSED_RGBA_ASTC_5x4_KHR;
63534
- if (p14 === RGBA_ASTC_5x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_5x5_KHR : extension.COMPRESSED_RGBA_ASTC_5x5_KHR;
63535
- if (p14 === RGBA_ASTC_6x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_6x5_KHR : extension.COMPRESSED_RGBA_ASTC_6x5_KHR;
63536
- if (p14 === RGBA_ASTC_6x6_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_6x6_KHR : extension.COMPRESSED_RGBA_ASTC_6x6_KHR;
63537
- if (p14 === RGBA_ASTC_8x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_8x5_KHR : extension.COMPRESSED_RGBA_ASTC_8x5_KHR;
63538
- if (p14 === RGBA_ASTC_8x6_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_8x6_KHR : extension.COMPRESSED_RGBA_ASTC_8x6_KHR;
63539
- if (p14 === RGBA_ASTC_8x8_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_8x8_KHR : extension.COMPRESSED_RGBA_ASTC_8x8_KHR;
63540
- if (p14 === RGBA_ASTC_10x5_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x5_KHR : extension.COMPRESSED_RGBA_ASTC_10x5_KHR;
63541
- if (p14 === RGBA_ASTC_10x6_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x6_KHR : extension.COMPRESSED_RGBA_ASTC_10x6_KHR;
63542
- if (p14 === RGBA_ASTC_10x8_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x8_KHR : extension.COMPRESSED_RGBA_ASTC_10x8_KHR;
63543
- if (p14 === RGBA_ASTC_10x10_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_10x10_KHR : extension.COMPRESSED_RGBA_ASTC_10x10_KHR;
63544
- if (p14 === RGBA_ASTC_12x10_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_12x10_KHR : extension.COMPRESSED_RGBA_ASTC_12x10_KHR;
63545
- if (p14 === RGBA_ASTC_12x12_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB8_ALPHA8_ASTC_12x12_KHR : extension.COMPRESSED_RGBA_ASTC_12x12_KHR;
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 (p14 === RGBA_BPTC_Format || p14 === RGB_BPTC_SIGNED_Format || p14 === RGB_BPTC_UNSIGNED_Format) {
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 (p14 === RGBA_BPTC_Format) return transfer === SRGBTransfer ? extension.COMPRESSED_SRGB_ALPHA_BPTC_UNORM_EXT : extension.COMPRESSED_RGBA_BPTC_UNORM_EXT;
63554
- if (p14 === RGB_BPTC_SIGNED_Format) return extension.COMPRESSED_RGB_BPTC_SIGNED_FLOAT_EXT;
63555
- if (p14 === RGB_BPTC_UNSIGNED_Format) return extension.COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_EXT;
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 (p14 === RED_RGTC1_Format || p14 === SIGNED_RED_RGTC1_Format || p14 === RED_GREEN_RGTC2_Format || p14 === SIGNED_RED_GREEN_RGTC2_Format) {
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 (p14 === RGBA_BPTC_Format) return extension.COMPRESSED_RED_RGTC1_EXT;
63564
- if (p14 === SIGNED_RED_RGTC1_Format) return extension.COMPRESSED_SIGNED_RED_RGTC1_EXT;
63565
- if (p14 === RED_GREEN_RGTC2_Format) return extension.COMPRESSED_RED_GREEN_RGTC2_EXT;
63566
- if (p14 === SIGNED_RED_GREEN_RGTC2_Format) return extension.COMPRESSED_SIGNED_RED_GREEN_RGTC2_EXT;
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 (p14 === UnsignedInt248Type) {
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[p14] !== void 0 ? gl[p14] : null;
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, p14 = (t5 - t0) / (t1 - t0), pp = p14 * p14, ppp = pp * p14;
66999
- const sP = -wP * ppp + 2 * wP * pp - wP * p14;
67000
- const s0 = (1 + wP) * ppp + (-1.5 - 2 * wP) * pp + (-0.5 + wP) * p14 + 1;
67001
- const s1 = (-1 - wN) * ppp + (1.5 + wN) * pp + 0.5 * p14;
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((p14) => p14.promise)).then((resolvedValues) => {
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 cached = Caching.rawImageCache.getIfPresent(keyStr);
69519
+ const cached2 = Caching.rawImageCache.getIfPresent(keyStr);
69517
69520
  try {
69518
69521
  return await this.infoToCanvasData(await info);
69519
69522
  } catch (err2) {
69520
- if (cached && Caching.rawImageCache.getIfPresent(keyStr) === cached) {
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 cached = Caching.textureCache.peek(keyStr);
69655
- if (cached && TextureLoader.hasFailed(cached)) {
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 p14 = [];
69965
+ let p13 = [];
69963
69966
  if (this.type) {
69964
- p14.push(this.type);
69967
+ p13.push(this.type);
69965
69968
  }
69966
- p14.push(this.path);
69967
- return p14.join("/");
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((p14) => `${p14}`);
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(p14) {
71456
- that.pending_buf[that.pending++] = p14;
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 p14;
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
- p14 = n4;
71702
+ p13 = n4;
71700
71703
  do {
71701
- m4 = head[--p14] & 65535;
71702
- head[p14] = m4 >= w_size ? m4 - w_size : 0;
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
- p14 = n4;
71708
+ p13 = n4;
71706
71709
  do {
71707
- m4 = prev[--p14] & 65535;
71708
- prev[p14] = m4 >= w_size ? m4 - w_size : 0;
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 p14;
74112
+ let p13;
74110
74113
  let q3;
74111
74114
  let w4;
74112
74115
  let xp;
74113
74116
  let y5;
74114
74117
  let z4;
74115
- p14 = 0;
74118
+ p13 = 0;
74116
74119
  i4 = n4;
74117
74120
  do {
74118
- c4[b4[bindex + p14]]++;
74119
- p14++;
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
- p14 = 1;
74157
+ p13 = 1;
74155
74158
  xp = 2;
74156
74159
  while (--i4 !== 0) {
74157
- x4[xp] = j4 += c4[p14];
74160
+ x4[xp] = j4 += c4[p13];
74158
74161
  xp++;
74159
- p14++;
74162
+ p13++;
74160
74163
  }
74161
74164
  i4 = 0;
74162
- p14 = 0;
74165
+ p13 = 0;
74163
74166
  do {
74164
- if ((j4 = b4[bindex + p14]) !== 0) {
74167
+ if ((j4 = b4[bindex + p13]) !== 0) {
74165
74168
  v6[x4[j4]++] = i4;
74166
74169
  }
74167
- p14++;
74170
+ p13++;
74168
74171
  } while (++i4 < n4);
74169
74172
  n4 = x4[g4];
74170
74173
  x4[0] = i4 = 0;
74171
- p14 = 0;
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 (p14 >= n4) {
74222
+ if (p13 >= n4) {
74220
74223
  r5[0] = 128 + 64;
74221
- } else if (v6[p14] < s4) {
74224
+ } else if (v6[p13] < s4) {
74222
74225
  r5[0] = /* (byte) */
74223
- v6[p14] < 256 ? 0 : 32 + 64;
74224
- r5[2] = v6[p14++];
74226
+ v6[p13] < 256 ? 0 : 32 + 64;
74227
+ r5[2] = v6[p13++];
74225
74228
  } else {
74226
74229
  r5[0] = /* (byte) */
74227
- e6[v6[p14] - s4] + 16 + 64;
74228
- r5[2] = d4[v6[p14++] - s4];
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 p14;
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
- p14 = z4.next_in_index;
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(p14++) & 255) << k4;
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(p14++) & 255) << k4;
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(p14++) & 255) << k4;
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
- p14 -= c4;
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 += p14 - z4.next_in_index;
74486
- z4.next_in_index = p14;
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
- p14 -= c4;
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 += p14 - z4.next_in_index;
74515
- z4.next_in_index = p14;
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
- p14 -= c4;
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 += p14 - z4.next_in_index;
74529
- z4.next_in_index = p14;
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
- p14 -= c4;
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 += p14 - z4.next_in_index;
74544
- z4.next_in_index = p14;
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 p14 = 0;
74569
+ let p13 = 0;
74567
74570
  let n4;
74568
74571
  let q3;
74569
74572
  let m4;
74570
74573
  let f4;
74571
- p14 = z4.next_in_index;
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 += p14 - z4.next_in_index;
74586
- z4.next_in_index = p14;
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
- p14 = z4.next_in_index;
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 += p14 - z4.next_in_index;
74615
- z4.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z4.next_in_index;
74654
- z4.next_in_index = p14;
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 += p14 - z4.next_in_index;
74667
- z4.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z4.next_in_index;
74693
- z4.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z4.next_in_index;
74723
- z4.next_in_index = p14;
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 += p14 - z4.next_in_index;
74736
- z4.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z4.next_in_index;
74774
- z4.next_in_index = p14;
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 += p14 - z4.next_in_index;
74808
- z4.next_in_index = p14;
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
- p14--;
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 += p14 - z4.next_in_index;
74835
- z4.next_in_index = p14;
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 += p14 - z4.next_in_index;
74847
- z4.next_in_index = p14;
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 += p14 - z4.next_in_index;
74856
- z4.next_in_index = p14;
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 += p14 - z4.next_in_index;
74865
- z4.next_in_index = p14;
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 p14;
74943
+ let p13;
74941
74944
  let q3;
74942
- p14 = z5.next_out_index;
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), p14);
74953
- p14 += n4;
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), p14);
74967
- p14 += n4;
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 = p14;
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 p14;
74981
+ let p13;
74979
74982
  let n4;
74980
74983
  let q3;
74981
74984
  let m4;
74982
74985
  let i4;
74983
- p14 = z5.next_in_index;
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 += p14 - z5.next_in_index;
75002
- z5.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z5.next_in_index;
75048
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75062
- z5.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z5.next_in_index;
75078
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75092
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75118
- z5.next_in_index = p14;
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(p14, t5), q3);
75131
- p14 += t5;
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 += p14 - z5.next_in_index;
75148
- z5.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z5.next_in_index;
75165
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75192
- z5.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z5.next_in_index;
75219
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75242
- z5.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z5.next_in_index;
75267
- z5.next_in_index = p14;
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(p14++) & 255) << k4;
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 += p14 - z5.next_in_index;
75291
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75321
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75333
- z5.next_in_index = p14;
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
- p14 = z5.next_in_index;
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 += p14 - z5.next_in_index;
75364
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75376
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75385
- z5.next_in_index = p14;
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 += p14 - z5.next_in_index;
75394
- z5.next_in_index = p14;
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 p14;
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
- p14 = z4.next_in_index;
75608
+ p13 = z4.next_in_index;
75606
75609
  m4 = istate.marker;
75607
75610
  while (n4 !== 0 && m4 < 4) {
75608
- if (z4.read_byte(p14) == mark[m4]) {
75611
+ if (z4.read_byte(p13) == mark[m4]) {
75609
75612
  m4++;
75610
- } else if (z4.read_byte(p14) !== 0) {
75613
+ } else if (z4.read_byte(p13) !== 0) {
75611
75614
  m4 = 0;
75612
75615
  } else {
75613
75616
  m4 = 4 - m4;
75614
75617
  }
75615
- p14++;
75618
+ p13++;
75616
75619
  n4--;
75617
75620
  }
75618
- z4.total_in += p14 - z4.next_in_index;
75619
- z4.next_in_index = p14;
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 cached = Caching.textureAssetCache.getIfPresent(keyStr);
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 (cached && Caching.textureAssetCache.getIfPresent(keyStr) === cached) {
80298
+ if (cached2 && Caching.textureAssetCache.getIfPresent(keyStr) === cached2) {
80296
80299
  Caching.textureAssetCache.invalidate(keyStr);
80297
80300
  }
80298
80301
  throw err2;
@@ -82358,6 +82361,95 @@ ${key}` : key;
82358
82361
  init_buffer2();
82359
82362
  init_process2();
82360
82363
 
82364
+ // src/model/block/BlockStateResolver.ts
82365
+ init_dirname();
82366
+ init_buffer2();
82367
+ init_process2();
82368
+ function matchesCondition(condition, state) {
82369
+ return Object.entries(condition).every(([key, value]) => {
82370
+ if (Array.isArray(value)) {
82371
+ if (key === "OR") return value.some((child) => matchesCondition(child, state));
82372
+ if (key === "AND") return value.every((child) => matchesCondition(child, state));
82373
+ return false;
82374
+ }
82375
+ return typeof value === "string" && state[key] !== void 0 && value.split("|").includes(`${state[key]}`);
82376
+ });
82377
+ }
82378
+ var BlockStateResolver = class {
82379
+ static async defaults(blockState) {
82380
+ const defaults = blockState.key ? await BlockStates.getDefaultState(blockState.key) : void 0;
82381
+ const state = {};
82382
+ if (defaults && Object.keys(defaults).length > 0) {
82383
+ for (const key in defaults) state[key] = defaults[key].default;
82384
+ } else if (blockState.variants) {
82385
+ const variant = Object.keys(blockState.variants)[0];
82386
+ if (variant) {
82387
+ for (const property of variant.split(",")) {
82388
+ const [key, value] = property.split("=");
82389
+ state[key] = value;
82390
+ }
82391
+ }
82392
+ } else if (blockState.multipart) {
82393
+ const condition = blockState.multipart.map((part) => part.when).find((when) => when !== void 0 && Object.values(when).every((value) => typeof value === "string"));
82394
+ for (const [key, value] of Object.entries(condition ?? {})) state[key] = value.split("|")[0];
82395
+ }
82396
+ return state;
82397
+ }
82398
+ static select(blockState, state, choose = this.choose) {
82399
+ return this.matching(blockState, state).map(choose);
82400
+ }
82401
+ static matching(blockState, state) {
82402
+ const out = [];
82403
+ if (blockState.variants) {
82404
+ if (Object.keys(blockState.variants).length === 1 && "" in blockState.variants) {
82405
+ out.push(blockState.variants[""]);
82406
+ } else {
82407
+ for (const variantKey in blockState.variants) {
82408
+ const matches = variantKey.split(",").every((property) => {
82409
+ const [key, value] = property.split("=");
82410
+ return `${state[key]}` === `${value}`;
82411
+ });
82412
+ if (matches) out.push(blockState.variants[variantKey]);
82413
+ }
82414
+ }
82415
+ } else if (blockState.multipart) {
82416
+ for (const part of blockState.multipart) {
82417
+ if (part.apply && (!part.when || matchesCondition(part.when, state))) {
82418
+ out.push(part.apply);
82419
+ }
82420
+ }
82421
+ }
82422
+ return out;
82423
+ }
82424
+ static choose(variants) {
82425
+ if (!Array.isArray(variants)) return variants;
82426
+ if (!variants.length) throw new MineRenderError("Blockstate variant arrays must not be empty");
82427
+ const total = variants.reduce((sum, variant) => {
82428
+ const weight = variant.weight ?? 1;
82429
+ if (!Number.isInteger(weight) || weight < 1) {
82430
+ throw new MineRenderError(`Invalid blockstate variant weight: ${weight}`);
82431
+ }
82432
+ return sum + weight;
82433
+ }, 0);
82434
+ let choice = Math.random() * total;
82435
+ for (const variant of variants) {
82436
+ choice -= variant.weight ?? 1;
82437
+ if (choice < 0) return variant;
82438
+ }
82439
+ return variants[variants.length - 1];
82440
+ }
82441
+ static rotation(variant) {
82442
+ const rotation = new Euler();
82443
+ if (typeof variant.x !== "undefined") {
82444
+ rotation.x = toRadians(clampRotationDegrees(variant.x));
82445
+ }
82446
+ if (typeof variant.y !== "undefined") {
82447
+ rotation.y = toRadians(clampRotationDegrees(typeof variant.x !== "undefined" ? variant.y : 360 - variant.y));
82448
+ }
82449
+ return rotation;
82450
+ }
82451
+ };
82452
+
82361
82453
  // src/model/block/BlockTints.ts
82362
82454
  init_dirname();
82363
82455
  init_buffer2();
@@ -83142,17 +83234,6 @@ ${key}` : key;
83142
83234
 
83143
83235
  // src/model/block/scene/BlockObject.ts
83144
83236
  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
83237
  var _BlockObject = class _BlockObject extends SceneObject {
83157
83238
  constructor(blockState, options) {
83158
83239
  super(options);
@@ -83171,22 +83252,7 @@ ${key}` : key;
83171
83252
  }
83172
83253
  async init() {
83173
83254
  if (this.options.applyDefaultState) {
83174
- const defaultState = this.blockState.key ? await BlockStates.getDefaultState(this.blockState.key) : void 0;
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
- }
83255
+ this._setState(await BlockStateResolver.defaults(this.blockState));
83190
83256
  }
83191
83257
  if (this.options.initialState !== void 0) this._setState(this.options.initialState);
83192
83258
  await this.recreateModels();
@@ -83277,39 +83343,7 @@ ${key}` : key;
83277
83343
  return ref;
83278
83344
  }
83279
83345
  async mapStateToVariant(state) {
83280
- const out = [];
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;
83346
+ return BlockStateResolver.select(this.blockState, state, (variants) => this.getSingleVariant(variants));
83313
83347
  }
83314
83348
  async recreateModels() {
83315
83349
  this.clearModels();
@@ -83320,21 +83354,7 @@ ${key}` : key;
83320
83354
  }
83321
83355
  }
83322
83356
  getSingleVariant(variants) {
83323
- if (!Array.isArray(variants)) return variants;
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];
83357
+ return BlockStateResolver.choose(variants);
83338
83358
  }
83339
83359
  // @deprecated
83340
83360
  async createAVariant(variants, instanceInfo) {
@@ -83342,13 +83362,7 @@ ${key}` : key;
83342
83362
  await this.createVariant(variant);
83343
83363
  }
83344
83364
  async createVariant(variant) {
83345
- const rotation = new Euler();
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
- }
83365
+ const rotation = BlockStateResolver.rotation(variant);
83352
83366
  const modelKey = AssetKey.parse("models", variant.model);
83353
83367
  modelKey.root = this.blockState.key?.root;
83354
83368
  const model = await Models.getMerged(modelKey);
@@ -88258,8 +88272,8 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
88258
88272
  [bilinear(1, 1, 1, 0), new Float32Array([1, 1, 1, 0])],
88259
88273
  [bilinear(1, 1, 1, 1), new Float32Array([1, 1, 1, 1])]
88260
88274
  ]);
88261
- function lerp2(a4, b4, p14) {
88262
- return a4 + (b4 - a4) * p14;
88275
+ function lerp2(a4, b4, p13) {
88276
+ return a4 + (b4 - a4) * p13;
88263
88277
  }
88264
88278
  function bilinear(e0, e1, e22, e32) {
88265
88279
  const a4 = lerp2(e0, e1, 1 - 0.25);
@@ -89717,11 +89731,102 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89717
89731
  init_dirname();
89718
89732
  init_buffer2();
89719
89733
  init_process2();
89734
+
89735
+ // src/world/SectionModels.ts
89736
+ init_dirname();
89737
+ init_buffer2();
89738
+ init_process2();
89739
+ var SectionModel = class extends ModelObject {
89740
+ applyTextures() {
89741
+ }
89742
+ };
89743
+ function cached(map, key, load) {
89744
+ let value = map.get(key);
89745
+ if (!value) {
89746
+ value = load().catch((error) => {
89747
+ map.delete(key);
89748
+ throw error;
89749
+ });
89750
+ map.set(key, value);
89751
+ }
89752
+ return value;
89753
+ }
89754
+ var SectionModels = class {
89755
+ constructor(maxAtlasSize = 2048) {
89756
+ this.maxAtlasSize = maxAtlasSize;
89757
+ this.states = /* @__PURE__ */ new WeakMap();
89758
+ this.models = /* @__PURE__ */ new WeakMap();
89759
+ this.templates = /* @__PURE__ */ new Set();
89760
+ if (!Number.isInteger(maxAtlasSize) || maxAtlasSize < 1) throw new RangeError("maxAtlasSize must be a positive integer");
89761
+ }
89762
+ async get(blockState, properties = {}) {
89763
+ if (!blockState.variants || blockState.multipart) return void 0;
89764
+ let states = this.states.get(blockState);
89765
+ if (!states) this.states.set(blockState, states = /* @__PURE__ */ new Map());
89766
+ const key = JSON.stringify(Object.entries(properties).sort(([a4], [b4]) => a4.localeCompare(b4)));
89767
+ const prepared = await cached(states, key, () => this.prepare(blockState, properties));
89768
+ if (!prepared) return void 0;
89769
+ return prepared.templates.get(BlockStateResolver.choose(prepared.variants));
89770
+ }
89771
+ async prepare(blockState, properties) {
89772
+ const state = { ...await BlockStateResolver.defaults(blockState), ...properties };
89773
+ const groups = BlockStateResolver.matching(blockState, state);
89774
+ if (groups.length !== 1) return void 0;
89775
+ const variants = groups[0];
89776
+ const choices = Array.isArray(variants) ? variants : [variants];
89777
+ if (!choices.length) return void 0;
89778
+ const templates = /* @__PURE__ */ new Map();
89779
+ for (const variant of choices) {
89780
+ const model = await Models.getMerged(AssetKey.parse("models", variant.model));
89781
+ if (!model) return void 0;
89782
+ const atlas = await UVMapper.getAtlas(model);
89783
+ const rotation = BlockStateResolver.rotation(variant);
89784
+ 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;
89785
+ const tints = await BlockTints.get(blockState.key, state, model);
89786
+ let models = this.models.get(model);
89787
+ if (!models) this.models.set(model, models = /* @__PURE__ */ new Map());
89788
+ const key = JSON.stringify([rotation.x, rotation.y, rotation.z, variant.uvlock, tints]);
89789
+ const template = await cached(models, key, async () => {
89790
+ const object = new SectionModel(model, {
89791
+ instanceMeshes: false,
89792
+ mergeMeshes: false,
89793
+ tints,
89794
+ uvLockRotation: variant.uvlock && (rotation.x !== 0 || rotation.y !== 0) ? [rotation.x, rotation.y, rotation.z] : void 0
89795
+ });
89796
+ await object.init();
89797
+ const geometry = object.children[0].geometry;
89798
+ geometry.applyMatrix4(new Matrix4().makeRotationFromEuler(rotation));
89799
+ object.clear();
89800
+ const cullFaces = CUBE_FACES.map((face) => {
89801
+ const local = CUBE_FACES.findIndex((name2) => name2 === atlas.model.elements[0].faces[face]?.cullface);
89802
+ if (local < 0) return 0;
89803
+ const normal = new Vector3(...CUBE_FACE_OFFSETS[local]).applyEuler(rotation);
89804
+ 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);
89805
+ return 1 << world;
89806
+ });
89807
+ const template2 = { geometry, atlas, cullFaces };
89808
+ this.templates.add(template2);
89809
+ return template2;
89810
+ });
89811
+ templates.set(variant, template);
89812
+ }
89813
+ return { variants, templates };
89814
+ }
89815
+ clear() {
89816
+ for (const template of this.templates) template.geometry.dispose();
89817
+ this.templates.clear();
89818
+ this.states = /* @__PURE__ */ new WeakMap();
89819
+ this.models = /* @__PURE__ */ new WeakMap();
89820
+ }
89821
+ };
89822
+
89823
+ // src/world/MineRenderWorld.ts
89720
89824
  var MineRenderWorld = class {
89721
- constructor(scene) {
89825
+ constructor(scene, options = {}) {
89722
89826
  this._chunks = /* @__PURE__ */ new Map();
89723
89827
  this.pendingCulling = /* @__PURE__ */ new Map();
89724
89828
  this.scene = scene;
89829
+ if (options.sectionMeshing) this.sectionModels = new SectionModels(options.maxAtlasSize);
89725
89830
  }
89726
89831
  getBlockAt(posOrX, y5, z4) {
89727
89832
  if (typeof posOrX == "number") {
@@ -89831,6 +89936,7 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89831
89936
  for (const chunk of chunks) {
89832
89937
  await chunk.dispose();
89833
89938
  }
89939
+ this.sectionModels?.clear();
89834
89940
  }
89835
89941
  updateCulling(positions) {
89836
89942
  for (const pos of positions) {
@@ -89845,17 +89951,22 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89845
89951
  while (this.pendingCulling.size) {
89846
89952
  const batch = [...this.pendingCulling.values()];
89847
89953
  this.pendingCulling.clear();
89954
+ const changed = /* @__PURE__ */ new Set();
89848
89955
  for (const pos of batch) {
89849
- const block = this.getBlockAt(pos)?.object;
89850
- if (!block) continue;
89956
+ const chunk = this.getChunkAt(pos);
89957
+ if (!chunk) continue;
89958
+ changed.add(chunk);
89959
+ if (!chunk.getBlockAt(pos)) continue;
89851
89960
  let mask = 0;
89852
89961
  for (const [face, offset] of CUBE_FACE_OFFSETS.entries()) {
89853
- if (this.getBlockAt(pos.clone().add(new Vector3(...offset)))?.object.isOccluding) {
89962
+ const neighbor = pos.clone().add(new Vector3(...offset));
89963
+ if (this.getChunkAt(neighbor)?.isOccludingAt(neighbor)) {
89854
89964
  mask |= 1 << face;
89855
89965
  }
89856
89966
  }
89857
- await block.setCullMask(mask);
89967
+ await chunk.setCullMaskAt(pos, mask);
89858
89968
  }
89969
+ for (const chunk of changed) chunk.rebuildSectionMesh();
89859
89970
  }
89860
89971
  } finally {
89861
89972
  this.culling = void 0;
@@ -89871,7 +89982,8 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89871
89982
  Math.floor(pos.x / 16),
89872
89983
  Math.floor(pos.y / 16),
89873
89984
  Math.floor(pos.z / 16),
89874
- (positions) => this.updateCulling(positions)
89985
+ (positions) => this.updateCulling(positions),
89986
+ this.sectionModels
89875
89987
  );
89876
89988
  this._chunks.set(key, chunk);
89877
89989
  }
@@ -89907,12 +90019,120 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89907
90019
  }
89908
90020
  };
89909
90021
 
90022
+ // src/world/SectionMesh.ts
90023
+ init_dirname();
90024
+ init_buffer2();
90025
+ init_process2();
90026
+ var SectionMesh = class _SectionMesh extends Group {
90027
+ constructor() {
90028
+ super(...arguments);
90029
+ this.ownedMeshes = [];
90030
+ }
90031
+ static build(entries, maxAtlasSize = 2048) {
90032
+ if (!Number.isInteger(maxAtlasSize) || maxAtlasSize < 1) throw new RangeError("Section atlas size must be a positive integer");
90033
+ const visible = entries.filter((entry) => entry.template.cullFaces.some((direction) => !(entry.cullMask & direction)));
90034
+ const atlases = [...new Set(visible.map((entry) => entry.template.atlas))].sort((a4, b4) => b4.image.height - a4.image.height);
90035
+ const pages = [];
90036
+ const locations = /* @__PURE__ */ new Map();
90037
+ for (const atlas of atlases) {
90038
+ const { width, height } = atlas.image;
90039
+ if (width > maxAtlasSize || height > maxAtlasSize) throw new RangeError("Model atlas exceeds the section atlas size limit");
90040
+ let selected;
90041
+ for (const page of pages) {
90042
+ const nextRow = page.x + width > maxAtlasSize;
90043
+ if ((nextRow ? page.y + page.rowHeight : page.y) + height > maxAtlasSize) continue;
90044
+ if (nextRow) {
90045
+ page.y += page.rowHeight;
90046
+ page.x = 0;
90047
+ page.rowHeight = 0;
90048
+ }
90049
+ selected = page;
90050
+ break;
90051
+ }
90052
+ if (!selected) {
90053
+ selected = { placements: [], entries: [], x: 0, y: 0, rowHeight: 0, width: 0, height: 0 };
90054
+ pages.push(selected);
90055
+ }
90056
+ const placement = { atlas, x: selected.x, y: selected.y };
90057
+ selected.placements.push(placement);
90058
+ selected.x += width;
90059
+ selected.rowHeight = Math.max(selected.rowHeight, height);
90060
+ selected.width = Math.max(selected.width, selected.x);
90061
+ selected.height = Math.max(selected.height, selected.y + height);
90062
+ locations.set(atlas, { page: selected, placement });
90063
+ }
90064
+ for (const entry of visible) locations.get(entry.template.atlas).page.entries.push(entry);
90065
+ const section = new _SectionMesh();
90066
+ for (const page of pages) {
90067
+ const canvas = createCanvas(page.width, page.height);
90068
+ const context = canvas.getContext("2d");
90069
+ for (const { atlas, x: x4, y: y5 } of page.placements) {
90070
+ context.drawImage(atlas.image.canvas, x4, y5);
90071
+ }
90072
+ const positions = [], normals = [], uvs = [], colors = [], indices = [];
90073
+ for (const { index, template, cullMask } of page.entries) {
90074
+ const position = template.geometry.getAttribute("position");
90075
+ const normal = template.geometry.getAttribute("normal");
90076
+ const uv = template.geometry.getAttribute("uv");
90077
+ const color2 = template.geometry.getAttribute("color");
90078
+ const sourceIndices = template.geometry.getIndex();
90079
+ const placement = locations.get(template.atlas).placement;
90080
+ const offsetX = index % 16 * 16;
90081
+ const offsetY = Math.floor(index / 256) * 16;
90082
+ const offsetZ = Math.floor(index / 16) % 16 * 16;
90083
+ for (let face = 0; face < 6; face++) {
90084
+ if (cullMask & template.cullFaces[face]) continue;
90085
+ const start = positions.length / 3;
90086
+ for (let corner = 0; corner < 4; corner++) {
90087
+ const vertex2 = face * 4 + corner;
90088
+ positions.push(position.getX(vertex2) + offsetX, position.getY(vertex2) + offsetY, position.getZ(vertex2) + offsetZ);
90089
+ normals.push(normal.getX(vertex2), normal.getY(vertex2), normal.getZ(vertex2));
90090
+ uvs.push(
90091
+ (placement.x + uv.getX(vertex2) * template.atlas.image.width) / page.width,
90092
+ 1 - (placement.y + (1 - uv.getY(vertex2)) * template.atlas.image.height) / page.height
90093
+ );
90094
+ colors.push(color2?.getX(vertex2) ?? 1, color2?.getY(vertex2) ?? 1, color2?.getZ(vertex2) ?? 1);
90095
+ }
90096
+ for (let corner = 0; corner < 6; corner++) indices.push(start + sourceIndices.getX(face * 6 + corner) - face * 4);
90097
+ }
90098
+ }
90099
+ const geometry = new BufferGeometry();
90100
+ geometry.setAttribute("position", new Float32BufferAttribute(positions, 3));
90101
+ geometry.setAttribute("normal", new Float32BufferAttribute(normals, 3));
90102
+ geometry.setAttribute("uv", new Float32BufferAttribute(uvs, 2));
90103
+ geometry.setAttribute("color", new Float32BufferAttribute(colors, 3));
90104
+ geometry.setIndex(indices);
90105
+ geometry.computeBoundingBox();
90106
+ geometry.computeBoundingSphere();
90107
+ const material = Materials.createShadedCanvasMaterial(canvas, false);
90108
+ material.vertexColors = true;
90109
+ const texture = material.uniforms?.map?.value ?? material.map;
90110
+ const mesh = new Mesh(geometry, material);
90111
+ section.add(mesh);
90112
+ section.ownedMeshes.push({ mesh, texture });
90113
+ }
90114
+ return section;
90115
+ }
90116
+ dispose() {
90117
+ for (const { mesh, texture } of this.ownedMeshes.splice(0)) {
90118
+ mesh.removeFromParent();
90119
+ mesh.geometry.dispose();
90120
+ mesh.material.dispose();
90121
+ texture?.dispose();
90122
+ }
90123
+ this.removeFromParent();
90124
+ }
90125
+ };
90126
+
89910
90127
  // src/world/Chunk.ts
89911
90128
  var Chunk = class _Chunk {
89912
- constructor(scene, x4, y5, z4, onBlocksChanged) {
90129
+ constructor(scene, x4, y5, z4, onBlocksChanged, sectionModels) {
89913
90130
  this.onBlocksChanged = onBlocksChanged;
90131
+ this.sectionModels = sectionModels;
89914
90132
  this.data = new ChunkData();
89915
90133
  this.renderedBlocks = /* @__PURE__ */ new Map();
90134
+ this.sectionBlocks = /* @__PURE__ */ new Map();
90135
+ this.meshDirty = false;
89916
90136
  this.scene = scene;
89917
90137
  this.x = x4;
89918
90138
  this.y = y5;
@@ -89951,7 +90171,8 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89951
90171
  const index = _Chunk.chunkPosToBlockIndex(pos);
89952
90172
  this.data.set(index, block);
89953
90173
  const readBlock = this.data.snapshot(index);
89954
- this.renderedBlocks.get(index)?.object.removeFromScene();
90174
+ this.renderedBlocks.get(index)?.object?.removeFromScene();
90175
+ if (this.sectionBlocks.delete(index)) this.meshDirty = true;
89955
90176
  this.renderedBlocks.delete(index);
89956
90177
  let object;
89957
90178
  try {
@@ -89962,13 +90183,19 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89962
90183
  this.data.set(index, void 0);
89963
90184
  return void 0;
89964
90185
  }
89965
- object = await this.scene.addBlock(blockState, {
89966
- mergeMeshes: true,
89967
- instanceMeshes: true,
89968
- maxInstanceCount: 2e3,
89969
- initialState: stored.properties
89970
- });
89971
- object.setPosition(MineRenderWorld.worldToScenePosition(worldPos));
90186
+ const template = await this.sectionModels?.get(blockState, stored.properties);
90187
+ if (template) {
90188
+ this.sectionBlocks.set(index, { index, template, cullMask: 0 });
90189
+ this.meshDirty = true;
90190
+ } else {
90191
+ object = await this.scene.addBlock(blockState, {
90192
+ mergeMeshes: true,
90193
+ instanceMeshes: true,
90194
+ maxInstanceCount: 2e3,
90195
+ initialState: stored.properties
90196
+ });
90197
+ object.setPosition(MineRenderWorld.worldToScenePosition(worldPos));
90198
+ }
89972
90199
  const info = { get block() {
89973
90200
  return readBlock();
89974
90201
  }, object };
@@ -89982,11 +90209,43 @@ uniform float opacity;varying vec2 vUv;void main(){vec4 texel=texture2D(inputBuf
89982
90209
  await onBlocksChanged?.([worldPos]);
89983
90210
  }
89984
90211
  }
90212
+ isOccludingAt(pos) {
90213
+ const index = _Chunk.chunkPosToBlockIndex(this.worldPosToChunkPos(pos));
90214
+ return this.sectionBlocks.has(index) || (this.renderedBlocks.get(index)?.object?.isOccluding ?? false);
90215
+ }
90216
+ async setCullMaskAt(pos, mask) {
90217
+ const index = _Chunk.chunkPosToBlockIndex(this.worldPosToChunkPos(pos));
90218
+ const entry = this.sectionBlocks.get(index);
90219
+ if (entry) {
90220
+ if (entry.cullMask !== mask) {
90221
+ entry.cullMask = mask;
90222
+ this.meshDirty = true;
90223
+ }
90224
+ } else {
90225
+ await this.renderedBlocks.get(index)?.object?.setCullMask(mask);
90226
+ }
90227
+ }
90228
+ rebuildSectionMesh() {
90229
+ if (!this.meshDirty) return;
90230
+ const next = this.sectionBlocks.size ? SectionMesh.build([...this.sectionBlocks.values()], this.sectionModels.maxAtlasSize) : void 0;
90231
+ this.sectionMesh?.dispose();
90232
+ this.sectionMesh = next;
90233
+ if (next) {
90234
+ next.position.set(this.x * 256, this.y * 256, this.z * 256);
90235
+ this.scene.add(next);
90236
+ }
90237
+ this.scene.dirty = true;
90238
+ this.meshDirty = false;
90239
+ }
89985
90240
  async clear(onBlocksChanged = this.onBlocksChanged) {
89986
90241
  const positions = [...this.renderedBlocks.keys()].map((index) => this.chunkPosToWorldPos(
89987
90242
  new Vector3(index % 16, Math.floor(index / 256), Math.floor(index / 16) % 16)
89988
90243
  ));
89989
- for (const info of this.renderedBlocks.values()) info.object.removeFromScene();
90244
+ for (const info of this.renderedBlocks.values()) info.object?.removeFromScene();
90245
+ this.sectionBlocks.clear();
90246
+ this.sectionMesh?.dispose();
90247
+ this.sectionMesh = void 0;
90248
+ this.meshDirty = false;
89990
90249
  this.renderedBlocks.clear();
89991
90250
  this.data.clear();
89992
90251
  await onBlocksChanged?.(positions);