@zhangqingcq/vgce 0.1.29 → 0.1.30

Sign up to get free protection for your applications and to get access to all the features.
package/dist/vgce.js CHANGED
@@ -5549,8 +5549,8 @@ function parseRichText(i, r) {
5549
5549
  }
5550
5550
  d < i.length && pushTokens(n, i.substring(d, i.length), r, c);
5551
5551
  var _ = [], v = 0, g = 0, y = r.padding, b = u === "truncate", A = r.lineOverflow === "truncate";
5552
- function w(Fe, Ve, Lt) {
5553
- Fe.width = Ve, Fe.lineHeight = Lt, v += Lt, g = Math.max(g, Ve);
5552
+ function w(Fe, Oe, Lt) {
5553
+ Fe.width = Oe, Fe.lineHeight = Lt, v += Lt, g = Math.max(g, Oe);
5554
5554
  }
5555
5555
  e:
5556
5556
  for (var S = 0; S < n.lines.length; S++) {
@@ -6032,17 +6032,17 @@ var PathProxy = function() {
6032
6032
  break;
6033
6033
  }
6034
6034
  case CMD$2.C: {
6035
- var _e = o[M++], ue = o[M++], Ie = o[M++], ze = o[M++], Fe = o[M++], Ve = o[M++];
6035
+ var _e = o[M++], ue = o[M++], Ie = o[M++], ze = o[M++], Fe = o[M++], Oe = o[M++];
6036
6036
  if (y) {
6037
6037
  var D = b[S++];
6038
6038
  if (w + D > T) {
6039
6039
  var re = (T - w) / D;
6040
- cubicSubdivide(p, _e, Ie, Fe, re, tmpOutX), cubicSubdivide(_, ue, ze, Ve, re, tmpOutY), r.bezierCurveTo(tmpOutX[1], tmpOutY[1], tmpOutX[2], tmpOutY[2], tmpOutX[3], tmpOutY[3]);
6040
+ cubicSubdivide(p, _e, Ie, Fe, re, tmpOutX), cubicSubdivide(_, ue, ze, Oe, re, tmpOutY), r.bezierCurveTo(tmpOutX[1], tmpOutY[1], tmpOutX[2], tmpOutY[2], tmpOutX[3], tmpOutY[3]);
6041
6041
  break e;
6042
6042
  }
6043
6043
  w += D;
6044
6044
  }
6045
- r.bezierCurveTo(_e, ue, Ie, ze, Fe, Ve), p = Fe, _ = Ve;
6045
+ r.bezierCurveTo(_e, ue, Ie, ze, Fe, Oe), p = Fe, _ = Oe;
6046
6046
  break;
6047
6047
  }
6048
6048
  case CMD$2.Q: {
@@ -6060,12 +6060,12 @@ var PathProxy = function() {
6060
6060
  break;
6061
6061
  }
6062
6062
  case CMD$2.A:
6063
- var Lt = o[M++], pe = o[M++], Cn = o[M++], In = o[M++], Dt = o[M++], de = o[M++], Et = o[M++], hn = !o[M++], vn = Cn > In ? Cn : In, kt = mathAbs$1(Cn - In) > 1e-3, Ce = Dt + de, he = !1;
6063
+ var Lt = o[M++], pe = o[M++], Cn = o[M++], In = o[M++], Dt = o[M++], he = o[M++], Et = o[M++], hn = !o[M++], vn = Cn > In ? Cn : In, kt = mathAbs$1(Cn - In) > 1e-3, Ce = Dt + he, de = !1;
6064
6064
  if (y) {
6065
6065
  var D = b[S++];
6066
- w + D > T && (Ce = Dt + de * (T - w) / D, he = !0), w += D;
6066
+ w + D > T && (Ce = Dt + he * (T - w) / D, de = !0), w += D;
6067
6067
  }
6068
- if (kt && r.ellipse ? r.ellipse(Lt, pe, Cn, In, Et, Dt, Ce, hn) : r.arc(Lt, pe, vn, Dt, Ce, hn), he)
6068
+ if (kt && r.ellipse ? r.ellipse(Lt, pe, Cn, In, Et, Dt, Ce, hn) : r.arc(Lt, pe, vn, Dt, Ce, hn), de)
6069
6069
  break e;
6070
6070
  ie && (d = mathCos$3(Dt) * Cn + Lt, f = mathSin$3(Dt) * In + pe), p = mathCos$3(Ce) * Cn + Lt, _ = mathSin$3(Ce) * In + pe;
6071
6071
  break;
@@ -6075,8 +6075,8 @@ var PathProxy = function() {
6075
6075
  if (y) {
6076
6076
  var D = b[S++];
6077
6077
  if (w + D > T) {
6078
- var Oe = T - w;
6079
- r.moveTo(v, g), r.lineTo(v + mathMin$2(Oe, Ue), g), Oe -= Ue, Oe > 0 && r.lineTo(v + Ue, g + mathMin$2(Oe, Ne)), Oe -= Ne, Oe > 0 && r.lineTo(v + mathMax$2(Ue - Oe, 0), g + Ne), Oe -= Ue, Oe > 0 && r.lineTo(v, g + mathMax$2(Ne - Oe, 0));
6078
+ var Ve = T - w;
6079
+ r.moveTo(v, g), r.lineTo(v + mathMin$2(Ve, Ue), g), Ve -= Ue, Ve > 0 && r.lineTo(v + Ue, g + mathMin$2(Ve, Ne)), Ve -= Ne, Ve > 0 && r.lineTo(v + mathMax$2(Ue - Ve, 0), g + Ne), Ve -= Ue, Ve > 0 && r.lineTo(v, g + mathMax$2(Ne - Ve, 0));
6080
6080
  break e;
6081
6081
  }
6082
6082
  w += D;
@@ -7445,31 +7445,31 @@ function buildPath$1(i, r) {
7445
7445
  else if (y > PI2$2 - e)
7446
7446
  i.moveTo(_ + o * mathCos$1(f), v + o * mathSin$1(f)), i.arc(_, v, o, f, p, !g), a > e && (i.moveTo(_ + a * mathCos$1(p), v + a * mathSin$1(p)), i.arc(_, v, a, p, f, g));
7447
7447
  else {
7448
- var A = void 0, w = void 0, S = void 0, T = void 0, x = void 0, L = void 0, O = void 0, M = void 0, k = void 0, ie = void 0, $ = void 0, Y = void 0, D = void 0, re = void 0, F = void 0, _e = void 0, ue = o * mathCos$1(f), Ie = o * mathSin$1(f), ze = a * mathCos$1(p), Fe = a * mathSin$1(p), Ve = y > e;
7449
- if (Ve) {
7448
+ var A = void 0, w = void 0, S = void 0, T = void 0, x = void 0, L = void 0, O = void 0, M = void 0, k = void 0, ie = void 0, $ = void 0, Y = void 0, D = void 0, re = void 0, F = void 0, _e = void 0, ue = o * mathCos$1(f), Ie = o * mathSin$1(f), ze = a * mathCos$1(p), Fe = a * mathSin$1(p), Oe = y > e;
7449
+ if (Oe) {
7450
7450
  var Lt = r.cornerRadius;
7451
7451
  Lt && (n = normalizeCornerRadius(Lt), A = n[0], w = n[1], S = n[2], T = n[3]);
7452
7452
  var pe = mathAbs(o - a) / 2;
7453
7453
  if (x = mathMin$1(pe, S), L = mathMin$1(pe, T), O = mathMin$1(pe, A), M = mathMin$1(pe, w), $ = k = mathMax$1(x, L), Y = ie = mathMax$1(O, M), (k > e || ie > e) && (D = o * mathCos$1(p), re = o * mathSin$1(p), F = a * mathCos$1(f), _e = a * mathSin$1(f), y < PI$3)) {
7454
7454
  var Cn = intersect(ue, Ie, F, _e, D, re, ze, Fe);
7455
7455
  if (Cn) {
7456
- var In = ue - Cn[0], Dt = Ie - Cn[1], de = D - Cn[0], Et = re - Cn[1], hn = 1 / mathSin$1(mathACos((In * de + Dt * Et) / (mathSqrt(In * In + Dt * Dt) * mathSqrt(de * de + Et * Et))) / 2), vn = mathSqrt(Cn[0] * Cn[0] + Cn[1] * Cn[1]);
7456
+ var In = ue - Cn[0], Dt = Ie - Cn[1], he = D - Cn[0], Et = re - Cn[1], hn = 1 / mathSin$1(mathACos((In * he + Dt * Et) / (mathSqrt(In * In + Dt * Dt) * mathSqrt(he * he + Et * Et))) / 2), vn = mathSqrt(Cn[0] * Cn[0] + Cn[1] * Cn[1]);
7457
7457
  $ = mathMin$1(k, (o - vn) / (hn + 1)), Y = mathMin$1(ie, (a - vn) / (hn - 1));
7458
7458
  }
7459
7459
  }
7460
7460
  }
7461
- if (!Ve)
7461
+ if (!Oe)
7462
7462
  i.moveTo(_ + ue, v + Ie);
7463
7463
  else if ($ > e) {
7464
- var kt = mathMin$1(S, $), Ce = mathMin$1(T, $), he = computeCornerTangents(F, _e, ue, Ie, o, kt, g), Ue = computeCornerTangents(D, re, ze, Fe, o, Ce, g);
7465
- i.moveTo(_ + he.cx + he.x0, v + he.cy + he.y0), $ < k && kt === Ce ? i.arc(_ + he.cx, v + he.cy, $, mathATan2(he.y0, he.x0), mathATan2(Ue.y0, Ue.x0), !g) : (kt > 0 && i.arc(_ + he.cx, v + he.cy, kt, mathATan2(he.y0, he.x0), mathATan2(he.y1, he.x1), !g), i.arc(_, v, o, mathATan2(he.cy + he.y1, he.cx + he.x1), mathATan2(Ue.cy + Ue.y1, Ue.cx + Ue.x1), !g), Ce > 0 && i.arc(_ + Ue.cx, v + Ue.cy, Ce, mathATan2(Ue.y1, Ue.x1), mathATan2(Ue.y0, Ue.x0), !g));
7464
+ var kt = mathMin$1(S, $), Ce = mathMin$1(T, $), de = computeCornerTangents(F, _e, ue, Ie, o, kt, g), Ue = computeCornerTangents(D, re, ze, Fe, o, Ce, g);
7465
+ i.moveTo(_ + de.cx + de.x0, v + de.cy + de.y0), $ < k && kt === Ce ? i.arc(_ + de.cx, v + de.cy, $, mathATan2(de.y0, de.x0), mathATan2(Ue.y0, Ue.x0), !g) : (kt > 0 && i.arc(_ + de.cx, v + de.cy, kt, mathATan2(de.y0, de.x0), mathATan2(de.y1, de.x1), !g), i.arc(_, v, o, mathATan2(de.cy + de.y1, de.cx + de.x1), mathATan2(Ue.cy + Ue.y1, Ue.cx + Ue.x1), !g), Ce > 0 && i.arc(_ + Ue.cx, v + Ue.cy, Ce, mathATan2(Ue.y1, Ue.x1), mathATan2(Ue.y0, Ue.x0), !g));
7466
7466
  } else
7467
7467
  i.moveTo(_ + ue, v + Ie), i.arc(_, v, o, f, p, !g);
7468
- if (!(a > e) || !Ve)
7468
+ if (!(a > e) || !Oe)
7469
7469
  i.lineTo(_ + ze, v + Fe);
7470
7470
  else if (Y > e) {
7471
- var kt = mathMin$1(A, Y), Ce = mathMin$1(w, Y), he = computeCornerTangents(ze, Fe, D, re, a, -Ce, g), Ue = computeCornerTangents(ue, Ie, F, _e, a, -kt, g);
7472
- i.lineTo(_ + he.cx + he.x0, v + he.cy + he.y0), Y < ie && kt === Ce ? i.arc(_ + he.cx, v + he.cy, Y, mathATan2(he.y0, he.x0), mathATan2(Ue.y0, Ue.x0), !g) : (Ce > 0 && i.arc(_ + he.cx, v + he.cy, Ce, mathATan2(he.y0, he.x0), mathATan2(he.y1, he.x1), !g), i.arc(_, v, a, mathATan2(he.cy + he.y1, he.cx + he.x1), mathATan2(Ue.cy + Ue.y1, Ue.cx + Ue.x1), g), kt > 0 && i.arc(_ + Ue.cx, v + Ue.cy, kt, mathATan2(Ue.y1, Ue.x1), mathATan2(Ue.y0, Ue.x0), !g));
7471
+ var kt = mathMin$1(A, Y), Ce = mathMin$1(w, Y), de = computeCornerTangents(ze, Fe, D, re, a, -Ce, g), Ue = computeCornerTangents(ue, Ie, F, _e, a, -kt, g);
7472
+ i.lineTo(_ + de.cx + de.x0, v + de.cy + de.y0), Y < ie && kt === Ce ? i.arc(_ + de.cx, v + de.cy, Y, mathATan2(de.y0, de.x0), mathATan2(Ue.y0, Ue.x0), !g) : (Ce > 0 && i.arc(_ + de.cx, v + de.cy, Ce, mathATan2(de.y0, de.x0), mathATan2(de.y1, de.x1), !g), i.arc(_, v, a, mathATan2(de.cy + de.y1, de.cx + de.x1), mathATan2(Ue.cy + Ue.y1, Ue.cx + Ue.x1), g), kt > 0 && i.arc(_ + Ue.cx, v + Ue.cy, kt, mathATan2(Ue.y1, Ue.x1), mathATan2(Ue.y0, Ue.x0), !g));
7473
7473
  } else
7474
7474
  i.lineTo(_ + ze, v + Fe), i.arc(_, v, a, p, f, g);
7475
7475
  }
@@ -13024,23 +13024,23 @@ function createOrUpdatePatternFromDecal(i, r) {
13024
13024
  return;
13025
13025
  for (var F = -L, _e = 0, ue = 0, Ie = 0; F < k.height; ) {
13026
13026
  if (_e % 2 === 0) {
13027
- for (var ze = ue / 2 % T.length, Fe = 0, Ve = 0, Lt = 0; Fe < k.width * 2; ) {
13027
+ for (var ze = ue / 2 % T.length, Fe = 0, Oe = 0, Lt = 0; Fe < k.width * 2; ) {
13028
13028
  for (var pe = 0, re = 0; re < w[Ie].length; ++re)
13029
13029
  pe += w[Ie][re];
13030
13030
  if (pe <= 0)
13031
13031
  break;
13032
- if (Ve % 2 === 0) {
13033
- var Cn = (1 - c.symbolSize) * 0.5, In = Fe + w[Ie][Ve] * Cn, Dt = F + S[_e] * Cn, de = w[Ie][Ve] * c.symbolSize, Et = S[_e] * c.symbolSize, hn = Lt / 2 % T[ze].length;
13034
- vn(In, Dt, de, Et, T[ze][hn]);
13032
+ if (Oe % 2 === 0) {
13033
+ var Cn = (1 - c.symbolSize) * 0.5, In = Fe + w[Ie][Oe] * Cn, Dt = F + S[_e] * Cn, he = w[Ie][Oe] * c.symbolSize, Et = S[_e] * c.symbolSize, hn = Lt / 2 % T[ze].length;
13034
+ vn(In, Dt, he, Et, T[ze][hn]);
13035
13035
  }
13036
- Fe += w[Ie][Ve], ++Lt, ++Ve, Ve === w[Ie].length && (Ve = 0);
13036
+ Fe += w[Ie][Oe], ++Lt, ++Oe, Oe === w[Ie].length && (Oe = 0);
13037
13037
  }
13038
13038
  ++Ie, Ie === w.length && (Ie = 0);
13039
13039
  }
13040
13040
  F += S[_e], ++ue, ++_e, _e === S.length && (_e = 0);
13041
13041
  }
13042
- function vn(kt, Ce, he, Ue, Ne) {
13043
- var Oe = a ? 1 : n, Pt = createSymbol(Ne, kt * Oe, Ce * Oe, he * Oe, Ue * Oe, c.color, c.symbolKeepAspect);
13042
+ function vn(kt, Ce, de, Ue, Ne) {
13043
+ var Ve = a ? 1 : n, Pt = createSymbol(Ne, kt * Ve, Ce * Ve, de * Ve, Ue * Ve, c.color, c.symbolKeepAspect);
13044
13044
  if (a) {
13045
13045
  var jt = o.painter.renderOneToVNode(Pt);
13046
13046
  jt && M.children.push(jt);
@@ -14691,14 +14691,14 @@ function prepareSeriesDataSchema(i, r) {
14691
14691
  A < c && ue.push(A++);
14692
14692
  }
14693
14693
  each$4(ue, function(ze, Fe) {
14694
- var Ve = b(ze);
14695
- if (f && F.type != null && (Ve.type = F.type), w(defaults(Ve, F), Y, Fe), Ve.name == null && D) {
14694
+ var Oe = b(ze);
14695
+ if (f && F.type != null && (Oe.type = F.type), w(defaults(Oe, F), Y, Fe), Oe.name == null && D) {
14696
14696
  var Lt = D[Fe];
14697
14697
  !isObject$3(Lt) && (Lt = {
14698
14698
  name: Lt
14699
- }), Ve.name = Ve.displayName = Lt.name, Ve.defaultTooltip = Lt.defaultTooltip;
14699
+ }), Oe.name = Oe.displayName = Lt.name, Oe.defaultTooltip = Lt.defaultTooltip;
14700
14700
  }
14701
- re && defaults(Ve.otherDims, re);
14701
+ re && defaults(Oe.otherDims, re);
14702
14702
  });
14703
14703
  }
14704
14704
  });
@@ -15311,10 +15311,10 @@ function createCSSAnimation(i, r, n, o) {
15311
15311
  function A(T) {
15312
15312
  var x = T[1], L = x.length, O = {}, M = {}, k = {}, ie = "animation-timing-function";
15313
15313
  function $(vn, kt, Ce) {
15314
- for (var he = vn.getTracks(), Ue = vn.getMaxTime(), Ne = 0; Ne < he.length; Ne++) {
15315
- var Oe = he[Ne];
15316
- if (Oe.needsAnimate()) {
15317
- var Pt = Oe.keyframes, jt = Oe.propName;
15314
+ for (var de = vn.getTracks(), Ue = vn.getMaxTime(), Ne = 0; Ne < de.length; Ne++) {
15315
+ var Ve = de[Ne];
15316
+ if (Ve.needsAnimate()) {
15317
+ var Pt = Ve.keyframes, jt = Ve.propName;
15318
15318
  if (Ce && (jt = Ce(jt)), jt)
15319
15319
  for (var _n = 0; _n < Pt.length; _n++) {
15320
15320
  var oe = Pt[_n], le = Math.round(oe.time / Ue * 100) + "%", j = getEasingFunc(oe.easing), V = oe.rawValue;
@@ -15338,12 +15338,12 @@ function createCSSAnimation(i, r, n, o) {
15338
15338
  var ze, Fe = !0;
15339
15339
  for (var F in M) {
15340
15340
  k[F] = k[F] || {};
15341
- var Ve = !ze, Ie = M[F][ie];
15342
- Ve && (ze = new PathProxy());
15341
+ var Oe = !ze, Ie = M[F][ie];
15342
+ Oe && (ze = new PathProxy());
15343
15343
  var Lt = ze.len();
15344
15344
  ze.reset(), k[F].d = buildPathString(i, M[F], ze);
15345
15345
  var pe = ze.len();
15346
- if (!Ve && Lt !== pe) {
15346
+ if (!Oe && Lt !== pe) {
15347
15347
  Fe = !1;
15348
15348
  break;
15349
15349
  }
@@ -15355,17 +15355,17 @@ function createCSSAnimation(i, r, n, o) {
15355
15355
  if (!o)
15356
15356
  for (var Y = 0; Y < L; Y++) {
15357
15357
  var D = x[Y], re = D.targetName;
15358
- re === "style" && $(D, k, function(he) {
15359
- return ANIMATE_STYLE_MAP[he];
15358
+ re === "style" && $(D, k, function(de) {
15359
+ return ANIMATE_STYLE_MAP[de];
15360
15360
  });
15361
15361
  }
15362
15362
  for (var Cn = keys(k), In = !0, Dt, Y = 1; Y < Cn.length; Y++) {
15363
- var de = Cn[Y - 1], Et = Cn[Y];
15364
- if (k[de][transformOriginKey] !== k[Et][transformOriginKey]) {
15363
+ var he = Cn[Y - 1], Et = Cn[Y];
15364
+ if (k[he][transformOriginKey] !== k[Et][transformOriginKey]) {
15365
15365
  In = !1;
15366
15366
  break;
15367
15367
  }
15368
- Dt = k[de][transformOriginKey];
15368
+ Dt = k[he][transformOriginKey];
15369
15369
  }
15370
15370
  if (In && Dt) {
15371
15371
  for (var F in k)
@@ -15929,7 +15929,7 @@ function pieLayout(i, r, n) {
15929
15929
  viewRect: c,
15930
15930
  r: _
15931
15931
  }), a.each(u, function(ze, Fe) {
15932
- var Ve;
15932
+ var Oe;
15933
15933
  if (isNaN(ze)) {
15934
15934
  a.setItemLayout(Fe, {
15935
15935
  angle: NaN,
@@ -15943,10 +15943,10 @@ function pieLayout(i, r, n) {
15943
15943
  });
15944
15944
  return;
15945
15945
  }
15946
- O !== "area" ? Ve = T === 0 && M ? x : ze * x : Ve = re / S, Ve < w ? (Ve = w, F -= w) : _e += ze;
15947
- var Lt = ue + ie * Ve, pe = 0, Cn = 0;
15948
- b > Ve ? (pe = ue + ie * Ve / 2, Cn = pe) : (pe = ue + Y, Cn = Lt - Y), a.setItemLayout(Fe, {
15949
- angle: Ve,
15946
+ O !== "area" ? Oe = T === 0 && M ? x : ze * x : Oe = re / S, Oe < w ? (Oe = w, F -= w) : _e += ze;
15947
+ var Lt = ue + ie * Oe, pe = 0, Cn = 0;
15948
+ b > Oe ? (pe = ue + ie * Oe / 2, Cn = pe) : (pe = ue + Y, Cn = Lt - Y), a.setItemLayout(Fe, {
15949
+ angle: Oe,
15950
15950
  startAngle: pe,
15951
15951
  endAngle: Cn,
15952
15952
  clockwise: L,
@@ -15960,17 +15960,17 @@ function pieLayout(i, r, n) {
15960
15960
  var Ie = re / S;
15961
15961
  a.each(u, function(ze, Fe) {
15962
15962
  if (!isNaN(ze)) {
15963
- var Ve = a.getItemLayout(Fe);
15964
- Ve.angle = Ie;
15963
+ var Oe = a.getItemLayout(Fe);
15964
+ Oe.angle = Ie;
15965
15965
  var Lt = 0, pe = 0;
15966
- Ie < b ? (Lt = g + ie * (Fe + 1 / 2) * Ie, pe = Lt) : (Lt = g + ie * Fe * Ie + Y, pe = g + ie * (Fe + 1) * Ie - Y), Ve.startAngle = Lt, Ve.endAngle = pe;
15966
+ Ie < b ? (Lt = g + ie * (Fe + 1 / 2) * Ie, pe = Lt) : (Lt = g + ie * Fe * Ie + Y, pe = g + ie * (Fe + 1) * Ie - Y), Oe.startAngle = Lt, Oe.endAngle = pe;
15967
15967
  }
15968
15968
  });
15969
15969
  } else
15970
15970
  x = F / _e, ue = g, a.each(u, function(ze, Fe) {
15971
15971
  if (!isNaN(ze)) {
15972
- var Ve = a.getItemLayout(Fe), Lt = Ve.angle === w ? w : ze * x, pe = 0, Cn = 0;
15973
- Lt < b ? (pe = ue + ie * Lt / 2, Cn = pe) : (pe = ue + Y, Cn = ue + ie * Lt - Y), Ve.startAngle = pe, Ve.endAngle = Cn, ue += ie * Lt;
15972
+ var Oe = a.getItemLayout(Fe), Lt = Oe.angle === w ? w : ze * x, pe = 0, Cn = 0;
15973
+ Lt < b ? (pe = ue + ie * Lt / 2, Cn = pe) : (pe = ue + Y, Cn = ue + ie * Lt - Y), Oe.startAngle = pe, Oe.endAngle = Cn, ue += ie * Lt;
15974
15974
  }
15975
15975
  });
15976
15976
  });
@@ -16094,24 +16094,24 @@ function pieLabelLayout(i) {
16094
16094
  return !1;
16095
16095
  }
16096
16096
  r.each(function(M) {
16097
- var k = r.getItemGraphicEl(M), ie = k.shape, $ = k.getTextContent(), Y = k.getTextGuideLine(), D = r.getItemModel(M), re = D.getModel("label"), F = re.get("position") || D.get(["emphasis", "label", "position"]), _e = re.get("distanceToLabelLine"), ue = re.get("alignTo"), Ie = parsePercent(re.get("edgeDistance"), p), ze = re.get("bleedMargin"), Fe = D.getModel("labelLine"), Ve = Fe.get("length");
16098
- Ve = parsePercent(Ve, p);
16097
+ var k = r.getItemGraphicEl(M), ie = k.shape, $ = k.getTextContent(), Y = k.getTextGuideLine(), D = r.getItemModel(M), re = D.getModel("label"), F = re.get("position") || D.get(["emphasis", "label", "position"]), _e = re.get("distanceToLabelLine"), ue = re.get("alignTo"), Ie = parsePercent(re.get("edgeDistance"), p), ze = re.get("bleedMargin"), Fe = D.getModel("labelLine"), Oe = Fe.get("length");
16098
+ Oe = parsePercent(Oe, p);
16099
16099
  var Lt = Fe.get("length2");
16100
16100
  if (Lt = parsePercent(Lt, p), Math.abs(ie.endAngle - ie.startAngle) < c) {
16101
16101
  each$4($.states, y), $.ignore = !0, Y && (each$4(Y.states, y), Y.ignore = !0);
16102
16102
  return;
16103
16103
  }
16104
16104
  if (b($)) {
16105
- var pe = (ie.startAngle + ie.endAngle) / 2, Cn = Math.cos(pe), In = Math.sin(pe), Dt, de, Et, hn;
16105
+ var pe = (ie.startAngle + ie.endAngle) / 2, Cn = Math.cos(pe), In = Math.sin(pe), Dt, he, Et, hn;
16106
16106
  o = ie.cx, a = ie.cy;
16107
16107
  var vn = F === "inside" || F === "inner";
16108
16108
  if (F === "center")
16109
- Dt = ie.cx, de = ie.cy, hn = "center";
16109
+ Dt = ie.cx, he = ie.cy, hn = "center";
16110
16110
  else {
16111
16111
  var kt = (vn ? (ie.r + ie.r0) / 2 * Cn : ie.r * Cn) + o, Ce = (vn ? (ie.r + ie.r0) / 2 * In : ie.r * In) + a;
16112
- if (Dt = kt + Cn * 3, de = Ce + In * 3, !vn) {
16113
- var he = kt + Cn * (Ve + f - ie.r), Ue = Ce + In * (Ve + f - ie.r), Ne = he + (Cn < 0 ? -1 : 1) * Lt, Oe = Ue;
16114
- ue === "edge" ? Dt = Cn < 0 ? _ + Ie : _ + p - Ie : Dt = Ne + (Cn < 0 ? -_e : _e), de = Oe, Et = [[kt, Ce], [he, Ue], [Ne, Oe]];
16112
+ if (Dt = kt + Cn * 3, he = Ce + In * 3, !vn) {
16113
+ var de = kt + Cn * (Oe + f - ie.r), Ue = Ce + In * (Oe + f - ie.r), Ne = de + (Cn < 0 ? -1 : 1) * Lt, Ve = Ue;
16114
+ ue === "edge" ? Dt = Cn < 0 ? _ + Ie : _ + p - Ie : Dt = Ne + (Cn < 0 ? -_e : _e), he = Ve, Et = [[kt, Ce], [de, Ue], [Ne, Ve]];
16115
16115
  }
16116
16116
  hn = vn ? "center" : ue === "edge" ? Cn > 0 ? "right" : "left" : Cn > 0 ? "left" : "right";
16117
16117
  }
@@ -16129,7 +16129,7 @@ function pieLabelLayout(i) {
16129
16129
  var j = In > 0;
16130
16130
  j && (le = Pt + le), jt = le - Pt;
16131
16131
  }
16132
- if (u = !!jt, $.x = Dt, $.y = de, $.rotation = jt, $.setStyle({
16132
+ if (u = !!jt, $.x = Dt, $.y = he, $.rotation = jt, $.setStyle({
16133
16133
  verticalAlign: "middle"
16134
16134
  }), vn) {
16135
16135
  $.setStyle({
@@ -16145,7 +16145,7 @@ function pieLabelLayout(i) {
16145
16145
  label: $,
16146
16146
  labelLine: Y,
16147
16147
  position: F,
16148
- len: Ve,
16148
+ len: Oe,
16149
16149
  len2: Lt,
16150
16150
  minTurnAngle: Fe.get("minTurnAngle"),
16151
16151
  maxSurfaceAngle: Fe.get("maxSurfaceAngle"),
@@ -20438,7 +20438,7 @@ const useEditPrivateStore = defineStore("edit-private-store", {
20438
20438
  }
20439
20439
  });
20440
20440
  var EVisibleConfKey = /* @__PURE__ */ ((i) => (i.ImportJson = "ImportJson", i.ExportJson = "ExportJson", i.ImportFile = "ImportFile", i))(EVisibleConfKey || {});
20441
- const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScopeId(), i), _hoisted_1$d = {
20441
+ const _withScopeId$2 = (i) => (pushScopeId("data-v-e813974f"), i = i(), popScopeId(), i), _hoisted_1$d = {
20442
20442
  class: "flex justify-between",
20443
20443
  style: { width: "100%" }
20444
20444
  }, _hoisted_2$b = {
@@ -20455,7 +20455,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
20455
20455
  }, _hoisted_8$5 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", {
20456
20456
  class: "font-bold mb-10px text-15px guide-title",
20457
20457
  style: { "padding-top": "16px" }
20458
- }, "多选", -1)), _hoisted_9$4 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", null, "在画布空白区域按住鼠标左键可以框选(图形中心点在框选区域即判定被选中),也可以按住ctrl+鼠标左键点图形进行多选", -1)), _hoisted_10$3 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", {
20458
+ }, "多选", -1)), _hoisted_9$4 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", null, "在画布空白区域按住鼠标左键可以框选(图形中心点在框选区域即判定被选中),也可以按住ctrl+鼠标左键点图形进行多选 ", -1)), _hoisted_10$3 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", {
20459
20459
  class: "el-divider el-divider--horizontal",
20460
20460
  role: "separator",
20461
20461
  style: { "--el-border-style": "solid" }
@@ -20463,7 +20463,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
20463
20463
  class: "el-divider el-divider--horizontal",
20464
20464
  role: "separator",
20465
20465
  style: { "--el-border-style": "solid" }
20466
- }, null, -1)), _hoisted_14$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", { class: "font-bold mb-10px text-15px guide-title" }, "画布缩放", -1)), _hoisted_15$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", null, "在画布中使用鼠标滚轮或者右侧面板‘图纸’栏可控制画布缩放,鼠标滚轮以鼠标位置为缩放中心,图纸栏以图纸原点(默认在左上角)为缩放中心", -1)), _hoisted_16$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", {
20466
+ }, null, -1)), _hoisted_14$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", { class: "font-bold mb-10px text-15px guide-title" }, "画布缩放", -1)), _hoisted_15$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", null, "在画布中使用鼠标滚轮或者右侧面板‘图纸’栏可控制画布缩放,鼠标滚轮以鼠标位置为缩放中心,图纸栏以图纸原点(默认在左上角)为缩放中心 ", -1)), _hoisted_16$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", {
20467
20467
  class: "el-divider el-divider--horizontal",
20468
20468
  role: "separator",
20469
20469
  style: { "--el-border-style": "solid" }
@@ -20518,7 +20518,9 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
20518
20518
  }, p = ref(!1), _ = computed({
20519
20519
  get: () => o.intention === EGlobalStoreIntention.Connection,
20520
20520
  set(v) {
20521
- o.intention = v ? EGlobalStoreIntention.Connection : EGlobalStoreIntention.None, v && o.setHandleSvgInfo(null);
20521
+ o.intention = v ? EGlobalStoreIntention.Connection : EGlobalStoreIntention.None, v && (o.done_json.forEach((g) => {
20522
+ g != null && g.selected && (g.selected = !1);
20523
+ }), o.setHandleSvgInfo(null));
20522
20524
  }
20523
20525
  });
20524
20526
  return (v, g) => (openBlock(), createElementBlock(Fragment, null, [
@@ -20739,7 +20741,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
20739
20741
  }, 8, ["modelValue"])
20740
20742
  ], 64));
20741
20743
  }
20742
- }), topPanel_vue_vue_type_style_index_0_scoped_2954e727_lang = "", TopPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$D, [["__scopeId", "data-v-2954e727"]]), _hoisted_1$c = { class: "component-group flex flex-wrap" }, _hoisted_2$a = ["onDragstart", "title"], _sfc_main$C = /* @__PURE__ */ defineComponent({
20744
+ }), topPanel_vue_vue_type_style_index_0_scoped_e813974f_lang = "", TopPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$D, [["__scopeId", "data-v-e813974f"]]), _hoisted_1$c = { class: "component-group flex flex-wrap" }, _hoisted_2$a = ["onDragstart", "title"], _sfc_main$C = /* @__PURE__ */ defineComponent({
20743
20745
  __name: "left-panel",
20744
20746
  props: {
20745
20747
  customToolbar: {}
@@ -21453,8 +21455,8 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21453
21455
  vueComp: {}
21454
21456
  },
21455
21457
  setup(i, { expose: r }) {
21456
- useCssVars((Ve) => ({
21457
- "17ec479e": unref(v)
21458
+ useCssVars((Oe) => ({
21459
+ "04e68382": unref(v)
21458
21460
  }));
21459
21461
  const n = useGlobalStore(pinia), o = useConfigStore(pinia), a = useSvgEditLayoutStore(pinia), u = useEditPrivateStore(pinia), c = useContextMenuStore(pinia);
21460
21462
  componentsRegister(i.vueComp);
@@ -21493,13 +21495,13 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21493
21495
  x: 0,
21494
21496
  y: 0
21495
21497
  }), A = computed(() => {
21496
- let Ve = 0;
21498
+ let Oe = 0;
21497
21499
  for (let Lt of n.done_json)
21498
- Lt.selected && Ve++;
21499
- return Ve > 0;
21500
+ Lt.selected && Oe++;
21501
+ return Oe > 0;
21500
21502
  });
21501
21503
  let w = !1, S = !1;
21502
- const T = (Ve) => {
21504
+ const T = (Oe) => {
21503
21505
  var Lt;
21504
21506
  if (n.intention != EGlobalStoreIntention.None) {
21505
21507
  if (n.intention == EGlobalStoreIntention.Create) {
@@ -21507,7 +21509,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21507
21509
  console.error("要创建的数据获取失败");
21508
21510
  return;
21509
21511
  }
21510
- const pe = Math.floor(Ve.offsetX / o.svg.scale - a.center_offset.x), Cn = Math.floor(Ve.offsetY / o.svg.scale - a.center_offset.y), In = {
21512
+ const pe = Math.floor(Oe.offsetX / o.svg.scale - a.center_offset.x), Cn = Math.floor(Oe.offsetY / o.svg.scale - a.center_offset.y), In = {
21511
21513
  id: randomString(),
21512
21514
  x: pe,
21513
21515
  y: Cn,
@@ -21569,26 +21571,29 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21569
21571
  }
21570
21572
  (Lt = p.value) == null || Lt.focus();
21571
21573
  }
21572
- }, x = (Ve) => {
21573
- Ve.preventDefault();
21574
- }, L = (Ve) => {
21575
- Ve.preventDefault();
21576
- }, O = (Ve, Lt, pe) => {
21574
+ }, x = (Oe) => {
21575
+ Oe.preventDefault();
21576
+ }, L = (Oe) => {
21577
+ Oe.preventDefault();
21578
+ }, O = (Oe, Lt, pe) => {
21577
21579
  var Cn, In, Dt;
21578
21580
  if ((Cn = p.value) == null || Cn.focus(), n.intention === EGlobalStoreIntention.Connection) {
21579
- if (pe.stopPropagation(), n.handle_svg_info)
21581
+ if (pe.stopPropagation(), n.handle_svg_info || createLine(pe), n.handle_svg_info)
21580
21582
  if (pe.button === 0) {
21581
- const de = n.handle_svg_info.info.props.point_position.val;
21582
- de.length > 1 && de[0].x !== de[1].x && de[0].y !== de[1].y && de.push({
21583
+ const he = n.handle_svg_info.info.props.point_position.val;
21584
+ he.length !== 1 && (Oe == null ? void 0 : Oe.type) !== EDoneJsonType.ConnectionLine ? he.push({
21583
21585
  x: n.mouse_info.new_position_x - n.mouse_info.position_x - a.center_offset.x,
21584
21586
  y: n.mouse_info.new_position_y - n.mouse_info.position_y - a.center_offset.y
21587
+ }) : n.handle_svg_info.info.props.point_position.val.push({
21588
+ x: 0,
21589
+ y: 0
21585
21590
  });
21586
21591
  } else
21587
21592
  pe.button === 2 && (n.intention = EGlobalStoreIntention.None, setSvgActualInfo(n.done_json[n.handle_svg_info.index]), n.setHandleSvgInfo(null));
21588
21593
  return;
21589
21594
  }
21590
21595
  if (pe.preventDefault(), pe.stopPropagation(), pe.ctrlKey && pe.button === 0)
21591
- ((In = n.handle_svg_info) != null && In.index || ((Dt = n.handle_svg_info) == null ? void 0 : Dt.index) === 0) && (n.done_json[n.handle_svg_info.index].selected = !0, n.setHandleSvgInfo(null), n.intention = EGlobalStoreIntention.None), Ve.selected = !Ve.selected;
21596
+ ((In = n.handle_svg_info) != null && In.index || ((Dt = n.handle_svg_info) == null ? void 0 : Dt.index) === 0) && (n.done_json[n.handle_svg_info.index].selected = !0, n.setHandleSvgInfo(null), n.intention = EGlobalStoreIntention.None), Oe.selected = !Oe.selected;
21592
21597
  else if (A.value) {
21593
21598
  n.intention = EGlobalStoreIntention.GroupMove, n.mouse_info = {
21594
21599
  state: EMouseInfoState.Down,
@@ -21599,47 +21604,47 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21599
21604
  new_position_x: 0,
21600
21605
  new_position_y: 0
21601
21606
  };
21602
- for (let de of n.done_json)
21603
- de.selected && (de.old_position = {
21604
- x: de.x,
21605
- y: de.y
21606
- }, de.point_coordinate_old = objectDeepClone(de.point_coordinate));
21607
+ for (let he of n.done_json)
21608
+ he.selected && (he.old_position = {
21609
+ x: he.x,
21610
+ y: he.y
21611
+ }, he.point_coordinate_old = objectDeepClone(he.point_coordinate));
21607
21612
  } else
21608
- n.intention = EGlobalStoreIntention.Select, n.setHandleSvgInfo(Ve, Lt), n.mouse_info = {
21613
+ n.intention = EGlobalStoreIntention.Select, n.setHandleSvgInfo(Oe, Lt), n.mouse_info = {
21609
21614
  state: EMouseInfoState.Down,
21610
21615
  position_x: Math.round((pe.clientX - a.canvasInfo.left) / o.svg.scale),
21611
21616
  position_y: Math.round((pe.clientY - a.canvasInfo.top) / o.svg.scale),
21612
- now_position_x: Ve.x,
21613
- now_position_y: Ve.y,
21617
+ now_position_x: Oe.x,
21618
+ now_position_y: Oe.y,
21614
21619
  new_position_x: 0,
21615
21620
  new_position_y: 0
21616
- }, Ve.point_coordinate_old = objectDeepClone(Ve.point_coordinate);
21617
- }, M = (Ve, Lt, pe) => {
21621
+ }, Oe.point_coordinate_old = objectDeepClone(Oe.point_coordinate);
21622
+ }, M = (Oe, Lt, pe) => {
21618
21623
  if (!(n.intention === EGlobalStoreIntention.Connection || n.mouse_info.state != EMouseInfoState.Down) && A.value && !w && ["SelectArea", "Move", "Select"].indexOf(n.intention) < 0) {
21619
21624
  for (let Cn of n.done_json)
21620
21625
  Cn.selected = !1, Cn.old_position = {
21621
21626
  x: 0,
21622
21627
  y: 0
21623
21628
  }, resetHandlePointOld(Cn);
21624
- n.intention = EGlobalStoreIntention.Select, n.setHandleSvgInfo(Ve, Lt), n.mouse_info = {
21629
+ n.intention = EGlobalStoreIntention.Select, n.setHandleSvgInfo(Oe, Lt), n.mouse_info = {
21625
21630
  state: EMouseInfoState.Down,
21626
21631
  position_x: Math.round((pe.clientX - a.canvasInfo.left) / o.svg.scale),
21627
21632
  position_y: Math.round((pe.clientY - a.canvasInfo.top) / o.svg.scale),
21628
- now_position_x: Ve.x,
21629
- now_position_y: Ve.y,
21633
+ now_position_x: Oe.x,
21634
+ now_position_y: Oe.y,
21630
21635
  new_position_x: 0,
21631
21636
  new_position_y: 0
21632
21637
  };
21633
21638
  }
21634
- }, k = (Ve, Lt, pe) => {
21635
- pe.preventDefault(), pe.stopPropagation(), g.connection_panel = !0, g.connection_line = !0, !((n.intention === EGlobalStoreIntention.Connection || n.intention === EGlobalStoreIntention.SetConnectionLineNode) && Ve.type === EDoneJsonType.ConnectionLine) && (g.select_item.info = Ve, g.select_item.index = Lt);
21636
- }, ie = (Ve, Lt, pe) => {
21637
- pe.preventDefault(), pe.stopPropagation(), !((n.intention === EGlobalStoreIntention.Connection || n.intention === EGlobalStoreIntention.SetConnectionLineNode) && Ve.type === EDoneJsonType.ConnectionLine) && (g.connection_panel = !1, g.connection_line = !1, g.select_item.info = null, g.select_item.index = -1);
21638
- }, $ = (Ve) => {
21639
- var Dt, de, Et, hn, vn, kt, Ce, he, Ue, Ne, Oe, Pt, jt, _n, oe, le;
21639
+ }, k = (Oe, Lt, pe) => {
21640
+ pe.preventDefault(), pe.stopPropagation(), g.connection_panel = !0, g.connection_line = !0, !((n.intention === EGlobalStoreIntention.Connection || n.intention === EGlobalStoreIntention.SetConnectionLineNode) && Oe.type === EDoneJsonType.ConnectionLine) && (g.select_item.info = Oe, g.select_item.index = Lt);
21641
+ }, ie = (Oe, Lt, pe) => {
21642
+ pe.preventDefault(), pe.stopPropagation(), !((n.intention === EGlobalStoreIntention.Connection || n.intention === EGlobalStoreIntention.SetConnectionLineNode) && Oe.type === EDoneJsonType.ConnectionLine) && (g.connection_panel = !1, g.connection_line = !1, g.select_item.info = null, g.select_item.index = -1);
21643
+ }, $ = (Oe) => {
21644
+ var Dt, he, Et, hn, vn, kt, Ce, de, Ue, Ne, Ve, Pt, jt, _n, oe, le;
21640
21645
  if (n.mouse_info.state != EMouseInfoState.Down && n.intention !== EGlobalStoreIntention.Connection)
21641
21646
  return;
21642
- const { clientX: Lt, clientY: pe } = Ve;
21647
+ const { clientX: Lt, clientY: pe } = Oe;
21643
21648
  n.mouse_info.new_position_x = Math.round(
21644
21649
  (Lt - a.canvasInfo.left) / o.svg.scale
21645
21650
  ), n.mouse_info.new_position_y = Math.round(
@@ -21655,7 +21660,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21655
21660
  x: Cn,
21656
21661
  y: In
21657
21662
  }, n.intention = EGlobalStoreIntention.Move, moveHandlePoint(n.handle_svg_info.info), moveAnchors(n.handle_svg_info.info), n.handle_svg_info.info.type === EDoneJsonType.ConnectionLine) {
21658
- if ((de = n.handle_svg_info.info.bind_anchors) != null && de.start) {
21663
+ if ((he = n.handle_svg_info.info.bind_anchors) != null && he.start) {
21659
21664
  let j = null;
21660
21665
  for (let V of n.done_json)
21661
21666
  V.id === ((hn = (Et = n.handle_svg_info.info.bind_anchors) == null ? void 0 : Et.start) == null ? void 0 : hn.target_id) && (j = V);
@@ -21684,7 +21689,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21684
21689
  if (j.x = V, j.y = z, j.client = {
21685
21690
  x: V,
21686
21691
  y: z
21687
- }, moveHandlePoint(j), moveAnchors(j), j.type === EDoneJsonType.ConnectionLine && ((he = j.bind_anchors) != null && he.end)) {
21692
+ }, moveHandlePoint(j), moveAnchors(j), j.type === EDoneJsonType.ConnectionLine && ((de = j.bind_anchors) != null && de.end)) {
21688
21693
  let ae = null;
21689
21694
  for (let xe of n.done_json)
21690
21695
  xe.id === ((Ne = (Ue = j.bind_anchors) == null ? void 0 : Ue.end) == null ? void 0 : Ne.target_id) && (ae = xe);
@@ -21771,12 +21776,12 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21771
21776
  2
21772
21777
  );
21773
21778
  } else if (n.intention === EGlobalStoreIntention.Connection && n.handle_svg_info) {
21774
- const j = (Oe = n.handle_svg_info) == null ? void 0 : Oe.info.props.point_position.val.length, V = n.mouse_info.new_position_x - n.mouse_info.position_x - a.center_offset.x, z = n.mouse_info.new_position_y - n.mouse_info.position_y - a.center_offset.y, ae = n.handle_svg_info.info.props.point_position.val[j - 2], xe = ((jt = (Pt = n.handle_svg_info) == null ? void 0 : Pt.info.props.point_r) == null ? void 0 : jt.val) + 2 || 4;
21779
+ const j = (Ve = n.handle_svg_info) == null ? void 0 : Ve.info.props.point_position.val.length, V = n.mouse_info.new_position_x - n.mouse_info.position_x - a.center_offset.x, z = n.mouse_info.new_position_y - n.mouse_info.position_y - a.center_offset.y, ae = n.handle_svg_info.info.props.point_position.val[j - 2], xe = ((jt = (Pt = n.handle_svg_info) == null ? void 0 : Pt.info.props.point_r) == null ? void 0 : jt.val) + 2 || 4;
21775
21780
  let qe = ae.x < V ? -xe : ae.x > V ? xe : 0, bn = ae.y < z ? -xe : ae.y > z ? xe : 0;
21776
- Ve.ctrlKey ? n.handle_svg_info.info.props.point_position.val[j - 1] = {
21781
+ Oe.ctrlKey ? n.handle_svg_info.info.props.point_position.val[j - 1] = {
21777
21782
  x: ae.x,
21778
21783
  y: z + bn
21779
- } : Ve.shiftKey ? n.handle_svg_info.info.props.point_position.val[j - 1] = {
21784
+ } : Oe.shiftKey ? n.handle_svg_info.info.props.point_position.val[j - 1] = {
21780
21785
  x: V + qe,
21781
21786
  y: ae.y
21782
21787
  } : n.handle_svg_info.info.props.point_position.val[j - 1] = {
@@ -21801,9 +21806,9 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21801
21806
  };
21802
21807
  }
21803
21808
  }, Y = () => {
21804
- var Ve, Lt, pe, Cn;
21809
+ var Oe, Lt, pe, Cn;
21805
21810
  if (n.mouse_info.state == EMouseInfoState.Down) {
21806
- if ((Ve = n.handle_svg_info) != null && Ve.info && n.intention == EGlobalStoreIntention.Move)
21811
+ if ((Oe = n.handle_svg_info) != null && Oe.info && n.intention == EGlobalStoreIntention.Move)
21807
21812
  setSvgActualInfo(n.done_json[n.handle_svg_info.index]), n.intention = EGlobalStoreIntention.None, n.setDoneJson(n.done_json);
21808
21813
  else if (n.intention == EGlobalStoreIntention.GroupMove) {
21809
21814
  if (w) {
@@ -21843,19 +21848,19 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21843
21848
  new_position_y: 0
21844
21849
  }, c.display = !1;
21845
21850
  }
21846
- }, D = (Ve) => {
21847
- const { clientX: Lt, clientY: pe } = Ve;
21851
+ }, D = (Oe) => {
21852
+ const { clientX: Lt, clientY: pe } = Oe;
21848
21853
  if (n.intention === EGlobalStoreIntention.Connection) {
21849
- n.handle_svg_info || createLine(Ve), n.handle_svg_info && (Ve.button === 0 ? n.handle_svg_info.info.props.point_position.val.length !== 1 ? n.handle_svg_info.info.props.point_position.val.push({
21854
+ n.handle_svg_info || createLine(Oe), n.handle_svg_info && (Oe.button === 0 ? n.handle_svg_info.info.props.point_position.val.length !== 1 ? n.handle_svg_info.info.props.point_position.val.push({
21850
21855
  x: n.mouse_info.new_position_x - n.mouse_info.position_x - a.center_offset.x,
21851
21856
  y: n.mouse_info.new_position_y - n.mouse_info.position_y - a.center_offset.y
21852
21857
  }) : n.handle_svg_info.info.props.point_position.val.push({
21853
21858
  x: 0,
21854
21859
  y: 0
21855
- }) : Ve.button === 2 && (n.intention = EGlobalStoreIntention.None, setSvgActualInfo(n.done_json[n.handle_svg_info.index]), n.setHandleSvgInfo(null)));
21860
+ }) : Oe.button === 2 && (n.intention = EGlobalStoreIntention.None, setSvgActualInfo(n.done_json[n.handle_svg_info.index]), n.setHandleSvgInfo(null)));
21856
21861
  return;
21857
21862
  }
21858
- Ve.button === 0 ? (n.intention = EGlobalStoreIntention.SelectArea, n.mouse_info = {
21863
+ Oe.button === 0 ? (n.intention = EGlobalStoreIntention.SelectArea, n.mouse_info = {
21859
21864
  state: EMouseInfoState.Down,
21860
21865
  position_x: Math.round(
21861
21866
  (Lt - a.canvasInfo.left) / o.svg.scale - a.center_offset.x
@@ -21876,7 +21881,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21876
21881
  x: 0,
21877
21882
  y: 0
21878
21883
  }
21879
- }) : Ve.button === 2 && (n.intention = EGlobalStoreIntention.MoveCanvas, n.mouse_info = {
21884
+ }) : Oe.button === 2 && (n.intention = EGlobalStoreIntention.MoveCanvas, n.mouse_info = {
21880
21885
  state: EMouseInfoState.Down,
21881
21886
  position_x: Math.round((Lt - a.canvasInfo.left) / o.svg.scale),
21882
21887
  position_y: Math.round((pe - a.canvasInfo.top) / o.svg.scale),
@@ -21886,56 +21891,56 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21886
21891
  new_position_y: 0
21887
21892
  });
21888
21893
  };
21889
- function re(Ve) {
21890
- Ve != null && Ve.wheelDelta && (Ve.wheelDelta > 0 ? (o.svg.scale = myFixed(o.svg.scale + 0.1, 1), getZoomPosition(Ve, o.svg.scale, a.center_offset, !0)) : o.svg.scale > 0.1 && (o.svg.scale = myFixed(o.svg.scale - 0.1, 1), getZoomPosition(Ve, o.svg.scale, a.center_offset, !1)));
21891
- }
21892
- const F = (Ve) => {
21893
- Ve.stopPropagation(), Ve.preventDefault();
21894
- }, _e = (Ve, Lt, pe) => {
21895
- n.intention !== EGlobalStoreIntention.Connection && f.value && (n.intention = EGlobalStoreIntention.ContextMenu, n.setHandleSvgInfo(Ve, Lt), f.value.style.left = pe.pageX + "px", f.value.style.top = pe.pageY + "px", c.info.MoveUpOneLevel.enable = c.info.MoveUpTopLevel.enable = c.info.MoveDownOneLevel.enable = c.info.MoveDownTopLevel.enable = !0, Lt === n.done_json.length - 1 && (c.info.MoveUpOneLevel.enable = c.info.MoveUpTopLevel.enable = !1), Lt === 0 && (c.info.MoveDownOneLevel.enable = c.info.MoveDownTopLevel.enable = !1), c.display = !0);
21896
- }, ue = (Ve, Lt, pe) => ({
21897
- x: myFixed(Ve.x - Ve.width / 2 * Lt + Ve.width / 2, 1),
21898
- y: myFixed(Ve.y - Ve.height / 2 * pe + Ve.height / 2, 1),
21899
- width: myFixed(Ve.width * Lt, 1),
21900
- height: myFixed(Ve.height * pe, 1)
21901
- }), Ie = (Ve) => {
21902
- Ve.preventDefault();
21894
+ function re(Oe) {
21895
+ Oe != null && Oe.wheelDelta && (Oe.wheelDelta > 0 ? (o.svg.scale = myFixed(o.svg.scale + 0.1, 1), getZoomPosition(Oe, o.svg.scale, a.center_offset, !0)) : o.svg.scale > 0.1 && (o.svg.scale = myFixed(o.svg.scale - 0.1, 1), getZoomPosition(Oe, o.svg.scale, a.center_offset, !1)));
21896
+ }
21897
+ const F = (Oe) => {
21898
+ Oe.stopPropagation(), Oe.preventDefault();
21899
+ }, _e = (Oe, Lt, pe) => {
21900
+ n.intention !== EGlobalStoreIntention.Connection && f.value && (n.intention = EGlobalStoreIntention.ContextMenu, n.setHandleSvgInfo(Oe, Lt), f.value.style.left = pe.pageX + "px", f.value.style.top = pe.pageY + "px", c.info.MoveUpOneLevel.enable = c.info.MoveUpTopLevel.enable = c.info.MoveDownOneLevel.enable = c.info.MoveDownTopLevel.enable = !0, Lt === n.done_json.length - 1 && (c.info.MoveUpOneLevel.enable = c.info.MoveUpTopLevel.enable = !1), Lt === 0 && (c.info.MoveDownOneLevel.enable = c.info.MoveDownTopLevel.enable = !1), c.display = !0);
21901
+ }, ue = (Oe, Lt, pe) => ({
21902
+ x: myFixed(Oe.x - Oe.width / 2 * Lt + Oe.width / 2, 1),
21903
+ y: myFixed(Oe.y - Oe.height / 2 * pe + Oe.height / 2, 1),
21904
+ width: myFixed(Oe.width * Lt, 1),
21905
+ height: myFixed(Oe.height * pe, 1)
21906
+ }), Ie = (Oe) => {
21907
+ Oe.preventDefault();
21903
21908
  let Lt = [];
21904
- if (!Ve.ctrlKey && ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight"].indexOf(Ve.key) > -1 && (A.value ? Lt = n.done_json.map((pe, Cn) => ({
21909
+ if (!Oe.ctrlKey && ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight"].indexOf(Oe.key) > -1 && (A.value ? Lt = n.done_json.map((pe, Cn) => ({
21905
21910
  selected: pe.selected,
21906
21911
  i: Cn
21907
- })).filter((pe) => pe.selected).map((pe) => pe.i) : n.handle_svg_info && Lt.push(n.handle_svg_info.index)), !Ve.ctrlKey && Ve.key == "ArrowUp") {
21912
+ })).filter((pe) => pe.selected).map((pe) => pe.i) : n.handle_svg_info && Lt.push(n.handle_svg_info.index)), !Oe.ctrlKey && Oe.key == "ArrowUp") {
21908
21913
  for (let pe of Lt)
21909
21914
  n.done_json[pe].y -= 1, n.done_json[pe].client.y -= 1, moveHandlePoint(n.done_json[pe], 0, -1), moveAnchors(n.done_json[pe]);
21910
21915
  useHistoryRecord(n.done_json);
21911
- } else if (!Ve.ctrlKey && Ve.key == "ArrowDown") {
21916
+ } else if (!Oe.ctrlKey && Oe.key == "ArrowDown") {
21912
21917
  for (let pe of Lt)
21913
21918
  n.done_json[pe].y += 1, n.done_json[pe].client.y += 1, moveHandlePoint(n.done_json[pe], 0, 1), moveAnchors(n.done_json[pe]);
21914
21919
  useHistoryRecord(n.done_json);
21915
- } else if (!Ve.ctrlKey && Ve.key == "ArrowLeft") {
21920
+ } else if (!Oe.ctrlKey && Oe.key == "ArrowLeft") {
21916
21921
  for (let pe of Lt)
21917
21922
  n.done_json[pe].x -= 1, n.done_json[pe].client.x -= 1, moveHandlePoint(n.done_json[pe], -1, 0), moveAnchors(n.done_json[pe]);
21918
21923
  useHistoryRecord(n.done_json);
21919
- } else if (!Ve.ctrlKey && Ve.key == "ArrowRight") {
21924
+ } else if (!Oe.ctrlKey && Oe.key == "ArrowRight") {
21920
21925
  for (let pe of Lt)
21921
21926
  n.done_json[pe].x += 1, n.done_json[pe].client.x += 1, moveHandlePoint(n.done_json[pe], 1, 0), moveAnchors(n.done_json[pe]);
21922
21927
  useHistoryRecord(n.done_json);
21923
21928
  } else
21924
- Ve.ctrlKey && Ve.key.toLowerCase() == "c" ? c.onContextMenuClick(EContextMenuInfoType.Copy) : !Ve.ctrlKey && Ve.key == "Delete" ? A.value ? (n.setDoneJson(n.done_json.filter((pe) => !pe.selected)), n.setHandleSvgInfo(
21929
+ Oe.ctrlKey && Oe.key.toLowerCase() == "c" ? c.onContextMenuClick(EContextMenuInfoType.Copy) : !Oe.ctrlKey && Oe.key == "Delete" ? A.value ? (n.setDoneJson(n.done_json.filter((pe) => !pe.selected)), n.setHandleSvgInfo(
21925
21930
  n.done_json[n.done_json.length - 1],
21926
21931
  n.done_json.length - 1
21927
- )) : c.onContextMenuClick(EContextMenuInfoType.Delete) : Ve.ctrlKey && Ve.key == "ArrowUp" ? c.onContextMenuClick(EContextMenuInfoType.MoveUpOneLevel) : Ve.ctrlKey && Ve.key == "ArrowDown" ? c.onContextMenuClick(EContextMenuInfoType.MoveDownOneLevel) : Ve.ctrlKey && Ve.key == "ArrowLeft" ? c.onContextMenuClick(EContextMenuInfoType.MoveDownTopLevel) : Ve.ctrlKey && Ve.key == "ArrowRight" ? c.onContextMenuClick(EContextMenuInfoType.MoveUpTopLevel) : Ve.ctrlKey && Ve.shiftKey && Ve.key.toLowerCase() == "z" ? u.topRedoBtnClick() : Ve.ctrlKey && Ve.key.toLowerCase() == "z" ? u.topUndoBtnClick() : Ve.ctrlKey && Ve.key.toLowerCase() == "delete" && (n.done_json.length <= 0 || n.setDoneJson([]));
21928
- }, ze = (Ve) => {
21932
+ )) : c.onContextMenuClick(EContextMenuInfoType.Delete) : Oe.ctrlKey && Oe.key == "ArrowUp" ? c.onContextMenuClick(EContextMenuInfoType.MoveUpOneLevel) : Oe.ctrlKey && Oe.key == "ArrowDown" ? c.onContextMenuClick(EContextMenuInfoType.MoveDownOneLevel) : Oe.ctrlKey && Oe.key == "ArrowLeft" ? c.onContextMenuClick(EContextMenuInfoType.MoveDownTopLevel) : Oe.ctrlKey && Oe.key == "ArrowRight" ? c.onContextMenuClick(EContextMenuInfoType.MoveUpTopLevel) : Oe.ctrlKey && Oe.shiftKey && Oe.key.toLowerCase() == "z" ? u.topRedoBtnClick() : Oe.ctrlKey && Oe.key.toLowerCase() == "z" ? u.topUndoBtnClick() : Oe.ctrlKey && Oe.key.toLowerCase() == "delete" && (n.done_json.length <= 0 || n.setDoneJson([]));
21933
+ }, ze = (Oe) => {
21929
21934
  const Lt = ["ArrowUp", "ArrowDown", "ArrowLeft", "ArrowRight"];
21930
- if (!Ve.ctrlKey && Lt.indexOf(Ve.key) > -1)
21935
+ if (!Oe.ctrlKey && Lt.indexOf(Oe.key) > -1)
21931
21936
  for (let pe of n.done_json)
21932
21937
  pe.selected && setSvgActualInfo(pe);
21933
21938
  }, Fe = () => {
21934
21939
  setSvgActualInfo(n.done_json[n.handle_svg_info.index], !0);
21935
21940
  };
21936
21941
  return onMounted(() => {
21937
- var Ve;
21938
- (Ve = p.value) == null || Ve.focus(), nextTick(function() {
21942
+ var Oe;
21943
+ (Oe = p.value) == null || Oe.focus(), nextTick(function() {
21939
21944
  var pe;
21940
21945
  const Lt = (pe = p.value) == null ? void 0 : pe.getBoundingClientRect();
21941
21946
  a.canvasInfo = {
@@ -21945,7 +21950,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21945
21950
  left: (Lt == null ? void 0 : Lt.left) || 0
21946
21951
  };
21947
21952
  });
21948
- }), r({ onCanvasMouseUp: Y }), (Ve, Lt) => (openBlock(), createElementBlock(Fragment, null, [
21953
+ }), r({ onCanvasMouseUp: Y }), (Oe, Lt) => (openBlock(), createElementBlock(Fragment, null, [
21949
21954
  createElementVNode("div", {
21950
21955
  ref_key: "canvasRef",
21951
21956
  ref: p,
@@ -21963,7 +21968,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
21963
21968
  onKeyup: ze,
21964
21969
  onMousewheel: re
21965
21970
  }, [
21966
- renderSlot(Ve.$slots, "background", {}, void 0, !0),
21971
+ renderSlot(Oe.$slots, "background", {}, void 0, !0),
21967
21972
  createElementVNode("div", _hoisted_1$8, [
21968
21973
  (openBlock(), createElementBlock("svg", _hoisted_2$6, [
21969
21974
  createElementVNode("defs", null, [
@@ -22003,7 +22008,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
22003
22008
  transform: `translate(${unref(a).center_offset.x * unref(o).svg.scale},${unref(a).center_offset.y * unref(o).svg.scale})rotate(0)scale(${unref(o).svg.scale})`
22004
22009
  }, [
22005
22010
  (openBlock(!0), createElementBlock(Fragment, null, renderList(unref(n).done_json, (pe, Cn) => {
22006
- var In, Dt, de, Et, hn, vn, kt, Ce, he, Ue, Ne, Oe, Pt, jt;
22011
+ var In, Dt, he, Et, hn, vn, kt, Ce, de, Ue, Ne, Ve, Pt, jt;
22007
22012
  return withDirectives((openBlock(), createElementBlock("g", {
22008
22013
  key: pe.id,
22009
22014
  transform: `translate(${pe.x},${pe.y})rotate(0)scale(1)`
@@ -22028,7 +22033,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
22028
22033
  "xlink:href": `#svg-${pe.name}`,
22029
22034
  ref_for: !0
22030
22035
  }, unref(prosToVBind)(pe, ["height", "width"]), {
22031
- width: ((de = (Dt = pe.props) == null ? void 0 : Dt.width) == null ? void 0 : de.val) ?? 100,
22036
+ width: ((he = (Dt = pe.props) == null ? void 0 : Dt.width) == null ? void 0 : he.val) ?? 100,
22032
22037
  height: ((hn = (Et = pe.props) == null ? void 0 : Et.height) == null ? void 0 : hn.val) ?? 100,
22033
22038
  id: pe.id,
22034
22039
  transform: `translate(${pe.actual_bound.x + pe.actual_bound.width / 2},${pe.actual_bound.y + pe.actual_bound.height / 2}) scale(${pe.scale_x},${pe.scale_y}) translate(${-(pe.actual_bound.x + pe.actual_bound.width / 2)},${-(pe.actual_bound.y + pe.actual_bound.height / 2)})`
@@ -22037,7 +22042,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
22037
22042
  ref_for: !0
22038
22043
  }, unref(prosToVBind)(pe, ["height", "width"]), {
22039
22044
  width: ((kt = (vn = pe.props) == null ? void 0 : vn.width) == null ? void 0 : kt.val) ?? 100,
22040
- height: ((he = (Ce = pe.props) == null ? void 0 : Ce.height) == null ? void 0 : he.val) ?? 100,
22045
+ height: ((de = (Ce = pe.props) == null ? void 0 : Ce.height) == null ? void 0 : de.val) ?? 100,
22041
22046
  id: pe.id,
22042
22047
  onResize: Fe,
22043
22048
  transform: `translate(${pe.actual_bound.x + pe.actual_bound.width / 2},${pe.actual_bound.y + pe.actual_bound.height / 2}) scale(${pe.scale_x},${pe.scale_y}) translate(${-(pe.actual_bound.x + pe.actual_bound.width / 2)},${-(pe.actual_bound.y + pe.actual_bound.height / 2)})`
@@ -22083,7 +22088,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
22083
22088
  "svg-item-in-group": pe.selected
22084
22089
  }
22085
22090
  }), null, 16, _hoisted_15)) : createCommentVNode("", !0),
22086
- ((Oe = unref(n).handle_svg_info) == null ? void 0 : Oe.info.id) === pe.id && unref(g).handle_panel && pe.type !== unref(EDoneJsonType).ConnectionLine ? (openBlock(), createBlock(HandlePanel, {
22091
+ ((Ve = unref(n).handle_svg_info) == null ? void 0 : Ve.info.id) === pe.id && unref(g).handle_panel && pe.type !== unref(EDoneJsonType).ConnectionLine ? (openBlock(), createBlock(HandlePanel, {
22087
22092
  key: 6,
22088
22093
  "item-info": pe
22089
22094
  }, null, 8, ["item-info"])) : createCommentVNode("", !0),
@@ -22132,7 +22137,7 @@ const _withScopeId$2 = (i) => (pushScopeId("data-v-2954e727"), i = i(), popScope
22132
22137
  ])
22133
22138
  ], 64));
22134
22139
  }
22135
- }), centerPanel_vue_vue_type_style_index_0_scoped_01b61b5b_lang = "", CenterPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$y, [["__scopeId", "data-v-01b61b5b"]]);
22140
+ }), centerPanel_vue_vue_type_style_index_0_scoped_de7d7390_lang = "", CenterPanel = /* @__PURE__ */ _export_sfc$1(_sfc_main$y, [["__scopeId", "data-v-de7d7390"]]);
22136
22141
  /*! Element Plus Icons Vue v2.3.1 */
22137
22142
  var aim_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ defineComponent({
22138
22143
  name: "Aim",
@@ -24013,31 +24018,31 @@ function Kt(i) {
24013
24018
  function Qt(i) {
24014
24019
  var r = i.state, n = i.options, o = i.name;
24015
24020
  if (!r.modifiersData[o]._skip) {
24016
- for (var a = n.mainAxis, u = a === void 0 ? !0 : a, c = n.altAxis, d = c === void 0 ? !0 : c, f = n.fallbackPlacements, p = n.padding, _ = n.boundary, v = n.rootBoundary, g = n.altBoundary, y = n.flipVariations, b = y === void 0 ? !0 : y, A = n.allowedAutoPlacements, w = r.options.placement, S = q(w), T = S === w, x = f || (T || !b ? [be(w)] : Kt(w)), L = [w].concat(x).reduce(function(Dt, de) {
24017
- return Dt.concat(q(de) === me ? Jt(r, { placement: de, boundary: _, rootBoundary: v, padding: p, flipVariations: b, allowedAutoPlacements: A }) : de);
24021
+ for (var a = n.mainAxis, u = a === void 0 ? !0 : a, c = n.altAxis, d = c === void 0 ? !0 : c, f = n.fallbackPlacements, p = n.padding, _ = n.boundary, v = n.rootBoundary, g = n.altBoundary, y = n.flipVariations, b = y === void 0 ? !0 : y, A = n.allowedAutoPlacements, w = r.options.placement, S = q(w), T = S === w, x = f || (T || !b ? [be(w)] : Kt(w)), L = [w].concat(x).reduce(function(Dt, he) {
24022
+ return Dt.concat(q(he) === me ? Jt(r, { placement: he, boundary: _, rootBoundary: v, padding: p, flipVariations: b, allowedAutoPlacements: A }) : he);
24018
24023
  }, []), O = r.rects.reference, M = r.rects.popper, k = /* @__PURE__ */ new Map(), ie = !0, $ = L[0], Y = 0; Y < L.length; Y++) {
24019
24024
  var D = L[Y], re = q(D), F = te(D) === U, _e = [E, R].indexOf(re) >= 0, ue = _e ? "width" : "height", Ie = ne(r, { placement: D, boundary: _, rootBoundary: v, altBoundary: g, padding: p }), ze = _e ? F ? W : P : F ? R : E;
24020
24025
  O[ue] > M[ue] && (ze = be(ze));
24021
- var Fe = be(ze), Ve = [];
24022
- if (u && Ve.push(Ie[re] <= 0), d && Ve.push(Ie[ze] <= 0, Ie[Fe] <= 0), Ve.every(function(Dt) {
24026
+ var Fe = be(ze), Oe = [];
24027
+ if (u && Oe.push(Ie[re] <= 0), d && Oe.push(Ie[ze] <= 0, Ie[Fe] <= 0), Oe.every(function(Dt) {
24023
24028
  return Dt;
24024
24029
  })) {
24025
24030
  $ = D, ie = !1;
24026
24031
  break;
24027
24032
  }
24028
- k.set(D, Ve);
24033
+ k.set(D, Oe);
24029
24034
  }
24030
24035
  if (ie)
24031
24036
  for (var Lt = b ? 3 : 1, pe = function(Dt) {
24032
- var de = L.find(function(Et) {
24037
+ var he = L.find(function(Et) {
24033
24038
  var hn = k.get(Et);
24034
24039
  if (hn)
24035
24040
  return hn.slice(0, Dt).every(function(vn) {
24036
24041
  return vn;
24037
24042
  });
24038
24043
  });
24039
- if (de)
24040
- return $ = de, "break";
24044
+ if (he)
24045
+ return $ = he, "break";
24041
24046
  }, Cn = Lt; Cn > 0; Cn--) {
24042
24047
  var In = pe(Cn);
24043
24048
  if (In === "break")
@@ -24083,7 +24088,7 @@ function on(i) {
24083
24088
  var r = i.state, n = i.options, o = i.name, a = n.mainAxis, u = a === void 0 ? !0 : a, c = n.altAxis, d = c === void 0 ? !1 : c, f = n.boundary, p = n.rootBoundary, _ = n.altBoundary, v = n.padding, g = n.tether, y = g === void 0 ? !0 : g, b = n.tetherOffset, A = b === void 0 ? 0 : b, w = ne(r, { boundary: f, rootBoundary: p, padding: v, altBoundary: _ }), S = q(r.placement), T = te(r.placement), x = !T, L = Le(S), O = rn(L), M = r.modifiersData.popperOffsets, k = r.rects.reference, ie = r.rects.popper, $ = typeof A == "function" ? A(Object.assign({}, r.rects, { placement: r.placement })) : A, Y = typeof $ == "number" ? { mainAxis: $, altAxis: $ } : Object.assign({ mainAxis: 0, altAxis: 0 }, $), D = r.modifiersData.offset ? r.modifiersData.offset[r.placement] : null, re = { x: 0, y: 0 };
24084
24089
  if (M) {
24085
24090
  if (u) {
24086
- var F, _e = L === "y" ? E : P, ue = L === "y" ? R : W, Ie = L === "y" ? "height" : "width", ze = M[L], Fe = ze + w[_e], Ve = ze - w[ue], Lt = y ? -ie[Ie] / 2 : 0, pe = T === U ? k[Ie] : ie[Ie], Cn = T === U ? -ie[Ie] : -k[Ie], In = r.elements.arrow, Dt = y && In ? ke(In) : { width: 0, height: 0 }, de = r.modifiersData["arrow#persistent"] ? r.modifiersData["arrow#persistent"].padding : st(), Et = de[_e], hn = de[ue], vn = fe(0, k[Ie], Dt[Ie]), kt = x ? k[Ie] / 2 - Lt - vn - Et - Y.mainAxis : pe - vn - Et - Y.mainAxis, Ce = x ? -k[Ie] / 2 + Lt + vn + hn + Y.mainAxis : Cn + vn + hn + Y.mainAxis, he = r.elements.arrow && se(r.elements.arrow), Ue = he ? L === "y" ? he.clientTop || 0 : he.clientLeft || 0 : 0, Ne = (F = D == null ? void 0 : D[L]) != null ? F : 0, Oe = ze + kt - Ne - Ue, Pt = ze + Ce - Ne, jt = fe(y ? ve(Fe, Oe) : Fe, ze, y ? X(Ve, Pt) : Ve);
24091
+ var F, _e = L === "y" ? E : P, ue = L === "y" ? R : W, Ie = L === "y" ? "height" : "width", ze = M[L], Fe = ze + w[_e], Oe = ze - w[ue], Lt = y ? -ie[Ie] / 2 : 0, pe = T === U ? k[Ie] : ie[Ie], Cn = T === U ? -ie[Ie] : -k[Ie], In = r.elements.arrow, Dt = y && In ? ke(In) : { width: 0, height: 0 }, he = r.modifiersData["arrow#persistent"] ? r.modifiersData["arrow#persistent"].padding : st(), Et = he[_e], hn = he[ue], vn = fe(0, k[Ie], Dt[Ie]), kt = x ? k[Ie] / 2 - Lt - vn - Et - Y.mainAxis : pe - vn - Et - Y.mainAxis, Ce = x ? -k[Ie] / 2 + Lt + vn + hn + Y.mainAxis : Cn + vn + hn + Y.mainAxis, de = r.elements.arrow && se(r.elements.arrow), Ue = de ? L === "y" ? de.clientTop || 0 : de.clientLeft || 0 : 0, Ne = (F = D == null ? void 0 : D[L]) != null ? F : 0, Ve = ze + kt - Ne - Ue, Pt = ze + Ce - Ne, jt = fe(y ? ve(Fe, Ve) : Fe, ze, y ? X(Oe, Pt) : Oe);
24087
24092
  M[L] = jt, re[L] = jt - ze;
24088
24093
  }
24089
24094
  if (d) {
@@ -25579,42 +25584,42 @@ const __default__$a = defineComponent({
25579
25584
  n.rules && kt.push(...castArray(n.rules));
25580
25585
  const Ce = a == null ? void 0 : a.rules;
25581
25586
  if (Ce && n.prop) {
25582
- const he = getProp(Ce, n.prop).value;
25583
- he && kt.push(...castArray(he));
25587
+ const de = getProp(Ce, n.prop).value;
25588
+ de && kt.push(...castArray(de));
25584
25589
  }
25585
25590
  if (vn !== void 0) {
25586
- const he = kt.map((Ue, Ne) => [Ue, Ne]).filter(([Ue]) => Object.keys(Ue).includes("required"));
25587
- if (he.length > 0)
25588
- for (const [Ue, Ne] of he)
25591
+ const de = kt.map((Ue, Ne) => [Ue, Ne]).filter(([Ue]) => Object.keys(Ue).includes("required"));
25592
+ if (de.length > 0)
25593
+ for (const [Ue, Ne] of de)
25589
25594
  Ue.required !== vn && (kt[Ne] = { ...Ue, required: vn });
25590
25595
  else
25591
25596
  kt.push({ required: vn });
25592
25597
  }
25593
25598
  return kt;
25594
- }), F = computed(() => re.value.length > 0), _e = (vn) => re.value.filter((Ce) => !Ce.trigger || !vn ? !0 : Array.isArray(Ce.trigger) ? Ce.trigger.includes(vn) : Ce.trigger === vn).map(({ trigger: Ce, ...he }) => he), ue = computed(() => re.value.some((vn) => vn.required)), Ie = computed(() => {
25599
+ }), F = computed(() => re.value.length > 0), _e = (vn) => re.value.filter((Ce) => !Ce.trigger || !vn ? !0 : Array.isArray(Ce.trigger) ? Ce.trigger.includes(vn) : Ce.trigger === vn).map(({ trigger: Ce, ...de }) => de), ue = computed(() => re.value.some((vn) => vn.required)), Ie = computed(() => {
25595
25600
  var vn;
25596
25601
  return v.value === "error" && n.showMessage && ((vn = a == null ? void 0 : a.showMessage) != null ? vn : !0);
25597
25602
  }), ze = computed(() => `${n.label || ""}${(a == null ? void 0 : a.labelSuffix) || ""}`), Fe = (vn) => {
25598
25603
  _.value = vn;
25599
- }, Ve = (vn) => {
25604
+ }, Oe = (vn) => {
25600
25605
  var kt, Ce;
25601
- const { errors: he, fields: Ue } = vn;
25602
- (!he || !Ue) && console.error(vn), Fe("error"), g.value = he ? (Ce = (kt = he == null ? void 0 : he[0]) == null ? void 0 : kt.message) != null ? Ce : `${n.prop} is required` : "", a == null || a.emit("validate", n.prop, !1, g.value);
25606
+ const { errors: de, fields: Ue } = vn;
25607
+ (!de || !Ue) && console.error(vn), Fe("error"), g.value = de ? (Ce = (kt = de == null ? void 0 : de[0]) == null ? void 0 : kt.message) != null ? Ce : `${n.prop} is required` : "", a == null || a.emit("validate", n.prop, !1, g.value);
25603
25608
  }, Lt = () => {
25604
25609
  Fe("success"), a == null || a.emit("validate", n.prop, !0, "");
25605
25610
  }, pe = async (vn) => {
25606
25611
  const kt = M.value;
25607
25612
  return new Schema({
25608
25613
  [kt]: vn
25609
- }).validate({ [kt]: D.value }, { firstFields: !0 }).then(() => (Lt(), !0)).catch((he) => (Ve(he), Promise.reject(he)));
25614
+ }).validate({ [kt]: D.value }, { firstFields: !0 }).then(() => (Lt(), !0)).catch((de) => (Oe(de), Promise.reject(de)));
25610
25615
  }, Cn = async (vn, kt) => {
25611
25616
  if (A || !n.prop)
25612
25617
  return !1;
25613
25618
  const Ce = isFunction(kt);
25614
25619
  if (!F.value)
25615
25620
  return kt == null || kt(!1), !1;
25616
- const he = _e(vn);
25617
- return he.length === 0 ? (kt == null || kt(!0), !0) : (Fe("validating"), pe(he).then(() => (kt == null || kt(!0), !0)).catch((Ue) => {
25621
+ const de = _e(vn);
25622
+ return de.length === 0 ? (kt == null || kt(!0), !0) : (Fe("validating"), pe(de).then(() => (kt == null || kt(!0), !0)).catch((Ue) => {
25618
25623
  const { fields: Ne } = Ue;
25619
25624
  return kt == null || kt(!1, Ne), Ce ? !1 : Promise.reject(Ne);
25620
25625
  }));
@@ -25626,7 +25631,7 @@ const __default__$a = defineComponent({
25626
25631
  return;
25627
25632
  const kt = getProp(vn, n.prop);
25628
25633
  A = !0, kt.value = clone$3(b), await nextTick(), In(), A = !1;
25629
- }, de = (vn) => {
25634
+ }, he = (vn) => {
25630
25635
  p.value.includes(vn) || p.value.push(vn);
25631
25636
  }, Et = (vn) => {
25632
25637
  p.value = p.value.filter((kt) => kt !== vn);
@@ -25644,7 +25649,7 @@ const __default__$a = defineComponent({
25644
25649
  isGroup: $,
25645
25650
  hasLabel: k,
25646
25651
  fieldValue: D,
25647
- addInputId: de,
25652
+ addInputId: he,
25648
25653
  removeInputId: Et,
25649
25654
  resetField: Dt,
25650
25655
  clearValidate: In,
@@ -25885,7 +25890,7 @@ const inputProps = buildProps({
25885
25890
  [A.b("group")]: u.prepend || u.append,
25886
25891
  [A.m("prefix")]: u.prefix || o.prefixIcon,
25887
25892
  [A.m("suffix")]: u.suffix || o.suffixIcon || o.clearable || o.showPassword,
25888
- [A.bm("suffix", "password-clear")]: Ve.value && Lt.value,
25893
+ [A.bm("suffix", "password-clear")]: Oe.value && Lt.value,
25889
25894
  [A.b("hidden")]: o.type === "hidden"
25890
25895
  },
25891
25896
  a.class
@@ -25913,7 +25918,7 @@ const inputProps = buildProps({
25913
25918
  o.inputStyle,
25914
25919
  M.value,
25915
25920
  { resize: o.resize }
25916
- ]), Fe = computed(() => isNil(o.modelValue) ? "" : String(o.modelValue)), Ve = computed(() => o.clearable && !b.value && !o.readonly && !!Fe.value && ($.value || x.value)), Lt = computed(() => o.showPassword && !b.value && !!Fe.value && (!!Fe.value || $.value)), pe = computed(() => o.showWordLimit && !!o.maxlength && (o.type === "text" || o.type === "textarea") && !b.value && !o.readonly && !o.showPassword), Cn = computed(() => Fe.value.length), In = computed(() => !!pe.value && Cn.value > Number(o.maxlength)), Dt = computed(() => !!u.suffix || !!o.suffixIcon || Ve.value || o.showPassword || pe.value || !!F.value && re.value), [de, Et] = useCursor(S);
25921
+ ]), Fe = computed(() => isNil(o.modelValue) ? "" : String(o.modelValue)), Oe = computed(() => o.clearable && !b.value && !o.readonly && !!Fe.value && ($.value || x.value)), Lt = computed(() => o.showPassword && !b.value && !!Fe.value && (!!Fe.value || $.value)), pe = computed(() => o.showWordLimit && !!o.maxlength && (o.type === "text" || o.type === "textarea") && !b.value && !o.readonly && !o.showPassword), Cn = computed(() => Fe.value.length), In = computed(() => !!pe.value && Cn.value > Number(o.maxlength)), Dt = computed(() => !!u.suffix || !!o.suffixIcon || Oe.value || o.showPassword || pe.value || !!F.value && re.value), [he, Et] = useCursor(S);
25917
25922
  useResizeObserver(T, (qe) => {
25918
25923
  if (kt(), !pe.value || o.resize !== "both")
25919
25924
  return;
@@ -25948,8 +25953,8 @@ const inputProps = buildProps({
25948
25953
  })(hn), Ce = () => {
25949
25954
  const qe = k.value, bn = o.formatter ? o.formatter(Fe.value) : Fe.value;
25950
25955
  !qe || qe.value === bn || (qe.value = bn);
25951
- }, he = async (qe) => {
25952
- de();
25956
+ }, de = async (qe) => {
25957
+ he();
25953
25958
  let { value: bn } = qe.target;
25954
25959
  if (o.formatter && (bn = o.parser ? o.parser(bn) : bn), !Ne.value) {
25955
25960
  if (bn === Fe.value) {
@@ -25962,10 +25967,10 @@ const inputProps = buildProps({
25962
25967
  n("change", qe.target.value);
25963
25968
  }, {
25964
25969
  isComposing: Ne,
25965
- handleCompositionStart: Oe,
25970
+ handleCompositionStart: Ve,
25966
25971
  handleCompositionUpdate: Pt,
25967
25972
  handleCompositionEnd: jt
25968
- } = useComposition({ emit: n, afterComposition: he }), _n = () => {
25973
+ } = useComposition({ emit: n, afterComposition: de }), _n = () => {
25969
25974
  L.value = !L.value, oe();
25970
25975
  }, oe = async () => {
25971
25976
  var qe;
@@ -26069,10 +26074,10 @@ const inputProps = buildProps({
26069
26074
  style: qe.inputStyle,
26070
26075
  form: qe.form,
26071
26076
  autofocus: qe.autofocus,
26072
- onCompositionstart: unref(Oe),
26077
+ onCompositionstart: unref(Ve),
26073
26078
  onCompositionupdate: unref(Pt),
26074
26079
  onCompositionend: unref(jt),
26075
- onInput: he,
26080
+ onInput: de,
26076
26081
  onChange: Ue,
26077
26082
  onKeydown: z
26078
26083
  }), null, 16, ["id", "minlength", "maxlength", "type", "disabled", "readonly", "autocomplete", "tabindex", "aria-label", "placeholder", "form", "autofocus", "onCompositionstart", "onCompositionupdate", "onCompositionend"]),
@@ -26084,7 +26089,7 @@ const inputProps = buildProps({
26084
26089
  createElementVNode("span", {
26085
26090
  class: normalizeClass(unref(A).e("suffix-inner"))
26086
26091
  }, [
26087
- !unref(Ve) || !unref(Lt) || !unref(pe) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
26092
+ !unref(Oe) || !unref(Lt) || !unref(pe) ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
26088
26093
  renderSlot(qe.$slots, "suffix"),
26089
26094
  qe.suffixIcon ? (openBlock(), createBlock(unref(ElIcon), {
26090
26095
  key: 0,
@@ -26096,7 +26101,7 @@ const inputProps = buildProps({
26096
26101
  _: 1
26097
26102
  }, 8, ["class"])) : createCommentVNode("v-if", !0)
26098
26103
  ], 64)) : createCommentVNode("v-if", !0),
26099
- unref(Ve) ? (openBlock(), createBlock(unref(ElIcon), {
26104
+ unref(Oe) ? (openBlock(), createBlock(unref(ElIcon), {
26100
26105
  key: 1,
26101
26106
  class: normalizeClass([unref(A).e("icon"), unref(A).e("clear")]),
26102
26107
  onMousedown: withModifiers(unref(NOOP), ["prevent"]),
@@ -26168,10 +26173,10 @@ const inputProps = buildProps({
26168
26173
  form: qe.form,
26169
26174
  autofocus: qe.autofocus,
26170
26175
  rows: qe.rows,
26171
- onCompositionstart: unref(Oe),
26176
+ onCompositionstart: unref(Ve),
26172
26177
  onCompositionupdate: unref(Pt),
26173
26178
  onCompositionend: unref(jt),
26174
- onInput: he,
26179
+ onInput: de,
26175
26180
  onFocus: unref(Y),
26176
26181
  onBlur: unref(D),
26177
26182
  onChange: Ue,
@@ -27203,8 +27208,8 @@ const DEFAULT_ARROW_OFFSET = 0, usePopperContent = (i) => {
27203
27208
  Y == null || Y(), Y = void 0;
27204
27209
  const ue = unref(F || y.value), Ie = unref(_e || y.value);
27205
27210
  isElement(ue) && (Y = watch([w, () => o.ariaLabel, T, () => o.id], (ze) => {
27206
- ["role", "aria-label", "aria-modal", "id"].forEach((Fe, Ve) => {
27207
- isNil(ze[Ve]) ? ue.removeAttribute(Fe) : ue.setAttribute(Fe, ze[Ve]);
27211
+ ["role", "aria-label", "aria-modal", "id"].forEach((Fe, Oe) => {
27212
+ isNil(ze[Oe]) ? ue.removeAttribute(Fe) : ue.setAttribute(Fe, ze[Oe]);
27208
27213
  });
27209
27214
  }, { immediate: !0 })), Ie !== ue && isElement(Ie) && ["role", "aria-label", "aria-modal", "id"].forEach((ze) => {
27210
27215
  Ie.removeAttribute(ze);
@@ -27959,7 +27964,7 @@ const MINIMUM_INPUT_WIDTH = 11, useSelect = (i, r) => {
27959
27964
  }
27960
27965
  }), Y = ref(!1), D = ref(), { form: re, formItem: F } = useFormItem(), { inputId: _e } = useFormItemInputId(i, {
27961
27966
  formItemContext: F
27962
- }), { valueOnClear: ue, isEmptyValue: Ie } = useEmptyValues(i), ze = computed(() => i.disabled || (re == null ? void 0 : re.disabled)), Fe = computed(() => isArray(i.modelValue) ? i.modelValue.length > 0 : !Ie(i.modelValue)), Ve = computed(() => i.clearable && !ze.value && c.inputHovering && Fe.value), Lt = computed(() => i.remote && i.filterable && !i.remoteShowSuffix ? "" : i.suffixIcon), pe = computed(() => a.is("reverse", Lt.value && Y.value)), Cn = computed(() => (F == null ? void 0 : F.validateState) || ""), In = computed(() => ValidateComponentsMap[Cn.value]), Dt = computed(() => i.remote ? 300 : 0), de = computed(() => i.loading ? i.loadingText || n("el.select.loading") : i.remote && !c.inputValue && c.options.size === 0 ? !1 : i.filterable && c.inputValue && c.options.size > 0 && Et.value === 0 ? i.noMatchText || n("el.select.noMatch") : c.options.size === 0 ? i.noDataText || n("el.select.noData") : null), Et = computed(() => hn.value.filter((An) => An.visible).length), hn = computed(() => {
27967
+ }), { valueOnClear: ue, isEmptyValue: Ie } = useEmptyValues(i), ze = computed(() => i.disabled || (re == null ? void 0 : re.disabled)), Fe = computed(() => isArray(i.modelValue) ? i.modelValue.length > 0 : !Ie(i.modelValue)), Oe = computed(() => i.clearable && !ze.value && c.inputHovering && Fe.value), Lt = computed(() => i.remote && i.filterable && !i.remoteShowSuffix ? "" : i.suffixIcon), pe = computed(() => a.is("reverse", Lt.value && Y.value)), Cn = computed(() => (F == null ? void 0 : F.validateState) || ""), In = computed(() => ValidateComponentsMap[Cn.value]), Dt = computed(() => i.remote ? 300 : 0), he = computed(() => i.loading ? i.loadingText || n("el.select.loading") : i.remote && !c.inputValue && c.options.size === 0 ? !1 : i.filterable && c.inputValue && c.options.size > 0 && Et.value === 0 ? i.noMatchText || n("el.select.noMatch") : c.options.size === 0 ? i.noDataText || n("el.select.noData") : null), Et = computed(() => hn.value.filter((An) => An.visible).length), hn = computed(() => {
27963
27968
  const An = Array.from(c.options.values()), Tn = [];
27964
27969
  return c.optionValues.forEach((Bn) => {
27965
27970
  const Nn = An.findIndex((Gn) => Gn.value === Bn);
@@ -27973,14 +27978,14 @@ const MINIMUM_INPUT_WIDTH = 11, useSelect = (i, r) => {
27973
27978
  var Tn;
27974
27979
  (Tn = An.updateOption) == null || Tn.call(An, c.inputValue);
27975
27980
  });
27976
- }, he = useFormSize(), Ue = computed(() => ["small"].includes(he.value) ? "small" : "default"), Ne = computed({
27981
+ }, de = useFormSize(), Ue = computed(() => ["small"].includes(de.value) ? "small" : "default"), Ne = computed({
27977
27982
  get() {
27978
- return Y.value && de.value !== !1;
27983
+ return Y.value && he.value !== !1;
27979
27984
  },
27980
27985
  set(An) {
27981
27986
  Y.value = An;
27982
27987
  }
27983
- }), Oe = computed(() => {
27988
+ }), Ve = computed(() => {
27984
27989
  if (i.multiple && !isUndefined(i.modelValue))
27985
27990
  return castArray(i.modelValue).length === 0 && !c.inputValue;
27986
27991
  const An = isArray(i.modelValue) ? i.modelValue[0] : i.modelValue;
@@ -28196,7 +28201,7 @@ const MINIMUM_INPUT_WIDTH = 11, useSelect = (i, r) => {
28196
28201
  expanded: Y,
28197
28202
  optionsArray: hn,
28198
28203
  hoverOption: D,
28199
- selectSize: he,
28204
+ selectSize: de,
28200
28205
  filteredOptionsCount: Et,
28201
28206
  resetCalculatorWidth: ae,
28202
28207
  updateTooltip: qe,
@@ -28209,10 +28214,10 @@ const MINIMUM_INPUT_WIDTH = 11, useSelect = (i, r) => {
28209
28214
  handleOptionSelect: Mn,
28210
28215
  scrollToOption: $n,
28211
28216
  hasModelValue: Fe,
28212
- shouldShowPlaceholder: Oe,
28217
+ shouldShowPlaceholder: Ve,
28213
28218
  currentPlaceholder: Pt,
28214
28219
  mouseEnterEventName: jt,
28215
- showClose: Ve,
28220
+ showClose: Oe,
28216
28221
  iconComponent: Lt,
28217
28222
  iconReverse: pe,
28218
28223
  validateState: Cn,
@@ -28222,7 +28227,7 @@ const MINIMUM_INPUT_WIDTH = 11, useSelect = (i, r) => {
28222
28227
  collapseTagSize: Ue,
28223
28228
  setSelected: le,
28224
28229
  selectDisabled: ze,
28225
- emptyText: de,
28230
+ emptyText: he,
28226
28231
  handleCompositionStart: L,
28227
28232
  handleCompositionUpdate: O,
28228
28233
  handleCompositionEnd: M,
@@ -30066,12 +30071,12 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30066
30071
  emits: ["onLineMouseUp"],
30067
30072
  setup(i, { emit: r }) {
30068
30073
  const n = r, o = i, a = useSvgEditLayoutStore(pinia), u = useConfigStore(pinia), c = function() {
30069
- return function(Ce, he, Ue) {
30070
- Ce && he && Ue && Ce.addEventListener(he, Ue, !1);
30074
+ return function(Ce, de, Ue) {
30075
+ Ce && de && Ue && Ce.addEventListener(de, Ue, !1);
30071
30076
  };
30072
30077
  }(), d = function() {
30073
- return function(Ce, he, Ue) {
30074
- Ce && he && Ce.removeEventListener(he, Ue, !1);
30078
+ return function(Ce, de, Ue) {
30079
+ Ce && de && Ce.removeEventListener(de, Ue, !1);
30075
30080
  };
30076
30081
  }();
30077
30082
  let f = 18, p = ref(0), _ = ref(0), v = ref([]), g = ref([]);
@@ -30083,11 +30088,11 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30083
30088
  })), Y = computed(() => ({
30084
30089
  padding: f + "px 0px 0px " + f + "px"
30085
30090
  })), D = computed(() => {
30086
- let Ce = 0, he = 0;
30091
+ let Ce = 0, de = 0;
30087
30092
  return y.value.map((Ue) => {
30088
30093
  const Ne = Ue.type === "h";
30089
30094
  return {
30090
- id: `${Ue.type}_${Ne ? Ce++ : he++}`,
30095
+ id: `${Ue.type}_${Ne ? Ce++ : de++}`,
30091
30096
  type: Ue.type,
30092
30097
  title: Ue.site.toFixed(0) + "px",
30093
30098
  [Ne ? "top" : "left"]: Ue.site * u.svg.scale + f + a.center_offset[Ne ? "y" : "x"] * u.svg.scale
@@ -30095,34 +30100,34 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30095
30100
  });
30096
30101
  });
30097
30102
  a.$subscribe((Ce) => {
30098
- var he, Ue, Ne, Oe;
30099
- ((Ue = (he = Ce.events) == null ? void 0 : he.target) != null && Ue.hasOwnProperty("left_nav") || (Oe = (Ne = Ce.events) == null ? void 0 : Ne.target) != null && Oe.hasOwnProperty("right_nav")) && window.setTimeout(re, 420);
30103
+ var de, Ue, Ne, Ve;
30104
+ ((Ue = (de = Ce.events) == null ? void 0 : de.target) != null && Ue.hasOwnProperty("left_nav") || (Ve = (Ne = Ce.events) == null ? void 0 : Ne.target) != null && Ve.hasOwnProperty("right_nav")) && window.setTimeout(re, 420);
30100
30105
  }), u.$subscribe((Ce) => {
30101
- var he, Ue;
30102
- (Ue = (he = Ce.events) == null ? void 0 : he.target) != null && Ue.hasOwnProperty("scale") && ze();
30106
+ var de, Ue;
30107
+ (Ue = (de = Ce.events) == null ? void 0 : de.target) != null && Ue.hasOwnProperty("scale") && ze();
30103
30108
  }), onMounted(() => {
30104
- c(document, "mousemove", Ve), c(document, "mouseup", Cn), re(), c(window, "resize", F);
30109
+ c(document, "mousemove", Oe), c(document, "mouseup", Cn), re(), c(window, "resize", F);
30105
30110
  }), onBeforeUnmount(() => {
30106
- d(document, "mousemove", Ve), d(document, "mouseup", Cn), d(window, "resize", F);
30111
+ d(document, "mousemove", Oe), d(document, "mouseup", Cn), d(window, "resize", F);
30107
30112
  });
30108
30113
  const re = () => {
30109
30114
  Ie(), ze();
30110
30115
  }, F = () => {
30111
30116
  v.value = [], g.value = [], re();
30112
- }, _e = ({ type: Ce, top: he, left: Ue }) => Ce === "h" ? { top: he + "px" } : { left: Ue + "px" }, ue = ({ type: Ce, id: he }) => Ce === "h" ? hn(he) : vn(he), Ie = () => {
30117
+ }, _e = ({ type: Ce, top: de, left: Ue }) => Ce === "h" ? { top: de + "px" } : { left: Ue + "px" }, ue = ({ type: Ce, id: de }) => Ce === "h" ? hn(de) : vn(de), Ie = () => {
30113
30118
  const Ce = window.getComputedStyle(M.value.parentNode, null);
30114
30119
  p.value = parseInt(Ce.getPropertyValue("width")), _.value = parseInt(Ce.getPropertyValue("height")), T = k.value.clientWidth, x = ie.value.clientHeight;
30115
30120
  }, ze = () => {
30116
30121
  Fe(v.value, p.value, a.center_offset.x), Fe(g.value, _.value, a.center_offset.y);
30117
- }, Fe = (Ce, he, Ue) => {
30122
+ }, Fe = (Ce, de, Ue) => {
30118
30123
  if (Ce.length === 0)
30119
- for (let Ne = 0; Ne < he; Ne += o.stepLength)
30124
+ for (let Ne = 0; Ne < de; Ne += o.stepLength)
30120
30125
  Ne % o.stepLength === 0 && Ce.push({ id: myFixed(Ne / u.svg.scale - Ue, 0) });
30121
30126
  else
30122
- Ce.forEach((Ne, Oe) => {
30123
- Ne.id = myFixed(Oe * o.stepLength / u.svg.scale - Ue, 0);
30127
+ Ce.forEach((Ne, Ve) => {
30128
+ Ne.id = myFixed(Ve * o.stepLength / u.svg.scale - Ue, 0);
30124
30129
  });
30125
- }, Ve = (Ce) => {
30130
+ }, Oe = (Ce) => {
30126
30131
  ze(), Lt(Ce);
30127
30132
  }, Lt = (Ce) => {
30128
30133
  if (!(Ce.layerX === Ce.x || Ce.layerY === Ce.y))
@@ -30148,16 +30153,16 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30148
30153
  if (b.value) {
30149
30154
  switch (b.value = !1, A) {
30150
30155
  case "x":
30151
- const he = Math.round(
30156
+ const de = Math.round(
30152
30157
  (Ce.layerY - f) / u.svg.scale - a.center_offset.y
30153
30158
  );
30154
- if (he <= 0) {
30159
+ if (de <= 0) {
30155
30160
  S.value = -999;
30156
30161
  return;
30157
30162
  }
30158
30163
  y.value.push({
30159
30164
  type: "h",
30160
- site: he
30165
+ site: de
30161
30166
  });
30162
30167
  break;
30163
30168
  case "y":
@@ -30192,22 +30197,22 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30192
30197
  }
30193
30198
  S.value = w.value = -999;
30194
30199
  }
30195
- }, Dt = (Ce, he, Ue, Ne) => {
30196
- if (he < Ue) {
30197
- let Oe;
30200
+ }, Dt = (Ce, de, Ue, Ne) => {
30201
+ if (de < Ue) {
30202
+ let Ve;
30198
30203
  D.value.forEach((Pt, jt) => {
30199
- Pt.id === L && (Oe = jt);
30200
- }), Ce.splice(Oe, 1);
30204
+ Pt.id === L && (Ve = jt);
30205
+ }), Ce.splice(Ve, 1);
30201
30206
  } else {
30202
- let Oe;
30207
+ let Ve;
30203
30208
  D.value.forEach((Pt, jt) => {
30204
- Pt.id === L && (Oe = jt);
30205
- }), Ce.splice(Oe, 1, {
30209
+ Pt.id === L && (Ve = jt);
30210
+ }), Ce.splice(Ve, 1, {
30206
30211
  type: Ne,
30207
- site: he
30212
+ site: de
30208
30213
  });
30209
30214
  }
30210
- }, de = () => {
30215
+ }, he = () => {
30211
30216
  pe("x");
30212
30217
  }, Et = () => {
30213
30218
  pe("y");
@@ -30218,7 +30223,7 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30218
30223
  }, kt = () => {
30219
30224
  n("onLineMouseUp");
30220
30225
  };
30221
- return (Ce, he) => (openBlock(), createElementBlock("div", {
30226
+ return (Ce, de) => (openBlock(), createElementBlock("div", {
30222
30227
  style: normalizeStyle$1(unref($)),
30223
30228
  class: "vue-ruler-wrapper",
30224
30229
  onselectStart: "return false;",
@@ -30230,7 +30235,7 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30230
30235
  ref_key: "horizontalRuler",
30231
30236
  ref: ie,
30232
30237
  class: "vue-ruler-h",
30233
- onMousedown: withModifiers(de, ["stop"])
30238
+ onMousedown: withModifiers(he, ["stop"])
30234
30239
  }, [
30235
30240
  (openBlock(!0), createElementBlock(Fragment, null, renderList(unref(v), (Ue, Ne) => (openBlock(), createElementBlock("span", {
30236
30241
  style: normalizeStyle$1({ left: Ne * Ce.stepLength + "px" }),
@@ -30267,7 +30272,7 @@ const _hoisted_1$4 = { class: "c-wall-d" }, _sfc_main$7 = /* @__PURE__ */ define
30267
30272
  class: normalizeClass(`vue-ruler-ref-line-${Ue.type}`),
30268
30273
  onMousedown: (Ne) => ue(Ue),
30269
30274
  onMouseup: kt,
30270
- onContextmenu: he[0] || (he[0] = //@ts-ignore
30275
+ onContextmenu: de[0] || (de[0] = //@ts-ignore
30271
30276
  (...Ne) => unref(preventDefault) && unref(preventDefault)(...Ne))
30272
30277
  }, null, 46, _hoisted_1$2))), 128))
30273
30278
  ], 512), [
@@ -30627,8 +30632,8 @@ var mqtt = { exports: {} };
30627
30632
  }
30628
30633
  ze = Ie.packet, this.log("deliver :: call _sendPacket for %o", ze);
30629
30634
  let Fe = !0;
30630
- ze.messageId && ze.messageId !== 0 && (this.messageIdProvider.register(ze.messageId) || (Fe = !1)), Fe ? this._sendPacket(ze, (Ve) => {
30631
- Ie.cb && Ie.cb(Ve), ue();
30635
+ ze.messageId && ze.messageId !== 0 && (this.messageIdProvider.register(ze.messageId) || (Fe = !1)), Fe ? this._sendPacket(ze, (Oe) => {
30636
+ Ie.cb && Ie.cb(Oe), ue();
30632
30637
  }) : (this.log("messageId: %d has already used. The message is skipped and removed.", ze.messageId), ue());
30633
30638
  };
30634
30639
  this.log("connect :: sending queued packets"), ue();
@@ -30677,10 +30682,10 @@ var mqtt = { exports: {} };
30677
30682
  F._write = (pe, Cn, In) => {
30678
30683
  ue = In, this.log("writable stream :: parsing buffer"), _e.parse(pe), ze();
30679
30684
  };
30680
- const Ve = (pe) => {
30685
+ const Oe = (pe) => {
30681
30686
  this.log("streamErrorHandler :: error", pe.message), $.includes(pe.code) ? (this.log("streamErrorHandler :: emitting error"), this.emit("error", pe)) : this.noop(pe);
30682
30687
  };
30683
- this.log("connect :: pipe stream to writable stream"), this.stream.pipe(F), this.stream.on("error", Ve), this.stream.on("close", () => {
30688
+ this.log("connect :: pipe stream to writable stream"), this.stream.pipe(F), this.stream.on("error", Oe), this.stream.on("close", () => {
30684
30689
  this.log("(%s)stream :: on close", this.options.clientId), this._flushVolatile(), this.log("stream: emit close to MqttClient"), this.emit("close");
30685
30690
  }), this.log("connect: sending packet `connect`");
30686
30691
  const Lt = {
@@ -30714,32 +30719,32 @@ var mqtt = { exports: {} };
30714
30719
  retain: !1,
30715
30720
  dup: !1
30716
30721
  }), _e);
30717
- const { qos: Fe, retain: Ve, dup: Lt, properties: pe, cbStorePut: Cn } = _e;
30722
+ const { qos: Fe, retain: Oe, dup: Lt, properties: pe, cbStorePut: Cn } = _e;
30718
30723
  if (this._checkDisconnecting(ue))
30719
30724
  return this;
30720
30725
  const In = () => {
30721
30726
  let Dt = 0;
30722
30727
  if ((Fe === 1 || Fe === 2) && (Dt = this._nextId(), Dt === null))
30723
30728
  return this.log("No messageId left"), !1;
30724
- const de = {
30729
+ const he = {
30725
30730
  cmd: "publish",
30726
30731
  topic: re,
30727
30732
  payload: F,
30728
30733
  qos: Fe,
30729
- retain: Ve,
30734
+ retain: Oe,
30730
30735
  messageId: Dt,
30731
30736
  dup: Lt
30732
30737
  };
30733
- switch (Ie.protocolVersion === 5 && (de.properties = pe), this.log("publish :: qos", Fe), Fe) {
30738
+ switch (Ie.protocolVersion === 5 && (he.properties = pe), this.log("publish :: qos", Fe), Fe) {
30734
30739
  case 1:
30735
30740
  case 2:
30736
- this.outgoing[de.messageId] = {
30741
+ this.outgoing[he.messageId] = {
30737
30742
  volatile: !1,
30738
30743
  cb: ue || this.noop
30739
- }, this.log("MqttClient:publish: packet cmd: %s", de.cmd), this._sendPacket(de, void 0, Cn);
30744
+ }, this.log("MqttClient:publish: packet cmd: %s", he.cmd), this._sendPacket(he, void 0, Cn);
30740
30745
  break;
30741
30746
  default:
30742
- this.log("MqttClient:publish: packet cmd: %s", de.cmd), this._sendPacket(de, ue, Cn);
30747
+ this.log("MqttClient:publish: packet cmd: %s", he.cmd), this._sendPacket(he, ue, Cn);
30743
30748
  break;
30744
30749
  }
30745
30750
  return !0;
@@ -30767,17 +30772,17 @@ var mqtt = { exports: {} };
30767
30772
  return k(_e, new Error(`Invalid topic ${Fe}`)), this;
30768
30773
  if (this._checkDisconnecting(_e))
30769
30774
  return this.log("subscribe: discconecting true"), this;
30770
- const Ve = {
30775
+ const Oe = {
30771
30776
  qos: 0
30772
30777
  };
30773
- ue === 5 && (Ve.nl = !1, Ve.rap = !1, Ve.rh = 0), F = Object.assign(Object.assign({}, Ve), F);
30774
- const Lt = F.properties, pe = [], Cn = (Dt, de) => {
30775
- if (de = de || F, !Object.prototype.hasOwnProperty.call(this._resubscribeTopics, Dt) || this._resubscribeTopics[Dt].qos < de.qos || Ie) {
30778
+ ue === 5 && (Oe.nl = !1, Oe.rap = !1, Oe.rh = 0), F = Object.assign(Object.assign({}, Oe), F);
30779
+ const Lt = F.properties, pe = [], Cn = (Dt, he) => {
30780
+ if (he = he || F, !Object.prototype.hasOwnProperty.call(this._resubscribeTopics, Dt) || this._resubscribeTopics[Dt].qos < he.qos || Ie) {
30776
30781
  const Et = {
30777
30782
  topic: Dt,
30778
- qos: de.qos
30783
+ qos: he.qos
30779
30784
  };
30780
- ue === 5 && (Et.nl = de.nl, Et.rap = de.rap, Et.rh = de.rh, Et.properties = Lt), this.log("subscribe: pushing topic `%s` and qos `%s` to subs list", Et.topic, Et.qos), pe.push(Et);
30785
+ ue === 5 && (Et.nl = he.nl, Et.rap = he.rap, Et.rh = he.rh, Et.properties = Lt), this.log("subscribe: pushing topic `%s` and qos `%s` to subs list", Et.topic, Et.qos), pe.push(Et);
30781
30786
  }
30782
30787
  };
30783
30788
  if (Array.isArray(re) ? re.forEach((Dt) => {
@@ -30790,12 +30795,12 @@ var mqtt = { exports: {} };
30790
30795
  const Dt = this._nextId();
30791
30796
  if (Dt === null)
30792
30797
  return this.log("No messageId left"), !1;
30793
- const de = {
30798
+ const he = {
30794
30799
  cmd: "subscribe",
30795
30800
  subscriptions: pe,
30796
30801
  messageId: Dt
30797
30802
  };
30798
- if (Lt && (de.properties = Lt), this.options.resubscribe) {
30803
+ if (Lt && (he.properties = Lt), this.options.resubscribe) {
30799
30804
  this.log("subscribe :: resubscribe true");
30800
30805
  const Et = [];
30801
30806
  pe.forEach((hn) => {
@@ -30803,9 +30808,9 @@ var mqtt = { exports: {} };
30803
30808
  const vn = { qos: hn.qos };
30804
30809
  ue === 5 && (vn.nl = hn.nl || !1, vn.rap = hn.rap || !1, vn.rh = hn.rh || 0, vn.properties = hn.properties), this._resubscribeTopics[hn.topic] = vn, Et.push(hn.topic);
30805
30810
  }
30806
- }), this.messageIdToTopic[de.messageId] = Et;
30811
+ }), this.messageIdToTopic[he.messageId] = Et;
30807
30812
  }
30808
- return this.outgoing[de.messageId] = {
30813
+ return this.outgoing[he.messageId] = {
30809
30814
  volatile: !0,
30810
30815
  cb(Et, hn) {
30811
30816
  if (!Et) {
@@ -30815,7 +30820,7 @@ var mqtt = { exports: {} };
30815
30820
  }
30816
30821
  _e(Et, pe);
30817
30822
  }
30818
- }, this.log("subscribe :: call _sendPacket"), this._sendPacket(de), !0;
30823
+ }, this.log("subscribe :: call _sendPacket"), this._sendPacket(he), !0;
30819
30824
  };
30820
30825
  return (this._storeProcessing || this._storeProcessingQueue.length > 0 || !In()) && this._storeProcessingQueue.push({
30821
30826
  invoke: In,
@@ -30845,8 +30850,8 @@ var mqtt = { exports: {} };
30845
30850
  messageId: ze,
30846
30851
  unsubscriptions: []
30847
30852
  };
30848
- return typeof re == "string" ? Fe.unsubscriptions = [re] : Array.isArray(re) && (Fe.unsubscriptions = re), this.options.resubscribe && Fe.unsubscriptions.forEach((Ve) => {
30849
- delete this._resubscribeTopics[Ve];
30853
+ return typeof re == "string" ? Fe.unsubscriptions = [re] : Array.isArray(re) && (Fe.unsubscriptions = re), this.options.resubscribe && Fe.unsubscriptions.forEach((Oe) => {
30854
+ delete this._resubscribeTopics[Oe];
30850
30855
  }), typeof F == "object" && F.properties && (Fe.properties = F.properties), this.outgoing[Fe.messageId] = {
30851
30856
  volatile: !0,
30852
30857
  cb: _e
@@ -30870,8 +30875,8 @@ var mqtt = { exports: {} };
30870
30875
  this.log("end :: closeStores: closing incoming and outgoing stores"), this.disconnected = !0, this.incomingStore.close((ze) => {
30871
30876
  this.outgoingStore.close((Fe) => {
30872
30877
  if (this.log("end :: closeStores: emitting end"), this.emit("end"), _e) {
30873
- const Ve = ze || Fe;
30874
- this.log("end :: closeStores: invoking callback with args"), _e(Ve);
30878
+ const Oe = ze || Fe;
30879
+ this.log("end :: closeStores: invoking callback with args"), _e(Oe);
30875
30880
  }
30876
30881
  });
30877
30882
  }), this._deferredReconnect && this._deferredReconnect();
@@ -31100,7 +31105,7 @@ var mqtt = { exports: {} };
31100
31105
  if (!_e)
31101
31106
  return;
31102
31107
  const Fe = _e.read(1);
31103
- let Ve;
31108
+ let Oe;
31104
31109
  if (!Fe) {
31105
31110
  _e.once("readable", ze);
31106
31111
  return;
@@ -31109,17 +31114,17 @@ var mqtt = { exports: {} };
31109
31114
  ze();
31110
31115
  return;
31111
31116
  }
31112
- !this.disconnecting && !this.reconnectTimer ? (Ve = this.outgoing[Fe.messageId] ? this.outgoing[Fe.messageId].cb : null, this.outgoing[Fe.messageId] = {
31117
+ !this.disconnecting && !this.reconnectTimer ? (Oe = this.outgoing[Fe.messageId] ? this.outgoing[Fe.messageId].cb : null, this.outgoing[Fe.messageId] = {
31113
31118
  volatile: !1,
31114
31119
  cb(Lt, pe) {
31115
- Ve && Ve(Lt, pe), ze();
31120
+ Oe && Oe(Lt, pe), ze();
31116
31121
  }
31117
31122
  }, this._packetIdsDuringStoreProcessing[Fe.messageId] = !0, this.messageIdProvider.register(Fe.messageId) ? this._sendPacket(Fe, void 0, void 0, !0) : this.log("messageId: %d has already used.", Fe.messageId)) : _e.destroy && _e.destroy();
31118
31123
  };
31119
31124
  _e.on("end", () => {
31120
31125
  let Fe = !0;
31121
- for (const Ve in this._packetIdsDuringStoreProcessing)
31122
- if (!this._packetIdsDuringStoreProcessing[Ve]) {
31126
+ for (const Oe in this._packetIdsDuringStoreProcessing)
31127
+ if (!this._packetIdsDuringStoreProcessing[Oe]) {
31123
31128
  Fe = !1;
31124
31129
  break;
31125
31130
  }
@@ -31397,12 +31402,12 @@ var mqtt = { exports: {} };
31397
31402
  re.close();
31398
31403
  });
31399
31404
  const _e = typeof re.addEventListener < "u";
31400
- re.readyState === re.OPEN ? k = F : (k = (0, p.default)(void 0, void 0, M), M.objectMode || (k._writev = Lt), _e ? re.addEventListener("open", Ie) : re.onopen = Ie), k.socket = re, _e ? (re.addEventListener("close", ze), re.addEventListener("error", Fe), re.addEventListener("message", Ve)) : (re.onclose = ze, re.onerror = Fe, re.onmessage = Ve);
31401
- function ue(In, Dt, de) {
31405
+ re.readyState === re.OPEN ? k = F : (k = (0, p.default)(void 0, void 0, M), M.objectMode || (k._writev = Lt), _e ? re.addEventListener("open", Ie) : re.onopen = Ie), k.socket = re, _e ? (re.addEventListener("close", ze), re.addEventListener("error", Fe), re.addEventListener("message", Oe)) : (re.onclose = ze, re.onerror = Fe, re.onmessage = Oe);
31406
+ function ue(In, Dt, he) {
31402
31407
  const Et = new _.Transform({
31403
31408
  objectMode: In.objectMode
31404
31409
  });
31405
- return Et._write = Dt, Et._flush = de, Et;
31410
+ return Et._write = Dt, Et._flush = he, Et;
31406
31411
  }
31407
31412
  function Ie() {
31408
31413
  k.setReadable(F), k.setWritable(F), k.emit("connect");
@@ -31413,24 +31418,24 @@ var mqtt = { exports: {} };
31413
31418
  function Fe(In) {
31414
31419
  k.destroy(In);
31415
31420
  }
31416
- function Ve(In) {
31421
+ function Oe(In) {
31417
31422
  let { data: Dt } = In;
31418
31423
  Dt instanceof ArrayBuffer ? Dt = c.Buffer.from(Dt) : Dt = c.Buffer.from(Dt, "utf8"), F.push(Dt);
31419
31424
  }
31420
31425
  function Lt(In, Dt) {
31421
- const de = new Array(In.length);
31426
+ const he = new Array(In.length);
31422
31427
  for (let Et = 0; Et < In.length; Et++)
31423
- typeof In[Et].chunk == "string" ? de[Et] = c.Buffer.from(In[Et], "utf8") : de[Et] = In[Et].chunk;
31424
- this._write(c.Buffer.concat(de), "binary", Dt);
31428
+ typeof In[Et].chunk == "string" ? he[Et] = c.Buffer.from(In[Et], "utf8") : he[Et] = In[Et].chunk;
31429
+ this._write(c.Buffer.concat(he), "binary", Dt);
31425
31430
  }
31426
- function pe(In, Dt, de) {
31427
- re.bufferedAmount > $ && setTimeout(pe, Y, In, Dt, de), D && typeof In == "string" && (In = c.Buffer.from(In, "utf8"));
31431
+ function pe(In, Dt, he) {
31432
+ re.bufferedAmount > $ && setTimeout(pe, Y, In, Dt, he), D && typeof In == "string" && (In = c.Buffer.from(In, "utf8"));
31428
31433
  try {
31429
31434
  re.send(In);
31430
31435
  } catch (Et) {
31431
- return de(Et);
31436
+ return he(Et);
31432
31437
  }
31433
- de();
31438
+ he();
31434
31439
  }
31435
31440
  function Cn(In) {
31436
31441
  re.close(), In();
@@ -32645,7 +32650,7 @@ var mqtt = { exports: {} };
32645
32650
  return _n(Ne(V, j.length - z), j, z, ae);
32646
32651
  }
32647
32652
  function F(j, V, z, ae) {
32648
- return _n(Oe(V), j, z, ae);
32653
+ return _n(Ve(V), j, z, ae);
32649
32654
  }
32650
32655
  function _e(j, V, z, ae) {
32651
32656
  return F(j, V, z, ae);
@@ -32728,15 +32733,15 @@ var mqtt = { exports: {} };
32728
32733
  }
32729
32734
  return Lt(ae);
32730
32735
  }
32731
- var Ve = 4096;
32736
+ var Oe = 4096;
32732
32737
  function Lt(j) {
32733
32738
  var V = j.length;
32734
- if (V <= Ve)
32739
+ if (V <= Oe)
32735
32740
  return String.fromCharCode.apply(String, j);
32736
32741
  for (var z = "", ae = 0; ae < V; )
32737
32742
  z += String.fromCharCode.apply(
32738
32743
  String,
32739
- j.slice(ae, ae += Ve)
32744
+ j.slice(ae, ae += Oe)
32740
32745
  );
32741
32746
  return z;
32742
32747
  }
@@ -32772,64 +32777,64 @@ var mqtt = { exports: {} };
32772
32777
  var xe = this.subarray(V, z);
32773
32778
  return xe.__proto__ = v.prototype, xe;
32774
32779
  };
32775
- function de(j, V, z) {
32780
+ function he(j, V, z) {
32776
32781
  if (j % 1 !== 0 || j < 0)
32777
32782
  throw new RangeError("offset is not uint");
32778
32783
  if (j + V > z)
32779
32784
  throw new RangeError("Trying to access beyond buffer length");
32780
32785
  }
32781
32786
  v.prototype.readUIntLE = function(V, z, ae) {
32782
- V = V >>> 0, z = z >>> 0, ae || de(V, z, this.length);
32787
+ V = V >>> 0, z = z >>> 0, ae || he(V, z, this.length);
32783
32788
  for (var xe = this[V], qe = 1, bn = 0; ++bn < z && (qe *= 256); )
32784
32789
  xe += this[V + bn] * qe;
32785
32790
  return xe;
32786
32791
  }, v.prototype.readUIntBE = function(V, z, ae) {
32787
- V = V >>> 0, z = z >>> 0, ae || de(V, z, this.length);
32792
+ V = V >>> 0, z = z >>> 0, ae || he(V, z, this.length);
32788
32793
  for (var xe = this[V + --z], qe = 1; z > 0 && (qe *= 256); )
32789
32794
  xe += this[V + --z] * qe;
32790
32795
  return xe;
32791
32796
  }, v.prototype.readUInt8 = function(V, z) {
32792
- return V = V >>> 0, z || de(V, 1, this.length), this[V];
32797
+ return V = V >>> 0, z || he(V, 1, this.length), this[V];
32793
32798
  }, v.prototype.readUInt16LE = function(V, z) {
32794
- return V = V >>> 0, z || de(V, 2, this.length), this[V] | this[V + 1] << 8;
32799
+ return V = V >>> 0, z || he(V, 2, this.length), this[V] | this[V + 1] << 8;
32795
32800
  }, v.prototype.readUInt16BE = function(V, z) {
32796
- return V = V >>> 0, z || de(V, 2, this.length), this[V] << 8 | this[V + 1];
32801
+ return V = V >>> 0, z || he(V, 2, this.length), this[V] << 8 | this[V + 1];
32797
32802
  }, v.prototype.readUInt32LE = function(V, z) {
32798
- return V = V >>> 0, z || de(V, 4, this.length), (this[V] | this[V + 1] << 8 | this[V + 2] << 16) + this[V + 3] * 16777216;
32803
+ return V = V >>> 0, z || he(V, 4, this.length), (this[V] | this[V + 1] << 8 | this[V + 2] << 16) + this[V + 3] * 16777216;
32799
32804
  }, v.prototype.readUInt32BE = function(V, z) {
32800
- return V = V >>> 0, z || de(V, 4, this.length), this[V] * 16777216 + (this[V + 1] << 16 | this[V + 2] << 8 | this[V + 3]);
32805
+ return V = V >>> 0, z || he(V, 4, this.length), this[V] * 16777216 + (this[V + 1] << 16 | this[V + 2] << 8 | this[V + 3]);
32801
32806
  }, v.prototype.readIntLE = function(V, z, ae) {
32802
- V = V >>> 0, z = z >>> 0, ae || de(V, z, this.length);
32807
+ V = V >>> 0, z = z >>> 0, ae || he(V, z, this.length);
32803
32808
  for (var xe = this[V], qe = 1, bn = 0; ++bn < z && (qe *= 256); )
32804
32809
  xe += this[V + bn] * qe;
32805
32810
  return qe *= 128, xe >= qe && (xe -= Math.pow(2, 8 * z)), xe;
32806
32811
  }, v.prototype.readIntBE = function(V, z, ae) {
32807
- V = V >>> 0, z = z >>> 0, ae || de(V, z, this.length);
32812
+ V = V >>> 0, z = z >>> 0, ae || he(V, z, this.length);
32808
32813
  for (var xe = z, qe = 1, bn = this[V + --xe]; xe > 0 && (qe *= 256); )
32809
32814
  bn += this[V + --xe] * qe;
32810
32815
  return qe *= 128, bn >= qe && (bn -= Math.pow(2, 8 * z)), bn;
32811
32816
  }, v.prototype.readInt8 = function(V, z) {
32812
- return V = V >>> 0, z || de(V, 1, this.length), this[V] & 128 ? (255 - this[V] + 1) * -1 : this[V];
32817
+ return V = V >>> 0, z || he(V, 1, this.length), this[V] & 128 ? (255 - this[V] + 1) * -1 : this[V];
32813
32818
  }, v.prototype.readInt16LE = function(V, z) {
32814
- V = V >>> 0, z || de(V, 2, this.length);
32819
+ V = V >>> 0, z || he(V, 2, this.length);
32815
32820
  var ae = this[V] | this[V + 1] << 8;
32816
32821
  return ae & 32768 ? ae | 4294901760 : ae;
32817
32822
  }, v.prototype.readInt16BE = function(V, z) {
32818
- V = V >>> 0, z || de(V, 2, this.length);
32823
+ V = V >>> 0, z || he(V, 2, this.length);
32819
32824
  var ae = this[V + 1] | this[V] << 8;
32820
32825
  return ae & 32768 ? ae | 4294901760 : ae;
32821
32826
  }, v.prototype.readInt32LE = function(V, z) {
32822
- return V = V >>> 0, z || de(V, 4, this.length), this[V] | this[V + 1] << 8 | this[V + 2] << 16 | this[V + 3] << 24;
32827
+ return V = V >>> 0, z || he(V, 4, this.length), this[V] | this[V + 1] << 8 | this[V + 2] << 16 | this[V + 3] << 24;
32823
32828
  }, v.prototype.readInt32BE = function(V, z) {
32824
- return V = V >>> 0, z || de(V, 4, this.length), this[V] << 24 | this[V + 1] << 16 | this[V + 2] << 8 | this[V + 3];
32829
+ return V = V >>> 0, z || he(V, 4, this.length), this[V] << 24 | this[V + 1] << 16 | this[V + 2] << 8 | this[V + 3];
32825
32830
  }, v.prototype.readFloatLE = function(V, z) {
32826
- return V = V >>> 0, z || de(V, 4, this.length), d.read(this, V, !0, 23, 4);
32831
+ return V = V >>> 0, z || he(V, 4, this.length), d.read(this, V, !0, 23, 4);
32827
32832
  }, v.prototype.readFloatBE = function(V, z) {
32828
- return V = V >>> 0, z || de(V, 4, this.length), d.read(this, V, !1, 23, 4);
32833
+ return V = V >>> 0, z || he(V, 4, this.length), d.read(this, V, !1, 23, 4);
32829
32834
  }, v.prototype.readDoubleLE = function(V, z) {
32830
- return V = V >>> 0, z || de(V, 8, this.length), d.read(this, V, !0, 52, 8);
32835
+ return V = V >>> 0, z || he(V, 8, this.length), d.read(this, V, !0, 52, 8);
32831
32836
  }, v.prototype.readDoubleBE = function(V, z) {
32832
- return V = V >>> 0, z || de(V, 8, this.length), d.read(this, V, !1, 52, 8);
32837
+ return V = V >>> 0, z || he(V, 8, this.length), d.read(this, V, !1, 52, 8);
32833
32838
  };
32834
32839
  function Et(j, V, z, ae, xe, qe) {
32835
32840
  if (!v.isBuffer(j))
@@ -32973,7 +32978,7 @@ var mqtt = { exports: {} };
32973
32978
  return this;
32974
32979
  };
32975
32980
  var Ce = /[^+/0-9A-Za-z-_]/g;
32976
- function he(j) {
32981
+ function de(j) {
32977
32982
  if (j = j.split("=")[0], j = j.trim().replace(Ce, ""), j.length < 2)
32978
32983
  return "";
32979
32984
  for (; j.length % 4 !== 0; )
@@ -33038,7 +33043,7 @@ var mqtt = { exports: {} };
33038
33043
  }
33039
33044
  return qe;
33040
33045
  }
33041
- function Oe(j) {
33046
+ function Ve(j) {
33042
33047
  for (var V = [], z = 0; z < j.length; ++z)
33043
33048
  V.push(j.charCodeAt(z) & 255);
33044
33049
  return V;
@@ -33049,7 +33054,7 @@ var mqtt = { exports: {} };
33049
33054
  return qe;
33050
33055
  }
33051
33056
  function jt(j) {
33052
- return c.toByteArray(he(j));
33057
+ return c.toByteArray(de(j));
33053
33058
  }
33054
33059
  function _n(j, V, z, ae) {
33055
33060
  for (var xe = 0; xe < ae && !(xe + z >= V.length || xe >= j.length); ++xe)
@@ -33589,7 +33594,7 @@ var mqtt = { exports: {} };
33589
33594
  ae.reading = !1, In(oe, ae);
33590
33595
  else {
33591
33596
  var xe;
33592
- if (z || (xe = Ve(ae, le)), xe)
33597
+ if (z || (xe = Oe(ae, le)), xe)
33593
33598
  re(oe, xe);
33594
33599
  else if (ae.objectMode || le && le.length > 0)
33595
33600
  if (typeof le != "string" && !ae.objectMode && Object.getPrototypeOf(le) !== _.prototype && (le = g(le)), V)
@@ -33609,7 +33614,7 @@ var mqtt = { exports: {} };
33609
33614
  function Fe(oe, le, j, V) {
33610
33615
  le.flowing && le.length === 0 && !le.sync ? (le.awaitDrain = 0, oe.emit("data", j)) : (le.length += le.objectMode ? 1 : j.length, V ? le.buffer.unshift(j) : le.buffer.push(j), le.needReadable && Dt(oe)), Et(oe, le);
33611
33616
  }
33612
- function Ve(oe, le) {
33617
+ function Oe(oe, le) {
33613
33618
  var j;
33614
33619
  return !y(le) && typeof le != "string" && le !== void 0 && !oe.objectMode && (j = new O("chunk", ["string", "Buffer", "Uint8Array"], le)), j;
33615
33620
  }
@@ -33640,7 +33645,7 @@ var mqtt = { exports: {} };
33640
33645
  var V = le.needReadable;
33641
33646
  A("need readable", V), (le.length === 0 || le.length - oe < le.highWaterMark) && (V = !0, A("length less than watermark", V)), le.ended || le.reading ? (V = !1, A("reading or ended", V)) : V && (A("do read"), le.reading = !0, le.sync = !0, le.length === 0 && (le.needReadable = !0), this._read(le.highWaterMark), le.sync = !1, le.reading || (oe = Cn(j, le)));
33642
33647
  var z;
33643
- return oe > 0 ? z = Oe(oe, le) : z = null, z === null ? (le.needReadable = le.length <= le.highWaterMark, oe = 0) : (le.length -= oe, le.awaitDrain = 0), le.length === 0 && (le.ended || (le.needReadable = !0), j !== oe && le.ended && Pt(this)), z !== null && this.emit("data", z), z;
33648
+ return oe > 0 ? z = Ve(oe, le) : z = null, z === null ? (le.needReadable = le.length <= le.highWaterMark, oe = 0) : (le.length -= oe, le.awaitDrain = 0), le.length === 0 && (le.ended || (le.needReadable = !0), j !== oe && le.ended && Pt(this)), z !== null && this.emit("data", z), z;
33644
33649
  };
33645
33650
  function In(oe, le) {
33646
33651
  if (A("onEofChunk"), !le.ended) {
@@ -33648,14 +33653,14 @@ var mqtt = { exports: {} };
33648
33653
  var j = le.decoder.end();
33649
33654
  j && j.length && (le.buffer.push(j), le.length += le.objectMode ? 1 : j.length);
33650
33655
  }
33651
- le.ended = !0, le.sync ? Dt(oe) : (le.needReadable = !1, le.emittedReadable || (le.emittedReadable = !0, de(oe)));
33656
+ le.ended = !0, le.sync ? Dt(oe) : (le.needReadable = !1, le.emittedReadable || (le.emittedReadable = !0, he(oe)));
33652
33657
  }
33653
33658
  }
33654
33659
  function Dt(oe) {
33655
33660
  var le = oe._readableState;
33656
- A("emitReadable", le.needReadable, le.emittedReadable), le.needReadable = !1, le.emittedReadable || (A("emitReadable", le.flowing), le.emittedReadable = !0, u.nextTick(de, oe));
33661
+ A("emitReadable", le.needReadable, le.emittedReadable), le.needReadable = !1, le.emittedReadable || (A("emitReadable", le.flowing), le.emittedReadable = !0, u.nextTick(he, oe));
33657
33662
  }
33658
- function de(oe) {
33663
+ function he(oe) {
33659
33664
  var le = oe._readableState;
33660
33665
  A("emitReadable_", le.destroyed, le.length, le.ended), !le.destroyed && (le.length || le.ended) && (oe.emit("readable"), le.emittedReadable = !1), le.needReadable = !le.flowing && !le.ended && le.length <= le.highWaterMark, Ne(oe);
33661
33666
  }
@@ -33767,9 +33772,9 @@ var mqtt = { exports: {} };
33767
33772
  }
33768
33773
  Ie.prototype.resume = function() {
33769
33774
  var oe = this._readableState;
33770
- return oe.flowing || (A("resume"), oe.flowing = !oe.readableListening, he(this, oe)), oe.paused = !1, this;
33775
+ return oe.flowing || (A("resume"), oe.flowing = !oe.readableListening, de(this, oe)), oe.paused = !1, this;
33771
33776
  };
33772
- function he(oe, le) {
33777
+ function de(oe, le) {
33773
33778
  le.resumeScheduled || (le.resumeScheduled = !0, u.nextTick(Ue, oe, le));
33774
33779
  }
33775
33780
  function Ue(oe, le) {
@@ -33837,7 +33842,7 @@ var mqtt = { exports: {} };
33837
33842
  set: function(le) {
33838
33843
  this._readableState && (this._readableState.flowing = le);
33839
33844
  }
33840
- }), Ie._fromList = Oe, Object.defineProperty(Ie.prototype, "readableLength", {
33845
+ }), Ie._fromList = Ve, Object.defineProperty(Ie.prototype, "readableLength", {
33841
33846
  // making it explicit this property is not enumerable
33842
33847
  // because otherwise some prototype manipulation in
33843
33848
  // userland will fail
@@ -33846,7 +33851,7 @@ var mqtt = { exports: {} };
33846
33851
  return this._readableState.length;
33847
33852
  }
33848
33853
  });
33849
- function Oe(oe, le) {
33854
+ function Ve(oe, le) {
33850
33855
  if (le.length === 0)
33851
33856
  return null;
33852
33857
  var j;
@@ -33937,9 +33942,9 @@ var mqtt = { exports: {} };
33937
33942
  (function() {
33938
33943
  o.exports = ue;
33939
33944
  function d(Ne) {
33940
- var Oe = this;
33945
+ var Ve = this;
33941
33946
  this.next = null, this.entry = null, this.finish = function() {
33942
- Ue(Oe, Ne);
33947
+ Ue(Ve, Ne);
33943
33948
  };
33944
33949
  }
33945
33950
  var f;
@@ -33958,16 +33963,16 @@ var mqtt = { exports: {} };
33958
33963
  n("inherits")(ue, _);
33959
33964
  function re() {
33960
33965
  }
33961
- function F(Ne, Oe, Pt) {
33962
- f = f || n("./_stream_duplex"), Ne = Ne || {}, typeof Pt != "boolean" && (Pt = Oe instanceof f), this.objectMode = !!Ne.objectMode, Pt && (this.objectMode = this.objectMode || !!Ne.writableObjectMode), this.highWaterMark = S(this, Ne, "writableHighWaterMark", Pt), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1;
33966
+ function F(Ne, Ve, Pt) {
33967
+ f = f || n("./_stream_duplex"), Ne = Ne || {}, typeof Pt != "boolean" && (Pt = Ve instanceof f), this.objectMode = !!Ne.objectMode, Pt && (this.objectMode = this.objectMode || !!Ne.writableObjectMode), this.highWaterMark = S(this, Ne, "writableHighWaterMark", Pt), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1;
33963
33968
  var jt = Ne.decodeStrings === !1;
33964
33969
  this.decodeStrings = !jt, this.defaultEncoding = Ne.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = function(_n) {
33965
- In(Oe, _n);
33970
+ In(Ve, _n);
33966
33971
  }, this.writecb = null, this.writelen = 0, this.bufferedRequest = null, this.lastBufferedRequest = null, this.pendingcb = 0, this.prefinished = !1, this.errorEmitted = !1, this.emitClose = Ne.emitClose !== !1, this.autoDestroy = !!Ne.autoDestroy, this.bufferedRequestCount = 0, this.corkedRequestsFree = new d(this);
33967
33972
  }
33968
33973
  F.prototype.getBuffer = function() {
33969
- for (var Oe = this.bufferedRequest, Pt = []; Oe; )
33970
- Pt.push(Oe), Oe = Oe.next;
33974
+ for (var Ve = this.bufferedRequest, Pt = []; Ve; )
33975
+ Pt.push(Ve), Ve = Ve.next;
33971
33976
  return Pt;
33972
33977
  }, function() {
33973
33978
  try {
@@ -33981,42 +33986,42 @@ var mqtt = { exports: {} };
33981
33986
  }();
33982
33987
  var _e;
33983
33988
  typeof Symbol == "function" && Symbol.hasInstance && typeof Function.prototype[Symbol.hasInstance] == "function" ? (_e = Function.prototype[Symbol.hasInstance], Object.defineProperty(ue, Symbol.hasInstance, {
33984
- value: function(Oe) {
33985
- return _e.call(this, Oe) ? !0 : this !== ue ? !1 : Oe && Oe._writableState instanceof F;
33989
+ value: function(Ve) {
33990
+ return _e.call(this, Ve) ? !0 : this !== ue ? !1 : Ve && Ve._writableState instanceof F;
33986
33991
  }
33987
- })) : _e = function(Oe) {
33988
- return Oe instanceof this;
33992
+ })) : _e = function(Ve) {
33993
+ return Ve instanceof this;
33989
33994
  };
33990
33995
  function ue(Ne) {
33991
33996
  f = f || n("./_stream_duplex");
33992
- var Oe = this instanceof f;
33993
- if (!Oe && !_e.call(ue, this))
33997
+ var Ve = this instanceof f;
33998
+ if (!Ve && !_e.call(ue, this))
33994
33999
  return new ue(Ne);
33995
- this._writableState = new F(Ne, this, Oe), this.writable = !0, Ne && (typeof Ne.write == "function" && (this._write = Ne.write), typeof Ne.writev == "function" && (this._writev = Ne.writev), typeof Ne.destroy == "function" && (this._destroy = Ne.destroy), typeof Ne.final == "function" && (this._final = Ne.final)), _.call(this);
34000
+ this._writableState = new F(Ne, this, Ve), this.writable = !0, Ne && (typeof Ne.write == "function" && (this._write = Ne.write), typeof Ne.writev == "function" && (this._writev = Ne.writev), typeof Ne.destroy == "function" && (this._destroy = Ne.destroy), typeof Ne.final == "function" && (this._final = Ne.final)), _.call(this);
33996
34001
  }
33997
34002
  ue.prototype.pipe = function() {
33998
34003
  D(this, new M());
33999
34004
  };
34000
- function Ie(Ne, Oe) {
34005
+ function Ie(Ne, Ve) {
34001
34006
  var Pt = new $();
34002
- D(Ne, Pt), u.nextTick(Oe, Pt);
34007
+ D(Ne, Pt), u.nextTick(Ve, Pt);
34003
34008
  }
34004
- function ze(Ne, Oe, Pt, jt) {
34009
+ function ze(Ne, Ve, Pt, jt) {
34005
34010
  var _n;
34006
- return Pt === null ? _n = new ie() : typeof Pt != "string" && !Oe.objectMode && (_n = new x("chunk", ["string", "Buffer"], Pt)), _n ? (D(Ne, _n), u.nextTick(jt, _n), !1) : !0;
34011
+ return Pt === null ? _n = new ie() : typeof Pt != "string" && !Ve.objectMode && (_n = new x("chunk", ["string", "Buffer"], Pt)), _n ? (D(Ne, _n), u.nextTick(jt, _n), !1) : !0;
34007
34012
  }
34008
- ue.prototype.write = function(Ne, Oe, Pt) {
34013
+ ue.prototype.write = function(Ne, Ve, Pt) {
34009
34014
  var jt = this._writableState, _n = !1, oe = !jt.objectMode && b(Ne);
34010
- return oe && !v.isBuffer(Ne) && (Ne = y(Ne)), typeof Oe == "function" && (Pt = Oe, Oe = null), oe ? Oe = "buffer" : Oe || (Oe = jt.defaultEncoding), typeof Pt != "function" && (Pt = re), jt.ending ? Ie(this, Pt) : (oe || ze(this, jt, Ne, Pt)) && (jt.pendingcb++, _n = Ve(this, jt, oe, Ne, Oe, Pt)), _n;
34015
+ return oe && !v.isBuffer(Ne) && (Ne = y(Ne)), typeof Ve == "function" && (Pt = Ve, Ve = null), oe ? Ve = "buffer" : Ve || (Ve = jt.defaultEncoding), typeof Pt != "function" && (Pt = re), jt.ending ? Ie(this, Pt) : (oe || ze(this, jt, Ne, Pt)) && (jt.pendingcb++, _n = Oe(this, jt, oe, Ne, Ve, Pt)), _n;
34011
34016
  }, ue.prototype.cork = function() {
34012
34017
  this._writableState.corked++;
34013
34018
  }, ue.prototype.uncork = function() {
34014
34019
  var Ne = this._writableState;
34015
34020
  Ne.corked && (Ne.corked--, !Ne.writing && !Ne.corked && !Ne.bufferProcessing && Ne.bufferedRequest && Et(this, Ne));
34016
- }, ue.prototype.setDefaultEncoding = function(Oe) {
34017
- if (typeof Oe == "string" && (Oe = Oe.toLowerCase()), !(["hex", "utf8", "utf-8", "ascii", "binary", "base64", "ucs2", "ucs-2", "utf16le", "utf-16le", "raw"].indexOf((Oe + "").toLowerCase()) > -1))
34018
- throw new Y(Oe);
34019
- return this._writableState.defaultEncoding = Oe, this;
34021
+ }, ue.prototype.setDefaultEncoding = function(Ve) {
34022
+ if (typeof Ve == "string" && (Ve = Ve.toLowerCase()), !(["hex", "utf8", "utf-8", "ascii", "binary", "base64", "ucs2", "ucs-2", "utf16le", "utf-16le", "raw"].indexOf((Ve + "").toLowerCase()) > -1))
34023
+ throw new Y(Ve);
34024
+ return this._writableState.defaultEncoding = Ve, this;
34020
34025
  }, Object.defineProperty(ue.prototype, "writableBuffer", {
34021
34026
  // making it explicit this property is not enumerable
34022
34027
  // because otherwise some prototype manipulation in
@@ -34026,8 +34031,8 @@ var mqtt = { exports: {} };
34026
34031
  return this._writableState && this._writableState.getBuffer();
34027
34032
  }
34028
34033
  });
34029
- function Fe(Ne, Oe, Pt) {
34030
- return !Ne.objectMode && Ne.decodeStrings !== !1 && typeof Oe == "string" && (Oe = v.from(Oe, Pt)), Oe;
34034
+ function Fe(Ne, Ve, Pt) {
34035
+ return !Ne.objectMode && Ne.decodeStrings !== !1 && typeof Ve == "string" && (Ve = v.from(Ve, Pt)), Ve;
34031
34036
  }
34032
34037
  Object.defineProperty(ue.prototype, "writableHighWaterMark", {
34033
34038
  // making it explicit this property is not enumerable
@@ -34038,77 +34043,77 @@ var mqtt = { exports: {} };
34038
34043
  return this._writableState.highWaterMark;
34039
34044
  }
34040
34045
  });
34041
- function Ve(Ne, Oe, Pt, jt, _n, oe) {
34046
+ function Oe(Ne, Ve, Pt, jt, _n, oe) {
34042
34047
  if (!Pt) {
34043
- var le = Fe(Oe, jt, _n);
34048
+ var le = Fe(Ve, jt, _n);
34044
34049
  jt !== le && (Pt = !0, _n = "buffer", jt = le);
34045
34050
  }
34046
- var j = Oe.objectMode ? 1 : jt.length;
34047
- Oe.length += j;
34048
- var V = Oe.length < Oe.highWaterMark;
34049
- if (V || (Oe.needDrain = !0), Oe.writing || Oe.corked) {
34050
- var z = Oe.lastBufferedRequest;
34051
- Oe.lastBufferedRequest = {
34051
+ var j = Ve.objectMode ? 1 : jt.length;
34052
+ Ve.length += j;
34053
+ var V = Ve.length < Ve.highWaterMark;
34054
+ if (V || (Ve.needDrain = !0), Ve.writing || Ve.corked) {
34055
+ var z = Ve.lastBufferedRequest;
34056
+ Ve.lastBufferedRequest = {
34052
34057
  chunk: jt,
34053
34058
  encoding: _n,
34054
34059
  isBuf: Pt,
34055
34060
  callback: oe,
34056
34061
  next: null
34057
- }, z ? z.next = Oe.lastBufferedRequest : Oe.bufferedRequest = Oe.lastBufferedRequest, Oe.bufferedRequestCount += 1;
34062
+ }, z ? z.next = Ve.lastBufferedRequest : Ve.bufferedRequest = Ve.lastBufferedRequest, Ve.bufferedRequestCount += 1;
34058
34063
  } else
34059
- Lt(Ne, Oe, !1, j, jt, _n, oe);
34064
+ Lt(Ne, Ve, !1, j, jt, _n, oe);
34060
34065
  return V;
34061
34066
  }
34062
- function Lt(Ne, Oe, Pt, jt, _n, oe, le) {
34063
- Oe.writelen = jt, Oe.writecb = le, Oe.writing = !0, Oe.sync = !0, Oe.destroyed ? Oe.onwrite(new k("write")) : Pt ? Ne._writev(_n, Oe.onwrite) : Ne._write(_n, oe, Oe.onwrite), Oe.sync = !1;
34067
+ function Lt(Ne, Ve, Pt, jt, _n, oe, le) {
34068
+ Ve.writelen = jt, Ve.writecb = le, Ve.writing = !0, Ve.sync = !0, Ve.destroyed ? Ve.onwrite(new k("write")) : Pt ? Ne._writev(_n, Ve.onwrite) : Ne._write(_n, oe, Ve.onwrite), Ve.sync = !1;
34064
34069
  }
34065
- function pe(Ne, Oe, Pt, jt, _n) {
34066
- --Oe.pendingcb, Pt ? (u.nextTick(_n, jt), u.nextTick(Ce, Ne, Oe), Ne._writableState.errorEmitted = !0, D(Ne, jt)) : (_n(jt), Ne._writableState.errorEmitted = !0, D(Ne, jt), Ce(Ne, Oe));
34070
+ function pe(Ne, Ve, Pt, jt, _n) {
34071
+ --Ve.pendingcb, Pt ? (u.nextTick(_n, jt), u.nextTick(Ce, Ne, Ve), Ne._writableState.errorEmitted = !0, D(Ne, jt)) : (_n(jt), Ne._writableState.errorEmitted = !0, D(Ne, jt), Ce(Ne, Ve));
34067
34072
  }
34068
34073
  function Cn(Ne) {
34069
34074
  Ne.writing = !1, Ne.writecb = null, Ne.length -= Ne.writelen, Ne.writelen = 0;
34070
34075
  }
34071
- function In(Ne, Oe) {
34076
+ function In(Ne, Ve) {
34072
34077
  var Pt = Ne._writableState, jt = Pt.sync, _n = Pt.writecb;
34073
34078
  if (typeof _n != "function")
34074
34079
  throw new O();
34075
- if (Cn(Pt), Oe)
34076
- pe(Ne, Pt, jt, Oe, _n);
34080
+ if (Cn(Pt), Ve)
34081
+ pe(Ne, Pt, jt, Ve, _n);
34077
34082
  else {
34078
34083
  var oe = hn(Pt) || Ne.destroyed;
34079
34084
  !oe && !Pt.corked && !Pt.bufferProcessing && Pt.bufferedRequest && Et(Ne, Pt), jt ? u.nextTick(Dt, Ne, Pt, oe, _n) : Dt(Ne, Pt, oe, _n);
34080
34085
  }
34081
34086
  }
34082
- function Dt(Ne, Oe, Pt, jt) {
34083
- Pt || de(Ne, Oe), Oe.pendingcb--, jt(), Ce(Ne, Oe);
34087
+ function Dt(Ne, Ve, Pt, jt) {
34088
+ Pt || he(Ne, Ve), Ve.pendingcb--, jt(), Ce(Ne, Ve);
34084
34089
  }
34085
- function de(Ne, Oe) {
34086
- Oe.length === 0 && Oe.needDrain && (Oe.needDrain = !1, Ne.emit("drain"));
34090
+ function he(Ne, Ve) {
34091
+ Ve.length === 0 && Ve.needDrain && (Ve.needDrain = !1, Ne.emit("drain"));
34087
34092
  }
34088
- function Et(Ne, Oe) {
34089
- Oe.bufferProcessing = !0;
34090
- var Pt = Oe.bufferedRequest;
34093
+ function Et(Ne, Ve) {
34094
+ Ve.bufferProcessing = !0;
34095
+ var Pt = Ve.bufferedRequest;
34091
34096
  if (Ne._writev && Pt && Pt.next) {
34092
- var jt = Oe.bufferedRequestCount, _n = new Array(jt), oe = Oe.corkedRequestsFree;
34097
+ var jt = Ve.bufferedRequestCount, _n = new Array(jt), oe = Ve.corkedRequestsFree;
34093
34098
  oe.entry = Pt;
34094
34099
  for (var le = 0, j = !0; Pt; )
34095
34100
  _n[le] = Pt, Pt.isBuf || (j = !1), Pt = Pt.next, le += 1;
34096
- _n.allBuffers = j, Lt(Ne, Oe, !0, Oe.length, _n, "", oe.finish), Oe.pendingcb++, Oe.lastBufferedRequest = null, oe.next ? (Oe.corkedRequestsFree = oe.next, oe.next = null) : Oe.corkedRequestsFree = new d(Oe), Oe.bufferedRequestCount = 0;
34101
+ _n.allBuffers = j, Lt(Ne, Ve, !0, Ve.length, _n, "", oe.finish), Ve.pendingcb++, Ve.lastBufferedRequest = null, oe.next ? (Ve.corkedRequestsFree = oe.next, oe.next = null) : Ve.corkedRequestsFree = new d(Ve), Ve.bufferedRequestCount = 0;
34097
34102
  } else {
34098
34103
  for (; Pt; ) {
34099
- var V = Pt.chunk, z = Pt.encoding, ae = Pt.callback, xe = Oe.objectMode ? 1 : V.length;
34100
- if (Lt(Ne, Oe, !1, xe, V, z, ae), Pt = Pt.next, Oe.bufferedRequestCount--, Oe.writing)
34104
+ var V = Pt.chunk, z = Pt.encoding, ae = Pt.callback, xe = Ve.objectMode ? 1 : V.length;
34105
+ if (Lt(Ne, Ve, !1, xe, V, z, ae), Pt = Pt.next, Ve.bufferedRequestCount--, Ve.writing)
34101
34106
  break;
34102
34107
  }
34103
- Pt === null && (Oe.lastBufferedRequest = null);
34108
+ Pt === null && (Ve.lastBufferedRequest = null);
34104
34109
  }
34105
- Oe.bufferedRequest = Pt, Oe.bufferProcessing = !1;
34110
+ Ve.bufferedRequest = Pt, Ve.bufferProcessing = !1;
34106
34111
  }
34107
- ue.prototype._write = function(Ne, Oe, Pt) {
34112
+ ue.prototype._write = function(Ne, Ve, Pt) {
34108
34113
  Pt(new L("_write()"));
34109
- }, ue.prototype._writev = null, ue.prototype.end = function(Ne, Oe, Pt) {
34114
+ }, ue.prototype._writev = null, ue.prototype.end = function(Ne, Ve, Pt) {
34110
34115
  var jt = this._writableState;
34111
- return typeof Ne == "function" ? (Pt = Ne, Ne = null, Oe = null) : typeof Oe == "function" && (Pt = Oe, Oe = null), Ne != null && this.write(Ne, Oe), jt.corked && (jt.corked = 1, this.uncork()), jt.ending || he(this, jt, Pt), this;
34116
+ return typeof Ne == "function" ? (Pt = Ne, Ne = null, Ve = null) : typeof Ve == "function" && (Pt = Ve, Ve = null), Ne != null && this.write(Ne, Ve), jt.corked && (jt.corked = 1, this.uncork()), jt.ending || de(this, jt, Pt), this;
34112
34117
  }, Object.defineProperty(ue.prototype, "writableLength", {
34113
34118
  // making it explicit this property is not enumerable
34114
34119
  // because otherwise some prototype manipulation in
@@ -34121,32 +34126,32 @@ var mqtt = { exports: {} };
34121
34126
  function hn(Ne) {
34122
34127
  return Ne.ending && Ne.length === 0 && Ne.bufferedRequest === null && !Ne.finished && !Ne.writing;
34123
34128
  }
34124
- function vn(Ne, Oe) {
34129
+ function vn(Ne, Ve) {
34125
34130
  Ne._final(function(Pt) {
34126
- Oe.pendingcb--, Pt && D(Ne, Pt), Oe.prefinished = !0, Ne.emit("prefinish"), Ce(Ne, Oe);
34131
+ Ve.pendingcb--, Pt && D(Ne, Pt), Ve.prefinished = !0, Ne.emit("prefinish"), Ce(Ne, Ve);
34127
34132
  });
34128
34133
  }
34129
- function kt(Ne, Oe) {
34130
- !Oe.prefinished && !Oe.finalCalled && (typeof Ne._final == "function" && !Oe.destroyed ? (Oe.pendingcb++, Oe.finalCalled = !0, u.nextTick(vn, Ne, Oe)) : (Oe.prefinished = !0, Ne.emit("prefinish")));
34134
+ function kt(Ne, Ve) {
34135
+ !Ve.prefinished && !Ve.finalCalled && (typeof Ne._final == "function" && !Ve.destroyed ? (Ve.pendingcb++, Ve.finalCalled = !0, u.nextTick(vn, Ne, Ve)) : (Ve.prefinished = !0, Ne.emit("prefinish")));
34131
34136
  }
34132
- function Ce(Ne, Oe) {
34133
- var Pt = hn(Oe);
34134
- if (Pt && (kt(Ne, Oe), Oe.pendingcb === 0 && (Oe.finished = !0, Ne.emit("finish"), Oe.autoDestroy))) {
34137
+ function Ce(Ne, Ve) {
34138
+ var Pt = hn(Ve);
34139
+ if (Pt && (kt(Ne, Ve), Ve.pendingcb === 0 && (Ve.finished = !0, Ne.emit("finish"), Ve.autoDestroy))) {
34135
34140
  var jt = Ne._readableState;
34136
34141
  (!jt || jt.autoDestroy && jt.endEmitted) && Ne.destroy();
34137
34142
  }
34138
34143
  return Pt;
34139
34144
  }
34140
- function he(Ne, Oe, Pt) {
34141
- Oe.ending = !0, Ce(Ne, Oe), Pt && (Oe.finished ? u.nextTick(Pt) : Ne.once("finish", Pt)), Oe.ended = !0, Ne.writable = !1;
34145
+ function de(Ne, Ve, Pt) {
34146
+ Ve.ending = !0, Ce(Ne, Ve), Pt && (Ve.finished ? u.nextTick(Pt) : Ne.once("finish", Pt)), Ve.ended = !0, Ne.writable = !1;
34142
34147
  }
34143
- function Ue(Ne, Oe, Pt) {
34148
+ function Ue(Ne, Ve, Pt) {
34144
34149
  var jt = Ne.entry;
34145
34150
  for (Ne.entry = null; jt; ) {
34146
34151
  var _n = jt.callback;
34147
- Oe.pendingcb--, _n(Pt), jt = jt.next;
34152
+ Ve.pendingcb--, _n(Pt), jt = jt.next;
34148
34153
  }
34149
- Oe.corkedRequestsFree.next = Ne;
34154
+ Ve.corkedRequestsFree.next = Ne;
34150
34155
  }
34151
34156
  Object.defineProperty(ue.prototype, "destroyed", {
34152
34157
  // making it explicit this property is not enumerable
@@ -34156,11 +34161,11 @@ var mqtt = { exports: {} };
34156
34161
  get: function() {
34157
34162
  return this._writableState === void 0 ? !1 : this._writableState.destroyed;
34158
34163
  },
34159
- set: function(Oe) {
34160
- this._writableState && (this._writableState.destroyed = Oe);
34164
+ set: function(Ve) {
34165
+ this._writableState && (this._writableState.destroyed = Ve);
34161
34166
  }
34162
- }), ue.prototype.destroy = A.destroy, ue.prototype._undestroy = A.undestroy, ue.prototype._destroy = function(Ne, Oe) {
34163
- Oe(Ne);
34167
+ }), ue.prototype.destroy = A.destroy, ue.prototype._undestroy = A.undestroy, ue.prototype._destroy = function(Ne, Ve) {
34168
+ Ve(Ne);
34164
34169
  };
34165
34170
  }).call(this);
34166
34171
  }).call(this, n("_process"), typeof commonjsGlobal < "u" ? commonjsGlobal : typeof self < "u" ? self : typeof window < "u" ? window : {});
@@ -34701,8 +34706,8 @@ var mqtt = { exports: {} };
34701
34706
  if (typeof ze == "function")
34702
34707
  c(ze, this, D);
34703
34708
  else
34704
- for (var Fe = ze.length, Ve = x(ze, Fe), re = 0; re < Fe; ++re)
34705
- c(Ve[re], this, D);
34709
+ for (var Fe = ze.length, Oe = x(ze, Fe), re = 0; re < Fe; ++re)
34710
+ c(Oe[re], this, D);
34706
34711
  return !0;
34707
34712
  };
34708
34713
  function b($, Y, D, re) {
@@ -36702,25 +36707,25 @@ var mqtt = { exports: {} };
36702
36707
  allowStale: Ie,
36703
36708
  dispose: ze,
36704
36709
  disposeAfter: Fe,
36705
- noDisposeOnSet: Ve,
36710
+ noDisposeOnSet: Oe,
36706
36711
  noUpdateTTL: Lt,
36707
36712
  maxSize: pe = 0,
36708
36713
  maxEntrySize: Cn = 0,
36709
36714
  sizeCalculation: In,
36710
36715
  fetchMethod: Dt,
36711
- fetchContext: de,
36716
+ fetchContext: he,
36712
36717
  noDeleteOnFetchRejection: Et,
36713
36718
  noDeleteOnStaleGet: hn,
36714
36719
  allowStaleOnFetchRejection: vn,
36715
36720
  allowStaleOnFetchAbort: kt,
36716
36721
  ignoreFetchAbort: Ce
36717
- } = $, { length: he, maxAge: Ue, stale: Ne } = $ instanceof k ? {} : $;
36722
+ } = $, { length: de, maxAge: Ue, stale: Ne } = $ instanceof k ? {} : $;
36718
36723
  if (Y !== 0 && !x(Y))
36719
36724
  throw new TypeError("max option must be a nonnegative integer");
36720
- const Oe = Y ? L(Y) : Array;
36721
- if (!Oe)
36725
+ const Ve = Y ? L(Y) : Array;
36726
+ if (!Ve)
36722
36727
  throw new Error("invalid max value: " + Y);
36723
- if (this.max = Y, this.maxSize = pe, this.maxEntrySize = Cn || this.maxSize, this.sizeCalculation = In || he, this.sizeCalculation) {
36728
+ if (this.max = Y, this.maxSize = pe, this.maxEntrySize = Cn || this.maxSize, this.sizeCalculation = In || de, this.sizeCalculation) {
36724
36729
  if (!this.maxSize && !this.maxEntrySize)
36725
36730
  throw new TypeError(
36726
36731
  "cannot set sizeCalculation without setting maxSize or maxEntrySize"
@@ -36732,11 +36737,11 @@ var mqtt = { exports: {} };
36732
36737
  throw new TypeError(
36733
36738
  "fetchMethod must be a function if specified"
36734
36739
  );
36735
- if (this.fetchContext = de, !this.fetchMethod && de !== void 0)
36740
+ if (this.fetchContext = he, !this.fetchMethod && he !== void 0)
36736
36741
  throw new TypeError(
36737
36742
  "cannot set fetchContext without fetchMethod"
36738
36743
  );
36739
- if (this.keyMap = /* @__PURE__ */ new Map(), this.keyList = new Array(Y).fill(null), this.valList = new Array(Y).fill(null), this.next = new Oe(Y), this.prev = new Oe(Y), this.head = 0, this.tail = 0, this.free = new M(Y), this.initialFill = 1, this.size = 0, typeof ze == "function" && (this.dispose = ze), typeof Fe == "function" ? (this.disposeAfter = Fe, this.disposed = []) : (this.disposeAfter = null, this.disposed = null), this.noDisposeOnSet = !!Ve, this.noUpdateTTL = !!Lt, this.noDeleteOnFetchRejection = !!Et, this.allowStaleOnFetchRejection = !!vn, this.allowStaleOnFetchAbort = !!kt, this.ignoreFetchAbort = !!Ce, this.maxEntrySize !== 0) {
36744
+ if (this.keyMap = /* @__PURE__ */ new Map(), this.keyList = new Array(Y).fill(null), this.valList = new Array(Y).fill(null), this.next = new Ve(Y), this.prev = new Ve(Y), this.head = 0, this.tail = 0, this.free = new M(Y), this.initialFill = 1, this.size = 0, typeof ze == "function" && (this.dispose = ze), typeof Fe == "function" ? (this.disposeAfter = Fe, this.disposed = []) : (this.disposeAfter = null, this.disposed = null), this.noDisposeOnSet = !!Oe, this.noUpdateTTL = !!Lt, this.noDeleteOnFetchRejection = !!Et, this.allowStaleOnFetchRejection = !!vn, this.allowStaleOnFetchAbort = !!kt, this.ignoreFetchAbort = !!Ce, this.maxEntrySize !== 0) {
36740
36745
  if (this.maxSize !== 0 && !x(this.maxSize))
36741
36746
  throw new TypeError(
36742
36747
  "maxSize must be a positive integer if specified"
@@ -36762,7 +36767,7 @@ var mqtt = { exports: {} };
36762
36767
  const Pt = "LRU_CACHE_UNBOUNDED";
36763
36768
  S(Pt) && (g.add(Pt), w("TTL caching without ttlAutopurge, max, or maxSize can result in unbounded memory consumption.", "UnboundedCacheWarning", Pt, k));
36764
36769
  }
36765
- Ne && y("stale", "allowStale"), Ue && y("maxAge", "ttl"), he && y("length", "sizeCalculation");
36770
+ Ne && y("stale", "allowStale"), Ue && y("maxAge", "ttl"), de && y("length", "sizeCalculation");
36766
36771
  }
36767
36772
  getRemainingTTL($) {
36768
36773
  return this.has($, { updateAgeOnHas: !1 }) ? 1 / 0 : 0;
@@ -36957,11 +36962,11 @@ var mqtt = { exports: {} };
36957
36962
  Fe = this.newIndex(), this.keyList[Fe] = $, this.valList[Fe] = Y, this.keyMap.set($, Fe), this.next[this.tail] = Fe, this.prev[Fe] = this.tail, this.tail = Fe, this.size++, this.addItemSize(Fe, _e, ze), ze && (ze.set = "add"), Ie = !1;
36958
36963
  else {
36959
36964
  this.moveToTail(Fe);
36960
- const Ve = this.valList[Fe];
36961
- if (Y !== Ve) {
36962
- if (this.isBackgroundFetch(Ve) ? Ve.__abortController.abort(new Error("replaced")) : F || (this.dispose(Ve, $, "set"), this.disposeAfter && this.disposed.push([Ve, $, "set"])), this.removeItemSize(Fe), this.valList[Fe] = Y, this.addItemSize(Fe, _e, ze), ze) {
36965
+ const Oe = this.valList[Fe];
36966
+ if (Y !== Oe) {
36967
+ if (this.isBackgroundFetch(Oe) ? Oe.__abortController.abort(new Error("replaced")) : F || (this.dispose(Oe, $, "set"), this.disposeAfter && this.disposed.push([Oe, $, "set"])), this.removeItemSize(Fe), this.valList[Fe] = Y, this.addItemSize(Fe, _e, ze), ze) {
36963
36968
  ze.set = "replace";
36964
- const Lt = Ve && this.isBackgroundFetch(Ve) ? Ve.__staleWhileFetching : Ve;
36969
+ const Lt = Oe && this.isBackgroundFetch(Oe) ? Oe.__staleWhileFetching : Oe;
36965
36970
  Lt !== void 0 && (ze.oldValue = Lt);
36966
36971
  }
36967
36972
  } else
@@ -37021,18 +37026,18 @@ var mqtt = { exports: {} };
37021
37026
  const { aborted: In } = _e.signal, Dt = D.ignoreFetchAbort && pe !== void 0;
37022
37027
  return D.status && (In && !Cn ? (D.status.fetchAborted = !0, D.status.fetchError = _e.signal.reason, Dt && (D.status.fetchAbortIgnored = !0)) : D.status.fetchResolved = !0), In && !Dt && !Cn ? Fe(_e.signal.reason) : (this.valList[Y] === Lt && (pe === void 0 ? Lt.__staleWhileFetching ? this.valList[Y] = Lt.__staleWhileFetching : this.delete($) : (D.status && (D.status.fetchUpdated = !0), this.set($, pe, ue.options))), pe);
37023
37028
  }, ze = (pe) => (D.status && (D.status.fetchRejected = !0, D.status.fetchError = pe), Fe(pe)), Fe = (pe) => {
37024
- const { aborted: Cn } = _e.signal, In = Cn && D.allowStaleOnFetchAbort, Dt = In || D.allowStaleOnFetchRejection, de = Dt || D.noDeleteOnFetchRejection;
37025
- if (this.valList[Y] === Lt && (!de || Lt.__staleWhileFetching === void 0 ? this.delete($) : In || (this.valList[Y] = Lt.__staleWhileFetching)), Dt)
37029
+ const { aborted: Cn } = _e.signal, In = Cn && D.allowStaleOnFetchAbort, Dt = In || D.allowStaleOnFetchRejection, he = Dt || D.noDeleteOnFetchRejection;
37030
+ if (this.valList[Y] === Lt && (!he || Lt.__staleWhileFetching === void 0 ? this.delete($) : In || (this.valList[Y] = Lt.__staleWhileFetching)), Dt)
37026
37031
  return D.status && Lt.__staleWhileFetching !== void 0 && (D.status.returnedStale = !0), Lt.__staleWhileFetching;
37027
37032
  if (Lt.__returned === Lt)
37028
37033
  throw pe;
37029
- }, Ve = (pe, Cn) => {
37034
+ }, Oe = (pe, Cn) => {
37030
37035
  this.fetchMethod($, F, ue).then((In) => pe(In), Cn), _e.signal.addEventListener("abort", () => {
37031
37036
  (!D.ignoreFetchAbort || D.allowStaleOnFetchAbort) && (pe(), D.allowStaleOnFetchAbort && (pe = (In) => Ie(In, !0)));
37032
37037
  });
37033
37038
  };
37034
37039
  D.status && (D.status.fetchDispatched = !0);
37035
- const Lt = new Promise(Ve).then(Ie, ze);
37040
+ const Lt = new Promise(Oe).then(Ie, ze);
37036
37041
  return Lt.__abortController = _e, Lt.__staleWhileFetching = F, Lt.__returned = null, Y === void 0 ? (this.set($, Lt, { ...ue.options, status: void 0 }), Y = this.keyMap.get($)) : this.valList[Y] = Lt, Lt;
37037
37042
  }
37038
37043
  isBackgroundFetch($) {
@@ -37055,13 +37060,13 @@ var mqtt = { exports: {} };
37055
37060
  noUpdateTTL: ze = this.noUpdateTTL,
37056
37061
  // fetch exclusive options
37057
37062
  noDeleteOnFetchRejection: Fe = this.noDeleteOnFetchRejection,
37058
- allowStaleOnFetchRejection: Ve = this.allowStaleOnFetchRejection,
37063
+ allowStaleOnFetchRejection: Oe = this.allowStaleOnFetchRejection,
37059
37064
  ignoreFetchAbort: Lt = this.ignoreFetchAbort,
37060
37065
  allowStaleOnFetchAbort: pe = this.allowStaleOnFetchAbort,
37061
37066
  fetchContext: Cn = this.fetchContext,
37062
37067
  forceRefresh: In = !1,
37063
37068
  status: Dt,
37064
- signal: de
37069
+ signal: he
37065
37070
  } = {}) {
37066
37071
  if (!this.fetchMethod)
37067
37072
  return Dt && (Dt.fetch = "get"), this.get($, {
@@ -37080,11 +37085,11 @@ var mqtt = { exports: {} };
37080
37085
  sizeCalculation: Ie,
37081
37086
  noUpdateTTL: ze,
37082
37087
  noDeleteOnFetchRejection: Fe,
37083
- allowStaleOnFetchRejection: Ve,
37088
+ allowStaleOnFetchRejection: Oe,
37084
37089
  allowStaleOnFetchAbort: pe,
37085
37090
  ignoreFetchAbort: Lt,
37086
37091
  status: Dt,
37087
- signal: de
37092
+ signal: he
37088
37093
  };
37089
37094
  let hn = this.keyMap.get($);
37090
37095
  if (hn === void 0) {
@@ -37100,8 +37105,8 @@ var mqtt = { exports: {} };
37100
37105
  const kt = this.isStale(hn);
37101
37106
  if (!In && !kt)
37102
37107
  return Dt && (Dt.fetch = "hit"), this.moveToTail(hn), D && this.updateItemAge(hn), this.statusTTL(Dt, hn), vn;
37103
- const Ce = this.backgroundFetch($, hn, Et, Cn), he = Ce.__staleWhileFetching !== void 0, Ue = he && Y;
37104
- return Dt && (Dt.fetch = he && kt ? "stale" : "refresh", Ue && kt && (Dt.returnedStale = !0)), Ue ? Ce.__staleWhileFetching : Ce.__returned = Ce;
37108
+ const Ce = this.backgroundFetch($, hn, Et, Cn), de = Ce.__staleWhileFetching !== void 0, Ue = de && Y;
37109
+ return Dt && (Dt.fetch = de && kt ? "stale" : "refresh", Ue && kt && (Dt.returnedStale = !0)), Ue ? Ce.__staleWhileFetching : Ce.__returned = Ce;
37105
37110
  }
37106
37111
  }
37107
37112
  get($, {
@@ -38101,36 +38106,36 @@ var mqtt = { exports: {} };
38101
38106
  }, { "./constants": 73, "./packet": 94, bl: 77, debug: 30, events: 49 }], 96: [function(n, o, a) {
38102
38107
  const u = n("./constants"), { Buffer: c } = n("buffer"), d = c.allocUnsafe(0), f = c.from([0]), p = n("./numbers"), _ = n("process-nextick-args").nextTick, v = n("debug")("mqtt-packet:writeToStream"), g = p.cache, y = p.generateNumber, b = p.generateCache, A = p.genBufVariableByteInt, w = p.generate4ByteBuffer;
38103
38108
  let S = Lt, T = !0;
38104
- function x(Ce, he, Ue) {
38105
- switch (v("generate called"), he.cork && (he.cork(), _(L, he)), T && (T = !1, b()), v("generate: packet.cmd: %s", Ce.cmd), Ce.cmd) {
38109
+ function x(Ce, de, Ue) {
38110
+ switch (v("generate called"), de.cork && (de.cork(), _(L, de)), T && (T = !1, b()), v("generate: packet.cmd: %s", Ce.cmd), Ce.cmd) {
38106
38111
  case "connect":
38107
- return O(Ce, he);
38112
+ return O(Ce, de);
38108
38113
  case "connack":
38109
- return M(Ce, he, Ue);
38114
+ return M(Ce, de, Ue);
38110
38115
  case "publish":
38111
- return k(Ce, he, Ue);
38116
+ return k(Ce, de, Ue);
38112
38117
  case "puback":
38113
38118
  case "pubrec":
38114
38119
  case "pubrel":
38115
38120
  case "pubcomp":
38116
- return ie(Ce, he, Ue);
38121
+ return ie(Ce, de, Ue);
38117
38122
  case "subscribe":
38118
- return $(Ce, he, Ue);
38123
+ return $(Ce, de, Ue);
38119
38124
  case "suback":
38120
- return Y(Ce, he, Ue);
38125
+ return Y(Ce, de, Ue);
38121
38126
  case "unsubscribe":
38122
- return D(Ce, he, Ue);
38127
+ return D(Ce, de, Ue);
38123
38128
  case "unsuback":
38124
- return re(Ce, he, Ue);
38129
+ return re(Ce, de, Ue);
38125
38130
  case "pingreq":
38126
38131
  case "pingresp":
38127
- return F(Ce, he);
38132
+ return F(Ce, de);
38128
38133
  case "disconnect":
38129
- return _e(Ce, he, Ue);
38134
+ return _e(Ce, de, Ue);
38130
38135
  case "auth":
38131
- return ue(Ce, he, Ue);
38136
+ return ue(Ce, de, Ue);
38132
38137
  default:
38133
- return he.destroy(new Error("Unknown command")), !1;
38138
+ return de.destroy(new Error("Unknown command")), !1;
38134
38139
  }
38135
38140
  }
38136
38141
  Object.defineProperty(x, "cacheNumbers", {
@@ -38144,47 +38149,47 @@ var mqtt = { exports: {} };
38144
38149
  function L(Ce) {
38145
38150
  Ce.uncork();
38146
38151
  }
38147
- function O(Ce, he, Ue) {
38148
- const Ne = Ce || {}, Oe = Ne.protocolId || "MQTT";
38152
+ function O(Ce, de, Ue) {
38153
+ const Ne = Ce || {}, Ve = Ne.protocolId || "MQTT";
38149
38154
  let Pt = Ne.protocolVersion || 4;
38150
38155
  const jt = Ne.will;
38151
38156
  let _n = Ne.clean;
38152
38157
  const oe = Ne.keepalive || 0, le = Ne.clientId || "", j = Ne.username, V = Ne.password, z = Ne.properties;
38153
38158
  _n === void 0 && (_n = !0);
38154
38159
  let ae = 0;
38155
- if (!Oe || typeof Oe != "string" && !c.isBuffer(Oe))
38156
- return he.destroy(new Error("Invalid protocolId")), !1;
38157
- if (ae += Oe.length + 2, Pt !== 3 && Pt !== 4 && Pt !== 5)
38158
- return he.destroy(new Error("Invalid protocol version")), !1;
38160
+ if (!Ve || typeof Ve != "string" && !c.isBuffer(Ve))
38161
+ return de.destroy(new Error("Invalid protocolId")), !1;
38162
+ if (ae += Ve.length + 2, Pt !== 3 && Pt !== 4 && Pt !== 5)
38163
+ return de.destroy(new Error("Invalid protocol version")), !1;
38159
38164
  if (ae += 1, (typeof le == "string" || c.isBuffer(le)) && (le || Pt >= 4) && (le || _n))
38160
38165
  ae += c.byteLength(le) + 2;
38161
38166
  else {
38162
38167
  if (Pt < 4)
38163
- return he.destroy(new Error("clientId must be supplied before 3.1.1")), !1;
38168
+ return de.destroy(new Error("clientId must be supplied before 3.1.1")), !1;
38164
38169
  if (_n * 1 === 0)
38165
- return he.destroy(new Error("clientId must be given if cleanSession set to 0")), !1;
38170
+ return de.destroy(new Error("clientId must be given if cleanSession set to 0")), !1;
38166
38171
  }
38167
38172
  if (typeof oe != "number" || oe < 0 || oe > 65535 || oe % 1 !== 0)
38168
- return he.destroy(new Error("Invalid keepalive")), !1;
38173
+ return de.destroy(new Error("Invalid keepalive")), !1;
38169
38174
  ae += 2, ae += 1;
38170
38175
  let xe, qe;
38171
38176
  if (Pt === 5) {
38172
- if (xe = Dt(he, z), !xe)
38177
+ if (xe = Dt(de, z), !xe)
38173
38178
  return !1;
38174
38179
  ae += xe.length;
38175
38180
  }
38176
38181
  if (jt) {
38177
38182
  if (typeof jt != "object")
38178
- return he.destroy(new Error("Invalid will")), !1;
38183
+ return de.destroy(new Error("Invalid will")), !1;
38179
38184
  if (!jt.topic || typeof jt.topic != "string")
38180
- return he.destroy(new Error("Invalid will topic")), !1;
38185
+ return de.destroy(new Error("Invalid will topic")), !1;
38181
38186
  if (ae += c.byteLength(jt.topic) + 2, ae += 2, jt.payload)
38182
38187
  if (jt.payload.length >= 0)
38183
38188
  typeof jt.payload == "string" ? ae += c.byteLength(jt.payload) : ae += jt.payload.length;
38184
38189
  else
38185
- return he.destroy(new Error("Invalid will payload")), !1;
38190
+ return de.destroy(new Error("Invalid will payload")), !1;
38186
38191
  if (qe = {}, Pt === 5) {
38187
- if (qe = Dt(he, jt.properties), !qe)
38192
+ if (qe = Dt(de, jt.properties), !qe)
38188
38193
  return !1;
38189
38194
  ae += qe.length;
38190
38195
  }
@@ -38194,80 +38199,80 @@ var mqtt = { exports: {} };
38194
38199
  if (kt(j))
38195
38200
  bn = !0, ae += c.byteLength(j) + 2;
38196
38201
  else
38197
- return he.destroy(new Error("Invalid username")), !1;
38202
+ return de.destroy(new Error("Invalid username")), !1;
38198
38203
  if (V != null) {
38199
38204
  if (!bn)
38200
- return he.destroy(new Error("Username is required to use password")), !1;
38205
+ return de.destroy(new Error("Username is required to use password")), !1;
38201
38206
  if (kt(V))
38202
38207
  ae += vn(V) + 2;
38203
38208
  else
38204
- return he.destroy(new Error("Invalid password")), !1;
38209
+ return de.destroy(new Error("Invalid password")), !1;
38205
38210
  }
38206
- he.write(u.CONNECT_HEADER), ze(he, ae), In(he, Oe), Ne.bridgeMode && (Pt += 128), he.write(
38211
+ de.write(u.CONNECT_HEADER), ze(de, ae), In(de, Ve), Ne.bridgeMode && (Pt += 128), de.write(
38207
38212
  Pt === 131 ? u.VERSION131 : Pt === 132 ? u.VERSION132 : Pt === 4 ? u.VERSION4 : Pt === 5 ? u.VERSION5 : u.VERSION3
38208
38213
  );
38209
38214
  let Sn = 0;
38210
- return Sn |= j != null ? u.USERNAME_MASK : 0, Sn |= V != null ? u.PASSWORD_MASK : 0, Sn |= jt && jt.retain ? u.WILL_RETAIN_MASK : 0, Sn |= jt && jt.qos ? jt.qos << u.WILL_QOS_SHIFT : 0, Sn |= jt ? u.WILL_FLAG_MASK : 0, Sn |= _n ? u.CLEAN_SESSION_MASK : 0, he.write(c.from([Sn])), S(he, oe), Pt === 5 && xe.write(), In(he, le), jt && (Pt === 5 && qe.write(), Fe(he, jt.topic), In(he, jt.payload)), j != null && In(he, j), V != null && In(he, V), !0;
38215
+ return Sn |= j != null ? u.USERNAME_MASK : 0, Sn |= V != null ? u.PASSWORD_MASK : 0, Sn |= jt && jt.retain ? u.WILL_RETAIN_MASK : 0, Sn |= jt && jt.qos ? jt.qos << u.WILL_QOS_SHIFT : 0, Sn |= jt ? u.WILL_FLAG_MASK : 0, Sn |= _n ? u.CLEAN_SESSION_MASK : 0, de.write(c.from([Sn])), S(de, oe), Pt === 5 && xe.write(), In(de, le), jt && (Pt === 5 && qe.write(), Fe(de, jt.topic), In(de, jt.payload)), j != null && In(de, j), V != null && In(de, V), !0;
38211
38216
  }
38212
- function M(Ce, he, Ue) {
38213
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Ne === 5 ? Oe.reasonCode : Oe.returnCode, jt = Oe.properties;
38217
+ function M(Ce, de, Ue) {
38218
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ne === 5 ? Ve.reasonCode : Ve.returnCode, jt = Ve.properties;
38214
38219
  let _n = 2;
38215
38220
  if (typeof Pt != "number")
38216
- return he.destroy(new Error("Invalid return code")), !1;
38221
+ return de.destroy(new Error("Invalid return code")), !1;
38217
38222
  let oe = null;
38218
38223
  if (Ne === 5) {
38219
- if (oe = Dt(he, jt), !oe)
38224
+ if (oe = Dt(de, jt), !oe)
38220
38225
  return !1;
38221
38226
  _n += oe.length;
38222
38227
  }
38223
- return he.write(u.CONNACK_HEADER), ze(he, _n), he.write(Oe.sessionPresent ? u.SESSIONPRESENT_HEADER : f), he.write(c.from([Pt])), oe != null && oe.write(), !0;
38228
+ return de.write(u.CONNACK_HEADER), ze(de, _n), de.write(Ve.sessionPresent ? u.SESSIONPRESENT_HEADER : f), de.write(c.from([Pt])), oe != null && oe.write(), !0;
38224
38229
  }
38225
- function k(Ce, he, Ue) {
38230
+ function k(Ce, de, Ue) {
38226
38231
  v("publish: packet: %o", Ce);
38227
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.qos || 0, jt = Oe.retain ? u.RETAIN_MASK : 0, _n = Oe.topic, oe = Oe.payload || d, le = Oe.messageId, j = Oe.properties;
38232
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.qos || 0, jt = Ve.retain ? u.RETAIN_MASK : 0, _n = Ve.topic, oe = Ve.payload || d, le = Ve.messageId, j = Ve.properties;
38228
38233
  let V = 0;
38229
38234
  if (typeof _n == "string")
38230
38235
  V += c.byteLength(_n) + 2;
38231
38236
  else if (c.isBuffer(_n))
38232
38237
  V += _n.length + 2;
38233
38238
  else
38234
- return he.destroy(new Error("Invalid topic")), !1;
38239
+ return de.destroy(new Error("Invalid topic")), !1;
38235
38240
  if (c.isBuffer(oe) ? V += oe.length : V += c.byteLength(oe), Pt && typeof le != "number")
38236
- return he.destroy(new Error("Invalid messageId")), !1;
38241
+ return de.destroy(new Error("Invalid messageId")), !1;
38237
38242
  Pt && (V += 2);
38238
38243
  let z = null;
38239
38244
  if (Ne === 5) {
38240
- if (z = Dt(he, j), !z)
38245
+ if (z = Dt(de, j), !z)
38241
38246
  return !1;
38242
38247
  V += z.length;
38243
38248
  }
38244
- return he.write(u.PUBLISH_HEADER[Pt][Oe.dup ? 1 : 0][jt ? 1 : 0]), ze(he, V), S(he, vn(_n)), he.write(_n), Pt > 0 && S(he, le), z != null && z.write(), v("publish: payload: %o", oe), he.write(oe);
38249
+ return de.write(u.PUBLISH_HEADER[Pt][Ve.dup ? 1 : 0][jt ? 1 : 0]), ze(de, V), S(de, vn(_n)), de.write(_n), Pt > 0 && S(de, le), z != null && z.write(), v("publish: payload: %o", oe), de.write(oe);
38245
38250
  }
38246
- function ie(Ce, he, Ue) {
38247
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.cmd || "puback", jt = Oe.messageId, _n = Oe.dup && Pt === "pubrel" ? u.DUP_MASK : 0;
38251
+ function ie(Ce, de, Ue) {
38252
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.cmd || "puback", jt = Ve.messageId, _n = Ve.dup && Pt === "pubrel" ? u.DUP_MASK : 0;
38248
38253
  let oe = 0;
38249
- const le = Oe.reasonCode, j = Oe.properties;
38254
+ const le = Ve.reasonCode, j = Ve.properties;
38250
38255
  let V = Ne === 5 ? 3 : 2;
38251
38256
  if (Pt === "pubrel" && (oe = 1), typeof jt != "number")
38252
- return he.destroy(new Error("Invalid messageId")), !1;
38257
+ return de.destroy(new Error("Invalid messageId")), !1;
38253
38258
  let z = null;
38254
38259
  if (Ne === 5 && typeof j == "object") {
38255
- if (z = de(he, j, Ue, V), !z)
38260
+ if (z = he(de, j, Ue, V), !z)
38256
38261
  return !1;
38257
38262
  V += z.length;
38258
38263
  }
38259
- return he.write(u.ACKS[Pt][oe][_n][0]), V === 3 && (V += le !== 0 ? 1 : -1), ze(he, V), S(he, jt), Ne === 5 && V !== 2 && he.write(c.from([le])), z !== null ? z.write() : V === 4 && he.write(c.from([0])), !0;
38264
+ return de.write(u.ACKS[Pt][oe][_n][0]), V === 3 && (V += le !== 0 ? 1 : -1), ze(de, V), S(de, jt), Ne === 5 && V !== 2 && de.write(c.from([le])), z !== null ? z.write() : V === 4 && de.write(c.from([0])), !0;
38260
38265
  }
38261
- function $(Ce, he, Ue) {
38266
+ function $(Ce, de, Ue) {
38262
38267
  v("subscribe: packet: ");
38263
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.dup ? u.DUP_MASK : 0, jt = Oe.messageId, _n = Oe.subscriptions, oe = Oe.properties;
38268
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.dup ? u.DUP_MASK : 0, jt = Ve.messageId, _n = Ve.subscriptions, oe = Ve.properties;
38264
38269
  let le = 0;
38265
38270
  if (typeof jt != "number")
38266
- return he.destroy(new Error("Invalid messageId")), !1;
38271
+ return de.destroy(new Error("Invalid messageId")), !1;
38267
38272
  le += 2;
38268
38273
  let j = null;
38269
38274
  if (Ne === 5) {
38270
- if (j = Dt(he, oe), !j)
38275
+ if (j = Dt(de, oe), !j)
38271
38276
  return !1;
38272
38277
  le += j.length;
38273
38278
  }
@@ -38275,149 +38280,149 @@ var mqtt = { exports: {} };
38275
38280
  for (let z = 0; z < _n.length; z += 1) {
38276
38281
  const ae = _n[z].topic, xe = _n[z].qos;
38277
38282
  if (typeof ae != "string")
38278
- return he.destroy(new Error("Invalid subscriptions - invalid topic")), !1;
38283
+ return de.destroy(new Error("Invalid subscriptions - invalid topic")), !1;
38279
38284
  if (typeof xe != "number")
38280
- return he.destroy(new Error("Invalid subscriptions - invalid qos")), !1;
38285
+ return de.destroy(new Error("Invalid subscriptions - invalid qos")), !1;
38281
38286
  if (Ne === 5) {
38282
38287
  if (typeof (_n[z].nl || !1) != "boolean")
38283
- return he.destroy(new Error("Invalid subscriptions - invalid No Local")), !1;
38288
+ return de.destroy(new Error("Invalid subscriptions - invalid No Local")), !1;
38284
38289
  if (typeof (_n[z].rap || !1) != "boolean")
38285
- return he.destroy(new Error("Invalid subscriptions - invalid Retain as Published")), !1;
38290
+ return de.destroy(new Error("Invalid subscriptions - invalid Retain as Published")), !1;
38286
38291
  const Sn = _n[z].rh || 0;
38287
38292
  if (typeof Sn != "number" || Sn > 2)
38288
- return he.destroy(new Error("Invalid subscriptions - invalid Retain Handling")), !1;
38293
+ return de.destroy(new Error("Invalid subscriptions - invalid Retain Handling")), !1;
38289
38294
  }
38290
38295
  le += c.byteLength(ae) + 2 + 1;
38291
38296
  }
38292
38297
  else
38293
- return he.destroy(new Error("Invalid subscriptions")), !1;
38294
- v("subscribe: writing to stream: %o", u.SUBSCRIBE_HEADER), he.write(u.SUBSCRIBE_HEADER[1][Pt ? 1 : 0][0]), ze(he, le), S(he, jt), j !== null && j.write();
38298
+ return de.destroy(new Error("Invalid subscriptions")), !1;
38299
+ v("subscribe: writing to stream: %o", u.SUBSCRIBE_HEADER), de.write(u.SUBSCRIBE_HEADER[1][Pt ? 1 : 0][0]), ze(de, le), S(de, jt), j !== null && j.write();
38295
38300
  let V = !0;
38296
38301
  for (const z of _n) {
38297
38302
  const ae = z.topic, xe = z.qos, qe = +z.nl, bn = +z.rap, Sn = z.rh;
38298
38303
  let xn;
38299
- Fe(he, ae), xn = u.SUBSCRIBE_OPTIONS_QOS[xe], Ne === 5 && (xn |= qe ? u.SUBSCRIBE_OPTIONS_NL : 0, xn |= bn ? u.SUBSCRIBE_OPTIONS_RAP : 0, xn |= Sn ? u.SUBSCRIBE_OPTIONS_RH[Sn] : 0), V = he.write(c.from([xn]));
38304
+ Fe(de, ae), xn = u.SUBSCRIBE_OPTIONS_QOS[xe], Ne === 5 && (xn |= qe ? u.SUBSCRIBE_OPTIONS_NL : 0, xn |= bn ? u.SUBSCRIBE_OPTIONS_RAP : 0, xn |= Sn ? u.SUBSCRIBE_OPTIONS_RH[Sn] : 0), V = de.write(c.from([xn]));
38300
38305
  }
38301
38306
  return V;
38302
38307
  }
38303
- function Y(Ce, he, Ue) {
38304
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.messageId, jt = Oe.granted, _n = Oe.properties;
38308
+ function Y(Ce, de, Ue) {
38309
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.messageId, jt = Ve.granted, _n = Ve.properties;
38305
38310
  let oe = 0;
38306
38311
  if (typeof Pt != "number")
38307
- return he.destroy(new Error("Invalid messageId")), !1;
38312
+ return de.destroy(new Error("Invalid messageId")), !1;
38308
38313
  if (oe += 2, typeof jt == "object" && jt.length)
38309
38314
  for (let j = 0; j < jt.length; j += 1) {
38310
38315
  if (typeof jt[j] != "number")
38311
- return he.destroy(new Error("Invalid qos vector")), !1;
38316
+ return de.destroy(new Error("Invalid qos vector")), !1;
38312
38317
  oe += 1;
38313
38318
  }
38314
38319
  else
38315
- return he.destroy(new Error("Invalid qos vector")), !1;
38320
+ return de.destroy(new Error("Invalid qos vector")), !1;
38316
38321
  let le = null;
38317
38322
  if (Ne === 5) {
38318
- if (le = de(he, _n, Ue, oe), !le)
38323
+ if (le = he(de, _n, Ue, oe), !le)
38319
38324
  return !1;
38320
38325
  oe += le.length;
38321
38326
  }
38322
- return he.write(u.SUBACK_HEADER), ze(he, oe), S(he, Pt), le !== null && le.write(), he.write(c.from(jt));
38327
+ return de.write(u.SUBACK_HEADER), ze(de, oe), S(de, Pt), le !== null && le.write(), de.write(c.from(jt));
38323
38328
  }
38324
- function D(Ce, he, Ue) {
38325
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.messageId, jt = Oe.dup ? u.DUP_MASK : 0, _n = Oe.unsubscriptions, oe = Oe.properties;
38329
+ function D(Ce, de, Ue) {
38330
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.messageId, jt = Ve.dup ? u.DUP_MASK : 0, _n = Ve.unsubscriptions, oe = Ve.properties;
38326
38331
  let le = 0;
38327
38332
  if (typeof Pt != "number")
38328
- return he.destroy(new Error("Invalid messageId")), !1;
38333
+ return de.destroy(new Error("Invalid messageId")), !1;
38329
38334
  if (le += 2, typeof _n == "object" && _n.length)
38330
38335
  for (let z = 0; z < _n.length; z += 1) {
38331
38336
  if (typeof _n[z] != "string")
38332
- return he.destroy(new Error("Invalid unsubscriptions")), !1;
38337
+ return de.destroy(new Error("Invalid unsubscriptions")), !1;
38333
38338
  le += c.byteLength(_n[z]) + 2;
38334
38339
  }
38335
38340
  else
38336
- return he.destroy(new Error("Invalid unsubscriptions")), !1;
38341
+ return de.destroy(new Error("Invalid unsubscriptions")), !1;
38337
38342
  let j = null;
38338
38343
  if (Ne === 5) {
38339
- if (j = Dt(he, oe), !j)
38344
+ if (j = Dt(de, oe), !j)
38340
38345
  return !1;
38341
38346
  le += j.length;
38342
38347
  }
38343
- he.write(u.UNSUBSCRIBE_HEADER[1][jt ? 1 : 0][0]), ze(he, le), S(he, Pt), j !== null && j.write();
38348
+ de.write(u.UNSUBSCRIBE_HEADER[1][jt ? 1 : 0][0]), ze(de, le), S(de, Pt), j !== null && j.write();
38344
38349
  let V = !0;
38345
38350
  for (let z = 0; z < _n.length; z++)
38346
- V = Fe(he, _n[z]);
38351
+ V = Fe(de, _n[z]);
38347
38352
  return V;
38348
38353
  }
38349
- function re(Ce, he, Ue) {
38350
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.messageId, jt = Oe.dup ? u.DUP_MASK : 0, _n = Oe.granted, oe = Oe.properties, le = Oe.cmd, j = 0;
38354
+ function re(Ce, de, Ue) {
38355
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.messageId, jt = Ve.dup ? u.DUP_MASK : 0, _n = Ve.granted, oe = Ve.properties, le = Ve.cmd, j = 0;
38351
38356
  let V = 2;
38352
38357
  if (typeof Pt != "number")
38353
- return he.destroy(new Error("Invalid messageId")), !1;
38358
+ return de.destroy(new Error("Invalid messageId")), !1;
38354
38359
  if (Ne === 5)
38355
38360
  if (typeof _n == "object" && _n.length)
38356
38361
  for (let ae = 0; ae < _n.length; ae += 1) {
38357
38362
  if (typeof _n[ae] != "number")
38358
- return he.destroy(new Error("Invalid qos vector")), !1;
38363
+ return de.destroy(new Error("Invalid qos vector")), !1;
38359
38364
  V += 1;
38360
38365
  }
38361
38366
  else
38362
- return he.destroy(new Error("Invalid qos vector")), !1;
38367
+ return de.destroy(new Error("Invalid qos vector")), !1;
38363
38368
  let z = null;
38364
38369
  if (Ne === 5) {
38365
- if (z = de(he, oe, Ue, V), !z)
38370
+ if (z = he(de, oe, Ue, V), !z)
38366
38371
  return !1;
38367
38372
  V += z.length;
38368
38373
  }
38369
- return he.write(u.ACKS[le][j][jt][0]), ze(he, V), S(he, Pt), z !== null && z.write(), Ne === 5 && he.write(c.from(_n)), !0;
38374
+ return de.write(u.ACKS[le][j][jt][0]), ze(de, V), S(de, Pt), z !== null && z.write(), Ne === 5 && de.write(c.from(_n)), !0;
38370
38375
  }
38371
- function F(Ce, he, Ue) {
38372
- return he.write(u.EMPTY[Ce.cmd]);
38376
+ function F(Ce, de, Ue) {
38377
+ return de.write(u.EMPTY[Ce.cmd]);
38373
38378
  }
38374
- function _e(Ce, he, Ue) {
38375
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.reasonCode, jt = Oe.properties;
38379
+ function _e(Ce, de, Ue) {
38380
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.reasonCode, jt = Ve.properties;
38376
38381
  let _n = Ne === 5 ? 1 : 0, oe = null;
38377
38382
  if (Ne === 5) {
38378
- if (oe = de(he, jt, Ue, _n), !oe)
38383
+ if (oe = he(de, jt, Ue, _n), !oe)
38379
38384
  return !1;
38380
38385
  _n += oe.length;
38381
38386
  }
38382
- return he.write(c.from([u.codes.disconnect << 4])), ze(he, _n), Ne === 5 && he.write(c.from([Pt])), oe !== null && oe.write(), !0;
38387
+ return de.write(c.from([u.codes.disconnect << 4])), ze(de, _n), Ne === 5 && de.write(c.from([Pt])), oe !== null && oe.write(), !0;
38383
38388
  }
38384
- function ue(Ce, he, Ue) {
38385
- const Ne = Ue ? Ue.protocolVersion : 4, Oe = Ce || {}, Pt = Oe.reasonCode, jt = Oe.properties;
38389
+ function ue(Ce, de, Ue) {
38390
+ const Ne = Ue ? Ue.protocolVersion : 4, Ve = Ce || {}, Pt = Ve.reasonCode, jt = Ve.properties;
38386
38391
  let _n = Ne === 5 ? 1 : 0;
38387
- Ne !== 5 && he.destroy(new Error("Invalid mqtt version for auth packet"));
38388
- const oe = de(he, jt, Ue, _n);
38389
- return oe ? (_n += oe.length, he.write(c.from([u.codes.auth << 4])), ze(he, _n), he.write(c.from([Pt])), oe !== null && oe.write(), !0) : !1;
38392
+ Ne !== 5 && de.destroy(new Error("Invalid mqtt version for auth packet"));
38393
+ const oe = he(de, jt, Ue, _n);
38394
+ return oe ? (_n += oe.length, de.write(c.from([u.codes.auth << 4])), ze(de, _n), de.write(c.from([Pt])), oe !== null && oe.write(), !0) : !1;
38390
38395
  }
38391
38396
  const Ie = {};
38392
- function ze(Ce, he) {
38393
- if (he > u.VARBYTEINT_MAX)
38394
- return Ce.destroy(new Error(`Invalid variable byte integer: ${he}`)), !1;
38395
- let Ue = Ie[he];
38396
- return Ue || (Ue = A(he), he < 16384 && (Ie[he] = Ue)), v("writeVarByteInt: writing to stream: %o", Ue), Ce.write(Ue);
38397
+ function ze(Ce, de) {
38398
+ if (de > u.VARBYTEINT_MAX)
38399
+ return Ce.destroy(new Error(`Invalid variable byte integer: ${de}`)), !1;
38400
+ let Ue = Ie[de];
38401
+ return Ue || (Ue = A(de), de < 16384 && (Ie[de] = Ue)), v("writeVarByteInt: writing to stream: %o", Ue), Ce.write(Ue);
38397
38402
  }
38398
- function Fe(Ce, he) {
38399
- const Ue = c.byteLength(he);
38400
- return S(Ce, Ue), v("writeString: %s", he), Ce.write(he, "utf8");
38403
+ function Fe(Ce, de) {
38404
+ const Ue = c.byteLength(de);
38405
+ return S(Ce, Ue), v("writeString: %s", de), Ce.write(de, "utf8");
38401
38406
  }
38402
- function Ve(Ce, he, Ue) {
38403
- Fe(Ce, he), Fe(Ce, Ue);
38407
+ function Oe(Ce, de, Ue) {
38408
+ Fe(Ce, de), Fe(Ce, Ue);
38404
38409
  }
38405
- function Lt(Ce, he) {
38406
- return v("writeNumberCached: number: %d", he), v("writeNumberCached: %o", g[he]), Ce.write(g[he]);
38410
+ function Lt(Ce, de) {
38411
+ return v("writeNumberCached: number: %d", de), v("writeNumberCached: %o", g[de]), Ce.write(g[de]);
38407
38412
  }
38408
- function pe(Ce, he) {
38409
- const Ue = y(he);
38413
+ function pe(Ce, de) {
38414
+ const Ue = y(de);
38410
38415
  return v("writeNumberGenerated: %o", Ue), Ce.write(Ue);
38411
38416
  }
38412
- function Cn(Ce, he) {
38413
- const Ue = w(he);
38417
+ function Cn(Ce, de) {
38418
+ const Ue = w(de);
38414
38419
  return v("write4ByteNumber: %o", Ue), Ce.write(Ue);
38415
38420
  }
38416
- function In(Ce, he) {
38417
- typeof he == "string" ? Fe(Ce, he) : he ? (S(Ce, he.length), Ce.write(he)) : S(Ce, 0);
38421
+ function In(Ce, de) {
38422
+ typeof de == "string" ? Fe(Ce, de) : de ? (S(Ce, de.length), Ce.write(de)) : S(Ce, 0);
38418
38423
  }
38419
- function Dt(Ce, he) {
38420
- if (typeof he != "object" || he.length != null)
38424
+ function Dt(Ce, de) {
38425
+ if (typeof de != "object" || de.length != null)
38421
38426
  return {
38422
38427
  length: 1,
38423
38428
  write() {
@@ -38485,10 +38490,10 @@ var mqtt = { exports: {} };
38485
38490
  }
38486
38491
  return oe;
38487
38492
  }
38488
- if (he)
38489
- for (const Pt in he) {
38493
+ if (de)
38494
+ for (const Pt in de) {
38490
38495
  let jt = 0, _n = 0;
38491
- const oe = he[Pt];
38496
+ const oe = de[Pt];
38492
38497
  if (Array.isArray(oe))
38493
38498
  for (let le = 0; le < oe.length; le++) {
38494
38499
  if (_n = Ne(Pt, oe[le]), !_n)
@@ -38507,76 +38512,76 @@ var mqtt = { exports: {} };
38507
38512
  return {
38508
38513
  length: c.byteLength(A(Ue)) + Ue,
38509
38514
  write() {
38510
- hn(Ce, he, Ue);
38515
+ hn(Ce, de, Ue);
38511
38516
  }
38512
38517
  };
38513
38518
  }
38514
- function de(Ce, he, Ue, Ne) {
38515
- const Oe = ["reasonString", "userProperties"], Pt = Ue && Ue.properties && Ue.properties.maximumPacketSize ? Ue.properties.maximumPacketSize : 0;
38516
- let jt = Dt(Ce, he);
38519
+ function he(Ce, de, Ue, Ne) {
38520
+ const Ve = ["reasonString", "userProperties"], Pt = Ue && Ue.properties && Ue.properties.maximumPacketSize ? Ue.properties.maximumPacketSize : 0;
38521
+ let jt = Dt(Ce, de);
38517
38522
  if (Pt)
38518
38523
  for (; Ne + jt.length > Pt; ) {
38519
- const _n = Oe.shift();
38520
- if (_n && he[_n])
38521
- delete he[_n], jt = Dt(Ce, he);
38524
+ const _n = Ve.shift();
38525
+ if (_n && de[_n])
38526
+ delete de[_n], jt = Dt(Ce, de);
38522
38527
  else
38523
38528
  return !1;
38524
38529
  }
38525
38530
  return jt;
38526
38531
  }
38527
- function Et(Ce, he, Ue) {
38528
- switch (u.propertiesTypes[he]) {
38532
+ function Et(Ce, de, Ue) {
38533
+ switch (u.propertiesTypes[de]) {
38529
38534
  case "byte": {
38530
- Ce.write(c.from([u.properties[he]])), Ce.write(c.from([+Ue]));
38535
+ Ce.write(c.from([u.properties[de]])), Ce.write(c.from([+Ue]));
38531
38536
  break;
38532
38537
  }
38533
38538
  case "int8": {
38534
- Ce.write(c.from([u.properties[he]])), Ce.write(c.from([Ue]));
38539
+ Ce.write(c.from([u.properties[de]])), Ce.write(c.from([Ue]));
38535
38540
  break;
38536
38541
  }
38537
38542
  case "binary": {
38538
- Ce.write(c.from([u.properties[he]])), In(Ce, Ue);
38543
+ Ce.write(c.from([u.properties[de]])), In(Ce, Ue);
38539
38544
  break;
38540
38545
  }
38541
38546
  case "int16": {
38542
- Ce.write(c.from([u.properties[he]])), S(Ce, Ue);
38547
+ Ce.write(c.from([u.properties[de]])), S(Ce, Ue);
38543
38548
  break;
38544
38549
  }
38545
38550
  case "int32": {
38546
- Ce.write(c.from([u.properties[he]])), Cn(Ce, Ue);
38551
+ Ce.write(c.from([u.properties[de]])), Cn(Ce, Ue);
38547
38552
  break;
38548
38553
  }
38549
38554
  case "var": {
38550
- Ce.write(c.from([u.properties[he]])), ze(Ce, Ue);
38555
+ Ce.write(c.from([u.properties[de]])), ze(Ce, Ue);
38551
38556
  break;
38552
38557
  }
38553
38558
  case "string": {
38554
- Ce.write(c.from([u.properties[he]])), Fe(Ce, Ue);
38559
+ Ce.write(c.from([u.properties[de]])), Fe(Ce, Ue);
38555
38560
  break;
38556
38561
  }
38557
38562
  case "pair": {
38558
- Object.getOwnPropertyNames(Ue).forEach((Oe) => {
38559
- const Pt = Ue[Oe];
38563
+ Object.getOwnPropertyNames(Ue).forEach((Ve) => {
38564
+ const Pt = Ue[Ve];
38560
38565
  Array.isArray(Pt) ? Pt.forEach((jt) => {
38561
- Ce.write(c.from([u.properties[he]])), Ve(Ce, Oe.toString(), jt.toString());
38562
- }) : (Ce.write(c.from([u.properties[he]])), Ve(Ce, Oe.toString(), Pt.toString()));
38566
+ Ce.write(c.from([u.properties[de]])), Oe(Ce, Ve.toString(), jt.toString());
38567
+ }) : (Ce.write(c.from([u.properties[de]])), Oe(Ce, Ve.toString(), Pt.toString()));
38563
38568
  });
38564
38569
  break;
38565
38570
  }
38566
38571
  default:
38567
- return Ce.destroy(new Error(`Invalid property ${he} value: ${Ue}`)), !1;
38572
+ return Ce.destroy(new Error(`Invalid property ${de} value: ${Ue}`)), !1;
38568
38573
  }
38569
38574
  }
38570
- function hn(Ce, he, Ue) {
38575
+ function hn(Ce, de, Ue) {
38571
38576
  ze(Ce, Ue);
38572
- for (const Ne in he)
38573
- if (Object.prototype.hasOwnProperty.call(he, Ne) && he[Ne] !== null) {
38574
- const Oe = he[Ne];
38575
- if (Array.isArray(Oe))
38576
- for (let Pt = 0; Pt < Oe.length; Pt++)
38577
- Et(Ce, Ne, Oe[Pt]);
38577
+ for (const Ne in de)
38578
+ if (Object.prototype.hasOwnProperty.call(de, Ne) && de[Ne] !== null) {
38579
+ const Ve = de[Ne];
38580
+ if (Array.isArray(Ve))
38581
+ for (let Pt = 0; Pt < Ve.length; Pt++)
38582
+ Et(Ce, Ne, Ve[Pt]);
38578
38583
  else
38579
- Et(Ce, Ne, Oe);
38584
+ Et(Ce, Ne, Ve);
38580
38585
  }
38581
38586
  }
38582
38587
  function vn(Ce) {
@@ -38903,78 +38908,78 @@ var mqtt = { exports: {} };
38903
38908
  function re(Dt) {
38904
38909
  throw new RangeError(k[Dt]);
38905
38910
  }
38906
- function F(Dt, de) {
38911
+ function F(Dt, he) {
38907
38912
  for (var Et = Dt.length, hn = []; Et--; )
38908
- hn[Et] = de(Dt[Et]);
38913
+ hn[Et] = he(Dt[Et]);
38909
38914
  return hn;
38910
38915
  }
38911
- function _e(Dt, de) {
38916
+ function _e(Dt, he) {
38912
38917
  var Et = Dt.split("@"), hn = "";
38913
38918
  Et.length > 1 && (hn = Et[0] + "@", Dt = Et[1]), Dt = Dt.replace(M, ".");
38914
- var vn = Dt.split("."), kt = F(vn, de).join(".");
38919
+ var vn = Dt.split("."), kt = F(vn, he).join(".");
38915
38920
  return hn + kt;
38916
38921
  }
38917
38922
  function ue(Dt) {
38918
- for (var de = [], Et = 0, hn = Dt.length, vn, kt; Et < hn; )
38919
- vn = Dt.charCodeAt(Et++), vn >= 55296 && vn <= 56319 && Et < hn ? (kt = Dt.charCodeAt(Et++), (kt & 64512) == 56320 ? de.push(((vn & 1023) << 10) + (kt & 1023) + 65536) : (de.push(vn), Et--)) : de.push(vn);
38920
- return de;
38923
+ for (var he = [], Et = 0, hn = Dt.length, vn, kt; Et < hn; )
38924
+ vn = Dt.charCodeAt(Et++), vn >= 55296 && vn <= 56319 && Et < hn ? (kt = Dt.charCodeAt(Et++), (kt & 64512) == 56320 ? he.push(((vn & 1023) << 10) + (kt & 1023) + 65536) : (he.push(vn), Et--)) : he.push(vn);
38925
+ return he;
38921
38926
  }
38922
38927
  function Ie(Dt) {
38923
- return F(Dt, function(de) {
38928
+ return F(Dt, function(he) {
38924
38929
  var Et = "";
38925
- return de > 65535 && (de -= 65536, Et += Y(de >>> 10 & 1023 | 55296), de = 56320 | de & 1023), Et += Y(de), Et;
38930
+ return he > 65535 && (he -= 65536, Et += Y(he >>> 10 & 1023 | 55296), he = 56320 | he & 1023), Et += Y(he), Et;
38926
38931
  }).join("");
38927
38932
  }
38928
38933
  function ze(Dt) {
38929
38934
  return Dt - 48 < 10 ? Dt - 22 : Dt - 65 < 26 ? Dt - 65 : Dt - 97 < 26 ? Dt - 97 : g;
38930
38935
  }
38931
- function Fe(Dt, de) {
38932
- return Dt + 22 + 75 * (Dt < 26) - ((de != 0) << 5);
38936
+ function Fe(Dt, he) {
38937
+ return Dt + 22 + 75 * (Dt < 26) - ((he != 0) << 5);
38933
38938
  }
38934
- function Ve(Dt, de, Et) {
38939
+ function Oe(Dt, he, Et) {
38935
38940
  var hn = 0;
38936
- for (Dt = Et ? $(Dt / w) : Dt >> 1, Dt += $(Dt / de); Dt > ie * b >> 1; hn += g)
38941
+ for (Dt = Et ? $(Dt / w) : Dt >> 1, Dt += $(Dt / he); Dt > ie * b >> 1; hn += g)
38937
38942
  Dt = $(Dt / ie);
38938
38943
  return $(hn + (ie + 1) * Dt / (Dt + A));
38939
38944
  }
38940
38945
  function Lt(Dt) {
38941
- var de = [], Et = Dt.length, hn, vn = 0, kt = T, Ce = S, he, Ue, Ne, Oe, Pt, jt, _n, oe, le;
38942
- for (he = Dt.lastIndexOf(x), he < 0 && (he = 0), Ue = 0; Ue < he; ++Ue)
38943
- Dt.charCodeAt(Ue) >= 128 && re("not-basic"), de.push(Dt.charCodeAt(Ue));
38944
- for (Ne = he > 0 ? he + 1 : 0; Ne < Et; ) {
38945
- for (Oe = vn, Pt = 1, jt = g; Ne >= Et && re("invalid-input"), _n = ze(Dt.charCodeAt(Ne++)), (_n >= g || _n > $((v - vn) / Pt)) && re("overflow"), vn += _n * Pt, oe = jt <= Ce ? y : jt >= Ce + b ? b : jt - Ce, !(_n < oe); jt += g)
38946
+ var he = [], Et = Dt.length, hn, vn = 0, kt = T, Ce = S, de, Ue, Ne, Ve, Pt, jt, _n, oe, le;
38947
+ for (de = Dt.lastIndexOf(x), de < 0 && (de = 0), Ue = 0; Ue < de; ++Ue)
38948
+ Dt.charCodeAt(Ue) >= 128 && re("not-basic"), he.push(Dt.charCodeAt(Ue));
38949
+ for (Ne = de > 0 ? de + 1 : 0; Ne < Et; ) {
38950
+ for (Ve = vn, Pt = 1, jt = g; Ne >= Et && re("invalid-input"), _n = ze(Dt.charCodeAt(Ne++)), (_n >= g || _n > $((v - vn) / Pt)) && re("overflow"), vn += _n * Pt, oe = jt <= Ce ? y : jt >= Ce + b ? b : jt - Ce, !(_n < oe); jt += g)
38946
38951
  le = g - oe, Pt > $(v / le) && re("overflow"), Pt *= le;
38947
- hn = de.length + 1, Ce = Ve(vn - Oe, hn, Oe == 0), $(vn / hn) > v - kt && re("overflow"), kt += $(vn / hn), vn %= hn, de.splice(vn++, 0, kt);
38952
+ hn = he.length + 1, Ce = Oe(vn - Ve, hn, Ve == 0), $(vn / hn) > v - kt && re("overflow"), kt += $(vn / hn), vn %= hn, he.splice(vn++, 0, kt);
38948
38953
  }
38949
- return Ie(de);
38954
+ return Ie(he);
38950
38955
  }
38951
38956
  function pe(Dt) {
38952
- var de, Et, hn, vn, kt, Ce, he, Ue, Ne, Oe, Pt, jt = [], _n, oe, le, j;
38953
- for (Dt = ue(Dt), _n = Dt.length, de = T, Et = 0, kt = S, Ce = 0; Ce < _n; ++Ce)
38957
+ var he, Et, hn, vn, kt, Ce, de, Ue, Ne, Ve, Pt, jt = [], _n, oe, le, j;
38958
+ for (Dt = ue(Dt), _n = Dt.length, he = T, Et = 0, kt = S, Ce = 0; Ce < _n; ++Ce)
38954
38959
  Pt = Dt[Ce], Pt < 128 && jt.push(Y(Pt));
38955
38960
  for (hn = vn = jt.length, vn && jt.push(x); hn < _n; ) {
38956
- for (he = v, Ce = 0; Ce < _n; ++Ce)
38957
- Pt = Dt[Ce], Pt >= de && Pt < he && (he = Pt);
38958
- for (oe = hn + 1, he - de > $((v - Et) / oe) && re("overflow"), Et += (he - de) * oe, de = he, Ce = 0; Ce < _n; ++Ce)
38959
- if (Pt = Dt[Ce], Pt < de && ++Et > v && re("overflow"), Pt == de) {
38960
- for (Ue = Et, Ne = g; Oe = Ne <= kt ? y : Ne >= kt + b ? b : Ne - kt, !(Ue < Oe); Ne += g)
38961
- j = Ue - Oe, le = g - Oe, jt.push(
38962
- Y(Fe(Oe + j % le, 0))
38961
+ for (de = v, Ce = 0; Ce < _n; ++Ce)
38962
+ Pt = Dt[Ce], Pt >= he && Pt < de && (de = Pt);
38963
+ for (oe = hn + 1, de - he > $((v - Et) / oe) && re("overflow"), Et += (de - he) * oe, he = de, Ce = 0; Ce < _n; ++Ce)
38964
+ if (Pt = Dt[Ce], Pt < he && ++Et > v && re("overflow"), Pt == he) {
38965
+ for (Ue = Et, Ne = g; Ve = Ne <= kt ? y : Ne >= kt + b ? b : Ne - kt, !(Ue < Ve); Ne += g)
38966
+ j = Ue - Ve, le = g - Ve, jt.push(
38967
+ Y(Fe(Ve + j % le, 0))
38963
38968
  ), Ue = $(j / le);
38964
- jt.push(Y(Fe(Ue, 0))), kt = Ve(Et, oe, hn == vn), Et = 0, ++hn;
38969
+ jt.push(Y(Fe(Ue, 0))), kt = Oe(Et, oe, hn == vn), Et = 0, ++hn;
38965
38970
  }
38966
- ++Et, ++de;
38971
+ ++Et, ++he;
38967
38972
  }
38968
38973
  return jt.join("");
38969
38974
  }
38970
38975
  function Cn(Dt) {
38971
- return _e(Dt, function(de) {
38972
- return L.test(de) ? Lt(de.slice(4).toLowerCase()) : de;
38976
+ return _e(Dt, function(he) {
38977
+ return L.test(he) ? Lt(he.slice(4).toLowerCase()) : he;
38973
38978
  });
38974
38979
  }
38975
38980
  function In(Dt) {
38976
- return _e(Dt, function(de) {
38977
- return O.test(de) ? "xn--" + pe(de) : de;
38981
+ return _e(Dt, function(he) {
38982
+ return O.test(he) ? "xn--" + pe(he) : he;
38978
38983
  });
38979
38984
  }
38980
38985
  if (_ = {
@@ -39248,8 +39253,8 @@ var mqtt = { exports: {} };
39248
39253
  readable: ue
39249
39254
  }), _e) {
39250
39255
  if (f(re))
39251
- Y._write = function(ze, Fe, Ve) {
39252
- re.write(ze, Fe) ? Ve() : M = Ve;
39256
+ Y._write = function(ze, Fe, Oe) {
39257
+ re.write(ze, Fe) ? Oe() : M = Oe;
39253
39258
  }, Y._final = function(ze) {
39254
39259
  re.end(), k = ze;
39255
39260
  }, re.on("drain", function() {
@@ -39260,19 +39265,19 @@ var mqtt = { exports: {} };
39260
39265
  });
39261
39266
  else if (v(re)) {
39262
39267
  const Fe = (g(re) ? re.writable : re).getWriter();
39263
- Y._write = async function(Ve, Lt, pe) {
39268
+ Y._write = async function(Oe, Lt, pe) {
39264
39269
  try {
39265
- await Fe.ready, Fe.write(Ve).catch(() => {
39270
+ await Fe.ready, Fe.write(Oe).catch(() => {
39266
39271
  }), pe();
39267
39272
  } catch (Cn) {
39268
39273
  pe(Cn);
39269
39274
  }
39270
- }, Y._final = async function(Ve) {
39275
+ }, Y._final = async function(Oe) {
39271
39276
  try {
39272
39277
  await Fe.ready, Fe.close().catch(() => {
39273
- }), k = Ve;
39278
+ }), k = Oe;
39274
39279
  } catch (Lt) {
39275
- Ve(Lt);
39280
+ Oe(Lt);
39276
39281
  }
39277
39282
  };
39278
39283
  }
@@ -39309,10 +39314,10 @@ var mqtt = { exports: {} };
39309
39314
  Y._read = async function() {
39310
39315
  for (; ; )
39311
39316
  try {
39312
- const { value: Fe, done: Ve } = await ze.read();
39317
+ const { value: Fe, done: Oe } = await ze.read();
39313
39318
  if (!Y.push(Fe))
39314
39319
  return;
39315
- if (Ve) {
39320
+ if (Oe) {
39316
39321
  Y.push(null);
39317
39322
  return;
39318
39323
  }
@@ -39336,14 +39341,14 @@ var mqtt = { exports: {} };
39336
39341
  ue && (ue.stack, Ie && !Ie.errored && (Ie.errored = ue), ze && !ze.errored && (ze.errored = ue));
39337
39342
  }
39338
39343
  function S(ue, Ie) {
39339
- const ze = this._readableState, Fe = this._writableState, Ve = Fe || ze;
39340
- return Fe != null && Fe.destroyed || ze != null && ze.destroyed ? (typeof Ie == "function" && Ie(), this) : (w(ue, Fe, ze), Fe && (Fe.destroyed = !0), ze && (ze.destroyed = !0), Ve.constructed ? T(this, ue, Ie) : this.once(b, function(Lt) {
39344
+ const ze = this._readableState, Fe = this._writableState, Oe = Fe || ze;
39345
+ return Fe != null && Fe.destroyed || ze != null && ze.destroyed ? (typeof Ie == "function" && Ie(), this) : (w(ue, Fe, ze), Fe && (Fe.destroyed = !0), ze && (ze.destroyed = !0), Oe.constructed ? T(this, ue, Ie) : this.once(b, function(Lt) {
39341
39346
  T(this, c(Lt, ue), Ie);
39342
39347
  }), this);
39343
39348
  }
39344
39349
  function T(ue, Ie, ze) {
39345
39350
  let Fe = !1;
39346
- function Ve(Lt) {
39351
+ function Oe(Lt) {
39347
39352
  if (Fe)
39348
39353
  return;
39349
39354
  Fe = !0;
@@ -39351,9 +39356,9 @@ var mqtt = { exports: {} };
39351
39356
  w(Lt, Cn, pe), Cn && (Cn.closed = !0), pe && (pe.closed = !0), typeof ze == "function" && ze(Lt), Lt ? u.nextTick(x, ue, Lt) : u.nextTick(L, ue);
39352
39357
  }
39353
39358
  try {
39354
- ue._destroy(Ie || null, Ve);
39359
+ ue._destroy(Ie || null, Oe);
39355
39360
  } catch (Lt) {
39356
- Ve(Lt);
39361
+ Oe(Lt);
39357
39362
  }
39358
39363
  }
39359
39364
  function x(ue, Ie) {
@@ -39372,10 +39377,10 @@ var mqtt = { exports: {} };
39372
39377
  ue && (ue.constructed = !0, ue.closed = !1, ue.closeEmitted = !1, ue.destroyed = !1, ue.errored = null, ue.errorEmitted = !1, ue.reading = !1, ue.ended = ue.readable === !1, ue.endEmitted = ue.readable === !1), Ie && (Ie.constructed = !0, Ie.destroyed = !1, Ie.closed = !1, Ie.closeEmitted = !1, Ie.errored = null, Ie.errorEmitted = !1, Ie.finalCalled = !1, Ie.prefinished = !1, Ie.ended = Ie.writable === !1, Ie.ending = Ie.writable === !1, Ie.finished = Ie.writable === !1);
39373
39378
  }
39374
39379
  function k(ue, Ie, ze) {
39375
- const Fe = ue._readableState, Ve = ue._writableState;
39376
- if (Ve != null && Ve.destroyed || Fe != null && Fe.destroyed)
39380
+ const Fe = ue._readableState, Oe = ue._writableState;
39381
+ if (Oe != null && Oe.destroyed || Fe != null && Fe.destroyed)
39377
39382
  return this;
39378
- Fe != null && Fe.autoDestroy || Ve != null && Ve.autoDestroy ? ue.destroy(Ie) : Ie && (Ie.stack, Ve && !Ve.errored && (Ve.errored = Ie), Fe && !Fe.errored && (Fe.errored = Ie), ze ? u.nextTick(O, ue, Ie) : O(ue, Ie));
39383
+ Fe != null && Fe.autoDestroy || Oe != null && Oe.autoDestroy ? ue.destroy(Ie) : Ie && (Ie.stack, Oe && !Oe.errored && (Oe.errored = Ie), Fe && !Fe.errored && (Fe.errored = Ie), ze ? u.nextTick(O, ue, Ie) : O(ue, Ie));
39379
39384
  }
39380
39385
  function ie(ue, Ie) {
39381
39386
  if (typeof ue._construct != "function")
@@ -39391,8 +39396,8 @@ var mqtt = { exports: {} };
39391
39396
  return;
39392
39397
  }
39393
39398
  Ie = !0;
39394
- const Ve = ue._readableState, Lt = ue._writableState, pe = Lt || Ve;
39395
- Ve && (Ve.constructed = !0), Lt && (Lt.constructed = !0), pe.destroyed ? ue.emit(b, Fe) : Fe ? k(ue, Fe, !0) : u.nextTick(Y, ue);
39399
+ const Oe = ue._readableState, Lt = ue._writableState, pe = Lt || Oe;
39400
+ Oe && (Oe.constructed = !0), Lt && (Lt.constructed = !0), pe.destroyed ? ue.emit(b, Fe) : Fe ? k(ue, Fe, !0) : u.nextTick(Y, ue);
39396
39401
  }
39397
39402
  try {
39398
39403
  ue._construct((Fe) => {
@@ -39545,12 +39550,12 @@ var mqtt = { exports: {} };
39545
39550
  readable: !1
39546
39551
  });
39547
39552
  if (typeof ue == "function") {
39548
- const { value: Fe, write: Ve, final: Lt, destroy: pe } = re(ue);
39553
+ const { value: Fe, write: Oe, final: Lt, destroy: pe } = re(ue);
39549
39554
  if (p(Fe))
39550
39555
  return M(D, Fe, {
39551
39556
  // TODO (ronag): highWaterMark?
39552
39557
  objectMode: !0,
39553
- write: Ve,
39558
+ write: Oe,
39554
39559
  final: Lt,
39555
39560
  destroy: pe
39556
39561
  });
@@ -39560,25 +39565,25 @@ var mqtt = { exports: {} };
39560
39565
  const Dt = Y(
39561
39566
  Cn,
39562
39567
  Fe,
39563
- (de) => {
39564
- if (de != null)
39565
- throw new S("nully", "body", de);
39568
+ (he) => {
39569
+ if (he != null)
39570
+ throw new S("nully", "body", he);
39566
39571
  },
39567
- (de) => {
39568
- T(In, de);
39572
+ (he) => {
39573
+ T(In, he);
39569
39574
  }
39570
39575
  );
39571
39576
  return In = new D({
39572
39577
  // TODO (ronag): highWaterMark?
39573
39578
  objectMode: !0,
39574
39579
  readable: !1,
39575
- write: Ve,
39576
- final(de) {
39580
+ write: Oe,
39581
+ final(he) {
39577
39582
  Lt(async () => {
39578
39583
  try {
39579
- await Dt, u.nextTick(de, null);
39584
+ await Dt, u.nextTick(he, null);
39580
39585
  } catch (Et) {
39581
- u.nextTick(de, Et);
39586
+ u.nextTick(he, Et);
39582
39587
  }
39583
39588
  });
39584
39589
  },
@@ -39596,10 +39601,10 @@ var mqtt = { exports: {} };
39596
39601
  writable: !1
39597
39602
  });
39598
39603
  if (typeof (ue == null ? void 0 : ue.writable) == "object" || typeof (ue == null ? void 0 : ue.readable) == "object") {
39599
- const Fe = ue != null && ue.readable ? v(ue == null ? void 0 : ue.readable) ? ue == null ? void 0 : ue.readable : _e(ue.readable) : void 0, Ve = ue != null && ue.writable ? g(ue == null ? void 0 : ue.writable) ? ue == null ? void 0 : ue.writable : _e(ue.writable) : void 0;
39604
+ const Fe = ue != null && ue.readable ? v(ue == null ? void 0 : ue.readable) ? ue == null ? void 0 : ue.readable : _e(ue.readable) : void 0, Oe = ue != null && ue.writable ? g(ue == null ? void 0 : ue.writable) ? ue == null ? void 0 : ue.writable : _e(ue.writable) : void 0;
39600
39605
  return F({
39601
39606
  readable: Fe,
39602
- writable: Ve
39607
+ writable: Oe
39603
39608
  });
39604
39609
  }
39605
39610
  const ze = ue == null ? void 0 : ue.then;
@@ -39608,11 +39613,11 @@ var mqtt = { exports: {} };
39608
39613
  return Y(
39609
39614
  ze,
39610
39615
  ue,
39611
- (Ve) => {
39612
- Ve != null && Fe.push(Ve), Fe.push(null);
39616
+ (Oe) => {
39617
+ Oe != null && Fe.push(Oe), Fe.push(null);
39613
39618
  },
39614
- (Ve) => {
39615
- T(Fe, Ve);
39619
+ (Oe) => {
39620
+ T(Fe, Oe);
39616
39621
  }
39617
39622
  ), Fe = new D({
39618
39623
  objectMode: !0,
@@ -39682,10 +39687,10 @@ var mqtt = { exports: {} };
39682
39687
  }
39683
39688
  function F(_e) {
39684
39689
  const ue = _e.readable && typeof _e.readable.read != "function" ? L.wrap(_e.readable) : _e.readable, Ie = _e.writable;
39685
- let ze = !!d(ue), Fe = !!f(Ie), Ve, Lt, pe, Cn, In;
39686
- function Dt(de) {
39690
+ let ze = !!d(ue), Fe = !!f(Ie), Oe, Lt, pe, Cn, In;
39691
+ function Dt(he) {
39687
39692
  const Et = Cn;
39688
- Cn = null, Et ? Et(de) : de && In.destroy(de);
39693
+ Cn = null, Et ? Et(he) : he && In.destroy(he);
39689
39694
  }
39690
39695
  return In = new D({
39691
39696
  // TODO (ronag): highWaterMark?
@@ -39693,43 +39698,43 @@ var mqtt = { exports: {} };
39693
39698
  writableObjectMode: !!(Ie != null && Ie.writableObjectMode),
39694
39699
  readable: ze,
39695
39700
  writable: Fe
39696
- }), Fe && (b(Ie, (de) => {
39697
- Fe = !1, de && T(ue, de), Dt(de);
39698
- }), In._write = function(de, Et, hn) {
39699
- Ie.write(de, Et) ? hn() : Ve = hn;
39700
- }, In._final = function(de) {
39701
- Ie.end(), Lt = de;
39701
+ }), Fe && (b(Ie, (he) => {
39702
+ Fe = !1, he && T(ue, he), Dt(he);
39703
+ }), In._write = function(he, Et, hn) {
39704
+ Ie.write(he, Et) ? hn() : Oe = hn;
39705
+ }, In._final = function(he) {
39706
+ Ie.end(), Lt = he;
39702
39707
  }, Ie.on("drain", function() {
39703
- if (Ve) {
39704
- const de = Ve;
39705
- Ve = null, de();
39708
+ if (Oe) {
39709
+ const he = Oe;
39710
+ Oe = null, he();
39706
39711
  }
39707
39712
  }), Ie.on("finish", function() {
39708
39713
  if (Lt) {
39709
- const de = Lt;
39710
- Lt = null, de();
39714
+ const he = Lt;
39715
+ Lt = null, he();
39711
39716
  }
39712
- })), ze && (b(ue, (de) => {
39713
- ze = !1, de && T(ue, de), Dt(de);
39717
+ })), ze && (b(ue, (he) => {
39718
+ ze = !1, he && T(ue, he), Dt(he);
39714
39719
  }), ue.on("readable", function() {
39715
39720
  if (pe) {
39716
- const de = pe;
39717
- pe = null, de();
39721
+ const he = pe;
39722
+ pe = null, he();
39718
39723
  }
39719
39724
  }), ue.on("end", function() {
39720
39725
  In.push(null);
39721
39726
  }), In._read = function() {
39722
39727
  for (; ; ) {
39723
- const de = ue.read();
39724
- if (de === null) {
39728
+ const he = ue.read();
39729
+ if (he === null) {
39725
39730
  pe = In._read;
39726
39731
  return;
39727
39732
  }
39728
- if (!In.push(de))
39733
+ if (!In.push(he))
39729
39734
  return;
39730
39735
  }
39731
- }), In._destroy = function(de, Et) {
39732
- !de && Cn !== null && (de = new A()), pe = null, Ve = null, Lt = null, Cn === null ? Et(de) : (Cn = Et, T(Ie, de), T(ue, de));
39736
+ }), In._destroy = function(he, Et) {
39737
+ !he && Cn !== null && (he = new A()), pe = null, Oe = null, Lt = null, Cn === null ? Et(he) : (Cn = Et, T(Ie, he), T(ue, he));
39733
39738
  }, In;
39734
39739
  }
39735
39740
  }, { "../../ours/errors": 126, "../../ours/primordials": 127, "../../ours/util": 128, "./destroy": 110, "./duplex": 111, "./end-of-stream": 113, "./from": 114, "./readable": 119, "./utils": 122, "abort-controller": 24, buffer: 29, "process/": 102 }], 113: [function(n, o, a) {
@@ -39755,21 +39760,21 @@ var mqtt = { exports: {} };
39755
39760
  const ze = () => {
39756
39761
  };
39757
39762
  function Fe(pe, Cn, In) {
39758
- var Dt, de;
39763
+ var Dt, he;
39759
39764
  if (arguments.length === 2 ? (In = Cn, Cn = _) : Cn == null ? Cn = _ : b(Cn, "options"), y(In, "callback"), g(Cn.signal, "options.signal"), In = v(In), O(pe) || Y(pe))
39760
- return Ve(pe, Cn, In);
39765
+ return Oe(pe, Cn, In);
39761
39766
  if (!F(pe))
39762
39767
  throw new f("stream", ["ReadableStream", "WritableStream", "Stream"], pe);
39763
- const Et = (Dt = Cn.readable) !== null && Dt !== void 0 ? Dt : L(pe), hn = (de = Cn.writable) !== null && de !== void 0 ? de : $(pe), vn = pe._writableState, kt = pe._readableState, Ce = () => {
39768
+ const Et = (Dt = Cn.readable) !== null && Dt !== void 0 ? Dt : L(pe), hn = (he = Cn.writable) !== null && he !== void 0 ? he : $(pe), vn = pe._writableState, kt = pe._readableState, Ce = () => {
39764
39769
  pe.writable || Ne();
39765
39770
  };
39766
- let he = _e(pe) && L(pe) === Et && $(pe) === hn, Ue = D(pe, !1);
39771
+ let de = _e(pe) && L(pe) === Et && $(pe) === hn, Ue = D(pe, !1);
39767
39772
  const Ne = () => {
39768
- Ue = !0, pe.destroyed && (he = !1), !(he && (!pe.readable || Et)) && (!Et || Oe) && In.call(pe);
39773
+ Ue = !0, pe.destroyed && (de = !1), !(de && (!pe.readable || Et)) && (!Et || Ve) && In.call(pe);
39769
39774
  };
39770
- let Oe = M(pe, !1);
39775
+ let Ve = M(pe, !1);
39771
39776
  const Pt = () => {
39772
- Oe = !0, pe.destroyed && (he = !1), !(he && (!pe.writable || hn)) && (!hn || Ue) && In.call(pe);
39777
+ Ve = !0, pe.destroyed && (de = !1), !(de && (!pe.writable || hn)) && (!hn || Ue) && In.call(pe);
39773
39778
  }, jt = (z) => {
39774
39779
  In.call(pe, z);
39775
39780
  };
@@ -39779,7 +39784,7 @@ var mqtt = { exports: {} };
39779
39784
  const z = re(pe) || k(pe);
39780
39785
  if (z && typeof z != "boolean")
39781
39786
  return In.call(pe, z);
39782
- if (Et && !Oe && L(pe, !0) && !M(pe, !1))
39787
+ if (Et && !Ve && L(pe, !0) && !M(pe, !1))
39783
39788
  return In.call(pe, new p());
39784
39789
  if (hn && !Ue && !D(pe, !1))
39785
39790
  return In.call(pe, new p());
@@ -39793,7 +39798,7 @@ var mqtt = { exports: {} };
39793
39798
  }, j = () => {
39794
39799
  pe.req.on("finish", Ne);
39795
39800
  };
39796
- Ie(pe) ? (pe.on("complete", Ne), he || pe.on("abort", oe), pe.req ? j() : pe.on("request", j)) : hn && !vn && (pe.on("end", Ce), pe.on("close", Ce)), !he && typeof pe.aborted == "boolean" && pe.on("aborted", oe), pe.on("end", Pt), pe.on("finish", Ne), Cn.error !== !1 && pe.on("error", jt), pe.on("close", oe), _n ? u.nextTick(oe) : vn != null && vn.errorEmitted || kt != null && kt.errorEmitted ? he || u.nextTick(le) : (!Et && (!he || x(pe)) && (Ue || ie(pe) === !1) || !hn && (!he || ie(pe)) && (Oe || x(pe) === !1) || kt && pe.req && pe.aborted) && u.nextTick(le);
39801
+ Ie(pe) ? (pe.on("complete", Ne), de || pe.on("abort", oe), pe.req ? j() : pe.on("request", j)) : hn && !vn && (pe.on("end", Ce), pe.on("close", Ce)), !de && typeof pe.aborted == "boolean" && pe.on("aborted", oe), pe.on("end", Pt), pe.on("finish", Ne), Cn.error !== !1 && pe.on("error", jt), pe.on("close", oe), _n ? u.nextTick(oe) : vn != null && vn.errorEmitted || kt != null && kt.errorEmitted ? de || u.nextTick(le) : (!Et && (!de || x(pe)) && (Ue || ie(pe) === !1) || !hn && (!de || ie(pe)) && (Ve || x(pe) === !1) || kt && pe.req && pe.aborted) && u.nextTick(le);
39797
39802
  const V = () => {
39798
39803
  In = ze, pe.removeListener("aborted", oe), pe.removeListener("complete", Ne), pe.removeListener("abort", oe), pe.removeListener("request", j), pe.req && pe.req.removeListener("finish", Ne), pe.removeListener("end", Ce), pe.removeListener("close", Ce), pe.removeListener("finish", Ne), pe.removeListener("end", Pt), pe.removeListener("error", jt), pe.removeListener("close", oe);
39799
39804
  };
@@ -39818,10 +39823,10 @@ var mqtt = { exports: {} };
39818
39823
  }
39819
39824
  return V;
39820
39825
  }
39821
- function Ve(pe, Cn, In) {
39822
- let Dt = !1, de = ze;
39826
+ function Oe(pe, Cn, In) {
39827
+ let Dt = !1, he = ze;
39823
39828
  if (Cn.signal)
39824
- if (de = () => {
39829
+ if (he = () => {
39825
39830
  Dt = !0, In.call(
39826
39831
  pe,
39827
39832
  new c(void 0, {
@@ -39829,12 +39834,12 @@ var mqtt = { exports: {} };
39829
39834
  })
39830
39835
  );
39831
39836
  }, Cn.signal.aborted)
39832
- u.nextTick(de);
39837
+ u.nextTick(he);
39833
39838
  else {
39834
39839
  const hn = In;
39835
39840
  In = v((...vn) => {
39836
- Cn.signal.removeEventListener("abort", de), hn.apply(pe, vn);
39837
- }), Cn.signal.addEventListener("abort", de);
39841
+ Cn.signal.removeEventListener("abort", he), hn.apply(pe, vn);
39842
+ }), Cn.signal.addEventListener("abort", he);
39838
39843
  }
39839
39844
  const Et = (...hn) => {
39840
39845
  Dt || u.nextTick(() => In.apply(pe, hn));
@@ -39844,9 +39849,9 @@ var mqtt = { exports: {} };
39844
39849
  function Lt(pe, Cn) {
39845
39850
  var In;
39846
39851
  let Dt = !1;
39847
- return Cn === null && (Cn = _), (In = Cn) !== null && In !== void 0 && In.cleanup && (A(Cn.cleanup, "cleanup"), Dt = Cn.cleanup), new w((de, Et) => {
39852
+ return Cn === null && (Cn = _), (In = Cn) !== null && In !== void 0 && In.cleanup && (A(Cn.cleanup, "cleanup"), Dt = Cn.cleanup), new w((he, Et) => {
39848
39853
  const hn = Fe(pe, Cn, (vn) => {
39849
- Dt && hn(), vn ? Et(vn) : de();
39854
+ Dt && hn(), vn ? Et(vn) : he();
39850
39855
  });
39851
39856
  });
39852
39857
  }
@@ -39979,20 +39984,20 @@ var mqtt = { exports: {} };
39979
39984
  function _e(kt, Ce) {
39980
39985
  if (Ce != null && y(Ce, "options"), (Ce == null ? void 0 : Ce.signal) != null && v(Ce.signal, "options.signal"), x(kt) && !T(kt))
39981
39986
  throw new c("stream", kt, "must be writable");
39982
- const he = w(this, kt);
39983
- return Ce != null && Ce.signal && S(Ce.signal, he), he;
39987
+ const de = w(this, kt);
39988
+ return Ce != null && Ce.signal && S(Ce.signal, de), de;
39984
39989
  }
39985
39990
  function ue(kt, Ce) {
39986
39991
  if (typeof kt != "function")
39987
39992
  throw new d("fn", ["Function", "AsyncFunction"], kt);
39988
39993
  Ce != null && y(Ce, "options"), (Ce == null ? void 0 : Ce.signal) != null && v(Ce.signal, "options.signal");
39989
- let he = 1;
39990
- return (Ce == null ? void 0 : Ce.concurrency) != null && (he = O(Ce.concurrency)), g(he, "concurrency", 1), (async function* () {
39991
- var Ne, Oe;
39994
+ let de = 1;
39995
+ return (Ce == null ? void 0 : Ce.concurrency) != null && (de = O(Ce.concurrency)), g(de, "concurrency", 1), (async function* () {
39996
+ var Ne, Ve;
39992
39997
  const Pt = new u(), jt = this, _n = [], oe = Pt.signal, le = {
39993
39998
  signal: oe
39994
39999
  }, j = () => Pt.abort();
39995
- Ce != null && (Ne = Ce.signal) !== null && Ne !== void 0 && Ne.aborted && j(), Ce == null || (Oe = Ce.signal) === null || Oe === void 0 || Oe.addEventListener("abort", j);
40000
+ Ce != null && (Ne = Ce.signal) !== null && Ne !== void 0 && Ne.aborted && j(), Ce == null || (Ve = Ce.signal) === null || Ve === void 0 || Ve.addEventListener("abort", j);
39996
40001
  let V, z, ae = !1;
39997
40002
  function xe() {
39998
40003
  ae = !0;
@@ -40010,7 +40015,7 @@ var mqtt = { exports: {} };
40010
40015
  } catch (Rn) {
40011
40016
  xn = $(Rn);
40012
40017
  }
40013
- xn !== re && (typeof ((bn = xn) === null || bn === void 0 ? void 0 : bn.catch) == "function" && xn.catch(xe), _n.push(xn), V && (V(), V = null), !ae && _n.length && _n.length >= he && await new ie((Rn) => {
40018
+ xn !== re && (typeof ((bn = xn) === null || bn === void 0 ? void 0 : bn.catch) == "function" && xn.catch(xe), _n.push(xn), V && (V(), V = null), !ae && _n.length && _n.length >= de && await new ie((Rn) => {
40014
40019
  z = Rn;
40015
40020
  }));
40016
40021
  }
@@ -40045,19 +40050,19 @@ var mqtt = { exports: {} };
40045
40050
  }
40046
40051
  function Ie(kt = void 0) {
40047
40052
  return kt != null && y(kt, "options"), (kt == null ? void 0 : kt.signal) != null && v(kt.signal, "options.signal"), (async function* () {
40048
- let he = 0;
40053
+ let de = 0;
40049
40054
  for await (const Ne of this) {
40050
40055
  var Ue;
40051
40056
  if (kt != null && (Ue = kt.signal) !== null && Ue !== void 0 && Ue.aborted)
40052
40057
  throw new _({
40053
40058
  cause: kt.signal.reason
40054
40059
  });
40055
- yield [he++, Ne];
40060
+ yield [de++, Ne];
40056
40061
  }
40057
40062
  }).call(this);
40058
40063
  }
40059
40064
  async function ze(kt, Ce = void 0) {
40060
- for await (const he of pe.call(this, kt, Ce))
40065
+ for await (const de of pe.call(this, kt, Ce))
40061
40066
  return !0;
40062
40067
  return !1;
40063
40068
  }
@@ -40066,62 +40071,62 @@ var mqtt = { exports: {} };
40066
40071
  throw new d("fn", ["Function", "AsyncFunction"], kt);
40067
40072
  return !await ze.call(
40068
40073
  this,
40069
- async (...he) => !await kt(...he),
40074
+ async (...de) => !await kt(...de),
40070
40075
  Ce
40071
40076
  );
40072
40077
  }
40073
- async function Ve(kt, Ce) {
40074
- for await (const he of pe.call(this, kt, Ce))
40075
- return he;
40078
+ async function Oe(kt, Ce) {
40079
+ for await (const de of pe.call(this, kt, Ce))
40080
+ return de;
40076
40081
  }
40077
40082
  async function Lt(kt, Ce) {
40078
40083
  if (typeof kt != "function")
40079
40084
  throw new d("fn", ["Function", "AsyncFunction"], kt);
40080
- async function he(Ue, Ne) {
40085
+ async function de(Ue, Ne) {
40081
40086
  return await kt(Ue, Ne), re;
40082
40087
  }
40083
- for await (const Ue of ue.call(this, he, Ce))
40088
+ for await (const Ue of ue.call(this, de, Ce))
40084
40089
  ;
40085
40090
  }
40086
40091
  function pe(kt, Ce) {
40087
40092
  if (typeof kt != "function")
40088
40093
  throw new d("fn", ["Function", "AsyncFunction"], kt);
40089
- async function he(Ue, Ne) {
40094
+ async function de(Ue, Ne) {
40090
40095
  return await kt(Ue, Ne) ? Ue : re;
40091
40096
  }
40092
- return ue.call(this, he, Ce);
40097
+ return ue.call(this, de, Ce);
40093
40098
  }
40094
40099
  class Cn extends f {
40095
40100
  constructor() {
40096
40101
  super("reduce"), this.message = "Reduce of an empty stream requires an initial value";
40097
40102
  }
40098
40103
  }
40099
- async function In(kt, Ce, he) {
40104
+ async function In(kt, Ce, de) {
40100
40105
  var Ue;
40101
40106
  if (typeof kt != "function")
40102
40107
  throw new d("reducer", ["Function", "AsyncFunction"], kt);
40103
- he != null && y(he, "options"), (he == null ? void 0 : he.signal) != null && v(he.signal, "options.signal");
40108
+ de != null && y(de, "options"), (de == null ? void 0 : de.signal) != null && v(de.signal, "options.signal");
40104
40109
  let Ne = arguments.length > 1;
40105
- if (he != null && (Ue = he.signal) !== null && Ue !== void 0 && Ue.aborted) {
40110
+ if (de != null && (Ue = de.signal) !== null && Ue !== void 0 && Ue.aborted) {
40106
40111
  const oe = new _(void 0, {
40107
- cause: he.signal.reason
40112
+ cause: de.signal.reason
40108
40113
  });
40109
40114
  throw this.once("error", () => {
40110
40115
  }), await A(this.destroy(oe)), oe;
40111
40116
  }
40112
- const Oe = new u(), Pt = Oe.signal;
40113
- if (he != null && he.signal) {
40117
+ const Ve = new u(), Pt = Ve.signal;
40118
+ if (de != null && de.signal) {
40114
40119
  const oe = {
40115
40120
  once: !0,
40116
40121
  [b]: this
40117
40122
  };
40118
- he.signal.addEventListener("abort", () => Oe.abort(), oe);
40123
+ de.signal.addEventListener("abort", () => Ve.abort(), oe);
40119
40124
  }
40120
40125
  let jt = !1;
40121
40126
  try {
40122
40127
  for await (const oe of this) {
40123
40128
  var _n;
40124
- if (jt = !0, he != null && (_n = he.signal) !== null && _n !== void 0 && _n.aborted)
40129
+ if (jt = !0, de != null && (_n = de.signal) !== null && _n !== void 0 && _n.aborted)
40125
40130
  throw new _();
40126
40131
  Ne ? Ce = await kt(Ce, oe, {
40127
40132
  signal: Pt
@@ -40130,7 +40135,7 @@ var mqtt = { exports: {} };
40130
40135
  if (!jt && !Ne)
40131
40136
  throw new Cn();
40132
40137
  } finally {
40133
- Oe.abort();
40138
+ Ve.abort();
40134
40139
  }
40135
40140
  return Ce;
40136
40141
  }
@@ -40138,8 +40143,8 @@ var mqtt = { exports: {} };
40138
40143
  kt != null && y(kt, "options"), (kt == null ? void 0 : kt.signal) != null && v(kt.signal, "options.signal");
40139
40144
  const Ce = [];
40140
40145
  for await (const Ue of this) {
40141
- var he;
40142
- if (kt != null && (he = kt.signal) !== null && he !== void 0 && he.aborted)
40146
+ var de;
40147
+ if (kt != null && (de = kt.signal) !== null && de !== void 0 && de.aborted)
40143
40148
  throw new _(void 0, {
40144
40149
  cause: kt.signal.reason
40145
40150
  });
@@ -40147,10 +40152,10 @@ var mqtt = { exports: {} };
40147
40152
  }
40148
40153
  return Ce;
40149
40154
  }
40150
- function de(kt, Ce) {
40151
- const he = ue.call(this, kt, Ce);
40155
+ function he(kt, Ce) {
40156
+ const de = ue.call(this, kt, Ce);
40152
40157
  return (async function* () {
40153
- for await (const Ne of he)
40158
+ for await (const Ne of de)
40154
40159
  yield* Ne;
40155
40160
  }).call(this);
40156
40161
  }
@@ -40166,11 +40171,11 @@ var mqtt = { exports: {} };
40166
40171
  var Ue;
40167
40172
  if (Ce != null && (Ue = Ce.signal) !== null && Ue !== void 0 && Ue.aborted)
40168
40173
  throw new _();
40169
- for await (const Oe of this) {
40174
+ for await (const Ve of this) {
40170
40175
  var Ne;
40171
40176
  if (Ce != null && (Ne = Ce.signal) !== null && Ne !== void 0 && Ne.aborted)
40172
40177
  throw new _();
40173
- kt-- <= 0 && (yield Oe);
40178
+ kt-- <= 0 && (yield Ve);
40174
40179
  }
40175
40180
  }).call(this);
40176
40181
  }
@@ -40179,12 +40184,12 @@ var mqtt = { exports: {} };
40179
40184
  var Ue;
40180
40185
  if (Ce != null && (Ue = Ce.signal) !== null && Ue !== void 0 && Ue.aborted)
40181
40186
  throw new _();
40182
- for await (const Oe of this) {
40187
+ for await (const Ve of this) {
40183
40188
  var Ne;
40184
40189
  if (Ce != null && (Ne = Ce.signal) !== null && Ne !== void 0 && Ne.aborted)
40185
40190
  throw new _();
40186
40191
  if (kt-- > 0)
40187
- yield Oe;
40192
+ yield Ve;
40188
40193
  else
40189
40194
  return;
40190
40195
  }
@@ -40194,7 +40199,7 @@ var mqtt = { exports: {} };
40194
40199
  asIndexedPairs: Ie,
40195
40200
  drop: hn,
40196
40201
  filter: pe,
40197
- flatMap: de,
40202
+ flatMap: he,
40198
40203
  map: ue,
40199
40204
  take: vn,
40200
40205
  compose: _e
@@ -40204,7 +40209,7 @@ var mqtt = { exports: {} };
40204
40209
  reduce: In,
40205
40210
  toArray: Dt,
40206
40211
  some: ze,
40207
- find: Ve
40212
+ find: Oe
40208
40213
  };
40209
40214
  }, { "../../ours/errors": 126, "../../ours/primordials": 127, "../validators": 124, "./add-abort-signal": 107, "./compose": 109, "./end-of-stream": 113, "./utils": 122, "abort-controller": 24 }], 117: [function(n, o, a) {
40210
40215
  const { ObjectSetPrototypeOf: u } = n("../../ours/primordials");
@@ -40252,13 +40257,13 @@ var mqtt = { exports: {} };
40252
40257
  readable: hn,
40253
40258
  writable: vn
40254
40259
  },
40255
- (he) => {
40256
- kt = !he;
40260
+ (de) => {
40261
+ kt = !de;
40257
40262
  }
40258
40263
  );
40259
40264
  return {
40260
- destroy: (he) => {
40261
- kt || (kt = !0, v.destroyer(Et, he || new S("pipe")));
40265
+ destroy: (de) => {
40266
+ kt || (kt = !0, v.destroyer(Et, de || new S("pipe")));
40262
40267
  },
40263
40268
  cleanup: Ce
40264
40269
  };
@@ -40266,7 +40271,7 @@ var mqtt = { exports: {} };
40266
40271
  function Fe(Et) {
40267
40272
  return L(Et[Et.length - 1], "streams[stream.length - 1]"), Et.pop();
40268
40273
  }
40269
- function Ve(Et) {
40274
+ function Oe(Et) {
40270
40275
  if (M(Et))
40271
40276
  return Et;
40272
40277
  if (ie(Et))
@@ -40277,19 +40282,19 @@ var mqtt = { exports: {} };
40277
40282
  Ie || (Ie = n("./readable")), yield* Ie.prototype[f].call(Et);
40278
40283
  }
40279
40284
  async function pe(Et, hn, vn, { end: kt }) {
40280
- let Ce, he = null;
40285
+ let Ce, de = null;
40281
40286
  const Ue = (Pt) => {
40282
- if (Pt && (Ce = Pt), he) {
40283
- const jt = he;
40284
- he = null, jt();
40287
+ if (Pt && (Ce = Pt), de) {
40288
+ const jt = de;
40289
+ de = null, jt();
40285
40290
  }
40286
40291
  }, Ne = () => new d((Pt, jt) => {
40287
- Ce ? jt(Ce) : he = () => {
40292
+ Ce ? jt(Ce) : de = () => {
40288
40293
  Ce ? jt(Ce) : Pt();
40289
40294
  };
40290
40295
  });
40291
40296
  hn.on("drain", Ue);
40292
- const Oe = p(
40297
+ const Ve = p(
40293
40298
  hn,
40294
40299
  {
40295
40300
  readable: !1
@@ -40304,20 +40309,20 @@ var mqtt = { exports: {} };
40304
40309
  } catch (Pt) {
40305
40310
  vn(Ce !== Pt ? y(Ce, Pt) : Pt);
40306
40311
  } finally {
40307
- Oe(), hn.off("drain", Ue);
40312
+ Ve(), hn.off("drain", Ue);
40308
40313
  }
40309
40314
  }
40310
40315
  async function Cn(Et, hn, vn, { end: kt }) {
40311
40316
  Y(hn) && (hn = hn.writable);
40312
40317
  const Ce = hn.getWriter();
40313
40318
  try {
40314
- for await (const he of Et)
40315
- await Ce.ready, Ce.write(he).catch(() => {
40319
+ for await (const de of Et)
40320
+ await Ce.ready, Ce.write(de).catch(() => {
40316
40321
  });
40317
40322
  await Ce.ready, kt && await Ce.close(), vn();
40318
- } catch (he) {
40323
+ } catch (de) {
40319
40324
  try {
40320
- await Ce.abort(he), vn(he);
40325
+ await Ce.abort(de), vn(de);
40321
40326
  } catch (Ue) {
40322
40327
  vn(Ue);
40323
40328
  }
@@ -40329,23 +40334,23 @@ var mqtt = { exports: {} };
40329
40334
  function Dt(Et, hn, vn) {
40330
40335
  if (Et.length === 1 && c(Et[0]) && (Et = Et[0]), Et.length < 2)
40331
40336
  throw new w("streams");
40332
- const kt = new _e(), Ce = kt.signal, he = vn == null ? void 0 : vn.signal, Ue = [];
40333
- O(he, "options.signal");
40337
+ const kt = new _e(), Ce = kt.signal, de = vn == null ? void 0 : vn.signal, Ue = [];
40338
+ O(de, "options.signal");
40334
40339
  function Ne() {
40335
40340
  le(new x());
40336
40341
  }
40337
- he == null || he.addEventListener("abort", Ne);
40338
- let Oe, Pt;
40342
+ de == null || de.addEventListener("abort", Ne);
40343
+ let Ve, Pt;
40339
40344
  const jt = [];
40340
40345
  let _n = 0;
40341
40346
  function oe(ae) {
40342
40347
  le(ae, --_n === 0);
40343
40348
  }
40344
40349
  function le(ae, xe) {
40345
- if (ae && (!Oe || Oe.code === "ERR_STREAM_PREMATURE_CLOSE") && (Oe = ae), !(!Oe && !xe)) {
40350
+ if (ae && (!Ve || Ve.code === "ERR_STREAM_PREMATURE_CLOSE") && (Ve = ae), !(!Ve && !xe)) {
40346
40351
  for (; jt.length; )
40347
- jt.shift()(Oe);
40348
- he == null || he.removeEventListener("abort", Ne), kt.abort(), xe && (Oe || Ue.forEach((qe) => qe()), u.nextTick(hn, Oe, Pt));
40352
+ jt.shift()(Ve);
40353
+ de == null || de.removeEventListener("abort", Ne), kt.abort(), xe && (Ve || Ue.forEach((qe) => qe()), u.nextTick(hn, Ve, Pt));
40349
40354
  }
40350
40355
  }
40351
40356
  let j;
@@ -40374,9 +40379,9 @@ var mqtt = { exports: {} };
40374
40379
  else if (typeof xe == "function") {
40375
40380
  if (Y(j)) {
40376
40381
  var V;
40377
- j = Ve((V = j) === null || V === void 0 ? void 0 : V.readable);
40382
+ j = Oe((V = j) === null || V === void 0 ? void 0 : V.readable);
40378
40383
  } else
40379
- j = Ve(j);
40384
+ j = Oe(j);
40380
40385
  if (j = xe(j, {
40381
40386
  signal: Ce
40382
40387
  }), qe) {
@@ -40416,7 +40421,7 @@ var mqtt = { exports: {} };
40416
40421
  } else if ($(xe)) {
40417
40422
  if (ie(j)) {
40418
40423
  _n += 2;
40419
- const Rn = de(j, xe, oe, {
40424
+ const Rn = he(j, xe, oe, {
40420
40425
  end: Sn
40421
40426
  });
40422
40427
  k(xe) && xn && Ue.push(Rn);
@@ -40438,7 +40443,7 @@ var mqtt = { exports: {} };
40438
40443
  j = xe;
40439
40444
  } else if (D(xe)) {
40440
40445
  if (ie(j))
40441
- _n++, Cn(Ve(j), xe, oe, {
40446
+ _n++, Cn(Oe(j), xe, oe, {
40442
40447
  end: Sn
40443
40448
  });
40444
40449
  else if (re(j) || M(j))
@@ -40459,19 +40464,19 @@ var mqtt = { exports: {} };
40459
40464
  } else
40460
40465
  j = g.from(xe);
40461
40466
  }
40462
- return (Ce != null && Ce.aborted || he != null && he.aborted) && u.nextTick(Ne), j;
40467
+ return (Ce != null && Ce.aborted || de != null && de.aborted) && u.nextTick(Ne), j;
40463
40468
  }
40464
- function de(Et, hn, vn, { end: kt }) {
40469
+ function he(Et, hn, vn, { end: kt }) {
40465
40470
  let Ce = !1;
40466
40471
  if (hn.on("close", () => {
40467
40472
  Ce || vn(new T());
40468
40473
  }), Et.pipe(hn, {
40469
40474
  end: !1
40470
40475
  }), kt) {
40471
- let he = function() {
40476
+ let de = function() {
40472
40477
  Ce = !0, hn.end();
40473
40478
  };
40474
- F(Et) ? u.nextTick(he) : Et.once("end", he);
40479
+ F(Et) ? u.nextTick(de) : Et.once("end", de);
40475
40480
  } else
40476
40481
  vn();
40477
40482
  return p(
@@ -40480,9 +40485,9 @@ var mqtt = { exports: {} };
40480
40485
  readable: !0,
40481
40486
  writable: !1
40482
40487
  },
40483
- (he) => {
40488
+ (de) => {
40484
40489
  const Ue = Et._readableState;
40485
- he && he.code === "ERR_STREAM_PREMATURE_CLOSE" && Ue && Ue.ended && !Ue.errored && !Ue.errorEmitted ? Et.once("end", vn).once("error", vn) : vn(he);
40490
+ de && de.code === "ERR_STREAM_PREMATURE_CLOSE" && Ue && Ue.ended && !Ue.errored && !Ue.errorEmitted ? Et.once("end", vn).once("error", vn) : vn(de);
40486
40491
  }
40487
40492
  ), p(
40488
40493
  hn,
@@ -40511,7 +40516,7 @@ var mqtt = { exports: {} };
40511
40516
  SymbolAsyncIterator: A,
40512
40517
  Symbol: w
40513
40518
  } = n("../../ours/primordials");
40514
- o.exports = de, de.ReadableState = Dt;
40519
+ o.exports = he, he.ReadableState = Dt;
40515
40520
  const { EventEmitter: S } = n("events"), { Stream: T, prependListener: x } = n("./legacy"), { Buffer: L } = n("buffer"), { addAbortSignal: O } = n("./add-abort-signal"), M = n("./end-of-stream");
40516
40521
  let k = n("../../ours/util").debuglog("stream", ($e) => {
40517
40522
  k = $e;
@@ -40525,28 +40530,28 @@ var mqtt = { exports: {} };
40525
40530
  ERR_STREAM_PUSH_AFTER_EOF: Ie,
40526
40531
  ERR_STREAM_UNSHIFT_AFTER_END_EVENT: ze
40527
40532
  }
40528
- } = n("../../ours/errors"), { validateObject: Fe } = n("../validators"), Ve = w("kPaused"), { StringDecoder: Lt } = n("string_decoder"), pe = n("./from");
40529
- g(de.prototype, T.prototype), g(de, T);
40533
+ } = n("../../ours/errors"), { validateObject: Fe } = n("../validators"), Oe = w("kPaused"), { StringDecoder: Lt } = n("string_decoder"), pe = n("./from");
40534
+ g(he.prototype, T.prototype), g(he, T);
40530
40535
  const Cn = () => {
40531
40536
  }, { errorOrDestroy: In } = $;
40532
40537
  function Dt($e, At, En) {
40533
- typeof En != "boolean" && (En = At instanceof n("./duplex")), this.objectMode = !!($e && $e.objectMode), En && (this.objectMode = this.objectMode || !!($e && $e.readableObjectMode)), this.highWaterMark = $e ? Y(this, $e, "readableHighWaterMark", En) : D(!1), this.buffer = new ie(), this.length = 0, this.pipes = [], this.flowing = null, this.ended = !1, this.endEmitted = !1, this.reading = !1, this.constructed = !0, this.sync = !0, this.needReadable = !1, this.emittedReadable = !1, this.readableListening = !1, this.resumeScheduled = !1, this[Ve] = null, this.errorEmitted = !1, this.emitClose = !$e || $e.emitClose !== !1, this.autoDestroy = !$e || $e.autoDestroy !== !1, this.destroyed = !1, this.errored = null, this.closed = !1, this.closeEmitted = !1, this.defaultEncoding = $e && $e.defaultEncoding || "utf8", this.awaitDrainWriters = null, this.multiAwaitDrain = !1, this.readingMore = !1, this.dataEmitted = !1, this.decoder = null, this.encoding = null, $e && $e.encoding && (this.decoder = new Lt($e.encoding), this.encoding = $e.encoding);
40538
+ typeof En != "boolean" && (En = At instanceof n("./duplex")), this.objectMode = !!($e && $e.objectMode), En && (this.objectMode = this.objectMode || !!($e && $e.readableObjectMode)), this.highWaterMark = $e ? Y(this, $e, "readableHighWaterMark", En) : D(!1), this.buffer = new ie(), this.length = 0, this.pipes = [], this.flowing = null, this.ended = !1, this.endEmitted = !1, this.reading = !1, this.constructed = !0, this.sync = !0, this.needReadable = !1, this.emittedReadable = !1, this.readableListening = !1, this.resumeScheduled = !1, this[Oe] = null, this.errorEmitted = !1, this.emitClose = !$e || $e.emitClose !== !1, this.autoDestroy = !$e || $e.autoDestroy !== !1, this.destroyed = !1, this.errored = null, this.closed = !1, this.closeEmitted = !1, this.defaultEncoding = $e && $e.defaultEncoding || "utf8", this.awaitDrainWriters = null, this.multiAwaitDrain = !1, this.readingMore = !1, this.dataEmitted = !1, this.decoder = null, this.encoding = null, $e && $e.encoding && (this.decoder = new Lt($e.encoding), this.encoding = $e.encoding);
40534
40539
  }
40535
- function de($e) {
40536
- if (!(this instanceof de))
40537
- return new de($e);
40540
+ function he($e) {
40541
+ if (!(this instanceof he))
40542
+ return new he($e);
40538
40543
  const At = this instanceof n("./duplex");
40539
40544
  this._readableState = new Dt($e, this, At), $e && (typeof $e.read == "function" && (this._read = $e.read), typeof $e.destroy == "function" && (this._destroy = $e.destroy), typeof $e.construct == "function" && (this._construct = $e.construct), $e.signal && !At && O($e.signal, this)), T.call(this, $e), $.construct(this, () => {
40540
- this._readableState.needReadable && Oe(this, this._readableState);
40545
+ this._readableState.needReadable && Ve(this, this._readableState);
40541
40546
  });
40542
40547
  }
40543
- de.prototype.destroy = $.destroy, de.prototype._undestroy = $.undestroy, de.prototype._destroy = function($e, At) {
40548
+ he.prototype.destroy = $.destroy, he.prototype._undestroy = $.undestroy, he.prototype._destroy = function($e, At) {
40544
40549
  At($e);
40545
- }, de.prototype[S.captureRejectionSymbol] = function($e) {
40550
+ }, he.prototype[S.captureRejectionSymbol] = function($e) {
40546
40551
  this.destroy($e);
40547
- }, de.prototype.push = function($e, At) {
40552
+ }, he.prototype.push = function($e, At) {
40548
40553
  return Et(this, $e, At, !1);
40549
- }, de.prototype.unshift = function($e, At) {
40554
+ }, he.prototype.unshift = function($e, At) {
40550
40555
  return Et(this, $e, At, !0);
40551
40556
  };
40552
40557
  function Et($e, At, En, wn) {
@@ -40556,7 +40561,7 @@ var mqtt = { exports: {} };
40556
40561
  if (Ln.objectMode || (typeof At == "string" ? (En = En || Ln.defaultEncoding, Ln.encoding !== En && (wn && Ln.encoding ? At = L.from(At, En).toString(Ln.encoding) : (At = L.from(At, En), En = ""))) : At instanceof L ? En = "" : T._isUint8Array(At) ? (At = T._uint8ArrayToBuffer(At), En = "") : At != null && (Mn = new F("chunk", ["string", "Buffer", "Uint8Array"], At))), Mn)
40557
40562
  In($e, Mn);
40558
40563
  else if (At === null)
40559
- Ln.reading = !1, he($e, Ln);
40564
+ Ln.reading = !1, de($e, Ln);
40560
40565
  else if (Ln.objectMode || At && At.length > 0)
40561
40566
  if (wn)
40562
40567
  if (Ln.endEmitted)
@@ -40571,19 +40576,19 @@ var mqtt = { exports: {} };
40571
40576
  else {
40572
40577
  if (Ln.destroyed || Ln.errored)
40573
40578
  return !1;
40574
- Ln.reading = !1, Ln.decoder && !En ? (At = Ln.decoder.write(At), Ln.objectMode || At.length !== 0 ? hn($e, Ln, At, !1) : Oe($e, Ln)) : hn($e, Ln, At, !1);
40579
+ Ln.reading = !1, Ln.decoder && !En ? (At = Ln.decoder.write(At), Ln.objectMode || At.length !== 0 ? hn($e, Ln, At, !1) : Ve($e, Ln)) : hn($e, Ln, At, !1);
40575
40580
  }
40576
40581
  else
40577
- wn || (Ln.reading = !1, Oe($e, Ln));
40582
+ wn || (Ln.reading = !1, Ve($e, Ln));
40578
40583
  return !Ln.ended && (Ln.length < Ln.highWaterMark || Ln.length === 0);
40579
40584
  }
40580
40585
  function hn($e, At, En, wn) {
40581
- At.flowing && At.length === 0 && !At.sync && $e.listenerCount("data") > 0 ? (At.multiAwaitDrain ? At.awaitDrainWriters.clear() : At.awaitDrainWriters = null, At.dataEmitted = !0, $e.emit("data", En)) : (At.length += At.objectMode ? 1 : En.length, wn ? At.buffer.unshift(En) : At.buffer.push(En), At.needReadable && Ue($e)), Oe($e, At);
40586
+ At.flowing && At.length === 0 && !At.sync && $e.listenerCount("data") > 0 ? (At.multiAwaitDrain ? At.awaitDrainWriters.clear() : At.awaitDrainWriters = null, At.dataEmitted = !0, $e.emit("data", En)) : (At.length += At.objectMode ? 1 : En.length, wn ? At.buffer.unshift(En) : At.buffer.push(En), At.needReadable && Ue($e)), Ve($e, At);
40582
40587
  }
40583
- de.prototype.isPaused = function() {
40588
+ he.prototype.isPaused = function() {
40584
40589
  const $e = this._readableState;
40585
- return $e[Ve] === !0 || $e.flowing === !1;
40586
- }, de.prototype.setEncoding = function($e) {
40590
+ return $e[Oe] === !0 || $e.flowing === !1;
40591
+ }, he.prototype.setEncoding = function($e) {
40587
40592
  const At = new Lt($e);
40588
40593
  this._readableState.decoder = At, this._readableState.encoding = this._readableState.decoder.encoding;
40589
40594
  const En = this._readableState.buffer;
@@ -40601,7 +40606,7 @@ var mqtt = { exports: {} };
40601
40606
  function Ce($e, At) {
40602
40607
  return $e <= 0 || At.length === 0 && At.ended ? 0 : At.objectMode ? 1 : f($e) ? At.flowing && At.length ? At.buffer.first().length : At.length : $e <= At.length ? $e : At.ended ? At.length : 0;
40603
40608
  }
40604
- de.prototype.read = function($e) {
40609
+ he.prototype.read = function($e) {
40605
40610
  k("read", $e), $e === void 0 ? $e = NaN : d($e) || ($e = p($e, 10));
40606
40611
  const At = this._readableState, En = $e;
40607
40612
  if ($e > At.highWaterMark && (At.highWaterMark = kt($e)), $e !== 0 && (At.emittedReadable = !1), $e === 0 && At.needReadable && ((At.highWaterMark !== 0 ? At.length >= At.highWaterMark : At.length > 0) || At.ended))
@@ -40623,7 +40628,7 @@ var mqtt = { exports: {} };
40623
40628
  let Ln;
40624
40629
  return $e > 0 ? Ln = xe($e, At) : Ln = null, Ln === null ? (At.needReadable = At.length <= At.highWaterMark, $e = 0) : (At.length -= $e, At.multiAwaitDrain ? At.awaitDrainWriters.clear() : At.awaitDrainWriters = null), At.length === 0 && (At.ended || (At.needReadable = !0), En !== $e && At.ended && qe(this)), Ln !== null && !At.errorEmitted && !At.closeEmitted && (At.dataEmitted = !0, this.emit("data", Ln)), Ln;
40625
40630
  };
40626
- function he($e, At) {
40631
+ function de($e, At) {
40627
40632
  if (k("onEofChunk"), !At.ended) {
40628
40633
  if (At.decoder) {
40629
40634
  const En = At.decoder.end();
@@ -40640,7 +40645,7 @@ var mqtt = { exports: {} };
40640
40645
  const At = $e._readableState;
40641
40646
  k("emitReadable_", At.destroyed, At.length, At.ended), !At.destroyed && !At.errored && (At.length || At.ended) && ($e.emit("readable"), At.emittedReadable = !1), At.needReadable = !At.flowing && !At.ended && At.length <= At.highWaterMark, V($e);
40642
40647
  }
40643
- function Oe($e, At) {
40648
+ function Ve($e, At) {
40644
40649
  !At.readingMore && At.constructed && (At.readingMore = !0, u.nextTick(Pt, $e, At));
40645
40650
  }
40646
40651
  function Pt($e, At) {
@@ -40651,9 +40656,9 @@ var mqtt = { exports: {} };
40651
40656
  }
40652
40657
  At.readingMore = !1;
40653
40658
  }
40654
- de.prototype._read = function($e) {
40659
+ he.prototype._read = function($e) {
40655
40660
  throw new _e("_read()");
40656
- }, de.prototype.pipe = function($e, At) {
40661
+ }, he.prototype.pipe = function($e, At) {
40657
40662
  const En = this, wn = this._readableState;
40658
40663
  wn.pipes.length === 1 && (wn.multiAwaitDrain || (wn.multiAwaitDrain = !0, wn.awaitDrainWriters = new b(wn.awaitDrainWriters ? [wn.awaitDrainWriters] : []))), wn.pipes.push($e), k("pipe count=%d opts=%j", wn.pipes.length, At);
40659
40664
  const Mn = (!At || At.end !== !1) && $e !== u.stdout && $e !== u.stderr ? $n : Wn;
@@ -40703,7 +40708,7 @@ var mqtt = { exports: {} };
40703
40708
  wn.awaitDrainWriters === At ? (k("pipeOnDrain", 1), wn.awaitDrainWriters = null) : wn.multiAwaitDrain && (k("pipeOnDrain", wn.awaitDrainWriters.size), wn.awaitDrainWriters.delete(At)), (!wn.awaitDrainWriters || wn.awaitDrainWriters.size === 0) && $e.listenerCount("data") && $e.resume();
40704
40709
  };
40705
40710
  }
40706
- de.prototype.unpipe = function($e) {
40711
+ he.prototype.unpipe = function($e) {
40707
40712
  const At = this._readableState, En = {
40708
40713
  hasUnpiped: !1
40709
40714
  };
@@ -40720,26 +40725,26 @@ var mqtt = { exports: {} };
40720
40725
  }
40721
40726
  const wn = c(At.pipes, $e);
40722
40727
  return wn === -1 ? this : (At.pipes.splice(wn, 1), At.pipes.length === 0 && this.pause(), $e.emit("unpipe", this, En), this);
40723
- }, de.prototype.on = function($e, At) {
40728
+ }, he.prototype.on = function($e, At) {
40724
40729
  const En = T.prototype.on.call(this, $e, At), wn = this._readableState;
40725
40730
  return $e === "data" ? (wn.readableListening = this.listenerCount("readable") > 0, wn.flowing !== !1 && this.resume()) : $e === "readable" && !wn.endEmitted && !wn.readableListening && (wn.readableListening = wn.needReadable = !0, wn.flowing = !1, wn.emittedReadable = !1, k("on readable", wn.length, wn.reading), wn.length ? Ue(this) : wn.reading || u.nextTick(oe, this)), En;
40726
- }, de.prototype.addListener = de.prototype.on, de.prototype.removeListener = function($e, At) {
40731
+ }, he.prototype.addListener = he.prototype.on, he.prototype.removeListener = function($e, At) {
40727
40732
  const En = T.prototype.removeListener.call(this, $e, At);
40728
40733
  return $e === "readable" && u.nextTick(_n, this), En;
40729
- }, de.prototype.off = de.prototype.removeListener, de.prototype.removeAllListeners = function($e) {
40734
+ }, he.prototype.off = he.prototype.removeListener, he.prototype.removeAllListeners = function($e) {
40730
40735
  const At = T.prototype.removeAllListeners.apply(this, arguments);
40731
40736
  return ($e === "readable" || $e === void 0) && u.nextTick(_n, this), At;
40732
40737
  };
40733
40738
  function _n($e) {
40734
40739
  const At = $e._readableState;
40735
- At.readableListening = $e.listenerCount("readable") > 0, At.resumeScheduled && At[Ve] === !1 ? At.flowing = !0 : $e.listenerCount("data") > 0 ? $e.resume() : At.readableListening || (At.flowing = null);
40740
+ At.readableListening = $e.listenerCount("readable") > 0, At.resumeScheduled && At[Oe] === !1 ? At.flowing = !0 : $e.listenerCount("data") > 0 ? $e.resume() : At.readableListening || (At.flowing = null);
40736
40741
  }
40737
40742
  function oe($e) {
40738
40743
  k("readable nexttick read 0"), $e.read(0);
40739
40744
  }
40740
- de.prototype.resume = function() {
40745
+ he.prototype.resume = function() {
40741
40746
  const $e = this._readableState;
40742
- return $e.flowing || (k("resume"), $e.flowing = !$e.readableListening, le(this, $e)), $e[Ve] = !1, this;
40747
+ return $e.flowing || (k("resume"), $e.flowing = !$e.readableListening, le(this, $e)), $e[Oe] = !1, this;
40743
40748
  };
40744
40749
  function le($e, At) {
40745
40750
  At.resumeScheduled || (At.resumeScheduled = !0, u.nextTick(j, $e, At));
@@ -40747,15 +40752,15 @@ var mqtt = { exports: {} };
40747
40752
  function j($e, At) {
40748
40753
  k("resume", At.reading), At.reading || $e.read(0), At.resumeScheduled = !1, $e.emit("resume"), V($e), At.flowing && !At.reading && $e.read(0);
40749
40754
  }
40750
- de.prototype.pause = function() {
40751
- return k("call pause flowing=%j", this._readableState.flowing), this._readableState.flowing !== !1 && (k("pause"), this._readableState.flowing = !1, this.emit("pause")), this._readableState[Ve] = !0, this;
40755
+ he.prototype.pause = function() {
40756
+ return k("call pause flowing=%j", this._readableState.flowing), this._readableState.flowing !== !1 && (k("pause"), this._readableState.flowing = !1, this.emit("pause")), this._readableState[Oe] = !0, this;
40752
40757
  };
40753
40758
  function V($e) {
40754
40759
  const At = $e._readableState;
40755
40760
  for (k("flow", At.flowing); At.flowing && $e.read() !== null; )
40756
40761
  ;
40757
40762
  }
40758
- de.prototype.wrap = function($e) {
40763
+ he.prototype.wrap = function($e) {
40759
40764
  let At = !1;
40760
40765
  $e.on("data", (wn) => {
40761
40766
  !this.push(wn) && $e.pause && (At = !0, $e.pause());
@@ -40776,13 +40781,13 @@ var mqtt = { exports: {} };
40776
40781
  this[Ln] === void 0 && typeof $e[Ln] == "function" && (this[Ln] = $e[Ln].bind($e));
40777
40782
  }
40778
40783
  return this;
40779
- }, de.prototype[A] = function() {
40784
+ }, he.prototype[A] = function() {
40780
40785
  return z(this);
40781
- }, de.prototype.iterator = function($e) {
40786
+ }, he.prototype.iterator = function($e) {
40782
40787
  return $e !== void 0 && Fe($e, "options"), z(this, $e);
40783
40788
  };
40784
40789
  function z($e, At) {
40785
- typeof $e.read != "function" && ($e = de.wrap($e, {
40790
+ typeof $e.read != "function" && ($e = he.wrap($e, {
40786
40791
  objectMode: !0
40787
40792
  }));
40788
40793
  const En = ae($e, At);
@@ -40823,7 +40828,7 @@ var mqtt = { exports: {} };
40823
40828
  (Ln || (At == null ? void 0 : At.destroyOnReturn) !== !1) && (Ln === void 0 || $e._readableState.autoDestroy) ? $.destroyer($e, null) : ($e.off("readable", wn), Mn());
40824
40829
  }
40825
40830
  }
40826
- _(de.prototype, {
40831
+ _(he.prototype, {
40827
40832
  readable: {
40828
40833
  __proto__: null,
40829
40834
  get() {
@@ -40935,13 +40940,13 @@ var mqtt = { exports: {} };
40935
40940
  paused: {
40936
40941
  __proto__: null,
40937
40942
  get() {
40938
- return this[Ve] !== !1;
40943
+ return this[Oe] !== !1;
40939
40944
  },
40940
40945
  set($e) {
40941
- this[Ve] = !!$e;
40946
+ this[Oe] = !!$e;
40942
40947
  }
40943
40948
  }
40944
- }), de._fromList = xe;
40949
+ }), he._fromList = xe;
40945
40950
  function xe($e, At) {
40946
40951
  if (At.length === 0)
40947
40952
  return null;
@@ -40967,20 +40972,20 @@ var mqtt = { exports: {} };
40967
40972
  function Sn($e) {
40968
40973
  $e.writable && !$e.writableEnded && !$e.destroyed && $e.end();
40969
40974
  }
40970
- de.from = function($e, At) {
40971
- return pe(de, $e, At);
40975
+ he.from = function($e, At) {
40976
+ return pe(he, $e, At);
40972
40977
  };
40973
40978
  let xn;
40974
40979
  function Rn() {
40975
40980
  return xn === void 0 && (xn = {}), xn;
40976
40981
  }
40977
- de.fromWeb = function($e, At) {
40982
+ he.fromWeb = function($e, At) {
40978
40983
  return Rn().newStreamReadableFromReadableStream($e, At);
40979
- }, de.toWeb = function($e, At) {
40984
+ }, he.toWeb = function($e, At) {
40980
40985
  return Rn().newReadableStreamFromStreamReadable($e, At);
40981
- }, de.wrap = function($e, At) {
40986
+ }, he.wrap = function($e, At) {
40982
40987
  var En, wn;
40983
- return new de({
40988
+ return new he({
40984
40989
  objectMode: (En = (wn = $e.readableObjectMode) !== null && wn !== void 0 ? wn : $e.objectMode) !== null && En !== void 0 ? En : !0,
40985
40990
  ...At,
40986
40991
  destroy(Ln, Mn) {
@@ -41065,120 +41070,120 @@ var mqtt = { exports: {} };
41065
41070
  };
41066
41071
  }, { "../../ours/errors": 126, "../../ours/primordials": 127, "./duplex": 111, "./state": 120 }], 122: [function(n, o, a) {
41067
41072
  const { Symbol: u, SymbolAsyncIterator: c, SymbolIterator: d, SymbolFor: f } = n("../../ours/primordials"), p = u("kDestroyed"), _ = u("kIsErrored"), v = u("kIsReadable"), g = u("kIsDisturbed"), y = f("nodejs.webstream.isClosedPromise"), b = f("nodejs.webstream.controllerErrorFunction");
41068
- function A(de, Et = !1) {
41073
+ function A(he, Et = !1) {
41069
41074
  var hn;
41070
- return !!(de && typeof de.pipe == "function" && typeof de.on == "function" && (!Et || typeof de.pause == "function" && typeof de.resume == "function") && (!de._writableState || ((hn = de._readableState) === null || hn === void 0 ? void 0 : hn.readable) !== !1) && // Duplex
41071
- (!de._writableState || de._readableState));
41075
+ return !!(he && typeof he.pipe == "function" && typeof he.on == "function" && (!Et || typeof he.pause == "function" && typeof he.resume == "function") && (!he._writableState || ((hn = he._readableState) === null || hn === void 0 ? void 0 : hn.readable) !== !1) && // Duplex
41076
+ (!he._writableState || he._readableState));
41072
41077
  }
41073
- function w(de) {
41078
+ function w(he) {
41074
41079
  var Et;
41075
- return !!(de && typeof de.write == "function" && typeof de.on == "function" && (!de._readableState || ((Et = de._writableState) === null || Et === void 0 ? void 0 : Et.writable) !== !1));
41080
+ return !!(he && typeof he.write == "function" && typeof he.on == "function" && (!he._readableState || ((Et = he._writableState) === null || Et === void 0 ? void 0 : Et.writable) !== !1));
41076
41081
  }
41077
- function S(de) {
41078
- return !!(de && typeof de.pipe == "function" && de._readableState && typeof de.on == "function" && typeof de.write == "function");
41082
+ function S(he) {
41083
+ return !!(he && typeof he.pipe == "function" && he._readableState && typeof he.on == "function" && typeof he.write == "function");
41079
41084
  }
41080
- function T(de) {
41081
- return de && (de._readableState || de._writableState || typeof de.write == "function" && typeof de.on == "function" || typeof de.pipe == "function" && typeof de.on == "function");
41085
+ function T(he) {
41086
+ return he && (he._readableState || he._writableState || typeof he.write == "function" && typeof he.on == "function" || typeof he.pipe == "function" && typeof he.on == "function");
41082
41087
  }
41083
- function x(de) {
41084
- return !!(de && !T(de) && typeof de.pipeThrough == "function" && typeof de.getReader == "function" && typeof de.cancel == "function");
41088
+ function x(he) {
41089
+ return !!(he && !T(he) && typeof he.pipeThrough == "function" && typeof he.getReader == "function" && typeof he.cancel == "function");
41085
41090
  }
41086
- function L(de) {
41087
- return !!(de && !T(de) && typeof de.getWriter == "function" && typeof de.abort == "function");
41091
+ function L(he) {
41092
+ return !!(he && !T(he) && typeof he.getWriter == "function" && typeof he.abort == "function");
41088
41093
  }
41089
- function O(de) {
41090
- return !!(de && !T(de) && typeof de.readable == "object" && typeof de.writable == "object");
41094
+ function O(he) {
41095
+ return !!(he && !T(he) && typeof he.readable == "object" && typeof he.writable == "object");
41091
41096
  }
41092
- function M(de) {
41093
- return x(de) || L(de) || O(de);
41097
+ function M(he) {
41098
+ return x(he) || L(he) || O(he);
41094
41099
  }
41095
- function k(de, Et) {
41096
- return de == null ? !1 : Et === !0 ? typeof de[c] == "function" : Et === !1 ? typeof de[d] == "function" : typeof de[c] == "function" || typeof de[d] == "function";
41100
+ function k(he, Et) {
41101
+ return he == null ? !1 : Et === !0 ? typeof he[c] == "function" : Et === !1 ? typeof he[d] == "function" : typeof he[c] == "function" || typeof he[d] == "function";
41097
41102
  }
41098
- function ie(de) {
41099
- if (!T(de))
41103
+ function ie(he) {
41104
+ if (!T(he))
41100
41105
  return null;
41101
- const Et = de._writableState, hn = de._readableState, vn = Et || hn;
41102
- return !!(de.destroyed || de[p] || vn != null && vn.destroyed);
41106
+ const Et = he._writableState, hn = he._readableState, vn = Et || hn;
41107
+ return !!(he.destroyed || he[p] || vn != null && vn.destroyed);
41103
41108
  }
41104
- function $(de) {
41105
- if (!w(de))
41109
+ function $(he) {
41110
+ if (!w(he))
41106
41111
  return null;
41107
- if (de.writableEnded === !0)
41112
+ if (he.writableEnded === !0)
41108
41113
  return !0;
41109
- const Et = de._writableState;
41114
+ const Et = he._writableState;
41110
41115
  return Et != null && Et.errored ? !1 : typeof (Et == null ? void 0 : Et.ended) != "boolean" ? null : Et.ended;
41111
41116
  }
41112
- function Y(de, Et) {
41113
- if (!w(de))
41117
+ function Y(he, Et) {
41118
+ if (!w(he))
41114
41119
  return null;
41115
- if (de.writableFinished === !0)
41120
+ if (he.writableFinished === !0)
41116
41121
  return !0;
41117
- const hn = de._writableState;
41122
+ const hn = he._writableState;
41118
41123
  return hn != null && hn.errored ? !1 : typeof (hn == null ? void 0 : hn.finished) != "boolean" ? null : !!(hn.finished || Et === !1 && hn.ended === !0 && hn.length === 0);
41119
41124
  }
41120
- function D(de) {
41121
- if (!A(de))
41125
+ function D(he) {
41126
+ if (!A(he))
41122
41127
  return null;
41123
- if (de.readableEnded === !0)
41128
+ if (he.readableEnded === !0)
41124
41129
  return !0;
41125
- const Et = de._readableState;
41130
+ const Et = he._readableState;
41126
41131
  return !Et || Et.errored ? !1 : typeof (Et == null ? void 0 : Et.ended) != "boolean" ? null : Et.ended;
41127
41132
  }
41128
- function re(de, Et) {
41129
- if (!A(de))
41133
+ function re(he, Et) {
41134
+ if (!A(he))
41130
41135
  return null;
41131
- const hn = de._readableState;
41136
+ const hn = he._readableState;
41132
41137
  return hn != null && hn.errored ? !1 : typeof (hn == null ? void 0 : hn.endEmitted) != "boolean" ? null : !!(hn.endEmitted || Et === !1 && hn.ended === !0 && hn.length === 0);
41133
41138
  }
41134
- function F(de) {
41135
- return de && de[v] != null ? de[v] : typeof (de == null ? void 0 : de.readable) != "boolean" ? null : ie(de) ? !1 : A(de) && de.readable && !re(de);
41139
+ function F(he) {
41140
+ return he && he[v] != null ? he[v] : typeof (he == null ? void 0 : he.readable) != "boolean" ? null : ie(he) ? !1 : A(he) && he.readable && !re(he);
41136
41141
  }
41137
- function _e(de) {
41138
- return typeof (de == null ? void 0 : de.writable) != "boolean" ? null : ie(de) ? !1 : w(de) && de.writable && !$(de);
41142
+ function _e(he) {
41143
+ return typeof (he == null ? void 0 : he.writable) != "boolean" ? null : ie(he) ? !1 : w(he) && he.writable && !$(he);
41139
41144
  }
41140
- function ue(de, Et) {
41141
- return T(de) ? ie(de) ? !0 : !((Et == null ? void 0 : Et.readable) !== !1 && F(de) || (Et == null ? void 0 : Et.writable) !== !1 && _e(de)) : null;
41145
+ function ue(he, Et) {
41146
+ return T(he) ? ie(he) ? !0 : !((Et == null ? void 0 : Et.readable) !== !1 && F(he) || (Et == null ? void 0 : Et.writable) !== !1 && _e(he)) : null;
41142
41147
  }
41143
- function Ie(de) {
41148
+ function Ie(he) {
41144
41149
  var Et, hn;
41145
- return T(de) ? de.writableErrored ? de.writableErrored : (Et = (hn = de._writableState) === null || hn === void 0 ? void 0 : hn.errored) !== null && Et !== void 0 ? Et : null : null;
41150
+ return T(he) ? he.writableErrored ? he.writableErrored : (Et = (hn = he._writableState) === null || hn === void 0 ? void 0 : hn.errored) !== null && Et !== void 0 ? Et : null : null;
41146
41151
  }
41147
- function ze(de) {
41152
+ function ze(he) {
41148
41153
  var Et, hn;
41149
- return T(de) ? de.readableErrored ? de.readableErrored : (Et = (hn = de._readableState) === null || hn === void 0 ? void 0 : hn.errored) !== null && Et !== void 0 ? Et : null : null;
41154
+ return T(he) ? he.readableErrored ? he.readableErrored : (Et = (hn = he._readableState) === null || hn === void 0 ? void 0 : hn.errored) !== null && Et !== void 0 ? Et : null : null;
41150
41155
  }
41151
- function Fe(de) {
41152
- if (!T(de))
41156
+ function Fe(he) {
41157
+ if (!T(he))
41153
41158
  return null;
41154
- if (typeof de.closed == "boolean")
41155
- return de.closed;
41156
- const Et = de._writableState, hn = de._readableState;
41157
- return typeof (Et == null ? void 0 : Et.closed) == "boolean" || typeof (hn == null ? void 0 : hn.closed) == "boolean" ? (Et == null ? void 0 : Et.closed) || (hn == null ? void 0 : hn.closed) : typeof de._closed == "boolean" && Ve(de) ? de._closed : null;
41159
+ if (typeof he.closed == "boolean")
41160
+ return he.closed;
41161
+ const Et = he._writableState, hn = he._readableState;
41162
+ return typeof (Et == null ? void 0 : Et.closed) == "boolean" || typeof (hn == null ? void 0 : hn.closed) == "boolean" ? (Et == null ? void 0 : Et.closed) || (hn == null ? void 0 : hn.closed) : typeof he._closed == "boolean" && Oe(he) ? he._closed : null;
41158
41163
  }
41159
- function Ve(de) {
41160
- return typeof de._closed == "boolean" && typeof de._defaultKeepAlive == "boolean" && typeof de._removedConnection == "boolean" && typeof de._removedContLen == "boolean";
41164
+ function Oe(he) {
41165
+ return typeof he._closed == "boolean" && typeof he._defaultKeepAlive == "boolean" && typeof he._removedConnection == "boolean" && typeof he._removedContLen == "boolean";
41161
41166
  }
41162
- function Lt(de) {
41163
- return typeof de._sent100 == "boolean" && Ve(de);
41167
+ function Lt(he) {
41168
+ return typeof he._sent100 == "boolean" && Oe(he);
41164
41169
  }
41165
- function pe(de) {
41170
+ function pe(he) {
41166
41171
  var Et;
41167
- return typeof de._consuming == "boolean" && typeof de._dumped == "boolean" && ((Et = de.req) === null || Et === void 0 ? void 0 : Et.upgradeOrConnect) === void 0;
41172
+ return typeof he._consuming == "boolean" && typeof he._dumped == "boolean" && ((Et = he.req) === null || Et === void 0 ? void 0 : Et.upgradeOrConnect) === void 0;
41168
41173
  }
41169
- function Cn(de) {
41170
- if (!T(de))
41174
+ function Cn(he) {
41175
+ if (!T(he))
41171
41176
  return null;
41172
- const Et = de._writableState, hn = de._readableState, vn = Et || hn;
41173
- return !vn && Lt(de) || !!(vn && vn.autoDestroy && vn.emitClose && vn.closed === !1);
41177
+ const Et = he._writableState, hn = he._readableState, vn = Et || hn;
41178
+ return !vn && Lt(he) || !!(vn && vn.autoDestroy && vn.emitClose && vn.closed === !1);
41174
41179
  }
41175
- function In(de) {
41180
+ function In(he) {
41176
41181
  var Et;
41177
- return !!(de && ((Et = de[g]) !== null && Et !== void 0 ? Et : de.readableDidRead || de.readableAborted));
41182
+ return !!(he && ((Et = he[g]) !== null && Et !== void 0 ? Et : he.readableDidRead || he.readableAborted));
41178
41183
  }
41179
- function Dt(de) {
41180
- var Et, hn, vn, kt, Ce, he, Ue, Ne, Oe, Pt;
41181
- return !!(de && ((Et = (hn = (vn = (kt = (Ce = (he = de[_]) !== null && he !== void 0 ? he : de.readableErrored) !== null && Ce !== void 0 ? Ce : de.writableErrored) !== null && kt !== void 0 ? kt : (Ue = de._readableState) === null || Ue === void 0 ? void 0 : Ue.errorEmitted) !== null && vn !== void 0 ? vn : (Ne = de._writableState) === null || Ne === void 0 ? void 0 : Ne.errorEmitted) !== null && hn !== void 0 ? hn : (Oe = de._readableState) === null || Oe === void 0 ? void 0 : Oe.errored) !== null && Et !== void 0 ? Et : !((Pt = de._writableState) === null || Pt === void 0) && Pt.errored));
41184
+ function Dt(he) {
41185
+ var Et, hn, vn, kt, Ce, de, Ue, Ne, Ve, Pt;
41186
+ return !!(he && ((Et = (hn = (vn = (kt = (Ce = (de = he[_]) !== null && de !== void 0 ? de : he.readableErrored) !== null && Ce !== void 0 ? Ce : he.writableErrored) !== null && kt !== void 0 ? kt : (Ue = he._readableState) === null || Ue === void 0 ? void 0 : Ue.errorEmitted) !== null && vn !== void 0 ? vn : (Ne = he._writableState) === null || Ne === void 0 ? void 0 : Ne.errorEmitted) !== null && hn !== void 0 ? hn : (Ve = he._readableState) === null || Ve === void 0 ? void 0 : Ve.errored) !== null && Et !== void 0 ? Et : !((Pt = he._writableState) === null || Pt === void 0) && Pt.errored));
41182
41187
  }
41183
41188
  o.exports = {
41184
41189
  kDestroyed: p,
@@ -41244,9 +41249,9 @@ var mqtt = { exports: {} };
41244
41249
  function Fe(oe, le, j) {
41245
41250
  typeof j != "boolean" && (j = le instanceof n("./duplex")), this.objectMode = !!(oe && oe.objectMode), j && (this.objectMode = this.objectMode || !!(oe && oe.writableObjectMode)), this.highWaterMark = oe ? L(this, oe, "writableHighWaterMark", j) : O(!1), this.finalCalled = !1, this.needDrain = !1, this.ending = !1, this.ended = !1, this.finished = !1, this.destroyed = !1;
41246
41251
  const V = !!(oe && oe.decodeStrings === !1);
41247
- this.decodeStrings = !V, this.defaultEncoding = oe && oe.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = de.bind(void 0, le), this.writecb = null, this.writelen = 0, this.afterWriteTickInfo = null, Ve(this), this.pendingcb = 0, this.constructed = !0, this.prefinished = !1, this.errorEmitted = !1, this.emitClose = !oe || oe.emitClose !== !1, this.autoDestroy = !oe || oe.autoDestroy !== !1, this.errored = null, this.closed = !1, this.closeEmitted = !1, this[ze] = [];
41252
+ this.decodeStrings = !V, this.defaultEncoding = oe && oe.defaultEncoding || "utf8", this.length = 0, this.writing = !1, this.corked = 0, this.sync = !0, this.bufferProcessing = !1, this.onwrite = he.bind(void 0, le), this.writecb = null, this.writelen = 0, this.afterWriteTickInfo = null, Oe(this), this.pendingcb = 0, this.constructed = !0, this.prefinished = !1, this.errorEmitted = !1, this.emitClose = !oe || oe.emitClose !== !1, this.autoDestroy = !oe || oe.autoDestroy !== !1, this.errored = null, this.closed = !1, this.closeEmitted = !1, this[ze] = [];
41248
41253
  }
41249
- function Ve(oe) {
41254
+ function Oe(oe) {
41250
41255
  oe.buffered = [], oe.bufferedIndex = 0, oe.allBuffers = !0, oe.allNoop = !0;
41251
41256
  }
41252
41257
  Fe.prototype.getBuffer = function() {
@@ -41327,7 +41332,7 @@ var mqtt = { exports: {} };
41327
41332
  function Dt(oe, le, j, V) {
41328
41333
  --le.pendingcb, V(j), vn(le), ue(oe, j);
41329
41334
  }
41330
- function de(oe, le) {
41335
+ function he(oe, le) {
41331
41336
  const j = oe._writableState, V = j.sync, z = j.writecb;
41332
41337
  if (typeof z != "function") {
41333
41338
  ue(oe, new ie());
@@ -41365,7 +41370,7 @@ var mqtt = { exports: {} };
41365
41370
  (V = oe.errored) !== null && V !== void 0 ? V : new Y("end")
41366
41371
  );
41367
41372
  }
41368
- Ve(oe);
41373
+ Oe(oe);
41369
41374
  }
41370
41375
  function kt(oe, le) {
41371
41376
  if (le.corked || le.bufferProcessing || le.destroyed || !le.constructed)
@@ -41380,7 +41385,7 @@ var mqtt = { exports: {} };
41380
41385
  for (let xn = xe; xn < j.length; ++xn)
41381
41386
  j[xn].callback(Sn);
41382
41387
  }, bn = le.allNoop && xe === 0 ? j : c(j, xe);
41383
- bn.allBuffers = le.allBuffers, In(oe, le, !0, le.length, bn, "", qe), Ve(le);
41388
+ bn.allBuffers = le.allBuffers, In(oe, le, !0, le.length, bn, "", qe), Oe(le);
41384
41389
  } else {
41385
41390
  do {
41386
41391
  const { chunk: qe, encoding: bn, callback: Sn } = j[xe];
@@ -41388,7 +41393,7 @@ var mqtt = { exports: {} };
41388
41393
  const xn = z ? 1 : qe.length;
41389
41394
  In(oe, le, !1, xn, qe, bn, Sn);
41390
41395
  } while (xe < j.length && !le.writing);
41391
- xe === j.length ? Ve(le) : xe > 256 ? (j.splice(0, xe), le.bufferedIndex = 0) : le.bufferedIndex = xe;
41396
+ xe === j.length ? Oe(le) : xe > 256 ? (j.splice(0, xe), le.bufferedIndex = 0) : le.bufferedIndex = xe;
41392
41397
  }
41393
41398
  le.bufferProcessing = !1;
41394
41399
  }
@@ -41418,7 +41423,7 @@ var mqtt = { exports: {} };
41418
41423
  function Ce(oe) {
41419
41424
  return oe.ending && !oe.destroyed && oe.constructed && oe.length === 0 && !oe.errored && oe.buffered.length === 0 && !oe.finished && !oe.writing && !oe.errorEmitted && !oe.closeEmitted;
41420
41425
  }
41421
- function he(oe, le) {
41426
+ function de(oe, le) {
41422
41427
  let j = !1;
41423
41428
  function V(z) {
41424
41429
  if (j) {
@@ -41431,7 +41436,7 @@ var mqtt = { exports: {} };
41431
41436
  ae[xe](z);
41432
41437
  ue(oe, z, le.sync);
41433
41438
  } else
41434
- Ce(le) && (le.prefinished = !0, oe.emit("prefinish"), le.pendingcb++, u.nextTick(Oe, oe, le));
41439
+ Ce(le) && (le.prefinished = !0, oe.emit("prefinish"), le.pendingcb++, u.nextTick(Ve, oe, le));
41435
41440
  }
41436
41441
  le.sync = !0, le.pendingcb++;
41437
41442
  try {
@@ -41442,18 +41447,18 @@ var mqtt = { exports: {} };
41442
41447
  le.sync = !1;
41443
41448
  }
41444
41449
  function Ue(oe, le) {
41445
- !le.prefinished && !le.finalCalled && (typeof oe._final == "function" && !le.destroyed ? (le.finalCalled = !0, he(oe, le)) : (le.prefinished = !0, oe.emit("prefinish")));
41450
+ !le.prefinished && !le.finalCalled && (typeof oe._final == "function" && !le.destroyed ? (le.finalCalled = !0, de(oe, le)) : (le.prefinished = !0, oe.emit("prefinish")));
41446
41451
  }
41447
41452
  function Ne(oe, le, j) {
41448
41453
  Ce(le) && (Ue(oe, le), le.pendingcb === 0 && (j ? (le.pendingcb++, u.nextTick(
41449
41454
  (V, z) => {
41450
- Ce(z) ? Oe(V, z) : z.pendingcb--;
41455
+ Ce(z) ? Ve(V, z) : z.pendingcb--;
41451
41456
  },
41452
41457
  oe,
41453
41458
  le
41454
- )) : Ce(le) && (le.pendingcb++, Oe(oe, le))));
41459
+ )) : Ce(le) && (le.pendingcb++, Ve(oe, le))));
41455
41460
  }
41456
- function Oe(oe, le) {
41461
+ function Ve(oe, le) {
41457
41462
  le.pendingcb--, le.finished = !0;
41458
41463
  const j = le[ze].splice(0);
41459
41464
  for (let V = 0; V < j.length; V++)
@@ -41615,7 +41620,7 @@ var mqtt = { exports: {} };
41615
41620
  throw new k(xe, "an integer", ae);
41616
41621
  if (ae < qe || ae > bn)
41617
41622
  throw new k(xe, `>= ${qe} && <= ${bn}`, ae);
41618
- }), Ve = x((ae, xe, qe = -2147483648, bn = 2147483647) => {
41623
+ }), Oe = x((ae, xe, qe = -2147483648, bn = 2147483647) => {
41619
41624
  if (typeof ae != "number")
41620
41625
  throw new O(xe, "number", ae);
41621
41626
  if (!p(ae))
@@ -41658,12 +41663,12 @@ var mqtt = { exports: {} };
41658
41663
  if (typeof ae != "boolean")
41659
41664
  throw new O(xe, "boolean", ae);
41660
41665
  }
41661
- function de(ae, xe, qe) {
41666
+ function he(ae, xe, qe) {
41662
41667
  return ae == null || !b(ae, xe) ? qe : ae[xe];
41663
41668
  }
41664
41669
  const Et = x((ae, xe, qe = null) => {
41665
- const bn = de(qe, "allowArray", !1), Sn = de(qe, "allowFunction", !1);
41666
- if (!de(qe, "nullable", !1) && ae === null || !bn && u(ae) || typeof ae != "object" && (!Sn || typeof ae != "function"))
41670
+ const bn = he(qe, "allowArray", !1), Sn = he(qe, "allowFunction", !1);
41671
+ if (!he(qe, "nullable", !1) && ae === null || !bn && u(ae) || typeof ae != "object" && (!Sn || typeof ae != "function"))
41667
41672
  throw new O(xe, "Object", ae);
41668
41673
  }), hn = x((ae, xe) => {
41669
41674
  if (ae != null && typeof ae != "object" && typeof ae != "function")
@@ -41686,7 +41691,7 @@ var mqtt = { exports: {} };
41686
41691
  for (let qe = 0; qe < ae.length; qe++)
41687
41692
  Dt(ae[qe], `${xe}[${qe}]`);
41688
41693
  }
41689
- function he(ae, xe = "signal") {
41694
+ function de(ae, xe = "signal") {
41690
41695
  if (pe(ae, xe), re[ae] === void 0)
41691
41696
  throw re[S(ae)] !== void 0 ? new ie(ae + " (signals must use all capital letters)") : new ie(ae);
41692
41697
  }
@@ -41699,7 +41704,7 @@ var mqtt = { exports: {} };
41699
41704
  if (qe === "hex" && bn % 2 !== 0)
41700
41705
  throw new M("encoding", xe, `is invalid for data of length ${bn}`);
41701
41706
  }
41702
- function Oe(ae, xe = "Port", qe = !0) {
41707
+ function Ve(ae, xe = "Port", qe = !0) {
41703
41708
  if (typeof ae != "number" && typeof ae != "string" || typeof ae == "string" && T(ae).length === 0 || +ae !== +ae >>> 0 || ae > 65535 || ae === 0 && !qe)
41704
41709
  throw new L(xe, ae, qe);
41705
41710
  return ae | 0;
@@ -41762,14 +41767,14 @@ var mqtt = { exports: {} };
41762
41767
  validateDictionary: hn,
41763
41768
  validateEncoding: Ne,
41764
41769
  validateFunction: jt,
41765
- validateInt32: Ve,
41770
+ validateInt32: Oe,
41766
41771
  validateInteger: Fe,
41767
41772
  validateNumber: Cn,
41768
41773
  validateObject: Et,
41769
41774
  validateOneOf: In,
41770
41775
  validatePlainFunction: _n,
41771
- validatePort: Oe,
41772
- validateSignalName: he,
41776
+ validatePort: Ve,
41777
+ validateSignalName: de,
41773
41778
  validateString: pe,
41774
41779
  validateUint32: Lt,
41775
41780
  validateUndefined: oe,
@@ -42530,9 +42535,9 @@ var mqtt = { exports: {} };
42530
42535
  Ie[0] = Ie[0].replace(ze, "/"), D = Ie.join(ue);
42531
42536
  var Fe = D;
42532
42537
  if (Fe = Fe.trim(), !F && D.split("#").length === 1) {
42533
- var Ve = _.exec(Fe);
42534
- if (Ve)
42535
- return this.path = Fe, this.href = Fe, this.pathname = Ve[1], Ve[2] ? (this.search = Ve[2], re ? this.query = M.parse(this.search.substr(1)) : this.query = this.search.substr(1)) : re && (this.search = "", this.query = {}), this;
42538
+ var Oe = _.exec(Fe);
42539
+ if (Oe)
42540
+ return this.path = Fe, this.href = Fe, this.pathname = Oe[1], Oe[2] ? (this.search = Oe[2], re ? this.query = M.parse(this.search.substr(1)) : this.query = this.search.substr(1)) : re && (this.search = "", this.query = {}), this;
42536
42541
  }
42537
42542
  var Lt = f.exec(Fe);
42538
42543
  if (Lt) {
@@ -42546,25 +42551,25 @@ var mqtt = { exports: {} };
42546
42551
  }
42547
42552
  if (!L[Lt] && (Cn || Lt && !O[Lt])) {
42548
42553
  for (var In = -1, Dt = 0; Dt < A.length; Dt++) {
42549
- var de = Fe.indexOf(A[Dt]);
42550
- de !== -1 && (In === -1 || de < In) && (In = de);
42554
+ var he = Fe.indexOf(A[Dt]);
42555
+ he !== -1 && (In === -1 || he < In) && (In = he);
42551
42556
  }
42552
42557
  var Et, hn;
42553
42558
  In === -1 ? hn = Fe.lastIndexOf("@") : hn = Fe.lastIndexOf("@", In), hn !== -1 && (Et = Fe.slice(0, hn), Fe = Fe.slice(hn + 1), this.auth = decodeURIComponent(Et)), In = -1;
42554
42559
  for (var Dt = 0; Dt < b.length; Dt++) {
42555
- var de = Fe.indexOf(b[Dt]);
42556
- de !== -1 && (In === -1 || de < In) && (In = de);
42560
+ var he = Fe.indexOf(b[Dt]);
42561
+ he !== -1 && (In === -1 || he < In) && (In = he);
42557
42562
  }
42558
42563
  In === -1 && (In = Fe.length), this.host = Fe.slice(0, In), Fe = Fe.slice(In), this.parseHost(), this.hostname = this.hostname || "";
42559
42564
  var vn = this.hostname[0] === "[" && this.hostname[this.hostname.length - 1] === "]";
42560
42565
  if (!vn)
42561
42566
  for (var kt = this.hostname.split(/\./), Dt = 0, Ce = kt.length; Dt < Ce; Dt++) {
42562
- var he = kt[Dt];
42563
- if (he && !he.match(S)) {
42564
- for (var Ue = "", Ne = 0, Oe = he.length; Ne < Oe; Ne++)
42565
- he.charCodeAt(Ne) > 127 ? Ue += "x" : Ue += he[Ne];
42567
+ var de = kt[Dt];
42568
+ if (de && !de.match(S)) {
42569
+ for (var Ue = "", Ne = 0, Ve = de.length; Ne < Ve; Ne++)
42570
+ de.charCodeAt(Ne) > 127 ? Ue += "x" : Ue += de[Ne];
42566
42571
  if (!Ue.match(S)) {
42567
- var Pt = kt.slice(0, Dt), jt = kt.slice(Dt + 1), _n = he.match(T);
42572
+ var Pt = kt.slice(0, Dt), jt = kt.slice(Dt + 1), _n = de.match(T);
42568
42573
  _n && (Pt.push(_n[1]), jt.unshift(_n[2])), jt.length && (Fe = "/" + jt.join(".") + Fe), this.hostname = Pt.join(".");
42569
42574
  break;
42570
42575
  }
@@ -42626,8 +42631,8 @@ var mqtt = { exports: {} };
42626
42631
  return F.href = F.format(), F;
42627
42632
  if (D.slashes && !D.protocol) {
42628
42633
  for (var ze = Object.keys(D), Fe = 0; Fe < ze.length; Fe++) {
42629
- var Ve = ze[Fe];
42630
- Ve !== "protocol" && (F[Ve] = D[Ve]);
42634
+ var Oe = ze[Fe];
42635
+ Oe !== "protocol" && (F[Oe] = D[Oe]);
42631
42636
  }
42632
42637
  return O[F.protocol] && F.hostname && !F.pathname && (F.path = F.pathname = "/"), F.href = F.format(), F;
42633
42638
  }
@@ -42651,13 +42656,13 @@ var mqtt = { exports: {} };
42651
42656
  }
42652
42657
  return F.slashes = F.slashes || D.slashes, F.href = F.format(), F;
42653
42658
  }
42654
- var de = F.pathname && F.pathname.charAt(0) === "/", Et = D.host || D.pathname && D.pathname.charAt(0) === "/", hn = Et || de || F.host && D.pathname, vn = hn, kt = F.pathname && F.pathname.split("/") || [], Ce = D.pathname && D.pathname.split("/") || [], he = F.protocol && !O[F.protocol];
42655
- if (he && (F.hostname = "", F.port = null, F.host && (kt[0] === "" ? kt[0] = F.host : kt.unshift(F.host)), F.host = "", D.protocol && (D.hostname = null, D.port = null, D.host && (Ce[0] === "" ? Ce[0] = D.host : Ce.unshift(D.host)), D.host = null), hn = hn && (Ce[0] === "" || kt[0] === "")), Et)
42659
+ var he = F.pathname && F.pathname.charAt(0) === "/", Et = D.host || D.pathname && D.pathname.charAt(0) === "/", hn = Et || he || F.host && D.pathname, vn = hn, kt = F.pathname && F.pathname.split("/") || [], Ce = D.pathname && D.pathname.split("/") || [], de = F.protocol && !O[F.protocol];
42660
+ if (de && (F.hostname = "", F.port = null, F.host && (kt[0] === "" ? kt[0] = F.host : kt.unshift(F.host)), F.host = "", D.protocol && (D.hostname = null, D.port = null, D.host && (Ce[0] === "" ? Ce[0] = D.host : Ce.unshift(D.host)), D.host = null), hn = hn && (Ce[0] === "" || kt[0] === "")), Et)
42656
42661
  F.host = D.host || D.host === "" ? D.host : F.host, F.hostname = D.hostname || D.hostname === "" ? D.hostname : F.hostname, F.search = D.search, F.query = D.query, kt = Ce;
42657
42662
  else if (Ce.length)
42658
42663
  kt || (kt = []), kt.pop(), kt = kt.concat(Ce), F.search = D.search, F.query = D.query;
42659
42664
  else if (!c.isNullOrUndefined(D.search)) {
42660
- if (he) {
42665
+ if (de) {
42661
42666
  F.hostname = F.host = kt.shift();
42662
42667
  var Ue = F.host && F.host.indexOf("@") > 0 ? F.host.split("@") : !1;
42663
42668
  Ue && (F.auth = Ue.shift(), F.host = F.hostname = Ue.shift());
@@ -42666,14 +42671,14 @@ var mqtt = { exports: {} };
42666
42671
  }
42667
42672
  if (!kt.length)
42668
42673
  return F.pathname = null, F.search ? F.path = "/" + F.search : F.path = null, F.href = F.format(), F;
42669
- for (var Ne = kt.slice(-1)[0], Oe = (F.host || D.host || kt.length > 1) && (Ne === "." || Ne === "..") || Ne === "", Pt = 0, jt = kt.length; jt >= 0; jt--)
42674
+ for (var Ne = kt.slice(-1)[0], Ve = (F.host || D.host || kt.length > 1) && (Ne === "." || Ne === "..") || Ne === "", Pt = 0, jt = kt.length; jt >= 0; jt--)
42670
42675
  Ne = kt[jt], Ne === "." ? kt.splice(jt, 1) : Ne === ".." ? (kt.splice(jt, 1), Pt++) : Pt && (kt.splice(jt, 1), Pt--);
42671
42676
  if (!hn && !vn)
42672
42677
  for (; Pt--; Pt)
42673
42678
  kt.unshift("..");
42674
- hn && kt[0] !== "" && (!kt[0] || kt[0].charAt(0) !== "/") && kt.unshift(""), Oe && kt.join("/").substr(-1) !== "/" && kt.push("");
42679
+ hn && kt[0] !== "" && (!kt[0] || kt[0].charAt(0) !== "/") && kt.unshift(""), Ve && kt.join("/").substr(-1) !== "/" && kt.push("");
42675
42680
  var _n = kt[0] === "" || kt[0] && kt[0].charAt(0) === "/";
42676
- if (he) {
42681
+ if (de) {
42677
42682
  F.hostname = F.host = _n ? "" : kt.length ? kt.shift() : "";
42678
42683
  var Ue = F.host && F.host.indexOf("@") > 0 ? F.host.split("@") : !1;
42679
42684
  Ue && (F.auth = Ue.shift(), F.host = F.hostname = Ue.shift());