@netless/appliance-plugin 1.1.14-beta.2 → 1.1.15-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,17 +1,17 @@
1
- var wn = Object.defineProperty;
2
- var mn = (a, i, t) => i in a ? wn(a, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : a[i] = t;
3
- var y = (a, i, t) => mn(a, typeof i != "symbol" ? i + "" : i, t);
1
+ var mn = Object.defineProperty;
2
+ var wn = (a, i, t) => i in a ? mn(a, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : a[i] = t;
3
+ var y = (a, i, t) => wn(a, typeof i != "symbol" ? i + "" : i, t);
4
4
  import { toJS as ji, autorun as ys, isRoom as K, isPlayer as Hi, InvisiblePlugin as go, RoomPhase as yo } from "white-web-sdk";
5
5
  import { Group as Yt, Path as ce, Rect as Ms, Polyline as ue, Ellipse as vn, Label as In, Scene as Mo, Layer as Nn, Sprite as Sn } from "spritejs";
6
6
  import { decompress as Tn, compress as kn } from "lz-string";
7
7
  import Qi from "lineclip";
8
8
  import Ei from "eventemitter2";
9
- import { cloneDeep as gt, isEqual as ft, isSet as Ft, debounce as yi, isNumber as _, isBoolean as Ut, clone as ws, throttle as se } from "lodash";
9
+ import { cloneDeep as gt, isEqual as ft, isSet as Ft, debounce as yi, isNumber as _, isBoolean as Ut, clone as ms, throttle as se } from "lodash";
10
10
  import k, { useContext as xt, useState as nt, useMemo as X, useEffect as yt, useRef as De, useCallback as Cn } from "react";
11
11
  import Gi, { createPortal as bn } from "react-dom";
12
12
  import Ae from "react-draggable";
13
13
  import { Resizable as xn } from "re-resizable";
14
- const Vm = "/fullWorker.js", Hm = "/subWorker.js";
14
+ const Vw = "/fullWorker.js", Hw = "/subWorker.js";
15
15
  var at = /* @__PURE__ */ ((a) => (a.selector = "selector", a.clicker = "clicker", a.laserPointer = "laserPointer", a.pencil = "pencil", a.rectangle = "rectangle", a.ellipse = "ellipse", a.shape = "shape", a.eraser = "eraser", a.pencilEraser = "pencilEraser", a.text = "text", a.straight = "straight", a.arrow = "arrow", a.hand = "hand", a.laserPen = "laserPen", a))(at || {}), st = /* @__PURE__ */ ((a) => (a.Normal = "Normal", a.Stroke = "Stroke", a.Dotted = "Dotted", a.LongDotted = "LongDotted", a))(st || {}), _t = /* @__PURE__ */ ((a) => (a.Triangle = "triangle", a.Rhombus = "rhombus", a.Pentagram = "pentagram", a.SpeechBalloon = "speechBalloon", a.Star = "star", a.Polygon = "polygon", a))(_t || {}), B = /* @__PURE__ */ ((a) => (a.None = "None", a.ShowFloatBar = "ShowFloatBar", a.ZIndexFloatBar = "ZIndexFloatBar", a.DeleteNode = "DeleteNode", a.CopyNode = "CopyNode", a.ZIndexActive = "ZIndexActive", a.ZIndexNode = "ZIndexNode", a.RotateNode = "RotateNode", a.SetColorNode = "SetColorNode", a.TranslateNode = "TranslateNode", a.ScaleNode = "ScaleNode", a.OriginalEvent = "OriginalEvent", a.CreateScene = "CreateScene", a.ActiveCursor = "ActiveCursor", a.MoveCursor = "MoveCursor", a.CommandEditor = "CommandEditor", a.SetEditorData = "SetEditorData", a.SetFontStyle = "SetFontStyle", a.SetPoint = "SetPoint", a.SetLock = "SetLock", a.SetShapeOpt = "SetShapeOpt", a.CameraChange = "CameraChange", a.ActiveMethod = "ActiveMethod", a))(B || {}), ot = /* @__PURE__ */ ((a) => (a.DisplayState = "DisplayState", a.MainEngine = "MainEngine", a.Cursor = "Cursor", a.BindMainView = "BindMainView", a))(ot || {}), Ln = /* @__PURE__ */ ((a) => (a[a.MainView = 0] = "MainView", a[a.Plugin = 1] = "Plugin", a[a.Both = 2] = "Both", a))(Ln || {}), I = /* @__PURE__ */ ((a) => (a[a.Pencil = 1] = "Pencil", a[a.Eraser = 2] = "Eraser", a[a.PencilEraser = 3] = "PencilEraser", a[a.BitMapEraser = 4] = "BitMapEraser", a[a.Selector = 5] = "Selector", a[a.Clicker = 6] = "Clicker", a[a.Arrow = 7] = "Arrow", a[a.Hand = 8] = "Hand", a[a.LaserPen = 9] = "LaserPen", a[a.Text = 10] = "Text", a[a.Straight = 11] = "Straight", a[a.Rectangle = 12] = "Rectangle", a[a.Ellipse = 13] = "Ellipse", a[a.Star = 14] = "Star", a[a.Triangle = 15] = "Triangle", a[a.Rhombus = 16] = "Rhombus", a[a.Polygon = 17] = "Polygon", a[a.SpeechBalloon = 18] = "SpeechBalloon", a[a.Image = 19] = "Image", a))(I || {}), U = /* @__PURE__ */ ((a) => (a[a.Local = 1] = "Local", a[a.Service = 2] = "Service", a[a.Worker = 3] = "Worker", a))(U || {}), P = /* @__PURE__ */ ((a) => (a[a.Pending = 0] = "Pending", a[a.Start = 1] = "Start", a[a.Doing = 2] = "Doing", a[a.Done = 3] = "Done", a[a.Unwritable = 4] = "Unwritable", a))(P || {}), x = /* @__PURE__ */ ((a) => (a[a.None = 0] = "None", a[a.Init = 1] = "Init", a[a.UpdateCamera = 2] = "UpdateCamera", a[a.UpdateTools = 3] = "UpdateTools", a[a.CreateWork = 4] = "CreateWork", a[a.DrawWork = 5] = "DrawWork", a[a.FullWork = 6] = "FullWork", a[a.UpdateNode = 7] = "UpdateNode", a[a.RemoveNode = 8] = "RemoveNode", a[a.Clear = 9] = "Clear", a[a.Select = 10] = "Select", a[a.Destroy = 11] = "Destroy", a[a.Snapshot = 12] = "Snapshot", a[a.BoundingBox = 13] = "BoundingBox", a[a.Cursor = 14] = "Cursor", a[a.TextUpdate = 15] = "TextUpdate", a[a.GetTextActive = 16] = "GetTextActive", a[a.TasksQueue = 17] = "TasksQueue", a[a.CursorHover = 18] = "CursorHover", a[a.CursorBlur = 19] = "CursorBlur", a[a.Console = 20] = "Console", a[a.PriorityWorker = 21] = "PriorityWorker", a[a.PriorityMainThreadWorker = 22] = "PriorityMainThreadWorker", a[a.GetImageBitMap = 23] = "GetImageBitMap", a[a.AuthWriter = 24] = "AuthWriter", a[a.AuthReader = 25] = "AuthReader", a[a.AuthClear = 26] = "AuthClear", a[a.AuthPage = 27] = "AuthPage", a[a.GetVNodeInfo = 28] = "GetVNodeInfo", a[a.UpdateDpr = 29] = "UpdateDpr", a))(x || {}), Nt = /* @__PURE__ */ ((a) => (a[a.None = 0] = "None", a[a.Bg = 1] = "Bg", a[a.ServiceFloat = 2] = "ServiceFloat", a[a.Float = 3] = "Float", a[a.TopFloat = 4] = "TopFloat", a))(Nt || {}), ti = /* @__PURE__ */ ((a) => (a[a.Cursor = 1] = "Cursor", a[a.TextCreate = 2] = "TextCreate", a))(ti || {}), si = /* @__PURE__ */ ((a) => (a[a.Top = 1] = "Top", a[a.Bottom = 2] = "Bottom", a))(si || {}), lt = /* @__PURE__ */ ((a) => (a[a.none = 1] = "none", a[a.all = 2] = "all", a[a.both = 3] = "both", a[a.proportional = 4] = "proportional", a))(lt || {}), zn = /* @__PURE__ */ ((a) => (a[a.Pending = 0] = "Pending", a[a.Start = 1] = "Start", a[a.Doing = 2] = "Doing", a[a.Done = 3] = "Done", a[a.Unwritable = 4] = "Unwritable", a))(zn || {}), ei = /* @__PURE__ */ ((a) => (a[a.inside = 0] = "inside", a[a.outside = 1] = "outside", a[a.intersect = 2] = "intersect", a))(ei || {}), Rt = /* @__PURE__ */ ((a) => (a.renderPage = "renderPage", a.addPage = "addPage", a.deletePage = "deletePage", a.addElement = "addElement", a.deleteElement = "deleteElement", a.clearPage = "clearPage", a.clearViewScenePath = "clearViewScenePath", a.clearView = "clearView", a))(Rt || {}), ee = /* @__PURE__ */ ((a) => (a.setAuth = "setAuth", a.setShow = "addShow", a.setHide = "setHide", a.setClear = "setClear", a))(ee || {}), ze = /* @__PURE__ */ ((a) => (a.Image = "image", a.Iconify = "iconify", a))(ze || {});
16
16
  const Pn = {
17
17
  linear: (a) => a,
@@ -497,7 +497,7 @@ var Je = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : t
497
497
  function je(a) {
498
498
  return a && a.__esModule && Object.prototype.hasOwnProperty.call(a, "default") ? a.default : a;
499
499
  }
500
- var An = typeof Je == "object" && Je && Je.Object === Object && Je, wo = An, jn = wo, En = typeof self == "object" && self && self.Object === Object && self, On = jn || En || Function("return this")(), Kt = On, Rn = Kt, Wn = Rn.Symbol, Ge = Wn, ms = Ge, mo = Object.prototype, Yn = mo.hasOwnProperty, Un = mo.toString, Be = ms ? ms.toStringTag : void 0;
500
+ var An = typeof Je == "object" && Je && Je.Object === Object && Je, mo = An, jn = mo, En = typeof self == "object" && self && self.Object === Object && self, On = jn || En || Function("return this")(), Kt = On, Rn = Kt, Wn = Rn.Symbol, Ge = Wn, ws = Ge, wo = Object.prototype, Yn = wo.hasOwnProperty, Un = wo.toString, Be = ws ? ws.toStringTag : void 0;
501
501
  function Bn(a) {
502
502
  var i = Yn.call(a, Be), t = a[Be];
503
503
  try {
@@ -516,11 +516,11 @@ var Qn = Hn, vs = Ge, Gn = Fn, Zn = Qn, Xn = "[object Null]", Jn = "[object Unde
516
516
  function qn(a) {
517
517
  return a == null ? a === void 0 ? Jn : Xn : Is && Is in Object(a) ? Gn(a) : Zn(a);
518
518
  }
519
- var me = qn;
519
+ var we = qn;
520
520
  function Kn(a) {
521
521
  return a != null && typeof a == "object";
522
522
  }
523
- var oe = Kn, _n = me, tr = oe, er = "[object Number]";
523
+ var oe = Kn, _n = we, tr = oe, er = "[object Number]";
524
524
  function ir(a) {
525
525
  return typeof a == "number" || tr(a) && _n(a) == er;
526
526
  }
@@ -554,15 +554,15 @@ function gr(a) {
554
554
  return t < 0 ? void 0 : i[t][1];
555
555
  }
556
556
  var yr = gr, Mr = Mi;
557
- function wr(a) {
557
+ function mr(a) {
558
558
  return Mr(this.__data__, a) > -1;
559
559
  }
560
- var mr = wr, vr = Mi;
560
+ var wr = mr, vr = Mi;
561
561
  function Ir(a, i) {
562
562
  var t = this.__data__, e = vr(t, a);
563
563
  return e < 0 ? (++this.size, t.push([a, i])) : t[e][1] = i, this;
564
564
  }
565
- var Nr = Ir, Sr = nr, Tr = pr, kr = yr, Cr = mr, br = Nr;
565
+ var Nr = Ir, Sr = nr, Tr = pr, kr = yr, Cr = wr, br = Nr;
566
566
  function Ee(a) {
567
567
  var i = -1, t = a == null ? 0 : a.length;
568
568
  for (this.clear(); ++i < t; ) {
@@ -575,7 +575,7 @@ Ee.prototype.delete = Tr;
575
575
  Ee.prototype.get = kr;
576
576
  Ee.prototype.has = Cr;
577
577
  Ee.prototype.set = br;
578
- var wi = Ee, xr = wi;
578
+ var mi = Ee, xr = mi;
579
579
  function Lr() {
580
580
  this.__data__ = new xr(), this.size = 0;
581
581
  }
@@ -597,7 +597,7 @@ function Rr(a) {
597
597
  var i = typeof a;
598
598
  return a != null && (i == "object" || i == "function");
599
599
  }
600
- var de = Rr, Wr = me, Yr = de, Ur = "[object AsyncFunction]", Br = "[object Function]", Fr = "[object GeneratorFunction]", $r = "[object Proxy]";
600
+ var de = Rr, Wr = we, Yr = de, Ur = "[object AsyncFunction]", Br = "[object Function]", Fr = "[object GeneratorFunction]", $r = "[object Proxy]";
601
601
  function Vr(a) {
602
602
  if (!Yr(a))
603
603
  return !1;
@@ -643,7 +643,7 @@ function ya(a, i) {
643
643
  var t = ga(a, i);
644
644
  return fa(t) ? t : void 0;
645
645
  }
646
- var ve = ya, Ma = ve, wa = Kt, ma = Ma(wa, "Map"), Xi = ma, va = ve, Ia = va(Object, "create"), mi = Ia, Ss = mi;
646
+ var ve = ya, Ma = ve, ma = Kt, wa = Ma(ma, "Map"), Xi = wa, va = ve, Ia = va(Object, "create"), wi = Ia, Ss = wi;
647
647
  function Na() {
648
648
  this.__data__ = Ss ? Ss(null) : {}, this.size = 0;
649
649
  }
@@ -652,7 +652,7 @@ function Ta(a) {
652
652
  var i = this.has(a) && delete this.__data__[a];
653
653
  return this.size -= i ? 1 : 0, i;
654
654
  }
655
- var ka = Ta, Ca = mi, ba = "__lodash_hash_undefined__", xa = Object.prototype, La = xa.hasOwnProperty;
655
+ var ka = Ta, Ca = wi, ba = "__lodash_hash_undefined__", xa = Object.prototype, La = xa.hasOwnProperty;
656
656
  function za(a) {
657
657
  var i = this.__data__;
658
658
  if (Ca) {
@@ -661,12 +661,12 @@ function za(a) {
661
661
  }
662
662
  return La.call(i, a) ? i[a] : void 0;
663
663
  }
664
- var Pa = za, Da = mi, Aa = Object.prototype, ja = Aa.hasOwnProperty;
664
+ var Pa = za, Da = wi, Aa = Object.prototype, ja = Aa.hasOwnProperty;
665
665
  function Ea(a) {
666
666
  var i = this.__data__;
667
667
  return Da ? i[a] !== void 0 : ja.call(i, a);
668
668
  }
669
- var Oa = Ea, Ra = mi, Wa = "__lodash_hash_undefined__";
669
+ var Oa = Ea, Ra = wi, Wa = "__lodash_hash_undefined__";
670
670
  function Ya(a, i) {
671
671
  var t = this.__data__;
672
672
  return this.size += this.has(a) ? 0 : 1, t[a] = Ra && i === void 0 ? Wa : i, this;
@@ -684,7 +684,7 @@ Oe.prototype.delete = Fa;
684
684
  Oe.prototype.get = $a;
685
685
  Oe.prototype.has = Va;
686
686
  Oe.prototype.set = Ha;
687
- var Qa = Oe, Ts = Qa, Ga = wi, Za = Xi;
687
+ var Qa = Oe, Ts = Qa, Ga = mi, Za = Xi;
688
688
  function Xa() {
689
689
  this.size = 0, this.__data__ = {
690
690
  hash: new Ts(),
@@ -733,18 +733,18 @@ Re.prototype.delete = fc;
733
733
  Re.prototype.get = gc;
734
734
  Re.prototype.has = yc;
735
735
  Re.prototype.set = Mc;
736
- var No = Re, wc = wi, mc = Xi, vc = No, Ic = 200;
736
+ var No = Re, mc = mi, wc = Xi, vc = No, Ic = 200;
737
737
  function Nc(a, i) {
738
738
  var t = this.__data__;
739
- if (t instanceof wc) {
739
+ if (t instanceof mc) {
740
740
  var e = t.__data__;
741
- if (!mc || e.length < Ic - 1)
741
+ if (!wc || e.length < Ic - 1)
742
742
  return e.push([a, i]), this.size = ++t.size, this;
743
743
  t = this.__data__ = new vc(e);
744
744
  }
745
745
  return t.set(a, i), this.size = t.size, this;
746
746
  }
747
- var Sc = Nc, Tc = wi, kc = zr, Cc = Dr, bc = jr, xc = Or, Lc = Sc;
747
+ var Sc = Nc, Tc = mi, kc = zr, Cc = Dr, bc = jr, xc = Or, Lc = Sc;
748
748
  function We(a) {
749
749
  var i = this.__data__ = new Tc(a);
750
750
  this.size = i.size;
@@ -796,7 +796,7 @@ function $c(a, i) {
796
796
  e[t] = i(t);
797
797
  return e;
798
798
  }
799
- var Vc = $c, Hc = me, Qc = oe, Gc = "[object Arguments]";
799
+ var Vc = $c, Hc = we, Qc = oe, Gc = "[object Arguments]";
800
800
  function Zc(a) {
801
801
  return Qc(a) && Hc(a) == Gc;
802
802
  }
@@ -823,9 +823,9 @@ var rl = nl, al = 9007199254740991;
823
823
  function cl(a) {
824
824
  return typeof a == "number" && a > -1 && a % 1 == 0 && a <= al;
825
825
  }
826
- var Lo = cl, ll = me, hl = Lo, ul = oe, dl = "[object Arguments]", pl = "[object Array]", fl = "[object Boolean]", gl = "[object Date]", yl = "[object Error]", Ml = "[object Function]", wl = "[object Map]", ml = "[object Number]", vl = "[object Object]", Il = "[object RegExp]", Nl = "[object Set]", Sl = "[object String]", Tl = "[object WeakMap]", kl = "[object ArrayBuffer]", Cl = "[object DataView]", bl = "[object Float32Array]", xl = "[object Float64Array]", Ll = "[object Int8Array]", zl = "[object Int16Array]", Pl = "[object Int32Array]", Dl = "[object Uint8Array]", Al = "[object Uint8ClampedArray]", jl = "[object Uint16Array]", El = "[object Uint32Array]", It = {};
826
+ var Lo = cl, ll = we, hl = Lo, ul = oe, dl = "[object Arguments]", pl = "[object Array]", fl = "[object Boolean]", gl = "[object Date]", yl = "[object Error]", Ml = "[object Function]", ml = "[object Map]", wl = "[object Number]", vl = "[object Object]", Il = "[object RegExp]", Nl = "[object Set]", Sl = "[object String]", Tl = "[object WeakMap]", kl = "[object ArrayBuffer]", Cl = "[object DataView]", bl = "[object Float32Array]", xl = "[object Float64Array]", Ll = "[object Int8Array]", zl = "[object Int16Array]", Pl = "[object Int32Array]", Dl = "[object Uint8Array]", Al = "[object Uint8ClampedArray]", jl = "[object Uint16Array]", El = "[object Uint32Array]", It = {};
827
827
  It[bl] = It[xl] = It[Ll] = It[zl] = It[Pl] = It[Dl] = It[Al] = It[jl] = It[El] = !0;
828
- It[dl] = It[pl] = It[kl] = It[fl] = It[Cl] = It[gl] = It[yl] = It[Ml] = It[wl] = It[ml] = It[vl] = It[Il] = It[Nl] = It[Sl] = It[Tl] = !1;
828
+ It[dl] = It[pl] = It[kl] = It[fl] = It[Cl] = It[gl] = It[yl] = It[Ml] = It[ml] = It[wl] = It[vl] = It[Il] = It[Nl] = It[Sl] = It[Tl] = !1;
829
829
  function Ol(a) {
830
830
  return ul(a) && hl(a.length) && !!It[ll(a)];
831
831
  }
@@ -838,7 +838,7 @@ function Wl(a) {
838
838
  var Ni = Wl, ni = { exports: {} };
839
839
  ni.exports;
840
840
  (function(a, i) {
841
- var t = wo, e = i && !i.nodeType && i, s = e && !0 && a && !a.nodeType && a, o = s && s.exports === e, n = o && t.process, r = function() {
841
+ var t = mo, e = i && !i.nodeType && i, s = e && !0 && a && !a.nodeType && a, o = s && s.exports === e, n = o && t.process, r = function() {
842
842
  try {
843
843
  var c = s && s.require && s.require("util").types;
844
844
  return c || n && n.binding && n.binding("util");
@@ -887,10 +887,10 @@ function gh(a) {
887
887
  return fh(a) ? dh(a) : ph(a);
888
888
  }
889
889
  var ts = gh, yh = Ii, Mh = ts;
890
- function wh(a, i) {
890
+ function mh(a, i) {
891
891
  return a && yh(i, Mh(i), a);
892
892
  }
893
- var mh = wh;
893
+ var wh = mh;
894
894
  function vh(a) {
895
895
  var i = [];
896
896
  if (a != null)
@@ -977,11 +977,11 @@ var Ro = du, pu = Ro, fu = is, gu = ts;
977
977
  function yu(a) {
978
978
  return pu(a, gu, fu);
979
979
  }
980
- var Wo = yu, Mu = Ro, wu = Oo, mu = es;
980
+ var Wo = yu, Mu = Ro, mu = Oo, wu = es;
981
981
  function vu(a) {
982
- return Mu(a, mu, wu);
982
+ return Mu(a, wu, mu);
983
983
  }
984
- var Iu = vu, Nu = ve, Su = Kt, Tu = Nu(Su, "DataView"), ku = Tu, Cu = ve, bu = Kt, xu = Cu(bu, "Promise"), Lu = xu, zu = ve, Pu = Kt, Du = zu(Pu, "Set"), Yo = Du, Au = ve, ju = Kt, Eu = Au(ju, "WeakMap"), Ou = Eu, Oi = ku, Ri = Xi, Wi = Lu, Yi = Yo, Ui = Ou, Uo = me, Ye = Io, zs = "[object Map]", Ru = "[object Object]", Ps = "[object Promise]", Ds = "[object Set]", As = "[object WeakMap]", js = "[object DataView]", Wu = Ye(Oi), Yu = Ye(Ri), Uu = Ye(Wi), Bu = Ye(Yi), Fu = Ye(Ui), fe = Uo;
984
+ var Iu = vu, Nu = ve, Su = Kt, Tu = Nu(Su, "DataView"), ku = Tu, Cu = ve, bu = Kt, xu = Cu(bu, "Promise"), Lu = xu, zu = ve, Pu = Kt, Du = zu(Pu, "Set"), Yo = Du, Au = ve, ju = Kt, Eu = Au(ju, "WeakMap"), Ou = Eu, Oi = ku, Ri = Xi, Wi = Lu, Yi = Yo, Ui = Ou, Uo = we, Ye = Io, zs = "[object Map]", Ru = "[object Object]", Ps = "[object Promise]", Ds = "[object Set]", As = "[object WeakMap]", js = "[object DataView]", Wu = Ye(Oi), Yu = Ye(Ri), Uu = Ye(Wi), Bu = Ye(Yi), Fu = Ye(Ui), fe = Uo;
985
985
  (Oi && fe(new Oi(new ArrayBuffer(1))) != js || Ri && fe(new Ri()) != zs || Wi && fe(Wi.resolve()) != Ps || Yi && fe(new Yi()) != Ds || Ui && fe(new Ui()) != As) && (fe = function(a) {
986
986
  var i = Uo(a), t = i == Ru ? a.constructor : void 0, e = t ? Ye(t) : "";
987
987
  if (e)
@@ -1028,7 +1028,7 @@ function nd(a, i) {
1028
1028
  var t = i ? od(a.buffer) : a.buffer;
1029
1029
  return new a.constructor(t, a.byteOffset, a.length);
1030
1030
  }
1031
- var rd = nd, ad = os, cd = Ku, ld = ed, hd = sd, ud = rd, dd = "[object Boolean]", pd = "[object Date]", fd = "[object Map]", gd = "[object Number]", yd = "[object RegExp]", Md = "[object Set]", wd = "[object String]", md = "[object Symbol]", vd = "[object ArrayBuffer]", Id = "[object DataView]", Nd = "[object Float32Array]", Sd = "[object Float64Array]", Td = "[object Int8Array]", kd = "[object Int16Array]", Cd = "[object Int32Array]", bd = "[object Uint8Array]", xd = "[object Uint8ClampedArray]", Ld = "[object Uint16Array]", zd = "[object Uint32Array]";
1031
+ var rd = nd, ad = os, cd = Ku, ld = ed, hd = sd, ud = rd, dd = "[object Boolean]", pd = "[object Date]", fd = "[object Map]", gd = "[object Number]", yd = "[object RegExp]", Md = "[object Set]", md = "[object String]", wd = "[object Symbol]", vd = "[object ArrayBuffer]", Id = "[object DataView]", Nd = "[object Float32Array]", Sd = "[object Float64Array]", Td = "[object Int8Array]", kd = "[object Int16Array]", Cd = "[object Int32Array]", bd = "[object Uint8Array]", xd = "[object Uint8ClampedArray]", Ld = "[object Uint16Array]", zd = "[object Uint32Array]";
1032
1032
  function Pd(a, i, t) {
1033
1033
  var e = a.constructor;
1034
1034
  switch (i) {
@@ -1052,13 +1052,13 @@ function Pd(a, i, t) {
1052
1052
  case fd:
1053
1053
  return new e();
1054
1054
  case gd:
1055
- case wd:
1055
+ case md:
1056
1056
  return new e(a);
1057
1057
  case yd:
1058
1058
  return ld(a);
1059
1059
  case Md:
1060
1060
  return new e();
1061
- case md:
1061
+ case wd:
1062
1062
  return hd(a);
1063
1063
  }
1064
1064
  }
@@ -1088,7 +1088,7 @@ function _d(a) {
1088
1088
  }
1089
1089
  var tp = _d, ep = tp, ip = Ni, Fs = qi, $s = Fs && Fs.isSet, sp = $s ? ip($s) : ep, Fo = sp;
1090
1090
  const op = /* @__PURE__ */ je(Fo);
1091
- var np = So, rp = Pc, ap = Co, cp = mh, lp = Oh, hp = Rh, up = Yh, dp = Jh, pp = lu, fp = Wo, gp = Iu, yp = Si, Mp = Qu, wp = Dd, mp = Ud, vp = Ze, Ip = Ji, Np = Xd, Sp = de, Tp = Fo, kp = ts, Cp = es, bp = 1, xp = 2, Lp = 4, $o = "[object Arguments]", zp = "[object Array]", Pp = "[object Boolean]", Dp = "[object Date]", Ap = "[object Error]", Vo = "[object Function]", jp = "[object GeneratorFunction]", Ep = "[object Map]", Op = "[object Number]", Ho = "[object Object]", Rp = "[object RegExp]", Wp = "[object Set]", Yp = "[object String]", Up = "[object Symbol]", Bp = "[object WeakMap]", Fp = "[object ArrayBuffer]", $p = "[object DataView]", Vp = "[object Float32Array]", Hp = "[object Float64Array]", Qp = "[object Int8Array]", Gp = "[object Int16Array]", Zp = "[object Int32Array]", Xp = "[object Uint8Array]", Jp = "[object Uint8ClampedArray]", qp = "[object Uint16Array]", Kp = "[object Uint32Array]", vt = {};
1091
+ var np = So, rp = Pc, ap = Co, cp = wh, lp = Oh, hp = Rh, up = Yh, dp = Jh, pp = lu, fp = Wo, gp = Iu, yp = Si, Mp = Qu, mp = Dd, wp = Ud, vp = Ze, Ip = Ji, Np = Xd, Sp = de, Tp = Fo, kp = ts, Cp = es, bp = 1, xp = 2, Lp = 4, $o = "[object Arguments]", zp = "[object Array]", Pp = "[object Boolean]", Dp = "[object Date]", Ap = "[object Error]", Vo = "[object Function]", jp = "[object GeneratorFunction]", Ep = "[object Map]", Op = "[object Number]", Ho = "[object Object]", Rp = "[object RegExp]", Wp = "[object Set]", Yp = "[object String]", Up = "[object Symbol]", Bp = "[object WeakMap]", Fp = "[object ArrayBuffer]", $p = "[object DataView]", Vp = "[object Float32Array]", Hp = "[object Float64Array]", Qp = "[object Int8Array]", Gp = "[object Int16Array]", Zp = "[object Int32Array]", Xp = "[object Uint8Array]", Jp = "[object Uint8ClampedArray]", qp = "[object Uint16Array]", Kp = "[object Uint32Array]", vt = {};
1092
1092
  vt[$o] = vt[zp] = vt[Fp] = vt[$p] = vt[Pp] = vt[Dp] = vt[Vp] = vt[Hp] = vt[Qp] = vt[Gp] = vt[Zp] = vt[Ep] = vt[Op] = vt[Ho] = vt[Rp] = vt[Wp] = vt[Yp] = vt[Up] = vt[Xp] = vt[Jp] = vt[qp] = vt[Kp] = !0;
1093
1093
  vt[Ap] = vt[Vo] = vt[Bp] = !1;
1094
1094
  function ii(a, i, t, e, s, o) {
@@ -1106,12 +1106,12 @@ function ii(a, i, t, e, s, o) {
1106
1106
  if (Ip(a))
1107
1107
  return hp(a, r);
1108
1108
  if (u == Ho || u == $o || d && !s) {
1109
- if (n = c || d ? {} : mp(a), !r)
1109
+ if (n = c || d ? {} : wp(a), !r)
1110
1110
  return c ? pp(a, lp(n, a)) : dp(a, cp(n, a));
1111
1111
  } else {
1112
1112
  if (!vt[u])
1113
1113
  return s ? a : {};
1114
- n = wp(a, u, r);
1114
+ n = mp(a, u, r);
1115
1115
  }
1116
1116
  }
1117
1117
  o || (o = new np());
@@ -1133,7 +1133,7 @@ function of(a) {
1133
1133
  return tf(a, ef | sf);
1134
1134
  }
1135
1135
  var nf = of;
1136
- const Pt = /* @__PURE__ */ je(nf), Qo = "1.1.14-beta.2", rf = "@netless/appliance-plugin", ns = typeof OffscreenCanvas == "function" ? "worker" : "mainThread";
1136
+ const Pt = /* @__PURE__ */ je(nf), Qo = "1.1.15-beta.1", rf = "@netless/appliance-plugin", ns = typeof OffscreenCanvas == "function" ? "worker" : "mainThread";
1137
1137
  if (typeof window < "u") {
1138
1138
  let a = window.__netlessUA || "";
1139
1139
  a += ` ${rf}@${Qo}`, window.__netlessUA = a;
@@ -1248,7 +1248,6 @@ const jt = class jt {
1248
1248
  }
1249
1249
  }
1250
1250
  drawEraserlines(i) {
1251
- var C;
1252
1251
  const { group: t, eraserlines: e, pos: s, layer: o } = i, n = !!o.renderer.glRenderer, r = o.parent, c = o.parent.parent, l = o.getAttribute("scale"), h = o.getAttribute("translate"), u = this.createVmRenderNode(`${this.workId}_bitMapLayer`, c, {
1253
1252
  offscreen: r.offscreen,
1254
1253
  width: r.width,
@@ -1267,9 +1266,9 @@ const jt = class jt {
1267
1266
  y: Math.floor(p.y - jt.SafeBorderPadding),
1268
1267
  width: Math.floor(p.width + jt.SafeBorderPadding * 2),
1269
1268
  height: Math.floor(p.height + jt.SafeBorderPadding * 2)
1270
- }, v = g.options.displayRatio, m = Math.floor(M.x * v), S = Math.floor(M.y * v), T = Math.floor(M.width * v), N = Math.floor(M.height * v), w = this.isTransparentRectByCanvas(g.context, { x: m, y: S, w: T, h: N });
1271
- if (c.removeChild(f), w) {
1272
- this.isDelete = !0, console.log("isTransparent===>", this.workId, (C = this.vNodes) == null ? void 0 : C.curNodeMap.size);
1269
+ }, v = g.options.displayRatio, w = Math.floor(M.x * v), S = Math.floor(M.y * v), T = Math.floor(M.width * v), N = Math.floor(M.height * v), m = this.isTransparentRectByCanvas(g.context, { x: w, y: S, w: T, h: N });
1270
+ if (c.removeChild(f), m) {
1271
+ this.isDelete = !0;
1273
1272
  return;
1274
1273
  }
1275
1274
  this.addEraserlines(t, e, s, n);
@@ -1381,7 +1380,7 @@ const jt = class jt {
1381
1380
  s.remove(), s.disconnect();
1382
1381
  }
1383
1382
  static updateNodeOpt(i) {
1384
- var m;
1383
+ var w;
1385
1384
  const { node: t, opt: e, vNodes: s, willSerializeData: o, targetNode: n } = i, { zIndex: r, translate: c, angle: l, originPoint: h, scenePoint: u, scale: d, pointMap: f, thickness: g } = e;
1386
1385
  let p;
1387
1386
  const M = n && Pt(n) || s.get(t.name);
@@ -1394,9 +1393,9 @@ const jt = class jt {
1394
1393
  ps(M.op, u, d, c);
1395
1394
  const T = [M.op[0], M.op[1]], N = [T[0] - S[0], T[1] - S[1]];
1396
1395
  if (M.centerPos = [M.centerPos[0] + N[0], M.centerPos[1] + N[1]], M.opt.translate = void 0, M.opt.scale = void 0, M.opt.eraserlines)
1397
- for (const w of Object.values(M.opt.eraserlines)) {
1398
- const { op: C, thickness: L } = w;
1399
- w.thickness = L * Math.max(d[0], d[1]);
1396
+ for (const m of Object.values(M.opt.eraserlines)) {
1397
+ const { op: C, thickness: L } = m;
1398
+ m.thickness = L * Math.max(d[0], d[1]);
1400
1399
  for (let D = 0; D < C.length; D++)
1401
1400
  fs(C[D], u, d, c);
1402
1401
  }
@@ -1421,18 +1420,18 @@ const jt = class jt {
1421
1420
  for (let T = 0, N = 0; T < M.op.length; T += 3, N++)
1422
1421
  M.op[T] = S[N][0], M.op[T + 1] = S[N][1];
1423
1422
  }
1424
- if (g && ((m = M == null ? void 0 : M.opt) != null && m.thickness) && (M.opt.thickness = g), o && !(h && d && n)) {
1423
+ if (g && ((w = M == null ? void 0 : M.opt) != null && w.thickness) && (M.opt.thickness = g), o && !(h && d && n)) {
1425
1424
  if (c) {
1426
1425
  const S = M.op.map((T, N) => {
1427
- const w = N % 3;
1428
- return w === 0 ? T + c[0] : w === 1 ? T + c[1] : T;
1426
+ const m = N % 3;
1427
+ return m === 0 ? T + c[0] : m === 1 ? T + c[1] : T;
1429
1428
  });
1430
1429
  if (M.op = S, M.centerPos = [M.centerPos[0] + c[0], M.centerPos[1] + c[1]], M != null && M.opt && (M.opt.translate = void 0), M.opt.eraserlines)
1431
1430
  for (const T of Object.values(M.opt.eraserlines)) {
1432
1431
  const { op: N } = T;
1433
- for (let w = 0; w < N.length; w++) {
1434
- const C = N[w].map((L, D) => D % 2 ? L + c[1] : L + c[0]);
1435
- T.op[w] = C;
1432
+ for (let m = 0; m < N.length; m++) {
1433
+ const C = N[m].map((L, D) => D % 2 ? L + c[1] : L + c[0]);
1434
+ T.op[m] = C;
1436
1435
  }
1437
1436
  }
1438
1437
  } else if (Wt(l)) {
@@ -1440,8 +1439,8 @@ const jt = class jt {
1440
1439
  if (EM(S, M.centerPos, l), M.op = S, M != null && M.opt && (M.opt.rotate = void 0), M.opt.eraserlines)
1441
1440
  for (const T of Object.values(M.opt.eraserlines)) {
1442
1441
  const { op: N } = T;
1443
- for (let w = 0; w < N.length; w++)
1444
- OM(N[w], M.centerPos, l);
1442
+ for (let m = 0; m < N.length; m++)
1443
+ OM(N[m], M.centerPos, l);
1445
1444
  }
1446
1445
  }
1447
1446
  }
@@ -1525,8 +1524,8 @@ class Go extends W {
1525
1524
  let g, p = !1;
1526
1525
  const M = this.syncIndex;
1527
1526
  if (this.syncTimestamp === 0 && (this.syncTimestamp = Date.now()), h.length && (h[0].taskId - this.syncTimestamp > this.syncUnitTime && (p = !0, this.syncTimestamp = h[0].taskId, this.syncIndex = this.tmpPoints.length), o || n)) {
1528
- const m = s ? this.fullLayer : this.drawLayer || this.fullLayer;
1529
- g = this.draw({ attrs: f, tasks: h, effects: u, layer: m, removeDrawCount: c });
1527
+ const w = s ? this.fullLayer : this.drawLayer || this.fullLayer;
1528
+ g = this.draw({ attrs: f, tasks: h, effects: u, layer: w, removeDrawCount: c });
1530
1529
  }
1531
1530
  if (o)
1532
1531
  return d > 10 && this.tmpPoints.splice(0, d - 10), {
@@ -1535,8 +1534,8 @@ class Go extends W {
1535
1534
  dataType: U.Local
1536
1535
  };
1537
1536
  const v = [];
1538
- return this.tmpPoints.slice(M).forEach((m) => {
1539
- v.push(m.x, m.y, this.computRadius(m.z, this.workOptions.thickness));
1537
+ return this.tmpPoints.slice(M).forEach((w) => {
1538
+ v.push(w.x, w.y, this.computRadius(w.z, this.workOptions.thickness));
1540
1539
  }), {
1541
1540
  ...this.baseConsumeResult,
1542
1541
  type: x.DrawWork,
@@ -1633,14 +1632,14 @@ class Go extends W {
1633
1632
  }
1634
1633
  draw(t) {
1635
1634
  const { attrs: e, tasks: s, replaceId: o, effects: n, layer: r, removeDrawCount: c } = t, { strokeColor: l, strokeType: h, thickness: u, zIndex: d, scale: f, rotate: g, translate: p, eraserlines: M } = this.workOptions;
1636
- n != null && n.size && (n.forEach((w) => {
1635
+ n != null && n.size && (n.forEach((m) => {
1637
1636
  var C;
1638
- (C = r.getElementById(w + "")) == null || C.remove();
1637
+ (C = r.getElementById(m + "")) == null || C.remove();
1639
1638
  }), n.clear()), c && this.removeDrawCountNodes(r, c);
1640
1639
  let v;
1641
- const m = [], S = r.worldPosition, T = r.worldScaling;
1642
- for (let w = 0; w < s.length; w++) {
1643
- const { pos: C, points: L } = s[w], { ps: D, rect: A } = this.computDrawPoints(L);
1640
+ const w = [], S = r.worldPosition, T = r.worldScaling;
1641
+ for (let m = 0; m < s.length; m++) {
1642
+ const { pos: C, points: L } = s[m], { ps: D, rect: A } = this.computDrawPoints(L);
1644
1643
  let E;
1645
1644
  const O = L.length === 1;
1646
1645
  h === st.Stroke || O ? E = re(D, !0) : E = re(D, !1);
@@ -1658,24 +1657,24 @@ class Go extends W {
1658
1657
  y: Math.floor((A.y + C[1]) * T[1] + S[1] - W.SafeBorderPadding),
1659
1658
  w: Math.floor(A.w * T[0] + 2 * W.SafeBorderPadding),
1660
1659
  h: Math.floor(A.h * T[1] + 2 * W.SafeBorderPadding)
1661
- }), m.push(z);
1660
+ }), w.push(z);
1662
1661
  }
1663
1662
  f && (e.scale = f), g && (e.rotate = g), p && (e.translate = p);
1664
1663
  const N = new Yt();
1665
1664
  if (v) {
1666
1665
  this.centerPos = W.getCenterPos(v, r);
1667
- const w = h === st.Stroke && !M;
1666
+ const m = h === st.Stroke && !M;
1668
1667
  N.attr({
1669
1668
  ...e,
1670
1669
  normalize: !0,
1671
1670
  anchor: [0.5, 0.5],
1672
- bgcolor: w ? l : void 0,
1671
+ bgcolor: m ? l : void 0,
1673
1672
  pos: this.centerPos,
1674
1673
  size: [(v.w - 2 * W.SafeBorderPadding) / T[0], (v.h - 2 * W.SafeBorderPadding) / T[1]],
1675
1674
  zIndex: d
1676
1675
  });
1677
- const C = m.map((L) => (L.pos = [L.pos[0] - this.centerPos[0], L.pos[1] - this.centerPos[1]], new ce(L)));
1678
- N.append(...C), w && N.seal(), M && (this.scaleType = lt.proportional, this.drawEraserlines({
1676
+ const C = w.map((L) => (L.pos = [L.pos[0] - this.centerPos[0], L.pos[1] - this.centerPos[1]], new ce(L)));
1677
+ N.append(...C), m && N.seal(), M && (this.scaleType = lt.proportional, this.drawEraserlines({
1679
1678
  group: N,
1680
1679
  eraserlines: M,
1681
1680
  pos: this.centerPos,
@@ -1683,13 +1682,13 @@ class Go extends W {
1683
1682
  })), this.replace(r, o, N);
1684
1683
  }
1685
1684
  if (f || g || p) {
1686
- const w = N == null ? void 0 : N.getBoundingClientRect();
1687
- if (w)
1685
+ const m = N == null ? void 0 : N.getBoundingClientRect();
1686
+ if (m)
1688
1687
  return {
1689
- x: Math.floor(w.x - W.SafeBorderPadding),
1690
- y: Math.floor(w.y - W.SafeBorderPadding),
1691
- w: Math.floor(w.width + W.SafeBorderPadding * 2),
1692
- h: Math.floor(w.height + W.SafeBorderPadding * 2)
1688
+ x: Math.floor(m.x - W.SafeBorderPadding),
1689
+ y: Math.floor(m.y - W.SafeBorderPadding),
1690
+ w: Math.floor(m.width + W.SafeBorderPadding * 2),
1691
+ h: Math.floor(m.height + W.SafeBorderPadding * 2)
1693
1692
  };
1694
1693
  }
1695
1694
  return v;
@@ -1700,7 +1699,7 @@ class Go extends W {
1700
1699
  computNomal(t) {
1701
1700
  let e = this.workOptions.thickness;
1702
1701
  const s = t.map((o) => (e = Math.max(e, o.radius), o.point));
1703
- return { ps: s, rect: wt(s, e) };
1702
+ return { ps: s, rect: mt(s, e) };
1704
1703
  }
1705
1704
  computStroke(t) {
1706
1705
  return t.length === 1 ? this.computDotStroke(t[0]) : this.computLineStroke(t);
@@ -1715,7 +1714,7 @@ class Go extends W {
1715
1714
  e.push(F.Sub(h, f)), s.push(F.Add(h, f));
1716
1715
  }
1717
1716
  const o = t[t.length - 1], n = F.GetSemicircleStroke(o.point, e[e.length - 1], -1, 8), r = F.GetSemicircleStroke(t[0].point, s[0], -1, 8), c = e.concat(n, s.reverse(), r);
1718
- return { ps: c, rect: wt(c) };
1717
+ return { ps: c, rect: mt(c) };
1719
1718
  }
1720
1719
  computDotStroke(t) {
1721
1720
  const { point: e, radius: s } = t, o = { x: e.x - s, y: e.y - s, w: s * 2, h: s * 2 };
@@ -1753,12 +1752,12 @@ class Go extends W {
1753
1752
  }), o > 0 && o < t.length - 1) {
1754
1753
  const v = t[o].getAngleByPoints(t[o - 1], t[o + 1]);
1755
1754
  if (v < 60 || v > 300) {
1756
- const m = (u = l.pop()) == null ? void 0 : u.point.clone();
1757
- m && s.push({
1755
+ const w = (u = l.pop()) == null ? void 0 : u.point.clone();
1756
+ w && s.push({
1758
1757
  taskId: h,
1759
1758
  pos: c,
1760
1759
  points: [...l, {
1761
- point: m,
1760
+ point: w,
1762
1761
  radius: M
1763
1762
  }]
1764
1763
  }), n = t[o].x, r = t[o].y, c = [n, r];
@@ -1793,7 +1792,7 @@ class Go extends W {
1793
1792
  if (f.setz(Math.min(f.z + 1, this.MAX_REPEAR)), r = Math.min(r, d), h > 1) {
1794
1793
  let v = h - 1;
1795
1794
  for (; v > 0; ) {
1796
- const m = this.tmpPoints[v].distance(this.tmpPoints[v - 1]), S = Math.max(this.tmpPoints[v].z - this.uniThickness * m, 0);
1795
+ const w = this.tmpPoints[v].distance(this.tmpPoints[v - 1]), S = Math.max(this.tmpPoints[v].z - this.uniThickness * w, 0);
1797
1796
  if (this.tmpPoints[v - 1].z >= S)
1798
1797
  break;
1799
1798
  this.tmpPoints[v - 1].setz(S), r = Math.min(r, v - 1), v--;
@@ -1922,7 +1921,7 @@ class Zo extends W {
1922
1921
  return { type: x.None };
1923
1922
  if (this.updateTempPoints(n || []), this.consumeIndex > this.tmpPoints.length - 4)
1924
1923
  return { type: x.None };
1925
- const { strokeColor: r, thickness: c, strokeType: l } = this.workOptions, h = wt(this.tmpPoints, c);
1924
+ const { strokeColor: r, thickness: c, strokeType: l } = this.workOptions, h = mt(this.tmpPoints, c);
1926
1925
  let u = !1;
1927
1926
  const d = this.syncIndex, f = this.tmpPoints.slice(this.consumeIndex);
1928
1927
  this.consumeIndex = this.tmpPoints.length - 1, this.syncTimestamp === 0 && (this.syncTimestamp = Date.now());
@@ -1970,7 +1969,7 @@ class Zo extends W {
1970
1969
  });
1971
1970
  r = g.ps, e = g.rect;
1972
1971
  } else
1973
- e = wt(this.tmpPoints, h);
1972
+ e = mt(this.tmpPoints, h);
1974
1973
  const d = {
1975
1974
  name: t == null ? void 0 : t.toString(),
1976
1975
  fillColor: c ? l : void 0,
@@ -2009,7 +2008,7 @@ class Zo extends W {
2009
2008
  var p;
2010
2009
  const { op: e, replaceId: s, isFullWork: o } = t, { strokeColor: n, thickness: r, strokeType: c } = this.workOptions;
2011
2010
  if (!e.length) {
2012
- const M = wt(this.tmpPoints, r);
2011
+ const M = mt(this.tmpPoints, r);
2013
2012
  return {
2014
2013
  x: M.x * this.fullLayer.worldScaling[0] + this.fullLayer.worldPosition[0],
2015
2014
  y: M.y * this.fullLayer.worldScaling[1] + this.fullLayer.worldPosition[1],
@@ -2028,7 +2027,7 @@ class Zo extends W {
2028
2027
  });
2029
2028
  u = M.ps, h = M.rect;
2030
2029
  } else
2031
- h = wt(this.tmpPoints, r);
2030
+ h = mt(this.tmpPoints, r);
2032
2031
  const f = {
2033
2032
  name: (p = this.workId) == null ? void 0 : p.toString(),
2034
2033
  fillColor: d ? n : void 0,
@@ -2195,7 +2194,7 @@ const Ce = class Ce extends W {
2195
2194
  const d = new b(r[u] * this.worldScaling[0] + this.worldPosition[0], r[u + 1] * this.worldScaling[1] + this.worldPosition[1], r[u + 2]);
2196
2195
  l.push(d), c.push(new F(d.x, d.y));
2197
2196
  }
2198
- const h = c.length && wt(c) || n.rect;
2197
+ const h = c.length && mt(c) || n.rect;
2199
2198
  Qe(h, this.eraserRect) && (l.length > 1 ? Qi.polyline(l.map((d) => d.XY), this.eraserPolyline).length && s.add(n.name) : s.add(n.name), o = ht(o, n.rect || h));
2200
2199
  }
2201
2200
  return s.forEach((n) => {
@@ -2301,7 +2300,7 @@ var yf = gf;
2301
2300
  function Mf(a, i) {
2302
2301
  return a.has(i);
2303
2302
  }
2304
- var as = Mf, wf = rs, mf = yf, vf = as, If = 1, Nf = 2;
2303
+ var as = Mf, mf = rs, wf = yf, vf = as, If = 1, Nf = 2;
2305
2304
  function Sf(a, i, t, e, s, o) {
2306
2305
  var n = t & If, r = a.length, c = i.length;
2307
2306
  if (r != c && !(n && c > r))
@@ -2309,7 +2308,7 @@ function Sf(a, i, t, e, s, o) {
2309
2308
  var l = o.get(a), h = o.get(i);
2310
2309
  if (l && h)
2311
2310
  return l == i && h == a;
2312
- var u = -1, d = !0, f = t & Nf ? new wf() : void 0;
2311
+ var u = -1, d = !0, f = t & Nf ? new mf() : void 0;
2313
2312
  for (o.set(a, i), o.set(i, a); ++u < r; ) {
2314
2313
  var g = a[u], p = i[u];
2315
2314
  if (e)
@@ -2321,9 +2320,9 @@ function Sf(a, i, t, e, s, o) {
2321
2320
  break;
2322
2321
  }
2323
2322
  if (f) {
2324
- if (!mf(i, function(v, m) {
2325
- if (!vf(f, m) && (g === v || s(g, v, t, e, o)))
2326
- return f.push(m);
2323
+ if (!wf(i, function(v, w) {
2324
+ if (!vf(f, w) && (g === v || s(g, v, t, e, o)))
2325
+ return f.push(w);
2327
2326
  })) {
2328
2327
  d = !1;
2329
2328
  break;
@@ -2402,10 +2401,10 @@ function Xf(a, i, t, e, s, o) {
2402
2401
  o.set(a, i), o.set(i, a);
2403
2402
  for (var M = n; ++u < c; ) {
2404
2403
  d = r[u];
2405
- var v = a[d], m = i[d];
2404
+ var v = a[d], w = i[d];
2406
2405
  if (e)
2407
- var S = n ? e(m, v, d, i, a, o) : e(v, m, d, a, i, o);
2408
- if (!(S === void 0 ? v === m || s(v, m, t, e, o) : S)) {
2406
+ var S = n ? e(w, v, d, i, a, o) : e(v, w, d, a, i, o);
2407
+ if (!(S === void 0 ? v === w || s(v, w, t, e, o) : S)) {
2409
2408
  p = !1;
2410
2409
  break;
2411
2410
  }
@@ -2447,7 +2446,7 @@ function cg(a, i) {
2447
2446
  return ag(a, i);
2448
2447
  }
2449
2448
  var lg = cg;
2450
- const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2449
+ const me = /* @__PURE__ */ je(lg), gi = class gi extends W {
2451
2450
  constructor(t) {
2452
2451
  super(t);
2453
2452
  y(this, "toolsType", I.Selector);
@@ -2473,7 +2472,7 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2473
2472
  this.workOptions = t.toolsOpt, this.vNodes = t.vNodes;
2474
2473
  }
2475
2474
  computSelector(t = !0) {
2476
- const e = wt(this.tmpPoints);
2475
+ const e = mt(this.tmpPoints);
2477
2476
  if (e.w === 0 || e.h === 0)
2478
2477
  return {
2479
2478
  selectIds: [],
@@ -2572,7 +2571,7 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2572
2571
  return { type: x.None };
2573
2572
  this.updateTempPoints(e);
2574
2573
  const n = this.computSelector();
2575
- if (this.selectIds && we(this.selectIds, n.selectIds))
2574
+ if (this.selectIds && me(this.selectIds, n.selectIds))
2576
2575
  return { type: x.None };
2577
2576
  this.selectIds = n.selectIds;
2578
2577
  const r = n.intersectRect;
@@ -2657,7 +2656,7 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2657
2656
  }
2658
2657
  if (r) {
2659
2658
  const h = r.name;
2660
- if (!we(this.oldSelectRect, r.rect)) {
2659
+ if (!me(this.oldSelectRect, r.rect)) {
2661
2660
  const u = /* @__PURE__ */ new Map([[h, r]]);
2662
2661
  this.getSelecteorInfo(u), this.draw(e, this.fullLayer, {
2663
2662
  intersectRect: r.rect,
@@ -2713,7 +2712,7 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2713
2712
  let h;
2714
2713
  const u = /* @__PURE__ */ new Map(), { originPoint: d, workState: f, angle: g, translate: p, dir: M, scale: v } = e;
2715
2714
  c && (p ? e.translate = [p[0] + c[0], p[1] + c[1]] : e.translate = c);
2716
- let m;
2715
+ let w;
2717
2716
  if (d || p || Wt(g)) {
2718
2717
  if (f === P.Start && s)
2719
2718
  return o.setTargetAssignKeys(s), {
@@ -2722,20 +2721,20 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2722
2721
  selectRect: this.oldSelectRect,
2723
2722
  rect: this.oldSelectRect
2724
2723
  };
2725
- if (m = o.getLastTarget(), !m)
2724
+ if (w = o.getLastTarget(), !w)
2726
2725
  return;
2727
2726
  }
2728
2727
  if (s)
2729
- for (const w of s) {
2730
- const C = o.get(w);
2728
+ for (const m of s) {
2729
+ const C = o.get(m);
2731
2730
  if (C) {
2732
- const { toolsType: L, opt: D } = C, A = (l == null ? void 0 : l.getElementsByName(w))[0];
2731
+ const { toolsType: L, opt: D } = C, A = (l == null ? void 0 : l.getElementsByName(m))[0];
2733
2732
  if (A) {
2734
2733
  let E = !1, O = !1;
2735
2734
  const z = { ...e };
2736
2735
  let j;
2737
2736
  if (L) {
2738
- z.thickness && C.opt.thickness && (E = C.opt.thickness !== z.thickness), z.strokeType && ((N = C.opt) != null && N.strokeType) && (O = C.opt.strokeType !== z.strokeType), j = m == null ? void 0 : m.get(w);
2737
+ z.thickness && C.opt.thickness && (E = C.opt.thickness !== z.thickness), z.strokeType && ((N = C.opt) != null && N.strokeType) && (O = C.opt.strokeType !== z.strokeType), j = w == null ? void 0 : w.get(m);
2739
2738
  const tt = nn(L);
2740
2739
  if (tt == null || tt.updateNodeOpt({
2741
2740
  node: A,
@@ -2743,46 +2742,46 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2743
2742
  vNodes: o,
2744
2743
  willSerializeData: n,
2745
2744
  targetNode: j
2746
- }), C && r && (n && (z.angle || z.translate) || z.originPoint && z.scenePoint && z.scale || z.pointMap && z.pointMap.has(w) || L === I.Text && (z.fontSize || z.translate || z.textInfos && z.textInfos.get(w)) || L === I.Image && (z.angle || z.translate || z.scale || z.strokeColor && D.type === ze.Iconify) || L === z.toolsType && z.willRefresh || E || O)) {
2745
+ }), C && r && (n && (z.angle || z.translate) || z.originPoint && z.scenePoint && z.scale || z.pointMap && z.pointMap.has(m) || L === I.Text && (z.fontSize || z.translate || z.textInfos && z.textInfos.get(m)) || L === I.Image && (z.angle || z.translate || z.scale || z.strokeColor && D.type === ze.Iconify) || L === z.toolsType && z.willRefresh || E || O)) {
2747
2746
  const et = r.createWorkShapeNode({
2748
- workId: w,
2747
+ workId: m,
2749
2748
  toolsType: L,
2750
2749
  toolsOpt: C.opt
2751
2750
  });
2752
- et == null || et.setWorkId(w);
2751
+ et == null || et.setWorkId(m);
2753
2752
  let G;
2754
2753
  if (L === I.Image)
2755
2754
  G = await et.consumeServiceAsync({
2756
2755
  isFullWork: !0,
2757
- replaceId: w,
2756
+ replaceId: m,
2758
2757
  worker: r
2759
2758
  });
2760
2759
  else if (L === I.Text)
2761
2760
  G = await et.consumeServiceAsync({
2762
2761
  isFullWork: !0,
2763
- replaceId: w
2762
+ replaceId: m
2764
2763
  });
2765
2764
  else
2766
2765
  try {
2767
2766
  G = et == null ? void 0 : et.consumeService({
2768
2767
  op: C.op,
2769
2768
  isFullWork: !0,
2770
- replaceId: w
2769
+ replaceId: m
2771
2770
  });
2772
2771
  } catch {
2773
2772
  continue;
2774
2773
  }
2775
2774
  G && (C.rect = G);
2776
2775
  }
2777
- C && (u.set(w, C), h = ht(h, C.rect));
2776
+ C && (u.set(m, C), h = ht(h, C.rect));
2778
2777
  }
2779
2778
  }
2780
2779
  }
2781
2780
  }
2782
- m && f === P.Done && (o.deleteLastTarget(), m = void 0);
2781
+ w && f === P.Done && (o.deleteLastTarget(), w = void 0);
2783
2782
  const S = h;
2784
2783
  if (d && p && v && M && S && !c) {
2785
- const w = [
2784
+ const m = [
2786
2785
  [S.x, S.y],
2787
2786
  [S.x + S.w, S.y],
2788
2787
  [S.x + S.w, S.y + S.h],
@@ -2793,22 +2792,22 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2793
2792
  case "top":
2794
2793
  case "topLeft":
2795
2794
  case "left":
2796
- p[0] > 0 && p[1] > 0 ? C = w[0] : p[0] > 0 ? C = w[3] : p[1] > 0 ? C = w[1] : C = w[2];
2795
+ p[0] > 0 && p[1] > 0 ? C = m[0] : p[0] > 0 ? C = m[3] : p[1] > 0 ? C = m[1] : C = m[2];
2797
2796
  break;
2798
2797
  case "topRight":
2799
- p[0] < 0 && p[1] > 0 ? C = w[1] : p[0] < 0 ? C = w[2] : p[1] > 0 ? C = w[0] : C = w[3];
2798
+ p[0] < 0 && p[1] > 0 ? C = m[1] : p[0] < 0 ? C = m[2] : p[1] > 0 ? C = m[0] : C = m[3];
2800
2799
  break;
2801
2800
  case "right":
2802
2801
  case "bottomRight":
2803
2802
  case "bottom":
2804
- p[0] < 0 && p[1] < 0 ? C = w[2] : p[0] < 0 ? C = w[1] : p[1] < 0 ? C = w[3] : C = w[0];
2803
+ p[0] < 0 && p[1] < 0 ? C = m[2] : p[0] < 0 ? C = m[1] : p[1] < 0 ? C = m[3] : C = m[0];
2805
2804
  break;
2806
2805
  case "bottomLeft":
2807
- p[0] > 0 && p[1] < 0 ? C = w[3] : p[0] > 0 ? C = w[0] : p[1] < 0 ? C = w[2] : C = w[1];
2806
+ p[0] > 0 && p[1] < 0 ? C = m[3] : p[0] > 0 ? C = m[0] : p[1] < 0 ? C = m[2] : C = m[1];
2808
2807
  break;
2809
2808
  }
2810
2809
  const L = C && [d[0] - C[0], d[1] - C[1]] || [0, 0];
2811
- if (!we(L, [0, 0]))
2810
+ if (!me(L, [0, 0]))
2812
2811
  return await this.updateSelector({ ...t, updateSelectorOpt: {}, offset: L });
2813
2812
  }
2814
2813
  this.getSelecteorInfo(u), this.draw(H, l, {
@@ -2885,7 +2884,7 @@ const we = /* @__PURE__ */ je(lg), gi = class gi extends W {
2885
2884
  const e = this.oldSelectRect;
2886
2885
  this.selectIds = [];
2887
2886
  const s = (n = this.workId) == null ? void 0 : n.toString(), o = [t[0] * this.fullLayer.worldScaling[0] + this.fullLayer.worldPosition[0], t[1] * this.fullLayer.worldScaling[0] + this.fullLayer.worldPosition[1]];
2888
- if (this.selectSingleTool(o, s, !0), this.oldSelectRect && !we(e, this.oldSelectRect))
2887
+ if (this.selectSingleTool(o, s, !0), this.oldSelectRect && !me(e, this.oldSelectRect))
2889
2888
  return {
2890
2889
  type: x.CursorHover,
2891
2890
  dataType: U.Local,
@@ -2986,10 +2985,10 @@ class qo extends W {
2986
2985
  };
2987
2986
  }
2988
2987
  draw(t) {
2989
- const { workId: e, layer: s } = t, { strokeColor: o, thickness: n, zIndex: r, scale: c, rotate: l, translate: h, strokeType: u, eraserlines: d } = this.workOptions, f = s.worldPosition, g = s.worldScaling, { points: p, pos: M, rect: v, isTriangle: m, trianglePoints: S, trianglePos: T } = this.computDrawPoints(n), N = [
2988
+ const { workId: e, layer: s } = t, { strokeColor: o, thickness: n, zIndex: r, scale: c, rotate: l, translate: h, strokeType: u, eraserlines: d } = this.workOptions, f = s.worldPosition, g = s.worldScaling, { points: p, pos: M, rect: v, isTriangle: w, trianglePoints: S, trianglePos: T } = this.computDrawPoints(n), N = [
2990
2989
  v.x + v.w / 2,
2991
2990
  v.y + v.h / 2
2992
- ], w = {
2991
+ ], m = {
2993
2992
  pos: N,
2994
2993
  name: e,
2995
2994
  id: e,
@@ -2997,8 +2996,8 @@ class qo extends W {
2997
2996
  anchor: [0.5, 0.5],
2998
2997
  size: [v.w, v.h]
2999
2998
  };
3000
- c && (w.scale = c), l && (w.rotate = l), h && (w.translate = h);
3001
- const C = new Yt(w), L = {
2999
+ c && (m.scale = c), l && (m.rotate = l), h && (m.translate = h);
3000
+ const C = new Yt(m), L = {
3002
3001
  points: S,
3003
3002
  pos: [T[0] - N[0], T[1] - N[1]],
3004
3003
  fillColor: o,
@@ -3006,13 +3005,13 @@ class qo extends W {
3006
3005
  lineWidth: 0,
3007
3006
  normalize: !1
3008
3007
  }, D = new ue(L);
3009
- if (C.append(D), !m && p && M) {
3008
+ if (C.append(D), !w && p && M) {
3010
3009
  const A = {
3011
3010
  points: p,
3012
3011
  pos: [M[0] - N[0], M[1] - N[1]],
3013
3012
  fillColor: o,
3014
3013
  strokeColor: o,
3015
- lineDash: u === st.Dotted && !m ? [1, n * 2] : u === st.LongDotted && !m ? [n, n * 2] : void 0,
3014
+ lineDash: u === st.Dotted && !w ? [1, n * 2] : u === st.LongDotted && !w ? [n, n * 2] : void 0,
3016
3015
  lineCap: u === st.Normal ? void 0 : "round",
3017
3016
  lineWidth: n,
3018
3017
  normalize: !1
@@ -3049,7 +3048,7 @@ class qo extends W {
3049
3048
  trianglePoints: p.map((v) => F.Sub(v, this.tmpPoints[1]).XY).flat(1),
3050
3049
  trianglePos: this.tmpPoints[1].XY,
3051
3050
  points: g.map((v) => F.Sub(v, this.tmpPoints[0]).XY).flat(1),
3052
- rect: wt(M),
3051
+ rect: mt(M),
3053
3052
  isTriangle: !1,
3054
3053
  pos: this.tmpPoints[0].XY
3055
3054
  };
@@ -3059,7 +3058,7 @@ class qo extends W {
3059
3058
  return {
3060
3059
  trianglePoints: r.map((c) => F.Sub(c, this.tmpPoints[1]).XY).flat(1),
3061
3060
  trianglePos: this.tmpPoints[1].XY,
3062
- rect: wt(r),
3061
+ rect: mt(r),
3063
3062
  isTriangle: !0
3064
3063
  };
3065
3064
  }
@@ -3177,8 +3176,8 @@ class Ko extends W {
3177
3176
  };
3178
3177
  }
3179
3178
  draw(t) {
3180
- const { workId: e, layer: s, isDrawing: o } = t, { strokeColor: n, fillColor: r, thickness: c, zIndex: l, scale: h, rotate: u, translate: d, strokeType: f, eraserlines: g } = this.workOptions, p = s.worldScaling, { radius: M, rect: v, pos: m } = this.computDrawPoints(c), S = {
3181
- pos: m,
3179
+ const { workId: e, layer: s, isDrawing: o } = t, { strokeColor: n, fillColor: r, thickness: c, zIndex: l, scale: h, rotate: u, translate: d, strokeType: f, eraserlines: g } = this.workOptions, p = s.worldScaling, { radius: M, rect: v, pos: w } = this.computDrawPoints(c), S = {
3180
+ pos: w,
3182
3181
  name: e,
3183
3182
  id: e,
3184
3183
  radius: M,
@@ -3193,7 +3192,7 @@ class Ko extends W {
3193
3192
  name: e,
3194
3193
  id: e,
3195
3194
  zIndex: l,
3196
- pos: m,
3195
+ pos: w,
3197
3196
  anchor: [0.5, 0.5],
3198
3197
  size: [v.w, v.h]
3199
3198
  };
@@ -3210,14 +3209,14 @@ class Ko extends W {
3210
3209
  });
3211
3210
  N.append(L);
3212
3211
  }
3213
- const w = new vn({
3212
+ const m = new vn({
3214
3213
  ...S,
3215
3214
  pos: [0, 0]
3216
3215
  });
3217
- N.append(w), g && (this.scaleType = lt.proportional, this.drawEraserlines({
3216
+ N.append(m), g && (this.scaleType = lt.proportional, this.drawEraserlines({
3218
3217
  group: N,
3219
3218
  eraserlines: g,
3220
- pos: m,
3219
+ pos: w,
3221
3220
  layer: s
3222
3221
  })), this.replace(s, e, N);
3223
3222
  const C = N.getBoundingClientRect();
@@ -3229,7 +3228,7 @@ class Ko extends W {
3229
3228
  };
3230
3229
  }
3231
3230
  computDrawPoints(t) {
3232
- const e = wt(this.tmpPoints), s = wt(this.tmpPoints, t), o = [Math.floor(e.x + e.w / 2), Math.floor(e.y + e.h / 2)];
3231
+ const e = mt(this.tmpPoints), s = mt(this.tmpPoints, t), o = [Math.floor(e.x + e.w / 2), Math.floor(e.y + e.h / 2)];
3233
3232
  return {
3234
3233
  rect: s,
3235
3234
  pos: o,
@@ -3290,7 +3289,7 @@ class _o extends W {
3290
3289
  this.workOptions = t.toolsOpt, this.syncTimestamp = 0, this.syncUnitTime = 50;
3291
3290
  }
3292
3291
  transformData() {
3293
- const t = wt(this.tmpPoints);
3292
+ const t = mt(this.tmpPoints);
3294
3293
  return [
3295
3294
  [t.x, t.y, 0],
3296
3295
  [t.x + t.w, t.y, 0],
@@ -3302,7 +3301,7 @@ class _o extends W {
3302
3301
  const { thickness: e } = this.workOptions, s = [];
3303
3302
  for (const r of t)
3304
3303
  s.push(new b(...r));
3305
- const o = wt(s, e), n = [o.x + o.w / 2, o.y + o.h / 2];
3304
+ const o = mt(s, e), n = [o.x + o.w / 2, o.y + o.h / 2];
3306
3305
  return {
3307
3306
  rect: o,
3308
3307
  pos: n,
@@ -3370,7 +3369,7 @@ class _o extends W {
3370
3369
  };
3371
3370
  }
3372
3371
  draw(t) {
3373
- const { workId: e, layer: s, isDrawing: o, ps: n, replaceId: r } = t, { strokeColor: c, fillColor: l, thickness: h, zIndex: u, scale: d, rotate: f, translate: g, strokeType: p, eraserlines: M } = this.workOptions, v = s.worldPosition, m = s.worldScaling, { points: S, rect: T, pos: N } = this.computDrawPoints(n), w = {
3372
+ const { workId: e, layer: s, isDrawing: o, ps: n, replaceId: r } = t, { strokeColor: c, fillColor: l, thickness: h, zIndex: u, scale: d, rotate: f, translate: g, strokeType: p, eraserlines: M } = this.workOptions, v = s.worldPosition, w = s.worldScaling, { points: S, rect: T, pos: N } = this.computDrawPoints(n), m = {
3374
3373
  close: !0,
3375
3374
  normalize: !0,
3376
3375
  points: S,
@@ -3381,10 +3380,10 @@ class _o extends W {
3381
3380
  lineCap: "round",
3382
3381
  lineDash: p === st.Dotted ? [1, h * 2] : p === st.LongDotted ? [h, h * 2] : void 0
3383
3382
  }, C = {
3384
- x: Math.floor(T.x * m[0] + v[0] - W.SafeBorderPadding),
3385
- y: Math.floor(T.y * m[1] + v[1] - W.SafeBorderPadding),
3386
- w: Math.floor(T.w * m[0] + 2 * W.SafeBorderPadding),
3387
- h: Math.floor(T.h * m[0] + 2 * W.SafeBorderPadding)
3383
+ x: Math.floor(T.x * w[0] + v[0] - W.SafeBorderPadding),
3384
+ y: Math.floor(T.y * w[1] + v[1] - W.SafeBorderPadding),
3385
+ w: Math.floor(T.w * w[0] + 2 * W.SafeBorderPadding),
3386
+ h: Math.floor(T.h * w[0] + 2 * W.SafeBorderPadding)
3388
3387
  }, L = new Yt({
3389
3388
  name: e,
3390
3389
  id: e,
@@ -3399,7 +3398,7 @@ class _o extends W {
3399
3398
  rotate: f,
3400
3399
  translate: g
3401
3400
  }), D = new ue({
3402
- ...w,
3401
+ ...m,
3403
3402
  pos: [0, 0]
3404
3403
  });
3405
3404
  if (L.appendChild(D), o) {
@@ -3409,7 +3408,7 @@ class _o extends W {
3409
3408
  pos: [0, 0],
3410
3409
  strokeColor: c,
3411
3410
  lineWidth: 1,
3412
- scale: [1 / m[0], 1 / m[1]]
3411
+ scale: [1 / w[0], 1 / w[1]]
3413
3412
  });
3414
3413
  L.appendChild(A);
3415
3414
  }
@@ -3542,7 +3541,7 @@ class tn extends W {
3542
3541
  };
3543
3542
  }
3544
3543
  draw(t) {
3545
- const { workId: e, layer: s, isDrawing: o } = t, { strokeColor: n, fillColor: r, thickness: c, zIndex: l, vertices: h, innerVerticeStep: u, innerRatio: d, scale: f, rotate: g, translate: p, strokeType: M, eraserlines: v } = this.workOptions, m = s.worldScaling, { rect: S, pos: T, points: N } = this.computDrawPoints(c, h, u, d), w = {
3544
+ const { workId: e, layer: s, isDrawing: o } = t, { strokeColor: n, fillColor: r, thickness: c, zIndex: l, vertices: h, innerVerticeStep: u, innerRatio: d, scale: f, rotate: g, translate: p, strokeType: M, eraserlines: v } = this.workOptions, w = s.worldScaling, { rect: S, pos: T, points: N } = this.computDrawPoints(c, h, u, d), m = {
3546
3545
  close: !0,
3547
3546
  points: N,
3548
3547
  lineWidth: c,
@@ -3569,12 +3568,12 @@ class tn extends W {
3569
3568
  pos: [0, 0],
3570
3569
  strokeColor: n,
3571
3570
  lineWidth: 1,
3572
- scale: [1 / m[0], 1 / m[1]]
3571
+ scale: [1 / w[0], 1 / w[1]]
3573
3572
  });
3574
3573
  L.append(E);
3575
3574
  }
3576
3575
  const D = new ue({
3577
- ...w,
3576
+ ...m,
3578
3577
  pos: [0, 0]
3579
3578
  });
3580
3579
  L.append(D), v && (this.scaleType = lt.proportional, this.drawEraserlines({
@@ -3592,14 +3591,14 @@ class tn extends W {
3592
3591
  };
3593
3592
  }
3594
3593
  computDrawPoints(t, e, s, o) {
3595
- const n = wt(this.tmpPoints), r = [Math.floor(n.x + n.w / 2), Math.floor(n.y + n.h / 2)], c = dn(n.w, n.h), l = Math.floor(Math.min(n.w, n.h) / 2), h = o * l, u = [], d = 2 * Math.PI / e;
3594
+ const n = mt(this.tmpPoints), r = [Math.floor(n.x + n.w / 2), Math.floor(n.y + n.h / 2)], c = dn(n.w, n.h), l = Math.floor(Math.min(n.w, n.h) / 2), h = o * l, u = [], d = 2 * Math.PI / e;
3596
3595
  for (let g = 0; g < e; g++) {
3597
3596
  const p = g * d - 0.5 * Math.PI;
3598
3597
  let M, v;
3599
3598
  g % s === 1 ? (M = h * c[0] * Math.cos(p), v = h * c[1] * Math.sin(p)) : (M = l * c[0] * Math.cos(p), v = l * c[1] * Math.sin(p), u.push(M, v)), u.push(M, v);
3600
3599
  }
3601
3600
  return {
3602
- rect: wt(this.tmpPoints, t),
3601
+ rect: mt(this.tmpPoints, t),
3603
3602
  pos: r,
3604
3603
  points: u
3605
3604
  };
@@ -3717,7 +3716,7 @@ class en extends W {
3717
3716
  };
3718
3717
  }
3719
3718
  draw(t) {
3720
- const { workId: e, layer: s, isDrawing: o } = t, { strokeColor: n, fillColor: r, thickness: c, zIndex: l, vertices: h, scale: u, rotate: d, translate: f, strokeType: g, eraserlines: p } = this.workOptions, M = s.worldScaling, { rect: v, pos: m, points: S } = this.computDrawPoints(c, h), T = {
3719
+ const { workId: e, layer: s, isDrawing: o } = t, { strokeColor: n, fillColor: r, thickness: c, zIndex: l, vertices: h, scale: u, rotate: d, translate: f, strokeType: g, eraserlines: p } = this.workOptions, M = s.worldScaling, { rect: v, pos: w, points: S } = this.computDrawPoints(c, h), T = {
3721
3720
  close: !0,
3722
3721
  points: S,
3723
3722
  lineWidth: c,
@@ -3731,12 +3730,12 @@ class en extends W {
3731
3730
  name: e,
3732
3731
  id: e,
3733
3732
  zIndex: l,
3734
- pos: m,
3733
+ pos: w,
3735
3734
  anchor: [0.5, 0.5],
3736
3735
  size: [v.w, v.h]
3737
3736
  };
3738
3737
  u && (N.scale = u), d && (N.rotate = d), f && (N.translate = f);
3739
- const w = new Yt(N);
3738
+ const m = new Yt(N);
3740
3739
  if (o) {
3741
3740
  const D = new ce({
3742
3741
  d: "M-4,0H4M0,-4V4",
@@ -3746,19 +3745,19 @@ class en extends W {
3746
3745
  lineWidth: 1,
3747
3746
  scale: [1 / M[0], 1 / M[1]]
3748
3747
  });
3749
- w.append(D);
3748
+ m.append(D);
3750
3749
  }
3751
3750
  const C = new ue({
3752
3751
  ...T,
3753
3752
  pos: [0, 0]
3754
3753
  });
3755
- w.append(C), p && (this.scaleType = lt.proportional, this.drawEraserlines({
3756
- group: w,
3754
+ m.append(C), p && (this.scaleType = lt.proportional, this.drawEraserlines({
3755
+ group: m,
3757
3756
  eraserlines: p,
3758
- pos: m,
3757
+ pos: w,
3759
3758
  layer: s
3760
- })), this.replace(s, e, w);
3761
- const L = w.getBoundingClientRect();
3759
+ })), this.replace(s, e, m);
3760
+ const L = m.getBoundingClientRect();
3762
3761
  return {
3763
3762
  x: Math.floor(L.x - W.SafeBorderPadding),
3764
3763
  y: Math.floor(L.y - W.SafeBorderPadding),
@@ -3767,13 +3766,13 @@ class en extends W {
3767
3766
  };
3768
3767
  }
3769
3768
  computDrawPoints(t, e) {
3770
- const s = wt(this.tmpPoints), o = [Math.floor(s.x + s.w / 2), Math.floor(s.y + s.h / 2)], n = dn(s.w, s.h), r = Math.floor(Math.min(s.w, s.h) / 2), c = [], l = 2 * Math.PI / e;
3769
+ const s = mt(this.tmpPoints), o = [Math.floor(s.x + s.w / 2), Math.floor(s.y + s.h / 2)], n = dn(s.w, s.h), r = Math.floor(Math.min(s.w, s.h) / 2), c = [], l = 2 * Math.PI / e;
3771
3770
  for (let u = 0; u < e; u++) {
3772
3771
  const d = u * l - 0.5 * Math.PI, f = r * n[0] * Math.cos(d), g = r * n[1] * Math.sin(d);
3773
3772
  c.push(f, g);
3774
3773
  }
3775
3774
  return {
3776
- rect: wt(this.tmpPoints, t),
3775
+ rect: mt(this.tmpPoints, t),
3777
3776
  pos: o,
3778
3777
  points: c
3779
3778
  };
@@ -3958,7 +3957,7 @@ class sn extends W {
3958
3957
  };
3959
3958
  }
3960
3959
  draw(t) {
3961
- const { workId: e, layer: s } = t, { strokeColor: o, fillColor: n, thickness: r, zIndex: c, placement: l, scale: h, rotate: u, translate: d, strokeType: f, eraserlines: g } = this.workOptions, { rect: p, pos: M, points: v } = this.computDrawPoints(r, l), m = {
3960
+ const { workId: e, layer: s } = t, { strokeColor: o, fillColor: n, thickness: r, zIndex: c, placement: l, scale: h, rotate: u, translate: d, strokeType: f, eraserlines: g } = this.workOptions, { rect: p, pos: M, points: v } = this.computDrawPoints(r, l), w = {
3962
3961
  points: v.map((C) => C.XY),
3963
3962
  lineWidth: r,
3964
3963
  fillColor: n !== "transparent" && n || void 0,
@@ -3979,7 +3978,7 @@ class sn extends W {
3979
3978
  };
3980
3979
  h && (S.scale = h), u && (S.rotate = u), d && (S.translate = d);
3981
3980
  const T = new Yt(S), N = new ue({
3982
- ...m,
3981
+ ...w,
3983
3982
  pos: [0, 0]
3984
3983
  });
3985
3984
  T.append(N), g && (this.scaleType = lt.proportional, this.drawEraserlines({
@@ -3988,16 +3987,16 @@ class sn extends W {
3988
3987
  pos: M,
3989
3988
  layer: s
3990
3989
  })), this.replace(s, e, T);
3991
- const w = T.getBoundingClientRect();
3990
+ const m = T.getBoundingClientRect();
3992
3991
  return {
3993
- x: Math.floor(w.x - W.SafeBorderPadding),
3994
- y: Math.floor(w.y - W.SafeBorderPadding),
3995
- w: Math.floor(w.width + W.SafeBorderPadding * 2),
3996
- h: Math.floor(w.height + W.SafeBorderPadding * 2)
3992
+ x: Math.floor(m.x - W.SafeBorderPadding),
3993
+ y: Math.floor(m.y - W.SafeBorderPadding),
3994
+ w: Math.floor(m.width + W.SafeBorderPadding * 2),
3995
+ h: Math.floor(m.height + W.SafeBorderPadding * 2)
3997
3996
  };
3998
3997
  }
3999
3998
  transformControlPoints(t) {
4000
- const e = wt(this.tmpPoints);
3999
+ const e = mt(this.tmpPoints);
4001
4000
  switch (t) {
4002
4001
  case "bottom":
4003
4002
  case "bottomLeft":
@@ -4046,70 +4045,70 @@ class sn extends W {
4046
4045
  }
4047
4046
  }
4048
4047
  computDrawPoints(t, e) {
4049
- const s = wt(this.tmpPoints), o = this.transformControlPoints(e), n = Math.floor(s.w * 0.1), r = Math.floor(s.h * 0.1), c = [], l = b.Add(o[0], new b(0, r, 0)), h = b.Add(o[0], new b(n, 0, 0)), u = qt.getBezierPoints(10, l, o[0], h), d = b.Sub(o[1], new b(n, 0, 0)), f = b.Add(o[1], new b(0, r, 0)), g = qt.getBezierPoints(10, d, o[1], f), p = b.Sub(o[2], new b(0, r, 0)), M = b.Sub(o[2], new b(n, 0, 0)), v = qt.getBezierPoints(10, p, o[2], M), m = b.Add(o[3], new b(n, 0, 0)), S = b.Sub(o[3], new b(0, r, 0)), T = qt.getBezierPoints(10, m, o[3], S), N = n * (1 - this.ratio) * 10, w = r * (1 - this.ratio) * 10;
4048
+ const s = mt(this.tmpPoints), o = this.transformControlPoints(e), n = Math.floor(s.w * 0.1), r = Math.floor(s.h * 0.1), c = [], l = b.Add(o[0], new b(0, r, 0)), h = b.Add(o[0], new b(n, 0, 0)), u = qt.getBezierPoints(10, l, o[0], h), d = b.Sub(o[1], new b(n, 0, 0)), f = b.Add(o[1], new b(0, r, 0)), g = qt.getBezierPoints(10, d, o[1], f), p = b.Sub(o[2], new b(0, r, 0)), M = b.Sub(o[2], new b(n, 0, 0)), v = qt.getBezierPoints(10, p, o[2], M), w = b.Add(o[3], new b(n, 0, 0)), S = b.Sub(o[3], new b(0, r, 0)), T = qt.getBezierPoints(10, w, o[3], S), N = n * (1 - this.ratio) * 10, m = r * (1 - this.ratio) * 10;
4050
4049
  switch (e) {
4051
4050
  case "bottom": {
4052
- const D = b.Sub(o[2], new b(n * 5 - N / 2, 0, 0)), A = b.Sub(o[2], new b(n * 5, -w, 0)), E = b.Sub(o[2], new b(n * 5 + N / 2, 0, 0));
4051
+ const D = b.Sub(o[2], new b(n * 5 - N / 2, 0, 0)), A = b.Sub(o[2], new b(n * 5, -m, 0)), E = b.Sub(o[2], new b(n * 5 + N / 2, 0, 0));
4053
4052
  c.push(A, E, ...T, ...u, ...g, ...v, D);
4054
4053
  break;
4055
4054
  }
4056
4055
  case "bottomRight": {
4057
- const D = b.Sub(o[2], new b(n * 1.1, 0, 0)), A = b.Sub(o[2], new b(n * 1.1 + N / 2, -w, 0)), E = b.Sub(o[2], new b(n * 1.1 + N, 0, 0));
4056
+ const D = b.Sub(o[2], new b(n * 1.1, 0, 0)), A = b.Sub(o[2], new b(n * 1.1 + N / 2, -m, 0)), E = b.Sub(o[2], new b(n * 1.1 + N, 0, 0));
4058
4057
  c.push(A, E, ...T, ...u, ...g, ...v, D);
4059
4058
  break;
4060
4059
  }
4061
4060
  case "bottomLeft": {
4062
- const D = b.Add(o[3], new b(n * 1.1 + N, 0, 0)), A = b.Add(o[3], new b(n * 1.1 + N / 2, w, 0)), E = b.Add(o[3], new b(n * 1.1, 0, 0));
4061
+ const D = b.Add(o[3], new b(n * 1.1 + N, 0, 0)), A = b.Add(o[3], new b(n * 1.1 + N / 2, m, 0)), E = b.Add(o[3], new b(n * 1.1, 0, 0));
4063
4062
  c.push(A, E, ...T, ...u, ...g, ...v, D);
4064
4063
  break;
4065
4064
  }
4066
4065
  case "top": {
4067
- const D = b.Sub(o[1], new b(n * 5 - N / 2, 0, 0)), A = b.Sub(o[1], new b(n * 5, w, 0)), E = b.Sub(o[1], new b(n * 5 + N / 2, 0, 0));
4066
+ const D = b.Sub(o[1], new b(n * 5 - N / 2, 0, 0)), A = b.Sub(o[1], new b(n * 5, m, 0)), E = b.Sub(o[1], new b(n * 5 + N / 2, 0, 0));
4068
4067
  c.push(A, D, ...g, ...v, ...T, ...u, E);
4069
4068
  break;
4070
4069
  }
4071
4070
  case "topRight": {
4072
- const D = b.Sub(o[1], new b(n * 1.1, 0, 0)), A = b.Sub(o[1], new b(n * 1.1 + N / 2, w, 0)), E = b.Sub(o[1], new b(n * 1.1 + N, 0, 0));
4071
+ const D = b.Sub(o[1], new b(n * 1.1, 0, 0)), A = b.Sub(o[1], new b(n * 1.1 + N / 2, m, 0)), E = b.Sub(o[1], new b(n * 1.1 + N, 0, 0));
4073
4072
  c.push(A, D, ...g, ...v, ...T, ...u, E);
4074
4073
  break;
4075
4074
  }
4076
4075
  case "topLeft": {
4077
- const D = b.Add(o[0], new b(n * 1.1 + N, 0, 0)), A = b.Add(o[0], new b(n * 1.1 + N / 2, -w, 0)), E = b.Add(o[0], new b(n * 1.1, 0, 0));
4076
+ const D = b.Add(o[0], new b(n * 1.1 + N, 0, 0)), A = b.Add(o[0], new b(n * 1.1 + N / 2, -m, 0)), E = b.Add(o[0], new b(n * 1.1, 0, 0));
4078
4077
  c.push(A, D, ...g, ...v, ...T, ...u, E);
4079
4078
  break;
4080
4079
  }
4081
4080
  case "left": {
4082
- const D = b.Add(o[0], new b(0, r * 5 - w / 2, 0)), A = b.Add(o[0], new b(-N, r * 5, 0)), E = b.Add(o[0], new b(0, r * 5 + w / 2, 0));
4081
+ const D = b.Add(o[0], new b(0, r * 5 - m / 2, 0)), A = b.Add(o[0], new b(-N, r * 5, 0)), E = b.Add(o[0], new b(0, r * 5 + m / 2, 0));
4083
4082
  c.push(A, D, ...u, ...g, ...v, ...T, E);
4084
4083
  break;
4085
4084
  }
4086
4085
  case "leftTop": {
4087
- const D = b.Add(o[0], new b(0, r * 1.1, 0)), A = b.Add(o[0], new b(-N, r * 1.1 + w / 2, 0)), E = b.Add(o[0], new b(0, r * 1.1 + w, 0));
4086
+ const D = b.Add(o[0], new b(0, r * 1.1, 0)), A = b.Add(o[0], new b(-N, r * 1.1 + m / 2, 0)), E = b.Add(o[0], new b(0, r * 1.1 + m, 0));
4088
4087
  c.push(A, D, ...u, ...g, ...v, ...T, E);
4089
4088
  break;
4090
4089
  }
4091
4090
  case "leftBottom": {
4092
- const D = b.Sub(o[3], new b(0, r * 1.1 + w, 0)), A = b.Sub(o[3], new b(N, r * 1.1 + w / 2, 0)), E = b.Sub(o[3], new b(0, r * 1.1, 0));
4091
+ const D = b.Sub(o[3], new b(0, r * 1.1 + m, 0)), A = b.Sub(o[3], new b(N, r * 1.1 + m / 2, 0)), E = b.Sub(o[3], new b(0, r * 1.1, 0));
4093
4092
  c.push(A, D, ...u, ...g, ...v, ...T, E);
4094
4093
  break;
4095
4094
  }
4096
4095
  case "right": {
4097
- const D = b.Add(o[1], new b(0, r * 5 - w / 2, 0)), A = b.Add(o[1], new b(N, r * 5, 0)), E = b.Add(o[1], new b(0, r * 5 + w / 2, 0));
4096
+ const D = b.Add(o[1], new b(0, r * 5 - m / 2, 0)), A = b.Add(o[1], new b(N, r * 5, 0)), E = b.Add(o[1], new b(0, r * 5 + m / 2, 0));
4098
4097
  c.push(A, E, ...v, ...T, ...u, ...g, D);
4099
4098
  break;
4100
4099
  }
4101
4100
  case "rightTop": {
4102
- const D = b.Add(o[1], new b(0, r * 1.1, 0)), A = b.Add(o[1], new b(N, r * 1.1 + w / 2, 0)), E = b.Add(o[1], new b(0, r * 1.1 + w, 0));
4101
+ const D = b.Add(o[1], new b(0, r * 1.1, 0)), A = b.Add(o[1], new b(N, r * 1.1 + m / 2, 0)), E = b.Add(o[1], new b(0, r * 1.1 + m, 0));
4103
4102
  c.push(A, E, ...v, ...T, ...u, ...g, D);
4104
4103
  break;
4105
4104
  }
4106
4105
  case "rightBottom": {
4107
- const D = b.Sub(o[2], new b(0, r * 1.1 + w, 0)), A = b.Sub(o[2], new b(-N, r * 1.1 + w / 2, 0)), E = b.Sub(o[2], new b(0, r * 1.1, 0));
4106
+ const D = b.Sub(o[2], new b(0, r * 1.1 + m, 0)), A = b.Sub(o[2], new b(-N, r * 1.1 + m / 2, 0)), E = b.Sub(o[2], new b(0, r * 1.1, 0));
4108
4107
  c.push(A, E, ...v, ...T, ...u, ...g, D);
4109
4108
  break;
4110
4109
  }
4111
4110
  }
4112
- const C = wt(this.tmpPoints, t), L = [Math.floor(C.x + C.w / 2), Math.floor(C.y + C.h / 2)];
4111
+ const C = mt(this.tmpPoints, t), L = [Math.floor(C.x + C.w / 2), Math.floor(C.y + C.h / 2)];
4113
4112
  return {
4114
4113
  rect: C,
4115
4114
  pos: L,
@@ -4157,7 +4156,7 @@ class sn extends W {
4157
4156
  return e.tagName === "GROUP" && (f = e.children[0]), n && (f.setAttribute("strokeColor", n), d != null && d.strokeColor && (d.strokeColor = n)), r && (r === "transparent" ? f.setAttribute("fillColor", "rgba(0,0,0,0)") : f.setAttribute("fillColor", r), d != null && d.fillColor && (d.fillColor = r)), c === I.SpeechBalloon && l && (d.placement = l), h && (u != null && u.opt) && ((g = u.opt) != null && g.strokeType) && (u.opt.strokeType = h), u && o.setInfo(e.name, { ...u, opt: d }), W.updateNodeOpt(t);
4158
4157
  }
4159
4158
  }
4160
- var hg = me, ug = oe, dg = "[object Boolean]";
4159
+ var hg = we, ug = oe, dg = "[object Boolean]";
4161
4160
  function pg(a) {
4162
4161
  return a === !0 || a === !1 || ug(a) && hg(a) == dg;
4163
4162
  }
@@ -4236,11 +4235,11 @@ class on extends W {
4236
4235
  };
4237
4236
  }
4238
4237
  draw(t) {
4239
- const { workId: e, layer: s } = t, { strokeColor: o, thickness: n, zIndex: r, scale: c, rotate: l, translate: h, strokeType: u, eraserlines: d } = this.workOptions, f = s.worldPosition, g = s.worldScaling, { d: p, rect: M, isDot: v } = this.computDrawPoints(n, u), m = [
4238
+ const { workId: e, layer: s } = t, { strokeColor: o, thickness: n, zIndex: r, scale: c, rotate: l, translate: h, strokeType: u, eraserlines: d } = this.workOptions, f = s.worldPosition, g = s.worldScaling, { d: p, rect: M, isDot: v } = this.computDrawPoints(n, u), w = [
4240
4239
  M.x + M.w / 2,
4241
4240
  M.y + M.h / 2
4242
4241
  ], S = new Yt({
4243
- pos: m,
4242
+ pos: w,
4244
4243
  anchor: [0.5, 0.5],
4245
4244
  size: [M.w, M.h],
4246
4245
  name: e,
@@ -4262,7 +4261,7 @@ class on extends W {
4262
4261
  if (S.append(N), d && (this.scaleType = lt.proportional, this.drawEraserlines({
4263
4262
  group: S,
4264
4263
  eraserlines: d,
4265
- pos: m,
4264
+ pos: w,
4266
4265
  layer: s
4267
4266
  })), this.replace(s, e, S), l || c || h) {
4268
4267
  const C = N.getBoundingClientRect();
@@ -4288,7 +4287,7 @@ class on extends W {
4288
4287
  let f;
4289
4288
  return e !== st.Normal ? f = re(this.tmpPoints, !1) : f = re(d, !0), {
4290
4289
  d: f,
4291
- rect: wt(d),
4290
+ rect: mt(d),
4292
4291
  isDot: !1,
4293
4292
  pos: this.tmpPoints[0].XY
4294
4293
  };
@@ -4297,7 +4296,7 @@ class on extends W {
4297
4296
  const e = F.GetDotStroke(this.tmpPoints[0], t / 2, 8);
4298
4297
  return {
4299
4298
  d: re(e, !0),
4300
- rect: wt(e),
4299
+ rect: mt(e),
4301
4300
  isDot: !0,
4302
4301
  pos: this.tmpPoints[0].XY
4303
4302
  };
@@ -4451,13 +4450,13 @@ const he = class he extends W {
4451
4450
  }
4452
4451
  static async createLabels(t, e, s) {
4453
4452
  var E;
4454
- const o = [], { x: n, y: r } = s, { width: c, height: l } = (E = e.parent) == null ? void 0 : E.parent, h = Ie(t.text), u = h.length, { fontSize: d, lineHeight: f, bold: g, textAlign: p, italic: M, fontFamily: v, verticalAlign: m, fontColor: S, fontBgColor: T, underline: N, lineThrough: w } = t, C = he.getSafetySnippetRatio(e) || 1, L = Math.floor(d * C), D = he.getSafetySnippetFontLength(L);
4453
+ const o = [], { x: n, y: r } = s, { width: c, height: l } = (E = e.parent) == null ? void 0 : E.parent, h = Ie(t.text), u = h.length, { fontSize: d, lineHeight: f, bold: g, textAlign: p, italic: M, fontFamily: v, verticalAlign: w, fontColor: S, fontBgColor: T, underline: N, lineThrough: m } = t, C = he.getSafetySnippetRatio(e) || 1, L = Math.floor(d * C), D = he.getSafetySnippetFontLength(L);
4455
4454
  let A = 0;
4456
4455
  for (let O = 0; O < u; O++) {
4457
4456
  const z = h[O], j = f || L * 1.5;
4458
4457
  if (z) {
4459
4458
  const tt = $M(z), et = [0, 0], G = [0, d * 1.2];
4460
- m === "middle" && (et[1] = O * d * 1.2 + 5);
4459
+ w === "middle" && (et[1] = O * d * 1.2 + 5);
4461
4460
  const Q = [0, -d * 0.15];
4462
4461
  et[0] = 5;
4463
4462
  const V = Math.sin(Math.PI / 180 * 20);
@@ -4482,9 +4481,9 @@ const he = class he extends W {
4482
4481
  }, Z = new In(dt), $ = await Z.textImageReady;
4483
4482
  let pt = !0;
4484
4483
  if ($) {
4485
- const mt = $.rect && $.rect[2], $t = $.rect && $.rect[3];
4486
- if (mt && $t) {
4487
- const Tt = mt / C, St = $t / C;
4484
+ const wt = $.rect && $.rect[2], $t = $.rect && $.rect[3];
4485
+ if (wt && $t) {
4486
+ const Tt = wt / C, St = $t / C;
4488
4487
  it = Tt + it, M === "italic" && (g === "bold" ? it = it - V * d * 1.2 : it = it - V * d), ((Q[0] + et[0] + Tt) * e.worldScaling[0] + n <= 0 || (Q[0] + et[0]) * e.worldScaling[0] + n >= c || (Q[1] + et[1] + St) * e.worldScaling[1] + r <= 0 || (Q[1] + et[1]) * e.worldScaling[1] + r >= l) && (Z.disconnect(), pt = !1), pt && ct.push(Z);
4489
4488
  }
4490
4489
  }
@@ -4504,7 +4503,7 @@ const he = class he extends W {
4504
4503
  }, pt = new ue($);
4505
4504
  ct.push(pt);
4506
4505
  }
4507
- if (w) {
4506
+ if (m) {
4508
4507
  const Z = {
4509
4508
  normalize: !1,
4510
4509
  pos: [0, d * 1.2 / 2],
@@ -4540,25 +4539,25 @@ const he = class he extends W {
4540
4539
  lineThrough: p,
4541
4540
  underline: M,
4542
4541
  fontSize: v,
4543
- textInfos: m,
4542
+ textInfos: w,
4544
4543
  zIndex: S
4545
4544
  } = s, T = n && Pt(n) || o.get(e.name);
4546
4545
  if (!T || !e.parent) return;
4547
- const w = T.opt;
4548
- if (Wt(S) && (e.setAttribute("zIndex", S), T.opt.zIndex = S), c && w.fontColor && (w.fontColor = c, e.children.forEach((C) => {
4546
+ const m = T.opt;
4547
+ if (Wt(S) && (e.setAttribute("zIndex", S), T.opt.zIndex = S), c && m.fontColor && (m.fontColor = c, e.children.forEach((C) => {
4549
4548
  C.tagName === "GROUP" && C.children.forEach((L) => {
4550
4549
  L.tagName === "LABEL" ? (L.setAttribute("fillColor", c), L.setAttribute("strokeColor", c)) : L.tagName === "POLYLINE" && L.setAttribute("strokeColor", c);
4551
4550
  });
4552
- })), r && w.fontBgColor && (w.fontBgColor = r, e.children.forEach((C) => {
4551
+ })), r && m.fontBgColor && (m.fontBgColor = r, e.children.forEach((C) => {
4553
4552
  C.tagName === "GROUP" && C.setAttribute("bgcolor", r);
4554
- })), f && (w.bold = f), g && (w.italic = g), ke(p) && (w.lineThrough = p), ke(M) && (w.underline = M), v && (w.fontSize = v), h && u && d && n && w.boxPoint) {
4555
- const C = m == null ? void 0 : m.get(e.name);
4553
+ })), f && (m.bold = f), g && (m.italic = g), ke(p) && (m.lineThrough = p), ke(M) && (m.underline = M), v && (m.fontSize = v), h && u && d && n && m.boxPoint) {
4554
+ const C = w == null ? void 0 : w.get(e.name);
4556
4555
  if (C) {
4557
4556
  const { fontSize: E, boxSize: O } = C;
4558
- w.boxSize = O || w.boxSize, w.fontSize = E || w.fontSize;
4557
+ m.boxSize = O || m.boxSize, m.fontSize = E || m.fontSize;
4559
4558
  }
4560
- const L = [w.boxPoint[0], w.boxPoint[1]];
4561
- ps(w.boxPoint, u, d, l);
4559
+ const L = [m.boxPoint[0], m.boxPoint[1]];
4560
+ ps(m.boxPoint, u, d, l);
4562
4561
  const D = [T.op[0], T.op[1]], A = [D[0] - L[0], D[1] - L[1]];
4563
4562
  if (T.centerPos = [T.centerPos[0] + A[0], T.centerPos[1] + A[1]], T.opt.eraserlines)
4564
4563
  for (const E of Object.values(T.opt.eraserlines)) {
@@ -4567,7 +4566,7 @@ const he = class he extends W {
4567
4566
  for (let j = 0; j < O.length; j++)
4568
4567
  fs(O[j], u, d, l);
4569
4568
  }
4570
- } else if (l && w.boxPoint && (w.boxPoint = [w.boxPoint[0] + l[0], w.boxPoint[1] + l[1]], T.centerPos = [T.centerPos[0] + l[0], T.centerPos[1] + l[1]], T.opt.eraserlines))
4569
+ } else if (l && m.boxPoint && (m.boxPoint = [m.boxPoint[0] + l[0], m.boxPoint[1] + l[1]], T.centerPos = [T.centerPos[0] + l[0], T.centerPos[1] + l[1]], T.opt.eraserlines))
4571
4570
  for (const C of Object.values(T.opt.eraserlines)) {
4572
4571
  const { op: L } = C;
4573
4572
  for (let D = 0; D < L.length; D++) {
@@ -4665,8 +4664,8 @@ const be = class be extends W {
4665
4664
  if (f !== -1 && f > -1) {
4666
4665
  const g = [], p = d.slice(0, f + 1);
4667
4666
  if (b.Equals(d[f], l[0]) || p.push(l[0].clone().setz(d[f].z)), p.length > 1 && g.push(p), f + l.length - 1 < d.length - 1) {
4668
- const M = f + l.length - 1, v = d.slice(M), m = l[l.length - 1];
4669
- b.Equals(d[M], m) || v.unshift(m.clone().setz(d[M].z)), v.length > 1 && g.push(v);
4667
+ const M = f + l.length - 1, v = d.slice(M), w = l[l.length - 1];
4668
+ b.Equals(d[M], w) || v.unshift(w.clone().setz(d[M].z)), v.length > 1 && g.push(v);
4670
4669
  }
4671
4670
  return h.splice(u, 1, ...g), h;
4672
4671
  }
@@ -4707,15 +4706,15 @@ const be = class be extends W {
4707
4706
  const M = new b(l[p] * this.worldScaling[0] + this.worldPosition[0], l[p + 1] * this.worldScaling[1] + this.worldPosition[1], l[p + 2]);
4708
4707
  f.push(M), d.push(new F(M.x, M.y));
4709
4708
  }
4710
- const g = d.length && wt(d) || c.rect;
4709
+ const g = d.length && mt(d) || c.rect;
4711
4710
  if (Qe(g, this.eraserRect)) {
4712
4711
  if (f.length > 1) {
4713
4712
  const p = Qi.polyline(f.map((M) => M.XY), this.eraserPolyline);
4714
4713
  if (p.length && (s.add(c.name), !u)) {
4715
4714
  const M = this.translateIntersect(p), v = this.cutPolyline(M, f);
4716
- for (let m = 0; m < v.length; m++) {
4717
- const S = `${r}_s_${m}`, T = [];
4718
- v[m].forEach((N) => {
4715
+ for (let w = 0; w < v.length; w++) {
4716
+ const S = `${r}_s_${w}`, T = [];
4717
+ v[w].forEach((N) => {
4719
4718
  T.push((N.x - this.worldPosition[0]) / this.worldScaling[0], (N.y - this.worldPosition[1]) / this.worldScaling[1], N.z);
4720
4719
  }), c.opt && c.toolsType && this.vNodes && (this.vNodes.setInfo(S, {
4721
4720
  rect: g,
@@ -4888,7 +4887,7 @@ const xe = class xe extends W {
4888
4887
  if (!this.vNodes)
4889
4888
  return { willDeleteNodes: o, willUpdateNodes: s, rect: n };
4890
4889
  const r = this.worldPosition;
4891
- let c = wt(this.tmpPoints, t);
4890
+ let c = mt(this.tmpPoints, t);
4892
4891
  c = Fi(c, r), c = jM(c, this.worldScaling, r);
4893
4892
  const { nodeRange: l } = this.vNodes.getRectIntersectRange(c);
4894
4893
  if (!l.size)
@@ -4905,20 +4904,20 @@ const xe = class xe extends W {
4905
4904
  h: f.h / this.worldScaling[1]
4906
4905
  };
4907
4906
  const g = [f.x, f.y, f.x + f.w, f.y + f.h], p = [], M = [];
4908
- for (const m of h)
4909
- Qi.polyline(m, g, p);
4907
+ for (const w of h)
4908
+ Qi.polyline(w, g, p);
4910
4909
  if (p.length && d.opt)
4911
- for (const m of p) {
4910
+ for (const w of p) {
4912
4911
  const S = [];
4913
- for (let T = 0; T < m.length; T++)
4914
- T !== 0 && we(m[T], m[T - 1]) || S.push(...m[T]);
4912
+ for (let T = 0; T < w.length; T++)
4913
+ T !== 0 && me(w[T], w[T - 1]) || S.push(...w[T]);
4915
4914
  M.push(S);
4916
4915
  }
4917
4916
  if (d.opt.eraserlines || (d.opt.eraserlines = []), d.opt.eraserlines) {
4918
4917
  if (d.opt.eraserlines.push({ op: M, thickness: t }), e) {
4919
- const { toolsType: m } = d, S = e.createWorkShapeNode({
4918
+ const { toolsType: w } = d, S = e.createWorkShapeNode({
4920
4919
  workId: u,
4921
- toolsType: m,
4920
+ toolsType: w,
4922
4921
  toolsOpt: d.opt
4923
4922
  });
4924
4923
  S == null || S.setWorkId(u);
@@ -4951,16 +4950,16 @@ const xe = class xe extends W {
4951
4950
  ...this.baseConsumeResult
4952
4951
  };
4953
4952
  this.syncIndex = Math.min(this.syncIndex, M, Math.max(0, this.tmpPoints.length - 2));
4954
- const m = {
4953
+ const w = {
4955
4954
  name: this.workId,
4956
4955
  id: Wt(c) && c.toString() || void 0
4957
4956
  }, S = this.syncIndex;
4958
4957
  this.syncTimestamp === 0 && (this.syncTimestamp = Date.now());
4959
4958
  let T = !1, N;
4960
- const w = this.tmpPoints.slice(M);
4959
+ const m = this.tmpPoints.slice(M);
4961
4960
  if (o || n) {
4962
4961
  const L = s ? this.fullLayer : this.drawLayer || this.fullLayer;
4963
- N = this.draw({ attrs: m, consumePoints: w, layer: L, removeDrawCount: r, thickness: f });
4962
+ N = this.draw({ attrs: w, consumePoints: m, layer: L, removeDrawCount: r, thickness: f });
4964
4963
  }
4965
4964
  if (o)
4966
4965
  return M > 10 && this.tmpPoints.splice(0, M - 10), {
@@ -4968,7 +4967,7 @@ const xe = class xe extends W {
4968
4967
  type: x.DrawWork,
4969
4968
  dataType: U.Local
4970
4969
  };
4971
- w[0].t - this.syncTimestamp > this.syncUnitTime && (T = !0, this.syncTimestamp = w[0].t, this.syncIndex = this.tmpPoints.length);
4970
+ m[0].t - this.syncTimestamp > this.syncUnitTime && (T = !0, this.syncTimestamp = m[0].t, this.syncIndex = this.tmpPoints.length);
4972
4971
  const C = [];
4973
4972
  return this.tmpPoints.slice(S).forEach((L) => {
4974
4973
  C.push(L.x, L.y, f / 2);
@@ -4987,7 +4986,7 @@ const xe = class xe extends W {
4987
4986
  draw(t) {
4988
4987
  const { attrs: e, consumePoints: s, layer: o, thickness: n, replaceId: r, removeDrawCount: c } = t;
4989
4988
  c && this.removeDrawCountNodes(o, c);
4990
- let l = wt(s, n);
4989
+ let l = mt(s, n);
4991
4990
  l = {
4992
4991
  x: Math.floor(l.x * this.worldScaling[0] + this.worldPosition[0] - W.SafeBorderPadding),
4993
4992
  y: Math.floor(l.y * this.worldScaling[1] + this.worldPosition[1] - W.SafeBorderPadding),
@@ -5005,9 +5004,9 @@ const xe = class xe extends W {
5005
5004
  for (const f of u)
5006
5005
  d.push({ op: f, thickness: n });
5007
5006
  for (const f of d) {
5008
- const { thickness: g, op: p } = f, M = p.reduce((N, w, C, L) => C > 0 && L[C - 1][0] === w[0] && L[C - 1][1] === w[1] ? N : N.concat(w[0], w[1]), []), v = this.computEraserPoints(M, g), m = re(v, !0), S = {
5007
+ const { thickness: g, op: p } = f, M = p.reduce((N, m, C, L) => C > 0 && L[C - 1][0] === m[0] && L[C - 1][1] === m[1] ? N : N.concat(m[0], m[1]), []), v = this.computEraserPoints(M, g), w = re(v, !0), S = {
5009
5008
  pos: [0, 0],
5010
- d: m,
5009
+ d: w,
5011
5010
  fillColor: "rgba(136,136,136,0.3)"
5012
5011
  }, T = new ce(S);
5013
5012
  h.append(T), h.seal();
@@ -5152,7 +5151,7 @@ function rn(a) {
5152
5151
  }
5153
5152
  return i;
5154
5153
  }
5155
- const Qm = "cursorhover", hs = 20, Mt = "mainView";
5154
+ const Qw = "cursorhover", hs = 20, Mt = "mainView";
5156
5155
  class gg {
5157
5156
  constructor(i, t) {
5158
5157
  y(this, "viewId");
@@ -5452,8 +5451,8 @@ class yg {
5452
5451
  timer: void 0
5453
5452
  };
5454
5453
  v.timer && clearTimeout(v.timer), v.resolve = M, v.timer = setTimeout(() => {
5455
- const m = this.imageResolveMap.get(d);
5456
- m != null && m.resolve && m.resolve(d);
5454
+ const w = this.imageResolveMap.get(d);
5455
+ w != null && w.resolve && w.resolve(d);
5457
5456
  }, 5e3), this.imageResolveMap.set(d, v), this._post({
5458
5457
  sp: [{
5459
5458
  imageSrc: d,
@@ -5581,7 +5580,7 @@ class yg {
5581
5580
  for (const h of l.sp) {
5582
5581
  let u = !1;
5583
5582
  for (const d of t)
5584
- if (we(h, d)) {
5583
+ if (me(h, d)) {
5585
5584
  u = !0;
5586
5585
  break;
5587
5586
  }
@@ -5694,9 +5693,9 @@ class Mg {
5694
5693
  }
5695
5694
  }
5696
5695
  }
5697
- var wg = Kt, mg = function() {
5698
- return wg.Date.now();
5699
- }, vg = mg, Ig = /\s/;
5696
+ var mg = Kt, wg = function() {
5697
+ return mg.Date.now();
5698
+ }, vg = wg, Ig = /\s/;
5700
5699
  function Ng(a) {
5701
5700
  for (var i = a.length; i-- && Ig.test(a.charAt(i)); )
5702
5701
  ;
@@ -5706,7 +5705,7 @@ var Sg = Ng, Tg = Sg, kg = /^\s+/;
5706
5705
  function Cg(a) {
5707
5706
  return a && a.slice(0, Tg(a) + 1).replace(kg, "");
5708
5707
  }
5709
- var bg = Cg, xg = me, Lg = oe, zg = "[object Symbol]";
5708
+ var bg = Cg, xg = we, Lg = oe, zg = "[object Symbol]";
5710
5709
  function Pg(a) {
5711
5710
  return typeof a == "symbol" || Lg(a) && xg(a) == zg;
5712
5711
  }
@@ -5732,39 +5731,39 @@ function Hg(a, i, t) {
5732
5731
  if (typeof a != "function")
5733
5732
  throw new TypeError(Fg);
5734
5733
  i = so(i) || 0, Bg(t) && (h = !!t.leading, u = "maxWait" in t, o = u ? $g(so(t.maxWait) || 0, i) : o, d = "trailing" in t ? !!t.trailing : d);
5735
- function f(w) {
5734
+ function f(m) {
5736
5735
  var C = e, L = s;
5737
- return e = s = void 0, l = w, n = a.apply(L, C), n;
5736
+ return e = s = void 0, l = m, n = a.apply(L, C), n;
5738
5737
  }
5739
- function g(w) {
5740
- return l = w, r = setTimeout(v, i), h ? f(w) : n;
5738
+ function g(m) {
5739
+ return l = m, r = setTimeout(v, i), h ? f(m) : n;
5741
5740
  }
5742
- function p(w) {
5743
- var C = w - c, L = w - l, D = i - C;
5741
+ function p(m) {
5742
+ var C = m - c, L = m - l, D = i - C;
5744
5743
  return u ? Vg(D, o - L) : D;
5745
5744
  }
5746
- function M(w) {
5747
- var C = w - c, L = w - l;
5745
+ function M(m) {
5746
+ var C = m - c, L = m - l;
5748
5747
  return c === void 0 || C >= i || C < 0 || u && L >= o;
5749
5748
  }
5750
5749
  function v() {
5751
- var w = Pi();
5752
- if (M(w))
5753
- return m(w);
5754
- r = setTimeout(v, p(w));
5750
+ var m = Pi();
5751
+ if (M(m))
5752
+ return w(m);
5753
+ r = setTimeout(v, p(m));
5755
5754
  }
5756
- function m(w) {
5757
- return r = void 0, d && e ? f(w) : (e = s = void 0, n);
5755
+ function w(m) {
5756
+ return r = void 0, d && e ? f(m) : (e = s = void 0, n);
5758
5757
  }
5759
5758
  function S() {
5760
5759
  r !== void 0 && clearTimeout(r), l = 0, e = c = s = r = void 0;
5761
5760
  }
5762
5761
  function T() {
5763
- return r === void 0 ? n : m(Pi());
5762
+ return r === void 0 ? n : w(Pi());
5764
5763
  }
5765
5764
  function N() {
5766
- var w = Pi(), C = M(w);
5767
- if (e = arguments, s = this, c = w, C) {
5765
+ var m = Pi(), C = M(m);
5766
+ if (e = arguments, s = this, c = m, C) {
5768
5767
  if (r === void 0)
5769
5768
  return g(c);
5770
5769
  if (u)
@@ -5841,9 +5840,9 @@ function py(a) {
5841
5840
  return a.apply(void 0, arguments);
5842
5841
  };
5843
5842
  }
5844
- var fy = py, gy = ly, yy = fy, My = yy(gy), wy = My, my = an, vy = sy, Iy = wy;
5843
+ var fy = py, gy = ly, yy = fy, My = yy(gy), my = My, wy = an, vy = sy, Iy = my;
5845
5844
  function Ny(a, i) {
5846
- return Iy(vy(a, i, my), a + "");
5845
+ return Iy(vy(a, i, wy), a + "");
5847
5846
  }
5848
5847
  var Sy = Ny;
5849
5848
  function Ty(a, i, t, e) {
@@ -5945,15 +5944,15 @@ function yM(a, i, t) {
5945
5944
  }
5946
5945
  return r;
5947
5946
  }
5948
- var MM = yM, wM = Zy, mM = eM, co = MM;
5947
+ var MM = yM, mM = Zy, wM = eM, co = MM;
5949
5948
  function vM(a, i, t) {
5950
5949
  var e = a.length;
5951
5950
  if (e < 2)
5952
5951
  return e ? co(a[0]) : [];
5953
5952
  for (var s = -1, o = Array(e); ++s < e; )
5954
5953
  for (var n = a[s], r = -1; ++r < e; )
5955
- r != s && (o[s] = wM(o[s] || n, a[r], i, t));
5956
- return co(mM(o, 1), i, t);
5954
+ r != s && (o[s] = mM(o[s] || n, a[r], i, t));
5955
+ return co(wM(o, 1), i, t);
5957
5956
  }
5958
5957
  var IM = vM, NM = _i, SM = oe;
5959
5958
  function TM(a) {
@@ -6497,7 +6496,7 @@ class DM extends yg {
6497
6496
  }
6498
6497
  async updateCamera(t) {
6499
6498
  const e = [], { cameraOpt: s } = t;
6500
- if (s && !we(this.cameraOpt, s)) {
6499
+ if (s && !me(this.cameraOpt, s)) {
6501
6500
  const o = !!this.topLayerWork.localWorkShapes.size, n = !!this.localWork.getWorkShapes().size;
6502
6501
  if (n && this.localWork.workShapesDone(), this.setCameraOpt(s), n && e.push({
6503
6502
  isClearAll: !0,
@@ -6689,10 +6688,10 @@ class He extends W {
6689
6688
  const M = e.parent;
6690
6689
  if (M) {
6691
6690
  if (g && (p.opt.strokeColor = g), Wt(f) && (e.setAttribute("zIndex", f), p.opt.zIndex = f), ke(d) && (p.opt.locked = d), c && l && h && r) {
6692
- const { centerX: v, centerY: m, width: S, height: T, uniformScale: N } = p.opt, w = N !== !1 ? [h[0], h[0]] : h, C = [v, m], L = [v, m];
6693
- ps(L, l, w, r);
6691
+ const { centerX: v, centerY: w, width: S, height: T, uniformScale: N } = p.opt, m = N !== !1 ? [h[0], h[0]] : h, C = [v, w], L = [v, w];
6692
+ ps(L, l, m, r);
6694
6693
  const D = [L[0] - C[0], L[1] - C[1]];
6695
- if (p.centerPos = [p.centerPos[0] + D[0], p.centerPos[1] + D[1]], p.opt.width = Math.round(S * w[0]), p.opt.height = Math.round(T * w[1]), p.opt.centerX = L[0], p.opt.centerY = L[1], p.opt.eraserlines)
6694
+ if (p.centerPos = [p.centerPos[0] + D[0], p.centerPos[1] + D[1]], p.opt.width = Math.round(S * m[0]), p.opt.height = Math.round(T * m[1]), p.opt.centerX = L[0], p.opt.centerY = L[1], p.opt.eraserlines)
6696
6695
  for (const A of Object.values(p.opt.eraserlines)) {
6697
6696
  const { op: E, thickness: O } = A;
6698
6697
  A.thickness = O * Math.max(h[0], h[1]);
@@ -6702,9 +6701,9 @@ class He extends W {
6702
6701
  } else if (r) {
6703
6702
  if (p.opt.centerX = p.opt.centerX + r[0], p.opt.centerY = p.opt.centerY + r[1], p.centerPos = [p.centerPos[0] + r[0], p.centerPos[1] + r[1]], p.opt.eraserlines)
6704
6703
  for (const v of Object.values(p.opt.eraserlines)) {
6705
- const { op: m } = v;
6706
- for (let S = 0; S < m.length; S++) {
6707
- const T = m[S].map((N, w) => w % 2 ? N + r[1] : N + r[0]);
6704
+ const { op: w } = v;
6705
+ for (let S = 0; S < w.length; S++) {
6706
+ const T = w[S].map((N, m) => m % 2 ? N + r[1] : N + r[0]);
6708
6707
  v.op[S] = T;
6709
6708
  }
6710
6709
  }
@@ -6734,7 +6733,7 @@ function ds(a, i) {
6734
6733
  }
6735
6734
  return i || a;
6736
6735
  }
6737
- function wt(a, i = 0) {
6736
+ function mt(a, i = 0) {
6738
6737
  const t = { x: 0, y: 0, w: 0, h: 0 };
6739
6738
  let e = 1 / 0, s = 1 / 0, o = -1 / 0, n = -1 / 0;
6740
6739
  return a.forEach((r) => {
@@ -6767,11 +6766,11 @@ function AM(a, i) {
6767
6766
  }
6768
6767
  function un(a, i) {
6769
6768
  const t = AM(a, i);
6770
- return wt(t);
6769
+ return mt(t);
6771
6770
  }
6772
6771
  function jM(a, i, t) {
6773
6772
  const e = new b(a.x, a.y), s = new b(a.x + a.w, a.y), o = new b(a.x + a.w, a.y + a.h), n = new b(a.x, a.y + a.h), r = new b(t[0], t[1]), c = new b(i[0], i[1]), l = b.ScaleWOrigin(e, c, r), h = b.ScaleWOrigin(s, c, r), u = b.ScaleWOrigin(o, c, r), d = b.ScaleWOrigin(n, c, r);
6774
- return wt([l, h, u, d]);
6773
+ return mt([l, h, u, d]);
6775
6774
  }
6776
6775
  function EM(a, i, t) {
6777
6776
  const e = new b(i[0], i[1]);
@@ -6856,7 +6855,7 @@ const Gt = (a, i) => new Promise(function(t) {
6856
6855
  }), ae = (a) => {
6857
6856
  const i = (a == null ? void 0 : a.webkitBackingStorePixelRatio) || (a == null ? void 0 : a.mozBackingStorePixelRatio) || (a == null ? void 0 : a.msBackingStorePixelRatio) || (a == null ? void 0 : a.oBackingStorePixelRatio) || (a == null ? void 0 : a.backingStorePixelRatio) || 1;
6858
6857
  return Math.max(1, (window.devicePixelRatio || 1) / i);
6859
- }, Gm = (a, i) => a.x + a.w < i.x || a.x > i.x + i.w || a.y + a.h < i.y || a.y > i.y + i.h ? ei.outside : a.x >= i.x && a.y >= i.y && a.x + a.w <= i.x + i.w && a.y + a.h <= i.y + i.h ? ei.inside : ei.intersect;
6858
+ }, Gw = (a, i) => a.x + a.w < i.x || a.x > i.x + i.w || a.y + a.h < i.y || a.y > i.y + i.h ? ei.outside : a.x >= i.x && a.y >= i.y && a.x + a.w <= i.x + i.w && a.y + a.h <= i.y + i.h ? ei.inside : ei.intersect;
6860
6859
  function $M(a) {
6861
6860
  let i = 0;
6862
6861
  for (let t = 0; t < a.length; t++) {
@@ -6919,8 +6918,8 @@ const kt = class kt extends VM {
6919
6918
  const g = kt.componentsLimits.indexOf(o), p = g >= 0 && g < kt.componentsLimits.length - 1;
6920
6919
  if ((h = (l = (c = this.control.room) == null ? void 0 : c.callbacks) == null ? void 0 : l.listeners) != null && h.map.onObjectsLimit && ((d = (u = this.control.room) == null ? void 0 : u.callbacks) == null || d.dispatch("onObjectsLimit", (v) => v(o, p))), !p) {
6921
6920
  this.control.room.logger.error(`exceeds the limit of ${o} components, current: ${s}`), (f = this.control.room) == null || f.disconnect().then(() => {
6922
- var v, m, S, T, N;
6923
- (S = (m = (v = this.control.room) == null ? void 0 : v.callbacks) == null ? void 0 : m.listeners) != null && S.map.onKickedWithReason && ((N = (T = this.control.room) == null ? void 0 : T.callbacks) == null || N.dispatch("onKickedWithReason", (w) => w("kickByAdmin")));
6921
+ var v, w, S, T, N;
6922
+ (S = (w = (v = this.control.room) == null ? void 0 : v.callbacks) == null ? void 0 : w.listeners) != null && S.map.onKickedWithReason && ((N = (T = this.control.room) == null ? void 0 : T.callbacks) == null || N.dispatch("onKickedWithReason", (m) => m("kickByAdmin")));
6924
6923
  });
6925
6924
  return;
6926
6925
  }
@@ -7121,16 +7120,16 @@ const kt = class kt extends VM {
7121
7120
  break;
7122
7121
  case x.DrawWork:
7123
7122
  if (g && s && typeof n == "number" && (u != null && u.length)) {
7124
- const N = this.isLocalId(s.toString()) ? this.transformKey(s) : s, w = this.storage[p] && this.storage[p][g] && this.storage[p][g][N] || void 0;
7125
- if (w != null && w.ops || (w == null ? void 0 : w.type) === x.FullWork)
7123
+ const N = this.isLocalId(s.toString()) ? this.transformKey(s) : s, m = this.storage[p] && this.storage[p][g] && this.storage[p][g][N] || void 0;
7124
+ if (m != null && m.ops || (m == null ? void 0 : m.type) === x.FullWork)
7126
7125
  return;
7127
- const C = n ? ((w == null ? void 0 : w.op) || []).slice(0, n).concat(u) : u || (w == null ? void 0 : w.op), L = c || (w == null ? void 0 : w.toolsType), D = r || (w == null ? void 0 : w.opt), A = h || (w == null ? void 0 : w.updateNodeOpt);
7126
+ const C = n ? ((m == null ? void 0 : m.op) || []).slice(0, n).concat(u) : u || (m == null ? void 0 : m.op), L = c || (m == null ? void 0 : m.toolsType), D = r || (m == null ? void 0 : m.opt), A = h || (m == null ? void 0 : m.updateNodeOpt);
7128
7127
  s && L && D && C && (this.control.renderControl.isUsePageAuth(p) && this.control.renderControl.addRenderPageElementId({
7129
7128
  viewId: p,
7130
7129
  scenePath: g,
7131
7130
  elementId: N.toString()
7132
7131
  }), this.updateValue(N.toString(), {
7133
- ...w,
7132
+ ...m,
7134
7133
  type: x.DrawWork,
7135
7134
  workId: s,
7136
7135
  updateNodeOpt: A,
@@ -7143,7 +7142,7 @@ const kt = class kt extends VM {
7143
7142
  break;
7144
7143
  case x.FullWork:
7145
7144
  if (g && s) {
7146
- const N = this.isLocalId(s.toString()) ? this.transformKey(s) : s, w = this.storage[p] && this.storage[p][g] && this.storage[p][g][N] || void 0, C = h || (w == null ? void 0 : w.updateNodeOpt), L = c || (w == null ? void 0 : w.toolsType), D = r || (w == null ? void 0 : w.opt), A = o || (w == null ? void 0 : w.ops);
7145
+ const N = this.isLocalId(s.toString()) ? this.transformKey(s) : s, m = this.storage[p] && this.storage[p][g] && this.storage[p][g][N] || void 0, C = h || (m == null ? void 0 : m.updateNodeOpt), L = c || (m == null ? void 0 : m.toolsType), D = r || (m == null ? void 0 : m.opt), A = o || (m == null ? void 0 : m.ops);
7147
7146
  L && D && (this.control.renderControl.isUsePageAuth(p) && this.control.renderControl.addRenderPageElementId({
7148
7147
  viewId: p,
7149
7148
  scenePath: g,
@@ -7163,23 +7162,23 @@ const kt = class kt extends VM {
7163
7162
  break;
7164
7163
  case x.RemoveNode:
7165
7164
  if (g && (l != null && l.length)) {
7166
- const N = l.map((w) => this.isLocalId(w + "") ? this.transformKey(w) : w);
7167
- this.storage[p] && this.storage[p][g] && (Object.keys(this.storage[p][g]).map((w) => {
7168
- N != null && N.includes(w) && (this.control.renderControl.isUsePageAuth(p) && this.control.renderControl.delRenderPageElementId({
7165
+ const N = l.map((m) => this.isLocalId(m + "") ? this.transformKey(m) : m);
7166
+ this.storage[p] && this.storage[p][g] && (Object.keys(this.storage[p][g]).map((m) => {
7167
+ N != null && N.includes(m) && (this.control.renderControl.isUsePageAuth(p) && this.control.renderControl.delRenderPageElementId({
7169
7168
  viewId: p,
7170
7169
  scenePath: g,
7171
- elementId: w
7172
- }), this.updateValue(w, void 0, { isSync: f, viewId: p, scenePath: g }));
7170
+ elementId: m
7171
+ }), this.updateValue(m, void 0, { isSync: f, viewId: p, scenePath: g }));
7173
7172
  }), Gt(() => {
7174
- var w;
7175
- this.control.pluginManager.dispatchPluginEvent("syncStorage", p, g), (w = this.control.miniMapManager) == null || w.updateMiniMapCamera(p);
7173
+ var m;
7174
+ this.control.pluginManager.dispatchPluginEvent("syncStorage", p, g), (m = this.control.miniMapManager) == null || m.updateMiniMapCamera(p);
7176
7175
  }, kt.syncInterval));
7177
7176
  }
7178
7177
  break;
7179
7178
  case x.UpdateNode:
7180
7179
  if (g && s && (h || o || r)) {
7181
- const N = this.isLocalId(s.toString()) ? this.transformKey(s) : s, w = this.storage[p] && this.storage[p][g] && this.storage[p][g][N] || void 0;
7182
- w && (w.updateNodeOpt = h, (o || u) && (w.ops = o, w.op = u), r && (w.opt = r), w.type = x.FullWork, this.updateValue(N.toString(), w, { isSync: f, viewId: p, scenePath: g }), Gt(() => {
7180
+ const N = this.isLocalId(s.toString()) ? this.transformKey(s) : s, m = this.storage[p] && this.storage[p][g] && this.storage[p][g][N] || void 0;
7181
+ m && (m.updateNodeOpt = h, (o || u) && (m.ops = o, m.op = u), r && (m.opt = r), m.type = x.FullWork, this.updateValue(N.toString(), m, { isSync: f, viewId: p, scenePath: g }), Gt(() => {
7183
7182
  var C;
7184
7183
  (C = this.control.miniMapManager) == null || C.updateMiniMapCamera(p);
7185
7184
  }, kt.syncInterval));
@@ -7190,8 +7189,8 @@ const kt = class kt extends VM {
7190
7189
  return;
7191
7190
  let v;
7192
7191
  d != null && d.length && (v = d.map((N) => this.isLocalId(N + "") ? this.transformKey(N) : N));
7193
- const m = this.transformKey(H), S = this.storage[p] && this.storage[p][g] && this.storage[p][g][m] || void 0, T = r || (S == null ? void 0 : S.opt);
7194
- v && this.checkOtherSelector(m, v, { isSync: f, viewId: p, scenePath: g }), this.updateValue(m, v && {
7192
+ const w = this.transformKey(H), S = this.storage[p] && this.storage[p][g] && this.storage[p][g][w] || void 0, T = r || (S == null ? void 0 : S.opt);
7193
+ v && this.checkOtherSelector(w, v, { isSync: f, viewId: p, scenePath: g }), this.updateValue(w, v && {
7195
7194
  type: x.Select,
7196
7195
  toolsType: I.Selector,
7197
7196
  opt: T,
@@ -7315,7 +7314,7 @@ const kt = class kt extends VM {
7315
7314
  this.removeStorageStateListener(), this.serviceStorage = {}, this.storage = {}, this.removeAuthStateListener(), this.authStorage = {};
7316
7315
  }
7317
7316
  dispatchPageAuth(t, e = !0) {
7318
- var l, h, u, d, f, g, p, M, v, m, S, T, N, w, C, L, D, A, E, O, z, j, tt, et, G, Q, V, it, ct, J, ut, q, dt, Z, $, pt, mt, $t;
7317
+ var l, h, u, d, f, g, p, M, v, w, S, T, N, m, C, L, D, A, E, O, z, j, tt, et, G, Q, V, it, ct, J, ut, q, dt, Z, $, pt, wt, $t;
7319
7318
  const { operation: s, viewId: o, scenePath: n, pageId: r, pageData: c } = t;
7320
7319
  switch (s) {
7321
7320
  case Rt.addPage: {
@@ -7344,13 +7343,13 @@ const kt = class kt extends VM {
7344
7343
  case Rt.deletePage: {
7345
7344
  if (!o || !n || !r)
7346
7345
  return;
7347
- (S = (m = (v = (M = (p = this.authStorage) == null ? void 0 : p.pageAuth) == null ? void 0 : M[o]) == null ? void 0 : v[n]) == null ? void 0 : m.pages) != null && S[r] && (delete this.authStorage.pageAuth[o][n].pages[r], e && ((T = this.plugin) == null || T.updateAttributes([this.authSpace, "pageAuth", o, n, "pages", r], void 0)));
7346
+ (S = (w = (v = (M = (p = this.authStorage) == null ? void 0 : p.pageAuth) == null ? void 0 : M[o]) == null ? void 0 : v[n]) == null ? void 0 : w.pages) != null && S[r] && (delete this.authStorage.pageAuth[o][n].pages[r], e && ((T = this.plugin) == null || T.updateAttributes([this.authSpace, "pageAuth", o, n, "pages", r], void 0)));
7348
7347
  return;
7349
7348
  }
7350
7349
  case Rt.clearPage: {
7351
7350
  if (!o || !n || !r)
7352
7351
  return;
7353
- (D = (L = (C = (w = (N = this.authStorage) == null ? void 0 : N.pageAuth) == null ? void 0 : w[o]) == null ? void 0 : C[n]) == null ? void 0 : L.pages) != null && D[r] && (delete this.authStorage.pageAuth[o][n].pages[r], e && ((A = this.plugin) == null || A.updateAttributes([this.authSpace, "pageAuth", o, n, "pages", r], {})));
7352
+ (D = (L = (C = (m = (N = this.authStorage) == null ? void 0 : N.pageAuth) == null ? void 0 : m[o]) == null ? void 0 : C[n]) == null ? void 0 : L.pages) != null && D[r] && (delete this.authStorage.pageAuth[o][n].pages[r], e && ((A = this.plugin) == null || A.updateAttributes([this.authSpace, "pageAuth", o, n, "pages", r], {})));
7354
7353
  return;
7355
7354
  }
7356
7355
  case Rt.addElement: {
@@ -7374,13 +7373,13 @@ const kt = class kt extends VM {
7374
7373
  case Rt.clearView: {
7375
7374
  if (!o)
7376
7375
  return;
7377
- (mt = (pt = this.authStorage) == null ? void 0 : pt.pageAuth) != null && mt[o] && (delete this.authStorage.pageAuth[o], e && (($t = this.plugin) == null || $t.updateAttributes([this.authSpace, "pageAuth", o], void 0)));
7376
+ (wt = (pt = this.authStorage) == null ? void 0 : pt.pageAuth) != null && wt[o] && (delete this.authStorage.pageAuth[o], e && (($t = this.plugin) == null || $t.updateAttributes([this.authSpace, "pageAuth", o], void 0)));
7378
7377
  return;
7379
7378
  }
7380
7379
  }
7381
7380
  }
7382
7381
  dispatchRenderAuth(t, e = !0) {
7383
- var l, h, u, d, f, g, p, M, v, m, S, T, N, w, C, L, D, A, E, O;
7382
+ var l, h, u, d, f, g, p, M, v, w, S, T, N, m, C, L, D, A, E, O;
7384
7383
  const { operation: s, viewId: o, uid: n, renderData: r, isClear: c } = t;
7385
7384
  if (o)
7386
7385
  switch (s) {
@@ -7424,7 +7423,7 @@ const kt = class kt extends VM {
7424
7423
  const z = [this.authSpace];
7425
7424
  Object.keys(this.authStorage).length && z.push("renderAuth");
7426
7425
  const j = this.authStorage.renderAuth || {};
7427
- Object.keys(j).length && z.push(o), j[o] = j[o] || {}, this.authStorage.renderAuth = j, Object.keys(j[o]).length && z.push("render"), j[o].render = j[o].render || {}, j[o].render !== !0 && (Object.keys(j[o].render).length && z.push(n), j[o].render[n] = !0), j[o].hide !== !0 && ((f = j[o].hide) != null && f[n]) && (delete j[o].hide[n], e && ((g = this.plugin) == null || g.updateAttributes([this.authSpace, "renderAuth", o, "hide", n], void 0))), e && (z.length === 1 ? (p = this.plugin) == null || p.updateAttributes(z, gt(this.authStorage)) : z.length === 2 ? (M = this.plugin) == null || M.updateAttributes(z, gt(j)) : z.length === 3 ? (v = this.plugin) == null || v.updateAttributes(z, gt(j[o])) : (m = this.plugin) == null || m.updateAttributes(z, !0));
7426
+ Object.keys(j).length && z.push(o), j[o] = j[o] || {}, this.authStorage.renderAuth = j, Object.keys(j[o]).length && z.push("render"), j[o].render = j[o].render || {}, j[o].render !== !0 && (Object.keys(j[o].render).length && z.push(n), j[o].render[n] = !0), j[o].hide !== !0 && ((f = j[o].hide) != null && f[n]) && (delete j[o].hide[n], e && ((g = this.plugin) == null || g.updateAttributes([this.authSpace, "renderAuth", o, "hide", n], void 0))), e && (z.length === 1 ? (p = this.plugin) == null || p.updateAttributes(z, gt(this.authStorage)) : z.length === 2 ? (M = this.plugin) == null || M.updateAttributes(z, gt(j)) : z.length === 3 ? (v = this.plugin) == null || v.updateAttributes(z, gt(j[o])) : (w = this.plugin) == null || w.updateAttributes(z, !0));
7428
7427
  return;
7429
7428
  }
7430
7429
  case ee.setHide: {
@@ -7433,7 +7432,7 @@ const kt = class kt extends VM {
7433
7432
  const z = [this.authSpace];
7434
7433
  Object.keys(this.authStorage).length && z.push("renderAuth");
7435
7434
  const j = this.authStorage.renderAuth || {};
7436
- Object.keys(j).length && z.push(o), j[o] = j[o] || {}, this.authStorage.renderAuth = j, Object.keys(j[o]).length && z.push("hide"), j[o].hide = j[o].hide || {}, j[o].hide !== !0 && (Object.keys(j[o].hide).length && z.push(n), j[o].hide[n] = !0), j[o].render !== !0 && ((S = j[o].render) != null && S[n]) && (delete j[o].render[n], e && ((T = this.plugin) == null || T.updateAttributes([this.authSpace, "renderAuth", o, "render", n], void 0))), e && (z.length === 1 ? (N = this.plugin) == null || N.updateAttributes(z, gt(this.authStorage)) : z.length === 2 ? (w = this.plugin) == null || w.updateAttributes(z, gt(j)) : z.length === 3 ? (C = this.plugin) == null || C.updateAttributes(z, gt(j[o])) : (L = this.plugin) == null || L.updateAttributes(z, !0));
7435
+ Object.keys(j).length && z.push(o), j[o] = j[o] || {}, this.authStorage.renderAuth = j, Object.keys(j[o]).length && z.push("hide"), j[o].hide = j[o].hide || {}, j[o].hide !== !0 && (Object.keys(j[o].hide).length && z.push(n), j[o].hide[n] = !0), j[o].render !== !0 && ((S = j[o].render) != null && S[n]) && (delete j[o].render[n], e && ((T = this.plugin) == null || T.updateAttributes([this.authSpace, "renderAuth", o, "render", n], void 0))), e && (z.length === 1 ? (N = this.plugin) == null || N.updateAttributes(z, gt(this.authStorage)) : z.length === 2 ? (m = this.plugin) == null || m.updateAttributes(z, gt(j)) : z.length === 3 ? (C = this.plugin) == null || C.updateAttributes(z, gt(j[o])) : (L = this.plugin) == null || L.updateAttributes(z, !0));
7437
7436
  return;
7438
7437
  }
7439
7438
  case ee.setClear: {
@@ -7621,7 +7620,7 @@ class QM {
7621
7620
  get interceptors() {
7622
7621
  return {
7623
7622
  set: (i, t) => {
7624
- var f, g, p, M, v, m, S, T;
7623
+ var f, g, p, M, v, w, S, T;
7625
7624
  if (!this.collector)
7626
7625
  return !0;
7627
7626
  const { viewId: e, scenePath: s, canSync: o, canWorker: n, type: r, opt: c, dataType: l } = t;
@@ -7632,8 +7631,8 @@ class QM {
7632
7631
  workId: i,
7633
7632
  msgType: x.UpdateNode
7634
7633
  }).forEach((N) => {
7635
- var w;
7636
- (w = this.control.worker) == null || w.taskBatchData.delete(N);
7634
+ var m;
7635
+ (m = this.control.worker) == null || m.taskBatchData.delete(N);
7637
7636
  }), (S = this.control.worker) == null || S.taskBatchData.add({
7638
7637
  workId: i,
7639
7638
  msgType: x.UpdateNode,
@@ -7671,7 +7670,7 @@ class QM {
7671
7670
  viewId: e,
7672
7671
  scenePath: s,
7673
7672
  willRefresh: !0
7674
- }), (m = this.control.worker) == null || m.runAnimation()));
7673
+ }), (w = this.control.worker) == null || w.runAnimation()));
7675
7674
  },
7676
7675
  delete: (i) => {
7677
7676
  var r, c;
@@ -8188,17 +8187,17 @@ class ZM extends Xt {
8188
8187
  return;
8189
8188
  const u = Math.floor(Math.random() * 30 + 1), d = ((M = h.cameraOpt) == null ? void 0 : M.scale) || 1, f = e && s && [e[0] - s[0] + u, e[1] - s[1] + u] || [u / d, u / d], p = (this.serviceColloctor.isLocalId(n) ? n : this.serviceColloctor.getLocalId(n.toString())) + "-" + l;
8190
8189
  if (o.toolsType === I.Text && o.opt) {
8191
- const m = o.opt;
8192
- if (m && m.boxPoint && m.text) {
8193
- m.workState = P.Done;
8194
- const S = m.boxPoint;
8195
- m.boxPoint = [S[0] + f[0], S[1] + f[1]], m.workState = P.Done;
8196
- const T = this.control.viewContainerManager.transformToOriginPoint(m.boxPoint, r);
8190
+ const w = o.opt;
8191
+ if (w && w.boxPoint && w.text) {
8192
+ w.workState = P.Done;
8193
+ const S = w.boxPoint;
8194
+ w.boxPoint = [S[0] + f[0], S[1] + f[1]], w.workState = P.Done;
8195
+ const T = this.control.viewContainerManager.transformToOriginPoint(w.boxPoint, r);
8197
8196
  this.control.textEditorManager.createTextForMasterController({
8198
8197
  workId: p,
8199
8198
  x: T[0],
8200
8199
  y: T[1],
8201
- opt: m,
8200
+ opt: w,
8202
8201
  scale: ((v = h.cameraOpt) == null ? void 0 : v.scale) || 1,
8203
8202
  type: ie.Text,
8204
8203
  isActive: !1,
@@ -8206,7 +8205,7 @@ class ZM extends Xt {
8206
8205
  scenePath: c
8207
8206
  }), this.collectForServiceWorker([{
8208
8207
  ...o,
8209
- opt: m,
8208
+ opt: w,
8210
8209
  type: x.FullWork,
8211
8210
  workId: p,
8212
8211
  viewId: r,
@@ -8216,7 +8215,7 @@ class ZM extends Xt {
8216
8215
  }
8217
8216
  }
8218
8217
  copySelector(t) {
8219
- var p, M, v, m, S, T, N, w, C;
8218
+ var p, M, v, w, S, T, N, m, C;
8220
8219
  const { viewId: e, store: s } = t, o = this.control.viewContainerManager.getView(e), n = s.selectIds;
8221
8220
  if (!this.serviceColloctor || !(n != null && n.length) || !o)
8222
8221
  return;
@@ -8230,13 +8229,13 @@ class ZM extends Xt {
8230
8229
  centerY: ((M = o.cameraOpt) == null ? void 0 : M.centerY) || 0,
8231
8230
  scale: ((v = o.cameraOpt) == null ? void 0 : v.scale) || 1
8232
8231
  }
8233
- }, l = this.control.hasOffscreenCanvas() && ((m = o.displayer.canvasBgRef.current) == null ? void 0 : m.getBoundingClientRect()) || ((S = o.displayer.canvasContainerRef.current) == null ? void 0 : S.getBoundingClientRect()), h = (N = (T = o.displayer) == null ? void 0 : T.floatBarRef.current) == null ? void 0 : N.getBoundingClientRect(), u = l && [l.x + l.width / 2, l.y + l.height / 2], d = h && [h.x + h.width / 2, h.y + h.height / 2], f = u && o.viewData && o.viewData.convertToPointInWorld({ x: u[0], y: u[1] }), g = d && o.viewData && o.viewData.convertToPointInWorld({ x: d[0], y: d[1] });
8232
+ }, l = this.control.hasOffscreenCanvas() && ((w = o.displayer.canvasBgRef.current) == null ? void 0 : w.getBoundingClientRect()) || ((S = o.displayer.canvasContainerRef.current) == null ? void 0 : S.getBoundingClientRect()), h = (N = (T = o.displayer) == null ? void 0 : T.floatBarRef.current) == null ? void 0 : N.getBoundingClientRect(), u = l && [l.x + l.width / 2, l.y + l.height / 2], d = h && [h.x + h.width / 2, h.y + h.height / 2], f = u && o.viewData && o.viewData.convertToPointInWorld({ x: u[0], y: u[1] }), g = d && o.viewData && o.viewData.convertToPointInWorld({ x: d[0], y: d[1] });
8234
8233
  f && g && (c.offset = {
8235
8234
  x: f.x - g.x,
8236
8235
  y: f.y - g.y
8237
8236
  });
8238
8237
  for (const L of n) {
8239
- const D = (C = (w = this.serviceColloctor) == null ? void 0 : w.getStorageData(o.id, o.focusScenePath)) == null ? void 0 : C[L];
8238
+ const D = (C = (m = this.serviceColloctor) == null ? void 0 : m.getStorageData(o.id, o.focusScenePath)) == null ? void 0 : C[L];
8240
8239
  D && r.set(L, D);
8241
8240
  }
8242
8241
  return {
@@ -8250,20 +8249,20 @@ class ZM extends Xt {
8250
8249
  if (!e.size || !this.serviceColloctor || !c)
8251
8250
  return;
8252
8251
  const { offset: l, cameraOpt: h } = s, { scale: u } = h, d = Math.floor(Math.random() * 30 + 1), f = l && [l.x + d, l.y + d] || [d / u, d / u], g = [], p = [];
8253
- for (const [v, m] of e.entries()) {
8252
+ for (const [v, w] of e.entries()) {
8254
8253
  const T = (this.serviceColloctor.isLocalId(v) ? v : this.serviceColloctor.getLocalId(v.toString())) + "-" + r, N = { useAnimation: !1 };
8255
- if (m.toolsType === I.Text && m.opt) {
8256
- const w = m.opt;
8257
- if (w && w.boxPoint && w.text) {
8258
- w.workState = P.Done;
8259
- const C = w.boxPoint;
8260
- w.boxPoint = [C[0] + f[0], C[1] + f[1]], w.workState = P.Done;
8261
- const L = this.control.viewContainerManager.transformToOriginPoint(w.boxPoint, o);
8254
+ if (w.toolsType === I.Text && w.opt) {
8255
+ const m = w.opt;
8256
+ if (m && m.boxPoint && m.text) {
8257
+ m.workState = P.Done;
8258
+ const C = m.boxPoint;
8259
+ m.boxPoint = [C[0] + f[0], C[1] + f[1]], m.workState = P.Done;
8260
+ const L = this.control.viewContainerManager.transformToOriginPoint(m.boxPoint, o);
8262
8261
  this.control.textEditorManager.createTextForMasterController({
8263
8262
  workId: T,
8264
8263
  x: L[0],
8265
8264
  y: L[1],
8266
- opt: w,
8265
+ opt: m,
8267
8266
  scale: ((M = c.cameraOpt) == null ? void 0 : M.scale) || 1,
8268
8267
  type: ie.Text,
8269
8268
  isActive: !1,
@@ -8272,8 +8271,8 @@ class ZM extends Xt {
8272
8271
  });
8273
8272
  }
8274
8273
  p.push({
8275
- ...m,
8276
- opt: w,
8274
+ ...w,
8275
+ opt: m,
8277
8276
  type: x.FullWork,
8278
8277
  workId: T,
8279
8278
  viewId: o,
@@ -8281,22 +8280,22 @@ class ZM extends Xt {
8281
8280
  });
8282
8281
  continue;
8283
8282
  }
8284
- if (m.toolsType === I.Image && (m.opt.uuid = T, m.opt.centerX = m.opt.centerX + f[0], m.opt.centerY = m.opt.centerY + f[1]), m.ops) {
8285
- const w = Ie(m.ops).map((L, D) => {
8283
+ if (w.toolsType === I.Image && (w.opt.uuid = T, w.opt.centerX = w.opt.centerX + f[0], w.opt.centerY = w.opt.centerY + f[1]), w.ops) {
8284
+ const m = Ie(w.ops).map((L, D) => {
8286
8285
  const A = D % 3;
8287
8286
  return A === 0 ? L + f[0] : A === 1 ? L + f[1] : L;
8288
- }), C = Zt(w);
8289
- m.ops = C;
8287
+ }), C = Zt(m);
8288
+ w.ops = C;
8290
8289
  }
8291
8290
  p.push({
8292
- ...m,
8291
+ ...w,
8293
8292
  updateNodeOpt: N,
8294
8293
  type: x.FullWork,
8295
8294
  workId: T,
8296
8295
  viewId: o,
8297
8296
  scenePath: n
8298
8297
  }), g.push([{
8299
- ...m,
8298
+ ...w,
8300
8299
  updateNodeOpt: N,
8301
8300
  workId: T,
8302
8301
  msgType: x.FullWork,
@@ -8355,12 +8354,12 @@ class XM extends Xt {
8355
8354
  return;
8356
8355
  const f = d.focusScenePath, g = [...e], p = this.serviceColloctor.storage, M = [], v = {};
8357
8356
  for ((l === P.Start || !this.undoTickerId && l === P.Done) && (this.undoTickerId = Date.now(), this.mainEngine.internalMsgEmitter.emit("addUndoTicker", this.undoTickerId, c)); g.length; ) {
8358
- const m = g.pop();
8359
- if (!m)
8357
+ const w = g.pop();
8358
+ if (!w)
8360
8359
  continue;
8361
- const S = m.toString(), T = this.serviceColloctor.isLocalId(S), N = T ? this.serviceColloctor.transformKey(m) : S;
8362
- let w = S;
8363
- !T && this.serviceColloctor.isOwn(w) && (w = this.serviceColloctor.getLocalId(w));
8360
+ const S = w.toString(), T = this.serviceColloctor.isLocalId(S), N = T ? this.serviceColloctor.transformKey(w) : S;
8361
+ let m = S;
8362
+ !T && this.serviceColloctor.isOwn(m) && (m = this.serviceColloctor.getLocalId(m));
8364
8363
  const C = p[c][f][N] || void 0;
8365
8364
  if (C) {
8366
8365
  const L = C.updateNodeOpt || {};
@@ -8378,7 +8377,7 @@ class XM extends Xt {
8378
8377
  v.textBgColor = [A, E, O], v.textBgOpacity = z;
8379
8378
  }
8380
8379
  if (C.toolsType === I.Text && C.opt && l !== P.Start) {
8381
- this.setTextColor(w, Pt(C), L, c), l === P.Done && (this.undoTickerId = void 0);
8380
+ this.setTextColor(m, Pt(C), L, c), l === P.Done && (this.undoTickerId = void 0);
8382
8381
  continue;
8383
8382
  }
8384
8383
  }
@@ -8396,7 +8395,7 @@ class XM extends Xt {
8396
8395
  }
8397
8396
  h && (L.thickness = h, v.strokeWidth = h), u && (L.strokeType = u, v.strokeType = u);
8398
8397
  const D = {
8399
- workId: w,
8398
+ workId: m,
8400
8399
  msgType: x.UpdateNode,
8401
8400
  dataType: U.Local,
8402
8401
  updateNodeOpt: L,
@@ -8408,15 +8407,15 @@ class XM extends Xt {
8408
8407
  viewId: c
8409
8408
  };
8410
8409
  M.push([D, {
8411
- workId: w,
8410
+ workId: m,
8412
8411
  msgType: x.UpdateNode,
8413
8412
  emitEventType: this.emitEventType
8414
8413
  }]);
8415
8414
  }
8416
8415
  }
8417
8416
  M.length && (l === P.Done && (this.undoTickerId = void 0), this.collectForLocalWorker(M)), Object.keys(v).length && setTimeout(() => {
8418
- var m;
8419
- (m = this.control.room) == null || m.setMemberState(v);
8417
+ var w;
8418
+ (w = this.control.room) == null || w.setMemberState(v);
8420
8419
  }, 0);
8421
8420
  }
8422
8421
  }
@@ -8482,16 +8481,16 @@ class JM extends Xt {
8482
8481
  const g = f.toString(), p = this.serviceColloctor.isLocalId(g), M = p ? this.serviceColloctor.transformKey(f) : g;
8483
8482
  let v = g;
8484
8483
  !p && this.serviceColloctor.isOwn(v) && (v = this.serviceColloctor.getLocalId(v));
8485
- const m = Pt(l[o][r][M]);
8484
+ const w = Pt(l[o][r][M]);
8486
8485
  let S;
8487
- if (m && v === H) {
8488
- if (m.selectIds) {
8489
- u.push(...m.selectIds), u.sort((C, L) => {
8486
+ if (w && v === H) {
8487
+ if (w.selectIds) {
8488
+ u.push(...w.selectIds), u.sort((C, L) => {
8490
8489
  var E, O, z, j;
8491
8490
  const D = ((O = (E = l[d(C, this.serviceColloctor)]) == null ? void 0 : E.opt) == null ? void 0 : O.zIndex) || 0, A = ((j = (z = l[d(C, this.serviceColloctor)]) == null ? void 0 : z.opt) == null ? void 0 : j.zIndex) || 0;
8492
8491
  return D > A ? 1 : C < L ? -1 : 0;
8493
8492
  });
8494
- const T = m.updateNodeOpt || {};
8493
+ const T = w.updateNodeOpt || {};
8495
8494
  T.zIndexLayer = s;
8496
8495
  const N = {
8497
8496
  workId: f,
@@ -8502,17 +8501,17 @@ class JM extends Xt {
8502
8501
  willRefreshSelector: !0,
8503
8502
  willSyncService: !0,
8504
8503
  viewId: o
8505
- }, w = /* @__PURE__ */ new Map();
8504
+ }, m = /* @__PURE__ */ new Map();
8506
8505
  s === si.Top ? (this.addMaxLayer(o), S = this.getMaxZIndex(o)) : (this.addMinLayer(o), S = this.getMinZIndex(o)), u.forEach((C) => {
8507
8506
  var E, O, z;
8508
8507
  const L = (E = this.serviceColloctor) == null ? void 0 : E.isLocalId(C);
8509
8508
  let D = L && ((O = this.serviceColloctor) == null ? void 0 : O.transformKey(C)) || C;
8510
8509
  const A = l[o][r][D];
8511
- !L && ((z = this.serviceColloctor) != null && z.isOwn(D)) && (D = this.serviceColloctor.getLocalId(D)), T.zIndex = S, A != null && A.opt && (A.opt.zIndex = S), A != null && A.opt && w.set(D, {
8510
+ !L && ((z = this.serviceColloctor) != null && z.isOwn(D)) && (D = this.serviceColloctor.getLocalId(D)), T.zIndex = S, A != null && A.opt && (A.opt.zIndex = S), A != null && A.opt && m.set(D, {
8512
8511
  updateNodeOpt: A.updateNodeOpt,
8513
8512
  opt: A.opt
8514
8513
  });
8515
- }), N.selectStore = w, N.willSerializeData = !0, h.push([N, {
8514
+ }), N.selectStore = m, N.willSerializeData = !0, h.push([N, {
8516
8515
  workId: f,
8517
8516
  msgType: x.UpdateNode,
8518
8517
  emitEventType: this.emitEventType
@@ -8547,21 +8546,21 @@ class qM extends Xt {
8547
8546
  for (f && this.mainEngine.internalMsgEmitter.emit("addUndoTicker", f, r); h.length; ) {
8548
8547
  const p = h.pop();
8549
8548
  if (!p) continue;
8550
- const M = p.toString(), v = this.serviceColloctor.isLocalId(M), m = v && this.serviceColloctor.transformKey(p) || M;
8549
+ const M = p.toString(), v = this.serviceColloctor.isLocalId(M), w = v && this.serviceColloctor.transformKey(p) || M;
8551
8550
  let S = M;
8552
8551
  !v && this.serviceColloctor.isOwn(S) && (S = this.serviceColloctor.getLocalId(S));
8553
- const T = u[r][l][m];
8552
+ const T = u[r][l][w];
8554
8553
  if (T && S === H) {
8555
8554
  if (T.selectIds) {
8556
8555
  const N = this.control.viewContainerManager.transformToScenePoint([o.x, o.y], r);
8557
8556
  if (n === P.Start && (this.cachePosition = N), this.cachePosition) {
8558
- const w = T.updateNodeOpt || {};
8559
- w.translate = [N[0] - this.cachePosition[0], N[1] - this.cachePosition[1]], w.workState = n;
8557
+ const m = T.updateNodeOpt || {};
8558
+ m.translate = [N[0] - this.cachePosition[0], N[1] - this.cachePosition[1]], m.workState = n;
8560
8559
  const C = {
8561
8560
  workId: p,
8562
8561
  msgType: x.UpdateNode,
8563
8562
  dataType: U.Local,
8564
- updateNodeOpt: w,
8563
+ updateNodeOpt: m,
8565
8564
  emitEventType: this.emitEventType,
8566
8565
  willSyncService: !0,
8567
8566
  textUpdateForWoker: !0,
@@ -8638,7 +8637,7 @@ class _M extends Xt {
8638
8637
  return { key: t, textInfo: o };
8639
8638
  }
8640
8639
  async collect(t, e) {
8641
- var m, S, T, N, w;
8640
+ var w, S, T, N, m;
8642
8641
  if (!this.serviceColloctor || !this.mainEngine)
8643
8642
  return;
8644
8643
  const { workIds: s, workState: o, viewId: n, originPoint: r, scenePoint: c, dir: l, scale: h, translate: u } = t;
@@ -8646,7 +8645,7 @@ class _M extends Xt {
8646
8645
  const d = this.control.viewContainerManager.getView(n);
8647
8646
  if (!(d != null && d.displayer))
8648
8647
  return;
8649
- const f = d.focusScenePath, g = [...s], p = (m = this.serviceColloctor) == null ? void 0 : m.storage, M = [], v = o === P.Start && Date.now() || void 0;
8648
+ const f = d.focusScenePath, g = [...s], p = (w = this.serviceColloctor) == null ? void 0 : w.storage, M = [], v = o === P.Start && Date.now() || void 0;
8650
8649
  for (v && this.mainEngine.internalMsgEmitter.emit("addUndoTicker", v, n); g.length; ) {
8651
8650
  const C = g.pop();
8652
8651
  if (!C)
@@ -8670,7 +8669,7 @@ class _M extends Xt {
8670
8669
  if (this.targetText.size && o !== P.Start && h) {
8671
8670
  const tt = [];
8672
8671
  for (const [G, Q] of this.targetText.entries()) {
8673
- const { opt: V } = Q, it = Math.floor(V.fontSize * h[0]), ct = this.cacheTextInfo.get(G), J = !ct && V.fontSize !== it || ct && ct.fontSize !== it || !1, ut = (w = this.control.textEditorManager.get(G)) == null ? void 0 : w.opt;
8672
+ const { opt: V } = Q, it = Math.floor(V.fontSize * h[0]), ct = this.cacheTextInfo.get(G), J = !ct && V.fontSize !== it || ct && ct.fontSize !== it || !1, ut = (m = this.control.textEditorManager.get(G)) == null ? void 0 : m.opt;
8674
8673
  if (J && ut && V.boxSize && V.boxPoint) {
8675
8674
  const q = this.setTextStyle(G, { ...ut, fontSize: it }, n);
8676
8675
  tt.push(q);
@@ -8832,7 +8831,7 @@ class _M extends Xt {
8832
8831
  // }
8833
8832
  // }
8834
8833
  }
8835
- class tw extends Xt {
8834
+ class tm extends Xt {
8836
8835
  constructor() {
8837
8836
  super(...arguments);
8838
8837
  y(this, "lastEmtData");
@@ -8840,7 +8839,7 @@ class tw extends Xt {
8840
8839
  y(this, "cacheOriginRotate", 0);
8841
8840
  }
8842
8841
  collect(t, e) {
8843
- var g, p, M, v, m;
8842
+ var g, p, M, v, w;
8844
8843
  if (!this.serviceColloctor || !this.mainEngine)
8845
8844
  return;
8846
8845
  const { workIds: s, angle: o, workState: n, viewId: r } = t;
@@ -8853,16 +8852,16 @@ class tw extends Xt {
8853
8852
  const S = h.pop();
8854
8853
  if (!S)
8855
8854
  continue;
8856
- const T = S.toString(), N = this.serviceColloctor.isLocalId(T), w = N && this.serviceColloctor.transformKey(S) || T;
8855
+ const T = S.toString(), N = this.serviceColloctor.isLocalId(T), m = N && this.serviceColloctor.transformKey(S) || T;
8857
8856
  let C = T;
8858
8857
  !N && this.serviceColloctor.isOwn(C) && (C = this.serviceColloctor.getLocalId(C));
8859
- const L = u[r][l][w];
8858
+ const L = u[r][l][m];
8860
8859
  if (L && C === H) {
8861
8860
  if (((p = L.selectIds) == null ? void 0 : p.length) === 1) {
8862
8861
  const D = L.selectIds[0];
8863
8862
  if (n === P.Start) {
8864
8863
  const z = ((M = this.serviceColloctor) == null ? void 0 : M.isLocalId(D)) && ((v = this.serviceColloctor) == null ? void 0 : v.transformKey(D)) || D, j = u[r][l][z];
8865
- this.cacheOriginRotate = ((m = j == null ? void 0 : j.opt) == null ? void 0 : m.rotate) || 0;
8864
+ this.cacheOriginRotate = ((w = j == null ? void 0 : j.opt) == null ? void 0 : w.rotate) || 0;
8866
8865
  }
8867
8866
  const A = L.updateNodeOpt || {};
8868
8867
  A.angle = (o + this.cacheOriginRotate) % 360, A.workState = n;
@@ -8889,7 +8888,7 @@ class tw extends Xt {
8889
8888
  n === P.Start ? this.mainEngine.unWritable() : n === P.Done && (this.mainEngine.abled(), this.lastEmtData = void 0), d.length && this.collectForLocalWorker(d, e);
8890
8889
  }
8891
8890
  }
8892
- function ew(a) {
8891
+ function em(a) {
8893
8892
  switch (a) {
8894
8893
  case I.Text:
8895
8894
  return ie.Text;
@@ -8903,7 +8902,7 @@ function ew(a) {
8903
8902
  return ie.Shape;
8904
8903
  }
8905
8904
  }
8906
- class iw extends Xt {
8905
+ class im extends Xt {
8907
8906
  constructor() {
8908
8907
  super(...arguments);
8909
8908
  y(this, "lastEmtData");
@@ -8912,7 +8911,7 @@ class iw extends Xt {
8912
8911
  }
8913
8912
  async setTextStyle(t, e, s, o) {
8914
8913
  const { bold: n, underline: r, lineThrough: c, italic: l, fontSize: h } = s;
8915
- if (e.toolsType && ew(e.toolsType) === ie.Text) {
8914
+ if (e.toolsType && em(e.toolsType) === ie.Text) {
8916
8915
  e.opt && (n && (e.opt.bold = n), Ut(r) && (e.opt.underline = r), Ut(c) && (e.opt.lineThrough = c), l && (e.opt.italic = l), h && (e.opt.fontSize = h));
8917
8916
  const d = await this.control.textEditorManager.updateTextControllerWithEffectAsync({
8918
8917
  workId: t,
@@ -8926,7 +8925,7 @@ class iw extends Xt {
8926
8925
  }
8927
8926
  }
8928
8927
  async collect(t) {
8929
- var m, S, T, N;
8928
+ var w, S, T, N;
8930
8929
  if (!this.serviceColloctor || !this.mainEngine)
8931
8930
  return;
8932
8931
  const { workIds: e, bold: s, italic: o, lineThrough: n, underline: r, viewId: c, fontSize: l } = t, h = this.control.viewContainerManager.getView(c);
@@ -8936,10 +8935,10 @@ class iw extends Xt {
8936
8935
  this.mainEngine.internalMsgEmitter.emit("addUndoTicker", p, c);
8937
8936
  const M = [];
8938
8937
  for (; d.length; ) {
8939
- const w = d.pop();
8940
- if (!w)
8938
+ const m = d.pop();
8939
+ if (!m)
8941
8940
  continue;
8942
- const C = w.toString(), L = this.serviceColloctor.isLocalId(C), D = L ? this.serviceColloctor.transformKey(w) : C;
8941
+ const C = m.toString(), L = this.serviceColloctor.isLocalId(C), D = L ? this.serviceColloctor.transformKey(m) : C;
8943
8942
  let A = C;
8944
8943
  !L && this.serviceColloctor.isOwn(A) && (A = this.serviceColloctor.getLocalId(A));
8945
8944
  const E = f[c][u][D] || void 0;
@@ -8950,7 +8949,7 @@ class iw extends Xt {
8950
8949
  M.push(z);
8951
8950
  continue;
8952
8951
  }
8953
- if (E && A === H && ((m = E.selectIds) != null && m.length))
8952
+ if (E && A === H && ((w = E.selectIds) != null && w.length))
8954
8953
  for (const z of E.selectIds) {
8955
8954
  const j = (S = this.serviceColloctor) == null ? void 0 : S.isLocalId(z);
8956
8955
  let tt = j && ((T = this.serviceColloctor) == null ? void 0 : T.transformKey(z)) || z;
@@ -8964,18 +8963,18 @@ class iw extends Xt {
8964
8963
  }
8965
8964
  }
8966
8965
  const v = await Promise.all(M);
8967
- for (const w of v)
8968
- if (w) {
8969
- const { key: C, textInfo: L } = w;
8966
+ for (const m of v)
8967
+ if (m) {
8968
+ const { key: C, textInfo: L } = m;
8970
8969
  L && (L.canSync = !0, L.canWorker = !0, this.control.textEditorManager.updateForViewEdited(C, L));
8971
8970
  }
8972
8971
  Object.keys(g).length && (this.timerId && (clearTimeout(this.timerId), this.timerId = void 0), this.timerId = setTimeout(() => {
8973
- var w;
8974
- this.timerId = void 0, (w = this.control.room) == null || w.setMemberState(g);
8972
+ var m;
8973
+ this.timerId = void 0, (m = this.control.room) == null || m.setMemberState(g);
8975
8974
  }, 0));
8976
8975
  }
8977
8976
  }
8978
- class sw extends Xt {
8977
+ class sm extends Xt {
8979
8978
  constructor() {
8980
8979
  super(...arguments);
8981
8980
  y(this, "lastEmtData");
@@ -8983,13 +8982,13 @@ class sw extends Xt {
8983
8982
  y(this, "undoTickerId");
8984
8983
  }
8985
8984
  collect(t) {
8986
- var m;
8985
+ var w;
8987
8986
  if (!this.serviceColloctor || !this.mainEngine)
8988
8987
  return;
8989
8988
  const { workId: e, pointMap: s, workState: o, viewId: n } = t, r = this.control.viewContainerManager.getView(n);
8990
8989
  if (!(r != null && r.displayer))
8991
8990
  return;
8992
- const c = r.focusScenePath, l = (m = this.serviceColloctor) == null ? void 0 : m.storage, h = [], u = o === P.Start && Date.now() || void 0;
8991
+ const c = r.focusScenePath, l = (w = this.serviceColloctor) == null ? void 0 : w.storage, h = [], u = o === P.Start && Date.now() || void 0;
8993
8992
  u && (this.undoTickerId = u, this.mainEngine.internalMsgEmitter.emit("addUndoTicker", u, n));
8994
8993
  const d = e;
8995
8994
  if (!d)
@@ -9020,7 +9019,7 @@ class sw extends Xt {
9020
9019
  o === P.Start ? this.mainEngine.unWritable() : o === P.Done && this.mainEngine.abled(), h.length && this.collectForLocalWorker(h);
9021
9020
  }
9022
9021
  }
9023
- class ow extends Xt {
9022
+ class om extends Xt {
9024
9023
  constructor() {
9025
9024
  super(...arguments);
9026
9025
  y(this, "lastEmtData");
@@ -9042,13 +9041,13 @@ class ow extends Xt {
9042
9041
  !g && this.serviceColloctor.isOwn(M) && (M = this.serviceColloctor.getLocalId(M));
9043
9042
  const v = l[o][r][p] || void 0;
9044
9043
  if (v) {
9045
- const m = v.updateNodeOpt || {};
9046
- m.isLocked = s;
9044
+ const w = v.updateNodeOpt || {};
9045
+ w.isLocked = s;
9047
9046
  const S = {
9048
9047
  workId: M,
9049
9048
  msgType: x.UpdateNode,
9050
9049
  dataType: U.Local,
9051
- updateNodeOpt: m,
9050
+ updateNodeOpt: w,
9052
9051
  emitEventType: this.emitEventType,
9053
9052
  willRefresh: !0,
9054
9053
  willRefreshSelector: !0,
@@ -9065,7 +9064,7 @@ class ow extends Xt {
9065
9064
  this.mainEngine.internalMsgEmitter.emit("addUndoTicker", u, o), h.length && this.collectForLocalWorker(h);
9066
9065
  }
9067
9066
  }
9068
- class nw extends Xt {
9067
+ class nm extends Xt {
9069
9068
  constructor() {
9070
9069
  super(...arguments);
9071
9070
  y(this, "lastEmtData");
@@ -9087,7 +9086,7 @@ class nw extends Xt {
9087
9086
  !g && this.serviceColloctor.isOwn(M) && (M = this.serviceColloctor.getLocalId(M));
9088
9087
  const v = l[s][r][p] || void 0;
9089
9088
  if (v) {
9090
- const m = {
9089
+ const w = {
9091
9090
  ...v.updateNodeOpt,
9092
9091
  ...o,
9093
9092
  willRefresh: !0
@@ -9097,7 +9096,7 @@ class nw extends Xt {
9097
9096
  workId: M,
9098
9097
  msgType: x.UpdateNode,
9099
9098
  dataType: U.Local,
9100
- updateNodeOpt: m,
9099
+ updateNodeOpt: w,
9101
9100
  emitEventType: this.emitEventType,
9102
9101
  willRefresh: !0,
9103
9102
  willRefreshSelector: !0,
@@ -9135,15 +9134,15 @@ class rt {
9135
9134
  case B.ScaleNode:
9136
9135
  return new _M();
9137
9136
  case B.RotateNode:
9138
- return new tw();
9137
+ return new tm();
9139
9138
  case B.SetFontStyle:
9140
- return new iw();
9139
+ return new im();
9141
9140
  case B.SetPoint:
9142
- return new sw();
9141
+ return new sm();
9143
9142
  case B.SetLock:
9144
- return new ow();
9143
+ return new om();
9145
9144
  case B.SetShapeOpt:
9146
- return new nw();
9145
+ return new nm();
9147
9146
  }
9148
9147
  }
9149
9148
  getBuilder(i) {
@@ -9179,7 +9178,7 @@ class rt {
9179
9178
  bt.InternalMsgEmitter.off(B.ActiveMethod, i);
9180
9179
  }
9181
9180
  }
9182
- class rw {
9181
+ class rm {
9183
9182
  constructor(i) {
9184
9183
  y(this, "master");
9185
9184
  y(this, "mainThreadWorkerMap", /* @__PURE__ */ new Map());
@@ -9208,7 +9207,7 @@ class rw {
9208
9207
  t && t.clearDrawLayer(1 / 0);
9209
9208
  }
9210
9209
  createMainThreadWorker(i, t) {
9211
- return new aw(i, t, this);
9210
+ return new am(i, t, this);
9212
9211
  }
9213
9212
  consume(i) {
9214
9213
  var t;
@@ -9251,7 +9250,7 @@ class rw {
9251
9250
  active() {
9252
9251
  }
9253
9252
  }
9254
- class aw {
9253
+ class am {
9255
9254
  constructor(i, t, e) {
9256
9255
  y(this, "viewId");
9257
9256
  y(this, "opt");
@@ -9266,7 +9265,7 @@ class aw {
9266
9265
  const n = {
9267
9266
  thread: this
9268
9267
  };
9269
- this.subLocalWork = new cw(n);
9268
+ this.subLocalWork = new cm(n);
9270
9269
  }
9271
9270
  createScene(i) {
9272
9271
  return new Mo({
@@ -9366,7 +9365,7 @@ class aw {
9366
9365
  e.disconnect(), this.subLocalLayer.removeChild(e);
9367
9366
  }
9368
9367
  }
9369
- class cw {
9368
+ class cm {
9370
9369
  constructor(i) {
9371
9370
  y(this, "thread");
9372
9371
  y(this, "workShapes", /* @__PURE__ */ new Map());
@@ -9438,7 +9437,7 @@ class cw {
9438
9437
  return this.workShapes.get(i);
9439
9438
  }
9440
9439
  }
9441
- const lw = async (a, i) => {
9440
+ const lm = async (a, i) => {
9442
9441
  const { src: t, isgl: e, isCache: s } = a;
9443
9442
  if (typeof Image == "function") {
9444
9443
  const o = new Image();
@@ -9458,7 +9457,7 @@ const lw = async (a, i) => {
9458
9457
  cache: "default"
9459
9458
  }).then((o) => o.blob()).then((o) => createImageBitmap(o, { imageOrientation: e ? "flipY" : "none" }).then((n) => n));
9460
9459
  };
9461
- class hw {
9460
+ class hm {
9462
9461
  constructor() {
9463
9462
  /** 异步同步时间间隔 */
9464
9463
  y(this, "maxLastSyncTime", Ot.syncOpt.interval);
@@ -9483,7 +9482,7 @@ class hw {
9483
9482
  return this.currentLocalWorkData.workState;
9484
9483
  }
9485
9484
  }
9486
- class uw extends hw {
9485
+ class um extends hm {
9487
9486
  constructor(t) {
9488
9487
  var o, n;
9489
9488
  super();
@@ -9597,7 +9596,7 @@ class uw extends hw {
9597
9596
  }
9598
9597
  async useMainThread() {
9599
9598
  console.info("no OffscreenCanvas");
9600
- const { MainThreadManagerImpl: t } = await import("./index-D5vax7MJ.mjs");
9599
+ const { MainThreadManagerImpl: t } = await import("./index-BY6CrjXe.mjs");
9601
9600
  this.mainThread = new t(this);
9602
9601
  }
9603
9602
  async on() {
@@ -9609,7 +9608,7 @@ class uw extends hw {
9609
9608
  console.error("no worker url config");
9610
9609
  return;
9611
9610
  }
9612
- this.fullWorker = new Worker(this.fullWorkerUrl, { type: "classic" }), this.subWorker = new Worker(this.subWorkerUrl, { type: "classic" }), this.subMainThreadWorker = new rw(this), this.fullWorker.onmessage = (t) => {
9611
+ this.fullWorker = new Worker(this.fullWorkerUrl, { type: "classic" }), this.subWorker = new Worker(this.subWorkerUrl, { type: "classic" }), this.subMainThreadWorker = new rm(this), this.fullWorker.onmessage = (t) => {
9613
9612
  var e, s;
9614
9613
  if (t.data) {
9615
9614
  const { render: o, sp: n, fullWorkerDrawCount: r, workerTasksqueueCount: c, viewId: l, consumeCount: h } = t.data;
@@ -9704,11 +9703,11 @@ class uw extends hw {
9704
9703
  willSyncService: p,
9705
9704
  isSync: M,
9706
9705
  imageBitmap: v,
9707
- canvasHeight: m,
9706
+ canvasHeight: w,
9708
9707
  canvasWidth: S,
9709
9708
  rect: T,
9710
9709
  op: N,
9711
- canTextEdit: w,
9710
+ canTextEdit: m,
9712
9711
  points: C,
9713
9712
  selectorColor: L,
9714
9713
  canRotate: D,
@@ -9734,8 +9733,8 @@ class uw extends hw {
9734
9733
  const Z = c.scenePath || this.viewContainerManager.getCurScenePath(j);
9735
9734
  switch (l) {
9736
9735
  case x.Select: {
9737
- const $ = h != null && h.length ? { ...d, selectIds: h, canvasHeight: m, canvasWidth: S, points: C } : void 0;
9738
- $ && (u != null && u.strokeColor) && ($.selectorColor = u.strokeColor), $ && L && ($.selectorColor = L), $ && f && ($.strokeColor = f), $ && (u != null && u.fillColor) && ($.fillColor = u.fillColor), $ && g && ($.fillColor = g), $ && Ut(D) && ($.canRotate = D), $ && A && ($.scaleType = A), $ && w && ($.canTextEdit = w), $ && E && ($.textOpt = E), $ && Ut(et) && ($.canLock = et), $ && Ut(G) && ($.isLocked = G), $ && Q && ($.shapeOpt = Q), $ && V && ($.toolsTypes = V), $ && it && ($.thickness = it), $ && ct && ($.strokeType = ct), $ && Ut(J) && ($.useStroke = J), j && this.viewContainerManager.showFloatBar(j, !!$, $), p && ((s = this.collector) == null || s.dispatch({ type: l, selectIds: h, opt: u, isSync: M, viewId: j, scenePath: Z }));
9736
+ const $ = h != null && h.length ? { ...d, selectIds: h, canvasHeight: w, canvasWidth: S, points: C } : void 0;
9737
+ $ && (u != null && u.strokeColor) && ($.selectorColor = u.strokeColor), $ && L && ($.selectorColor = L), $ && f && ($.strokeColor = f), $ && (u != null && u.fillColor) && ($.fillColor = u.fillColor), $ && g && ($.fillColor = g), $ && Ut(D) && ($.canRotate = D), $ && A && ($.scaleType = A), $ && m && ($.canTextEdit = m), $ && E && ($.textOpt = E), $ && Ut(et) && ($.canLock = et), $ && Ut(G) && ($.isLocked = G), $ && Q && ($.shapeOpt = Q), $ && V && ($.toolsTypes = V), $ && it && ($.thickness = it), $ && ct && ($.strokeType = ct), $ && Ut(J) && ($.useStroke = J), j && this.viewContainerManager.showFloatBar(j, !!$, $), p && ((s = this.collector) == null || s.dispatch({ type: l, selectIds: h, opt: u, isSync: M, viewId: j, scenePath: Z }));
9739
9738
  break;
9740
9739
  }
9741
9740
  case x.Snapshot:
@@ -9762,13 +9761,13 @@ class uw extends hw {
9762
9761
  break;
9763
9762
  case x.TextUpdate:
9764
9763
  if (O === I.Text && z && j) {
9765
- const $ = this.viewContainerManager.transformToOriginPoint((u == null ? void 0 : u.boxPoint) || [0, 0], j), pt = (u == null ? void 0 : u.boxSize) || [0, 0], mt = (n = this.viewContainerManager.getView(j)) == null ? void 0 : n.cameraOpt;
9764
+ const $ = this.viewContainerManager.transformToOriginPoint((u == null ? void 0 : u.boxPoint) || [0, 0], j), pt = (u == null ? void 0 : u.boxSize) || [0, 0], wt = (n = this.viewContainerManager.getView(j)) == null ? void 0 : n.cameraOpt;
9766
9765
  u ? this.control.textEditorManager.updateTextForWorker({
9767
9766
  x: $[0],
9768
9767
  y: $[1],
9769
9768
  w: pt[0],
9770
9769
  h: pt[1],
9771
- scale: (mt == null ? void 0 : mt.scale) || 1,
9770
+ scale: (wt == null ? void 0 : wt.scale) || 1,
9772
9771
  workId: z,
9773
9772
  opt: u,
9774
9773
  dataType: tt,
@@ -9789,11 +9788,11 @@ class uw extends hw {
9789
9788
  }, Date.now());
9790
9789
  break;
9791
9790
  case x.GetImageBitMap:
9792
- q && j && z && lw({
9791
+ q && j && z && lm({
9793
9792
  src: q,
9794
9793
  isgl: ut
9795
9794
  }).then(($) => {
9796
- var mt;
9795
+ var wt;
9797
9796
  const pt = /* @__PURE__ */ new Set();
9798
9797
  if (pt.add({
9799
9798
  msgType: x.GetImageBitMap,
@@ -9804,7 +9803,7 @@ class uw extends hw {
9804
9803
  isSubWorker: dt,
9805
9804
  imageBitmap: $
9806
9805
  }), !this.control.hasOffscreenCanvas())
9807
- (mt = this.mainThread) == null || mt.consume(pt);
9806
+ (wt = this.mainThread) == null || wt.consume(pt);
9808
9807
  else {
9809
9808
  const $t = dt ? this.subWorker : this.fullWorker;
9810
9809
  $ ? $t.postMessage(pt, [$]) : $t.postMessage(pt);
@@ -9813,8 +9812,8 @@ class uw extends hw {
9813
9812
  break;
9814
9813
  case x.GetVNodeInfo:
9815
9814
  if (z) {
9816
- const $ = z.toString(), pt = (r = this.getVNodeInfoResolveMap.get($)) == null ? void 0 : r.resolve, mt = { ...c, uuid: $ };
9817
- pt && pt(mt);
9815
+ const $ = z.toString(), pt = (r = this.getVNodeInfoResolveMap.get($)) == null ? void 0 : r.resolve, wt = { ...c, uuid: $ };
9816
+ pt && pt(wt);
9818
9817
  }
9819
9818
  break;
9820
9819
  default:
@@ -9829,12 +9828,12 @@ class uw extends hw {
9829
9828
  collectorAsyncData(t) {
9830
9829
  var e, s, o, n;
9831
9830
  for (const r of t) {
9832
- const { type: c, op: l, workId: h, index: u, removeIds: d, ops: f, opt: g, updateNodeOpt: p, toolsType: M, isSync: v, viewId: m, isLockSentEventCursor: S, nextTasks: T } = r;
9833
- if (!m) {
9831
+ const { type: c, op: l, workId: h, index: u, removeIds: d, ops: f, opt: g, updateNodeOpt: p, toolsType: M, isSync: v, viewId: w, isLockSentEventCursor: S, nextTasks: T } = r;
9832
+ if (!w) {
9834
9833
  console.error("collectorAsyncData", r);
9835
9834
  return;
9836
9835
  }
9837
- const N = r.scenePath || this.viewContainerManager.getCurScenePath(m);
9836
+ const N = r.scenePath || this.viewContainerManager.getCurScenePath(w);
9838
9837
  switch (c) {
9839
9838
  case x.None: {
9840
9839
  S && Gt(() => {
@@ -9851,7 +9850,7 @@ class uw extends hw {
9851
9850
  workId: h,
9852
9851
  index: u,
9853
9852
  isSync: v,
9854
- viewId: m,
9853
+ viewId: w,
9855
9854
  scenePath: N,
9856
9855
  updateNodeOpt: p
9857
9856
  });
@@ -9866,19 +9865,19 @@ class uw extends hw {
9866
9865
  opt: g,
9867
9866
  toolsType: M,
9868
9867
  isSync: v,
9869
- viewId: m,
9868
+ viewId: w,
9870
9869
  scenePath: N
9871
9870
  }), this.willSelectorWorkId && h && h.toString() === this.willSelectorWorkId && this.control.runEffectWork(() => {
9872
- this.setShapeSelectorByWorkId(this.willSelectorWorkId, m), this.willSelectorWorkId = void 0;
9871
+ this.setShapeSelectorByWorkId(this.willSelectorWorkId, w), this.willSelectorWorkId = void 0;
9873
9872
  });
9874
9873
  break;
9875
9874
  }
9876
9875
  case x.UpdateNode: {
9877
- (o = this.collector) == null || o.dispatch({ type: c, updateNodeOpt: p, workId: h, opt: g, ops: f, op: l, isSync: v, viewId: m, scenePath: N });
9876
+ (o = this.collector) == null || o.dispatch({ type: c, updateNodeOpt: p, workId: h, opt: g, ops: f, op: l, isSync: v, viewId: w, scenePath: N });
9878
9877
  break;
9879
9878
  }
9880
9879
  case x.RemoveNode: {
9881
- d && this.control.textEditorManager.deleteBatch(d, !1, !1), (n = this.collector) == null || n.dispatch({ type: c, removeIds: d, isSync: v, viewId: m, scenePath: N }), this.willSelectorWorkId && (d != null && d.includes(this.willSelectorWorkId)) && (this.willSelectorWorkId = void 0);
9880
+ d && this.control.textEditorManager.deleteBatch(d, !1, !1), (n = this.collector) == null || n.dispatch({ type: c, removeIds: d, isSync: v, viewId: w, scenePath: N }), this.willSelectorWorkId && (d != null && d.includes(this.willSelectorWorkId)) && (this.willSelectorWorkId = void 0);
9882
9881
  break;
9883
9882
  }
9884
9883
  }
@@ -10122,7 +10121,7 @@ class uw extends hw {
10122
10121
  }), this.control.renderControl.destoryByViewId(t, e);
10123
10122
  }
10124
10123
  onServiceDerive(t, e) {
10125
- var f, g, p, M, v, m, S;
10124
+ var f, g, p, M, v, w, S;
10126
10125
  const { newValue: s, oldValue: o, viewId: n, scenePath: r } = e, c = gt(s) || {}, l = t;
10127
10126
  let h = c.type;
10128
10127
  if (!s && o) {
@@ -10145,9 +10144,9 @@ class uw extends hw {
10145
10144
  if (!this.control.renderControl.isFilterAble({ viewId: n, elementId: t, scenePath: r }, h))
10146
10145
  return;
10147
10146
  const T = c;
10148
- if (T.workId = (v = this.collector) != null && v.isOwn(l) ? (m = this.collector) == null ? void 0 : m.getLocalId(l) : l, T.msgType = h, T.toolsType === I.LaserPen && (T.isRunSubWork = !0), T.dataType = U.Service, T.viewId = n, T.scenePath = r, T.selectIds && (T.selectIds = T.selectIds.map((N) => {
10149
- var w, C;
10150
- return (w = this.collector) != null && w.isOwn(N) ? (C = this.collector) == null ? void 0 : C.getLocalId(N) : N;
10147
+ if (T.workId = (v = this.collector) != null && v.isOwn(l) ? (w = this.collector) == null ? void 0 : w.getLocalId(l) : l, T.msgType = h, T.toolsType === I.LaserPen && (T.isRunSubWork = !0), T.dataType = U.Service, T.viewId = n, T.scenePath = r, T.selectIds && (T.selectIds = T.selectIds.map((N) => {
10148
+ var m, C;
10149
+ return (m = this.collector) != null && m.isOwn(N) ? (C = this.collector) == null ? void 0 : C.getLocalId(N) : N;
10151
10150
  })), T && T.toolsType === I.Text || (o == null ? void 0 : o.toolsType) === I.Text) {
10152
10151
  this.control.textEditorManager.onServiceDerive(T);
10153
10152
  return;
@@ -10182,9 +10181,9 @@ class uw extends hw {
10182
10181
  if (!this.control.renderControl.isFilterAble({ viewId: t, elementId: p, scenePath: e }, M))
10183
10182
  continue;
10184
10183
  const v = o[p];
10185
- if (v.workId = (d = this.collector) != null && d.isOwn(p) ? (f = this.collector) == null ? void 0 : f.getLocalId(p) : p, v.msgType = M, v.dataType = U.Service, v.viewId = t, v.scenePath = e, v.useAnimation = !!r, v.selectIds && (v.selectIds = v.selectIds.map((m) => {
10184
+ if (v.workId = (d = this.collector) != null && d.isOwn(p) ? (f = this.collector) == null ? void 0 : f.getLocalId(p) : p, v.msgType = M, v.dataType = U.Service, v.viewId = t, v.scenePath = e, v.useAnimation = !!r, v.selectIds && (v.selectIds = v.selectIds.map((w) => {
10186
10185
  var S, T;
10187
- return (S = this.collector) != null && S.isOwn(m) ? (T = this.collector) == null ? void 0 : T.getLocalId(m) : m;
10186
+ return (S = this.collector) != null && S.isOwn(w) ? (T = this.collector) == null ? void 0 : T.getLocalId(w) : w;
10188
10187
  })), v.toolsType === I.Text) {
10189
10188
  this.control.textEditorManager.onServiceDerive(v);
10190
10189
  continue;
@@ -10605,9 +10604,9 @@ class uw extends hw {
10605
10604
  viewId: g.id
10606
10605
  // maxZIndex: this.zIndexNodeMethod?.getMaxZIndex(viewId)
10607
10606
  };
10608
- return this.taskBatchData.add(v), this.runAnimation(), new Promise((m) => {
10609
- this.snapshotMap.set(t, m);
10610
- }).then((m) => (this.snapshotMap.delete(t), m));
10607
+ return this.taskBatchData.add(v), this.runAnimation(), new Promise((w) => {
10608
+ this.snapshotMap.set(t, w);
10609
+ }).then((w) => (this.snapshotMap.delete(t), w));
10611
10610
  }
10612
10611
  }
10613
10612
  }
@@ -10861,7 +10860,7 @@ class uw extends hw {
10861
10860
  });
10862
10861
  }
10863
10862
  }
10864
- class dw {
10863
+ class dm {
10865
10864
  constructor(i) {
10866
10865
  y(this, "internalMsgEmitter");
10867
10866
  y(this, "control");
@@ -11014,7 +11013,7 @@ class dw {
11014
11013
  (t = this.control.room) == null || t.setMemberState(i);
11015
11014
  }
11016
11015
  }
11017
- class pw {
11016
+ class pm {
11018
11017
  constructor(i) {
11019
11018
  y(this, "control");
11020
11019
  y(this, "roomMemberManager");
@@ -11400,7 +11399,7 @@ class pw {
11400
11399
  e.has(r) && Object.keys(s).includes(r) && ((n = this.control.collector) == null || n.updateValue(r, void 0, { isSync: !0, viewId: i, scenePath: t }));
11401
11400
  }
11402
11401
  }
11403
- class fw {
11402
+ class fm {
11404
11403
  constructor(i) {
11405
11404
  y(this, "internalMsgEmitter");
11406
11405
  y(this, "control");
@@ -11510,7 +11509,7 @@ class fw {
11510
11509
  t && (this.maps.delete(t), this.control.viewContainerManager.setActiveMiniMap(t, !1));
11511
11510
  }
11512
11511
  }
11513
- class gw {
11512
+ class gm {
11514
11513
  constructor() {
11515
11514
  y(this, "control");
11516
11515
  y(this, "_listeners", {});
@@ -11528,7 +11527,7 @@ class gw {
11528
11527
  delete this._listeners[i];
11529
11528
  }
11530
11529
  }
11531
- class yw {
11530
+ class ym {
11532
11531
  constructor(i) {
11533
11532
  y(this, "control");
11534
11533
  y(this, "worker");
@@ -11613,7 +11612,7 @@ const ye = class ye {
11613
11612
  internalMsgEmitter: ye.InternalMsgEmitter,
11614
11613
  publicMsgEmitter: ye.PublicMsgEmitter
11615
11614
  };
11616
- this.cursor = new GM(o), this.textEditorManager = new QM(o), this.worker = new uw(o), this.hotkeyManager = new dw(o), this.renderControl = new pw(o), this.miniMapManager = new fw(o), this.pluginManager = new yw(o);
11615
+ this.cursor = new GM(o), this.textEditorManager = new QM(o), this.worker = new um(o), this.hotkeyManager = new dm(o), this.renderControl = new pm(o), this.miniMapManager = new fm(o), this.pluginManager = new ym(o);
11617
11616
  }
11618
11617
  get disableEraseText() {
11619
11618
  return this._disableEraseText || !1;
@@ -12104,7 +12103,7 @@ const Me = class Me {
12104
12103
  return !!t.includes(e);
12105
12104
  }
12106
12105
  refreshPlugin(i, t = !1) {
12107
- var r, c, l, h, u, d, f, g, p, M, v, m, S, T, N, w, C, L, D, A, E;
12106
+ var r, c, l, h, u, d, f, g, p, M, v, w, S, T, N, m, C, L, D, A, E;
12108
12107
  let e;
12109
12108
  const { scenePath: s } = i, o = i.data;
12110
12109
  if (!o || !this.collector)
@@ -12158,7 +12157,7 @@ const Me = class Me {
12158
12157
  it && (j.selectIds = Q.filter((ct) => !!ct));
12159
12158
  }
12160
12159
  }
12161
- (m = this.collector) == null || m.updateValue(O.key, O.data, { viewId: this.viewId, scenePath: s, isSync: !0, storage: n });
12160
+ (w = this.collector) == null || w.updateValue(O.key, O.data, { viewId: this.viewId, scenePath: s, isSync: !0, storage: n });
12162
12161
  }
12163
12162
  }
12164
12163
  break;
@@ -12179,7 +12178,7 @@ const Me = class Me {
12179
12178
  let ct = !1;
12180
12179
  for (const J of it)
12181
12180
  for (let ut = 0; ut < V.length; ut++)
12182
- J != null && J.selectIds && ((w = J.selectIds) != null && w.includes(V[ut])) && (delete V[ut], ct = !0);
12181
+ J != null && J.selectIds && ((m = J.selectIds) != null && m.includes(V[ut])) && (delete V[ut], ct = !0);
12183
12182
  ct && (Q.selectIds = V.filter((J) => !!J));
12184
12183
  }
12185
12184
  }
@@ -12213,11 +12212,11 @@ const Me = class Me {
12213
12212
  };
12214
12213
  y(Me, "sdkCallBack"), y(Me, "MaxStackLength", 20), y(Me, "waitTime", 100);
12215
12214
  let fi = Me;
12216
- function Mw(a) {
12215
+ function Mm(a) {
12217
12216
  return a instanceof TouchEvent || a instanceof window.TouchEvent || (a == null ? void 0 : a.touches) && (a == null ? void 0 : a.touches.length) || (a == null ? void 0 : a.changedTouches) && (a == null ? void 0 : a.changedTouches.length);
12218
12217
  }
12219
12218
  function Pe(a) {
12220
- return Mw(a) && (a.touches && a.touches.length === 1 || a.changedTouches && a.changedTouches.length === 1);
12219
+ return Mm(a) && (a.touches && a.touches.length === 1 || a.changedTouches && a.changedTouches.length === 1);
12221
12220
  }
12222
12221
  function pn(a) {
12223
12222
  return a.touches && a.touches.length ? {
@@ -12268,7 +12267,7 @@ class Ve {
12268
12267
  }
12269
12268
  validator(i, t, e) {
12270
12269
  var n;
12271
- const s = ws(i[t]), o = ws(e);
12270
+ const s = ms(i[t]), o = ms(e);
12272
12271
  t === "focusScenePath" && e && !ft(s, o) && (this.control.internalSceneChange(i.id, o), (n = this.focuedView) == null || n.displayer.commiter.onChangeScene()), t === "cameraOpt" && !ft(s, o) && this.control.internalCameraChange(i.id, o);
12273
12272
  }
12274
12273
  destroyAppView(i, t = !1) {
@@ -12361,12 +12360,12 @@ class Ve {
12361
12360
  }
12362
12361
  /** 绘制view */
12363
12362
  render(i) {
12364
- var t, e, s, o, n, r, c, l, h, u, d, f, g, p, M, v, m;
12363
+ var t, e, s, o, n, r, c, l, h, u, d, f, g, p, M, v, w;
12365
12364
  for (const S of i) {
12366
- const { rect: T, imageBitmap: N, isClear: w, isUnClose: C, drawCanvas: L, clearCanvas: D, viewId: A } = S, E = (t = this.getView(A)) == null ? void 0 : t.displayer;
12365
+ const { rect: T, imageBitmap: N, isClear: m, isUnClose: C, drawCanvas: L, clearCanvas: D, viewId: A } = S, E = (t = this.getView(A)) == null ? void 0 : t.displayer;
12367
12366
  if (E && T) {
12368
12367
  const { dpr: O, canvasBgRef: z, canvasFloatRef: j, canvasServiceFloatRef: tt, canvasTopRef: et } = E, G = Math.floor(T.w * O), Q = Math.floor(T.h * O), V = T.x * O, it = T.y * O;
12369
- if (w) {
12368
+ if (m) {
12370
12369
  switch (D) {
12371
12370
  case Nt.TopFloat:
12372
12371
  (s = (e = et.current) == null ? void 0 : e.getContext("2d")) == null || s.clearRect(V, it, G, Q);
@@ -12397,7 +12396,7 @@ class Ve {
12397
12396
  break;
12398
12397
  }
12399
12398
  case Nt.Bg: {
12400
- (m = (v = z.current) == null ? void 0 : v.getContext("2d")) == null || m.drawImage(N, 0, 0, G, Q, V, it, G, Q);
12399
+ (w = (v = z.current) == null ? void 0 : v.getContext("2d")) == null || w.drawImage(N, 0, 0, G, Q, V, it, G, Q);
12401
12400
  break;
12402
12401
  }
12403
12402
  }
@@ -12434,7 +12433,7 @@ y(Ve, "defaultCameraOpt", {
12434
12433
  handleEvent: !1,
12435
12434
  depth: !1
12436
12435
  });
12437
- class ww {
12436
+ class mm {
12438
12437
  constructor(i, t, e) {
12439
12438
  y(this, "viewId");
12440
12439
  y(this, "control");
@@ -12586,22 +12585,10 @@ class ww {
12586
12585
  return (o = i.offsetParent) != null && o.nodeName && i.offsetParent.nodeName !== "BODY" && (s = this.getContainerOffset(i.offsetParent, s)), s;
12587
12586
  }
12588
12587
  bindDisplayerEvent(i) {
12589
- i.addEventListener("mousedown", this.mousedown, !1), i.addEventListener("touchstart", this.touchstart, {
12590
- capture: !0,
12591
- passive: !1
12592
- }), window.addEventListener("mouseleave", this.mouseup, !1), window.addEventListener("mousemove", this.mousemove, {
12593
- capture: !0,
12594
- passive: !1
12595
- }), window.addEventListener("mouseup", this.mouseup, !1), window.addEventListener("touchmove", this.touchmove, {
12596
- capture: !0,
12597
- passive: !1
12598
- }), window.addEventListener("touchend", this.touchend, {
12599
- capture: !0,
12600
- passive: !1
12601
- }), i.addEventListener("mousemove", this.cursorMouseMove, !1), i.addEventListener("mouseleave", this.cursorMouseLeave, !1), i.addEventListener("keydown", this.keydown, !0);
12588
+ i.addEventListener("mousedown", this.mousedown, !1), i.addEventListener("touchstart", this.touchstart, !1), document.addEventListener("mouseleave", this.mouseup, !1), document.addEventListener("mousemove", this.mousemove, !1), document.addEventListener("mouseup", this.mouseup, !1), document.addEventListener("touchmove", this.touchmove, !1), document.addEventListener("touchend", this.touchend, !1), i.addEventListener("mousemove", this.cursorMouseMove, !1), i.addEventListener("mouseleave", this.cursorMouseLeave, !1), i.addEventListener("keydown", this.keydown, !0);
12602
12589
  }
12603
12590
  removeDisplayerEvent(i) {
12604
- i.removeEventListener("mousedown", this.mousedown), i.removeEventListener("touchstart", this.touchstart), window.removeEventListener("mouseleave", this.mouseup), window.removeEventListener("mousemove", this.mousemove), window.removeEventListener("mouseup", this.mouseup), window.removeEventListener("touchmove", this.touchmove), window.removeEventListener("touchend", this.touchend), i.removeEventListener("mousemove", this.cursorMouseMove), i.removeEventListener("mouseleave", this.cursorMouseLeave), i.removeEventListener("keydown", this.keydown);
12591
+ i.removeEventListener("mousedown", this.mousedown, !1), i.removeEventListener("touchstart", this.touchstart, !1), document.removeEventListener("mouseleave", this.mouseup, !1), document.removeEventListener("mousemove", this.mousemove, !1), document.removeEventListener("mouseup", this.mouseup, !1), document.removeEventListener("touchmove", this.touchmove, !1), document.removeEventListener("touchend", this.touchend, !1), i.removeEventListener("mousemove", this.cursorMouseMove, !1), i.removeEventListener("mouseleave", this.cursorMouseLeave, !1), i.removeEventListener("keydown", this.keydown, !0);
12605
12592
  }
12606
12593
  }
12607
12594
  class fn {
@@ -12743,39 +12730,27 @@ class fn {
12743
12730
  return (o = i.offsetParent) != null && o.nodeName && i.offsetParent.nodeName !== "BODY" && (s = this.getContainerOffset(i.offsetParent, s)), s;
12744
12731
  }
12745
12732
  bindDisplayerEvent(i) {
12746
- i.addEventListener("mousedown", this.mousedown, !1), window.addEventListener("mouseleave", this.mouseup, !1), window.addEventListener("mousemove", this.mousemove, {
12747
- capture: !1,
12748
- passive: !1
12749
- }), window.addEventListener("mouseup", this.mouseup, !1), i.addEventListener("touchstart", this.touchstart, {
12750
- capture: !0,
12751
- passive: !1
12752
- }), window.addEventListener("touchmove", this.touchmove, {
12753
- capture: !0,
12754
- passive: !1
12755
- }), window.addEventListener("touchend", this.touchend, {
12756
- capture: !0,
12757
- passive: !1
12758
- }), i.addEventListener("mousemove", this.cursorMouseMove, !0), i.addEventListener("mouseleave", this.cursorMouseLeave, !0), i.addEventListener("keydown", this.keydown, !0);
12733
+ i.addEventListener("mousedown", this.mousedown, !1), document.addEventListener("mouseleave", this.mouseup, !1), document.addEventListener("mousemove", this.mousemove, !1), document.addEventListener("mouseup", this.mouseup, !1), i.addEventListener("touchstart", this.touchstart, !1), document.addEventListener("touchmove", this.touchmove, !1), document.addEventListener("touchend", this.touchend, !1), i.addEventListener("mousemove", this.cursorMouseMove, !1), i.addEventListener("mouseleave", this.cursorMouseLeave, !1), i.addEventListener("keydown", this.keydown, !0);
12759
12734
  }
12760
12735
  removeDisplayerEvent(i) {
12761
- i.removeEventListener("mousedown", this.mousedown), i.removeEventListener("touchstart", this.touchstart), window.removeEventListener("mouseleave", this.mouseup), window.removeEventListener("mousemove", this.mousemove), window.removeEventListener("mouseup", this.mouseup), window.removeEventListener("touchmove", this.touchmove), window.removeEventListener("touchend", this.touchend), i.removeEventListener("mousemove", this.cursorMouseMove), i.removeEventListener("mouseleave", this.cursorMouseLeave), i.removeEventListener("keydown", this.keydown);
12736
+ i.removeEventListener("mousedown", this.mousedown, !1), document.removeEventListener("mouseleave", this.mouseup, !1), document.removeEventListener("mousemove", this.mousemove, !1), document.removeEventListener("mouseup", this.mouseup, !1), i.removeEventListener("touchstart", this.touchstart, !1), document.removeEventListener("touchmove", this.touchmove, !1), document.removeEventListener("touchend", this.touchend, !1), i.removeEventListener("mousemove", this.cursorMouseMove, !1), i.removeEventListener("mouseleave", this.cursorMouseLeave, !1), i.removeEventListener("keydown", this.keydown, !0);
12762
12737
  }
12763
12738
  }
12764
- const mw = "index-module__Container__nLsM3", vw = "index-module__CanvasBox__j2Xe-", Iw = "index-module__FloatCanvas__d1YR7", Nw = "index-module__TopFloatCanvas__7IaCw", Sw = "index-module__CanvasBoxSub__hcMeK", Tw = "index-module__SnapshotBox__--eeE", kw = "index-module__FloatBar__cm-EL", Cw = "index-module__RotateBtn__HSSkf", bw = "index-module__ResizeBtn__yjvda", xw = "index-module__CursorBox__2UHvI", Lw = "index-module__TextEditorContainer__Qm8KC", zw = "index-module__ResizeTowBox__HOllX", Pw = "index-module__FloatBarBtn__FJrOG", Et = {
12765
- Container: mw,
12766
- CanvasBox: vw,
12767
- FloatCanvas: Iw,
12768
- TopFloatCanvas: Nw,
12769
- CanvasBoxSub: Sw,
12770
- SnapshotBox: Tw,
12771
- FloatBar: kw,
12772
- RotateBtn: Cw,
12773
- ResizeBtn: bw,
12774
- CursorBox: xw,
12775
- TextEditorContainer: Lw,
12776
- ResizeTowBox: zw,
12777
- FloatBarBtn: Pw
12778
- }, Dw = {
12739
+ const wm = "index-module__Container__nLsM3", vm = "index-module__CanvasBox__j2Xe-", Im = "index-module__FloatCanvas__d1YR7", Nm = "index-module__TopFloatCanvas__7IaCw", Sm = "index-module__CanvasBoxSub__hcMeK", Tm = "index-module__SnapshotBox__--eeE", km = "index-module__FloatBar__cm-EL", Cm = "index-module__RotateBtn__HSSkf", bm = "index-module__ResizeBtn__yjvda", xm = "index-module__CursorBox__2UHvI", Lm = "index-module__TextEditorContainer__Qm8KC", zm = "index-module__ResizeTowBox__HOllX", Pm = "index-module__FloatBarBtn__FJrOG", Et = {
12740
+ Container: wm,
12741
+ CanvasBox: vm,
12742
+ FloatCanvas: Im,
12743
+ TopFloatCanvas: Nm,
12744
+ CanvasBoxSub: Sm,
12745
+ SnapshotBox: Tm,
12746
+ FloatBar: km,
12747
+ RotateBtn: Cm,
12748
+ ResizeBtn: bm,
12749
+ CursorBox: xm,
12750
+ TextEditorContainer: Lm,
12751
+ ResizeTowBox: zm,
12752
+ FloatBarBtn: Pm
12753
+ }, Dm = {
12779
12754
  delete: "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEyIDZ2NmEyIDIgMCAwIDEtMiAySDZhMiAyIDAgMCAxLTItMlY2aDBtMS0yYTIgMiAwIDAgMSAyLTJoMmEyIDIgMCAwIDEgMiAyaDBNMyA0aDEwIiBzdHJva2U9IiM0NDRFNjAiIGZpbGw9Im5vbmUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPjwvc3ZnPg==",
12780
12755
  duplicate: "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMTYiIGhlaWdodD0iMTYiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PGcgc3Ryb2tlPSIjNDQ0RTYwIiBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiPjxwYXRoIGQ9Ik0xMSAySDZhMSAxIDAgMCAwLTEgMXY4YTEgMSAwIDAgMCAxIDFoNmExIDEgMCAwIDAgMS0xVjRoMGwtMi0yeiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIi8+PHBhdGggZD0iTTExIDJ2MWExIDEgMCAwIDAgMSAxaDFsLTItMnoiLz48cGF0aCBkPSJNOSAxNEg0YTEgMSAwIDAgMS0xLTFWNWgwIiBzdHJva2UtbGluZWNhcD0icm91bmQiLz48L2c+PC9zdmc+",
12781
12756
  "layer-pressed": "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzIiIGhlaWdodD0iMzIiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0ibTE2IDEwLTYgNCA2IDQgNi00em0tNiA4IDYgNCA2LTQiIHN0cm9rZT0iIzMzODFGRiIgZmlsbD0ibm9uZSIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIi8+PC9zdmc+",
@@ -12813,9 +12788,9 @@ const mw = "index-module__Container__nLsM3", vw = "index-module__CanvasBox__j2Xe
12813
12788
  "speechBallon-placement": "data:image/svg+xml;base64,PHN2ZyB2aWV3Qm94PSIwIDAgMTAyNCAxMDI0IiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNiIgaGVpZ2h0PSIxNiI+PHBhdGggZD0iTTU3NiAyMTMuMzMzMzMzbDIyLjYxMzMzMyAyMi42MTMzMzRhMzIgMzIgMCAwIDAgMC00NS4yMjY2NjdMNTc2IDIxMy4zMzMzMzN6IG0tNjIuNzItMTA3Ljk0NjY2NmEzMiAzMiAwIDEgMC00NS4yMjY2NjcgNDUuMjI2NjY2bDQ1LjIyNjY2Ny00NS4yMjY2NjZ6IG0tNDUuMjI2NjY3IDE3MC42NjY2NjZhMzIgMzIgMCAwIDAgNDUuMjI2NjY3IDQ1LjIyNjY2N2wtNDUuMjI2NjY3LTQ1LjIyNjY2N3pNNDQ4IDgxMC42NjY2NjdsLTIyLjYxMzMzMy0yMi42MTMzMzRhMzIgMzIgMCAwIDAgMCA0NS4yMjY2NjdsMjIuNjEzMzMzLTIyLjYxMzMzM3ogbTEwNy45NDY2NjctNjIuNzJhMzIgMzIgMCAxIDAtNDUuMjI2NjY3LTQ1LjIyNjY2N2w0NS4yMjY2NjcgNDUuMjI2NjY3eiBtLTQ1LjIyNjY2NyAxNzAuNjY2NjY2YTMyIDMyIDAgMSAwIDQ1LjIyNjY2Ny00NS4yMjY2NjZsLTQ1LjIyNjY2NyA0NS4yMjY2NjZ6TTgxMC42NjY2NjcgNTc2bC0yMi42MTMzMzQgMjIuNjEzMzMzYTMyIDMyIDAgMCAwIDQ1LjIyNjY2NyAwTDgxMC42NjY2NjcgNTc2eiBtMTA3Ljk0NjY2Ni02Mi43MmEzMiAzMiAwIDEgMC00NS4yMjY2NjYtNDUuMjI2NjY3bDQ1LjIyNjY2NiA0NS4yMjY2Njd6IG0tMTcwLjY2NjY2Ni00NS4yMjY2NjdhMzIgMzIgMCAxIDAtNDUuMjI2NjY3IDQ1LjIyNjY2N2w0NS4yMjY2NjctNDUuMjI2NjY3ek0yMTMuMzMzMzMzIDQ0OGwyMi42MTMzMzQtMjIuNjEzMzMzYTMyIDMyIDAgMCAwLTQ1LjIyNjY2NyAwbDIyLjYxMzMzMyAyMi42MTMzMzN6IG02Mi43MiAxMDcuOTQ2NjY3YTMyIDMyIDAgMCAwIDQ1LjIyNjY2Ny00NS4yMjY2NjdsLTQ1LjIyNjY2NyA0NS4yMjY2Njd6IG0tMTcwLjY2NjY2Ni00NS4yMjY2NjdhMzIgMzIgMCAxIDAgNDUuMjI2NjY2IDQ1LjIyNjY2N2wtNDUuMjI2NjY2LTQ1LjIyNjY2N3pNMzA5LjMzMzMzMyAyMTMuMzMzMzMzQTc0LjY2NjY2NyA3NC42NjY2NjcgMCAwIDEgMjM0LjY2NjY2NyAyODh2NjRBMTM4LjY2NjY2NyAxMzguNjY2NjY3IDAgMCAwIDM3My4zMzMzMzMgMjEzLjMzMzMzM2gtNjR6TTIzNC42NjY2NjcgMjg4QTc0LjY2NjY2NyA3NC42NjY2NjcgMCAwIDEgMTYwIDIxMy4zMzMzMzNoLTY0QTEzOC42NjY2NjcgMTM4LjY2NjY2NyAwIDAgMCAyMzQuNjY2NjY3IDM1MnYtNjR6TTE2MCAyMTMuMzMzMzMzYzAtNDEuMjE2IDMzLjQ1MDY2Ny03NC42NjY2NjcgNzQuNjY2NjY3LTc0LjY2NjY2NnYtNjRBMTM4LjY2NjY2NyAxMzguNjY2NjY3IDAgMCAwIDk2IDIxMy4zMzMzMzNoNjR6TTIzNC42NjY2NjcgMTM4LjY2NjY2N2M0MS4yMTYgMCA3NC42NjY2NjcgMzMuNDUwNjY3IDc0LjY2NjY2NiA3NC42NjY2NjZoNjRBMTM4LjY2NjY2NyAxMzguNjY2NjY3IDAgMCAwIDIzNC42NjY2NjcgNzQuNjY2NjY3djY0ek0zNDEuMzMzMzMzIDI0NS4zMzMzMzNoMjM0LjY2NjY2N3YtNjRIMzQxLjMzMzMzM3Y2NHogbTI1Ny4yOC01NC42MTMzMzNsLTg1LjMzMzMzMy04NS4zMzMzMzMtNDUuMjI2NjY3IDQ1LjIyNjY2NiA4NS4zMzMzMzQgODUuMzMzMzM0IDQ1LjIyNjY2Ni00NS4yMjY2Njd6IG0tNDUuMjI2NjY2IDBsLTg1LjMzMzMzNCA4NS4zMzMzMzMgNDUuMjI2NjY3IDQ1LjIyNjY2NyA4NS4zMzMzMzMtODUuMzMzMzMzLTQ1LjIyNjY2Ni00NS4yMjY2Njd6TTY1MC42NjY2NjcgODEwLjY2NjY2N2ExMzguNjY2NjY3IDEzOC42NjY2NjcgMCAwIDAgMTM4LjY2NjY2NiAxMzguNjY2NjY2di02NEE3NC42NjY2NjcgNzQuNjY2NjY3IDAgMCAxIDcxNC42NjY2NjcgODEwLjY2NjY2N2gtNjR6IG0xMzguNjY2NjY2IDEzOC42NjY2NjZBMTM4LjY2NjY2NyAxMzguNjY2NjY3IDAgMCAwIDkyOCA4MTAuNjY2NjY3aC02NGE3NC42NjY2NjcgNzQuNjY2NjY3IDAgMCAxLTc0LjY2NjY2NyA3NC42NjY2NjZ2NjR6TTkyOCA4MTAuNjY2NjY3YTEzOC42NjY2NjcgMTM4LjY2NjY2NyAwIDAgMC0xMzguNjY2NjY3LTEzOC42NjY2Njd2NjRjNDEuMjE2IDAgNzQuNjY2NjY3IDMzLjQ1MDY2NyA3NC42NjY2NjcgNzQuNjY2NjY3aDY0eiBtLTEzOC42NjY2NjctMTM4LjY2NjY2N0ExMzguNjY2NjY3IDEzOC42NjY2NjcgMCAwIDAgNjUwLjY2NjY2NyA4MTAuNjY2NjY3aDY0YzAtNDEuMjE2IDMzLjQ1MDY2Ny03NC42NjY2NjcgNzQuNjY2NjY2LTc0LjY2NjY2N3YtNjR6IG0tMTA2LjY2NjY2NiAxMDYuNjY2NjY3aC0yMzQuNjY2NjY3djY0SDY4Mi42NjY2Njd2LTY0eiBtLTIxMi4wNTMzMzQgNTQuNjEzMzMzbDg1LjMzMzMzNC04NS4zMzMzMzMtNDUuMjI2NjY3LTQ1LjIyNjY2Ny04NS4zMzMzMzMgODUuMzMzMzMzIDQ1LjIyNjY2NiA0NS4yMjY2Njd6IG0tNDUuMjI2NjY2IDBsODUuMzMzMzMzIDg1LjMzMzMzMyA0NS4yMjY2NjctNDUuMjI2NjY2LTg1LjMzMzMzNC04NS4zMzMzMzQtNDUuMjI2NjY2IDQ1LjIyNjY2N3pNNjcyIDIzNC42NjY2NjdBMTM4LjY2NjY2NyAxMzguNjY2NjY3IDAgMCAwIDgxMC42NjY2NjcgMzczLjMzMzMzM3YtNjRhNzQuNjY2NjY3IDc0LjY2NjY2NyAwIDAgMS03NC42NjY2NjctNzQuNjY2NjY2aC02NHpNODEwLjY2NjY2NyAzNzMuMzMzMzMzYTEzOC42NjY2NjcgMTM4LjY2NjY2NyAwIDAgMCAxMzguNjY2NjY2LTEzOC42NjY2NjZoLTY0QTc0LjY2NjY2NyA3NC42NjY2NjcgMCAwIDEgODEwLjY2NjY2NyAzMDkuMzMzMzMzdjY0eiBtMTM4LjY2NjY2Ni0xMzguNjY2NjY2QTEzOC42NjY2NjcgMTM4LjY2NjY2NyAwIDAgMCA4MTAuNjY2NjY3IDk2djY0YzQxLjIxNiAwIDc0LjY2NjY2NyAzMy40NTA2NjcgNzQuNjY2NjY2IDc0LjY2NjY2N2g2NHpNODEwLjY2NjY2NyA5NmExMzguNjY2NjY3IDEzOC42NjY2NjcgMCAwIDAtMTM4LjY2NjY2NyAxMzguNjY2NjY3aDY0YzAtNDEuMjE2IDMzLjQ1MDY2Ny03NC42NjY2NjcgNzQuNjY2NjY3LTc0LjY2NjY2N3YtNjR6TTc3OC42NjY2NjcgMzQxLjMzMzMzM3YyMzQuNjY2NjY3aDY0VjM0MS4zMzMzMzNoLTY0eiBtNTQuNjEzMzMzIDI1Ny4yOGw4NS4zMzMzMzMtODUuMzMzMzMzLTQ1LjIyNjY2Ni00NS4yMjY2NjctODUuMzMzMzM0IDg1LjMzMzMzNCA0NS4yMjY2NjcgNDUuMjI2NjY2eiBtMC00NS4yMjY2NjZsLTg1LjMzMzMzMy04NS4zMzMzMzQtNDUuMjI2NjY3IDQ1LjIyNjY2NyA4NS4zMzMzMzMgODUuMzMzMzMzIDQ1LjIyNjY2Ny00NS4yMjY2NjZ6TTEzOC42NjY2NjcgNzg5LjMzMzMzM2MwLTQxLjIxNiAzMy40NTA2NjctNzQuNjY2NjY3IDc0LjY2NjY2Ni03NC42NjY2NjZ2LTY0YTEzOC42NjY2NjcgMTM4LjY2NjY2NyAwIDAgMC0xMzguNjY2NjY2IDEzOC42NjY2NjZoNjR6TTIxMy4zMzMzMzMgNzE0LjY2NjY2N2M0MS4yMTYgMCA3NC42NjY2NjcgMzMuNDUwNjY3IDc0LjY2NjY2NyA3NC42NjY2NjZoNjRBMTM4LjY2NjY2NyAxMzguNjY2NjY3IDAgMCAwIDIxMy4zMzMzMzMgNjUwLjY2NjY2N3Y2NHogbTc0LjY2NjY2NyA3NC42NjY2NjZBNzQuNjY2NjY3IDc0LjY2NjY2NyAwIDAgMSAyMTMuMzMzMzMzIDg2NHY2NGExMzguNjY2NjY3IDEzOC42NjY2NjcgMCAwIDAgMTM4LjY2NjY2Ny0xMzguNjY2NjY3aC02NHpNMjEzLjMzMzMzMyA4NjRhNzQuNjY2NjY3IDc0LjY2NjY2NyAwIDAgMS03NC42NjY2NjYtNzQuNjY2NjY3aC02NEExMzguNjY2NjY3IDEzOC42NjY2NjcgMCAwIDAgMjEzLjMzMzMzMyA5Mjh2LTY0ek0yNDUuMzMzMzMzIDY4Mi42NjY2Njd2LTIzNC42NjY2NjdoLTY0VjY4Mi42NjY2NjdoNjR6IG0tNTQuNjEzMzMzLTIxMi4wNTMzMzRsODUuMzMzMzMzIDg1LjMzMzMzNCA0NS4yMjY2NjctNDUuMjI2NjY3LTg1LjMzMzMzMy04NS4zMzMzMzMtNDUuMjI2NjY3IDQ1LjIyNjY2NnogbTAtNDUuMjI2NjY2bC04NS4zMzMzMzMgODUuMzMzMzMzIDQ1LjIyNjY2NiA0NS4yMjY2NjcgODUuMzMzMzM0LTg1LjMzMzMzNC00NS4yMjY2NjctNDUuMjI2NjY2eiIgIGZpbGw9IiM0NDRFNjAiPjwvcGF0aD48L3N2Zz4="
12814
12789
  };
12815
12790
  function Dt(a) {
12816
- return Dw[a];
12791
+ return Dm[a];
12817
12792
  }
12818
- const Aw = (a) => {
12793
+ const Am = (a) => {
12819
12794
  const { workIds: i, mananger: t } = a;
12820
12795
  return /* @__PURE__ */ k.createElement(
12821
12796
  "div",
@@ -12832,7 +12807,7 @@ const Aw = (a) => {
12832
12807
  },
12833
12808
  /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt("delete") })
12834
12809
  );
12835
- }, jw = (a) => {
12810
+ }, jm = (a) => {
12836
12811
  const { workIds: i, viewId: t } = a;
12837
12812
  return /* @__PURE__ */ k.createElement(
12838
12813
  "div",
@@ -12851,7 +12826,7 @@ const Aw = (a) => {
12851
12826
  }, lo = (a) => {
12852
12827
  const { icon: i, onPointerUpHandler: t } = a;
12853
12828
  return /* @__PURE__ */ k.createElement("div", { className: "button normal-button", onPointerUp: t }, /* @__PURE__ */ k.createElement("img", { src: Dt(i) }));
12854
- }, Ew = (a) => {
12829
+ }, Em = (a) => {
12855
12830
  const { open: i, setOpen: t, floatBarRef: e } = a, { floatBarData: s, mananger: o } = xt(Ct), [n, r] = nt([]), c = X(() => {
12856
12831
  if (e != null && e.current && _(s == null ? void 0 : s.y) && (o != null && o.height)) {
12857
12832
  if (e.current.offsetTop && e.current.offsetTop + s.y > 180) {
@@ -12900,7 +12875,7 @@ const Aw = (a) => {
12900
12875
  l,
12901
12876
  /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt(i ? "layer-pressed" : "layer") })
12902
12877
  );
12903
- }, Ow = () => /* @__PURE__ */ k.createElement("svg", { style: { marginLeft: "2px" }, viewBox: "0 0 1025 1024", width: "14", height: "14" }, /* @__PURE__ */ k.createElement("path", { d: "M1016.5248 493.8752c-9.984-9.984-26.2144-9.984-36.1984 0l-183.6032 183.6032c-29.952 29.952-78.6944 29.952-108.5952 0l-239.2064-239.2064c-14.4384-14.4384-22.3744-33.6896-22.3744-54.3232s7.936-39.8848 22.3744-54.3232l183.6032-183.6032c9.984-9.984 9.984-26.2144 0-36.1984s-26.2144-9.984-36.1984 0l-183.6032 183.6032c-24.1152 24.1152-37.376 56.2176-37.376 90.5216 0 14.592 2.4576 28.8256 7.0656 42.1888l-374.8864 374.8864c-4.8128 4.8128-7.4752 11.3152-7.4752 18.1248l0 76.8c0 14.1312 11.4688 25.6 25.6 25.6l486.4 0c6.8096 0 13.312-2.7136 18.1248-7.4752l170.0864-170.0864c13.3632 4.6592 27.5968 7.0656 42.1888 7.0656 34.2528 0 66.4064-13.2608 90.5216-37.376l183.6032-183.6032c9.984-9.984 9.984-26.2144 0-36.1984zM501.4016 870.4l-450.2016 0 0-40.6016 358.5024-358.5024c1.024 1.0752 1.9968 2.1504 3.0208 3.1744l239.2064 239.2064c1.024 1.024 2.0992 2.048 3.1744 3.0208l-153.7024 153.7024z", fill: "#000000" })), gn = (a) => {
12878
+ }, Om = () => /* @__PURE__ */ k.createElement("svg", { style: { marginLeft: "2px" }, viewBox: "0 0 1025 1024", width: "14", height: "14" }, /* @__PURE__ */ k.createElement("path", { d: "M1016.5248 493.8752c-9.984-9.984-26.2144-9.984-36.1984 0l-183.6032 183.6032c-29.952 29.952-78.6944 29.952-108.5952 0l-239.2064-239.2064c-14.4384-14.4384-22.3744-33.6896-22.3744-54.3232s7.936-39.8848 22.3744-54.3232l183.6032-183.6032c9.984-9.984 9.984-26.2144 0-36.1984s-26.2144-9.984-36.1984 0l-183.6032 183.6032c-24.1152 24.1152-37.376 56.2176-37.376 90.5216 0 14.592 2.4576 28.8256 7.0656 42.1888l-374.8864 374.8864c-4.8128 4.8128-7.4752 11.3152-7.4752 18.1248l0 76.8c0 14.1312 11.4688 25.6 25.6 25.6l486.4 0c6.8096 0 13.312-2.7136 18.1248-7.4752l170.0864-170.0864c13.3632 4.6592 27.5968 7.0656 42.1888 7.0656 34.2528 0 66.4064-13.2608 90.5216-37.376l183.6032-183.6032c9.984-9.984 9.984-26.2144 0-36.1984zM501.4016 870.4l-450.2016 0 0-40.6016 358.5024-358.5024c1.024 1.0752 1.9968 2.1504 3.0208 3.1744l239.2064 239.2064c1.024 1.024 2.0992 2.048 3.1744 3.0208l-153.7024 153.7024z", fill: "#000000" })), gn = (a) => {
12904
12879
  const { activeColor: i, onPointerUpHandler: t } = a;
12905
12880
  return /* @__PURE__ */ k.createElement(
12906
12881
  "div",
@@ -12980,7 +12955,7 @@ const Aw = (a) => {
12980
12955
  )
12981
12956
  ))
12982
12957
  );
12983
- }, Rw = (a) => {
12958
+ }, Rm = (a) => {
12984
12959
  const { min: i, max: t, activeNumber: e, setActiveNumber: s, color: o } = a, [n, r] = nt({ x: 108, y: 0 });
12985
12960
  if (yt(() => {
12986
12961
  const u = Math.ceil((e - i) / (t - i) * 100) + 8;
@@ -13042,7 +13017,7 @@ const Aw = (a) => {
13042
13017
  )
13043
13018
  ))
13044
13019
  );
13045
- }, Ww = (a) => {
13020
+ }, Wm = (a) => {
13046
13021
  const { useStroke: i, color: t, activeStrokeType: e, setStrokeType: s } = a;
13047
13022
  return /* @__PURE__ */ k.createElement("div", { className: "stroke-type-box" }, !!i && /* @__PURE__ */ k.createElement(
13048
13023
  "div",
@@ -13081,39 +13056,39 @@ const Aw = (a) => {
13081
13056
  }
13082
13057
  }
13083
13058
  ));
13084
- }, Yw = (a) => {
13059
+ }, Ym = (a) => {
13085
13060
  const { open: i, setOpen: t, floatBarRef: e } = a, { floatBarData: s, floatBarColors: o, mananger: n, setFloatBarData: r } = xt(Ct), [c, l] = nt(), [h, u] = nt(1);
13086
13061
  yt(() => {
13087
13062
  if (s != null && s.strokeColor) {
13088
- const [m, S] = Ti(s.strokeColor);
13089
- l(m), u(S);
13063
+ const [w, S] = Ti(s.strokeColor);
13064
+ l(w), u(S);
13090
13065
  }
13091
13066
  }, [s]);
13092
13067
  const d = X(() => {
13093
13068
  if (e != null && e.current && _(s == null ? void 0 : s.y) && (n != null && n.height)) {
13094
13069
  if (e.current.offsetTop && e.current.offsetTop + s.y > 180) {
13095
- const m = {};
13096
- return m.top = "inherit", m.bottom = 50, m;
13070
+ const w = {};
13071
+ return w.top = "inherit", w.bottom = 50, w;
13097
13072
  } else if (!e.current.offsetTop && (n == null ? void 0 : n.height) - e.current.offsetTop - s.y < 120) {
13098
- const m = {};
13099
- return m.top = "inherit", m.bottom = 50, m;
13073
+ const w = {};
13074
+ return w.top = "inherit", w.bottom = 50, w;
13100
13075
  }
13101
13076
  }
13102
- }, [(e == null ? void 0 : e.current) && s, n == null ? void 0 : n.height]), f = X(() => /* @__PURE__ */ k.createElement(Ci, { key: "strokeColors", opacity: h, activeColor: c, setCurOpacity: (m, S, T) => {
13103
- T === P.Start && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !0), T === P.Done && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !1), u(m);
13104
- const N = Lt(S, m);
13077
+ }, [(e == null ? void 0 : e.current) && s, n == null ? void 0 : n.height]), f = X(() => /* @__PURE__ */ k.createElement(Ci, { key: "strokeColors", opacity: h, activeColor: c, setCurOpacity: (w, S, T) => {
13078
+ T === P.Start && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !0), T === P.Done && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !1), u(w);
13079
+ const N = Lt(S, w);
13105
13080
  s != null && s.strokeColor && r({ strokeColor: N }), rt.emitMethod(
13106
13081
  ot.MainEngine,
13107
13082
  B.SetColorNode,
13108
13083
  { workIds: [H], strokeColor: N, workState: T, viewId: n == null ? void 0 : n.viewId }
13109
13084
  );
13110
13085
  } }), [h, c, n == null ? void 0 : n.control.room, n == null ? void 0 : n.viewId, s]), g = X(() => {
13111
- var m, S;
13086
+ var w, S;
13112
13087
  return c && (s != null && s.thickness) ? /* @__PURE__ */ k.createElement(
13113
- Rw,
13088
+ Rm,
13114
13089
  {
13115
13090
  key: "strokeThickness",
13116
- min: Math.min(s.thickness, ((m = n == null ? void 0 : n.control.pluginOptions.strokeWidth) == null ? void 0 : m.min) || 1),
13091
+ min: Math.min(s.thickness, ((w = n == null ? void 0 : n.control.pluginOptions.strokeWidth) == null ? void 0 : w.min) || 1),
13117
13092
  max: Math.max(s.thickness, ((S = n == null ? void 0 : n.control.pluginOptions.strokeWidth) == null ? void 0 : S.max) || 10),
13118
13093
  activeNumber: s.thickness,
13119
13094
  setActiveNumber: (T, N) => {
@@ -13127,16 +13102,16 @@ const Aw = (a) => {
13127
13102
  }
13128
13103
  ) : null;
13129
13104
  }, [c, s == null ? void 0 : s.thickness, n == null ? void 0 : n.control.room, n == null ? void 0 : n.viewId]), p = X(() => c && (s != null && s.strokeType) ? /* @__PURE__ */ k.createElement(
13130
- Ww,
13105
+ Wm,
13131
13106
  {
13132
13107
  key: "strokeType",
13133
13108
  useStroke: s == null ? void 0 : s.useStroke,
13134
13109
  activeStrokeType: s.strokeType,
13135
- setStrokeType: (m) => {
13136
- s.strokeType && r({ strokeType: m }), rt.emitMethod(
13110
+ setStrokeType: (w) => {
13111
+ s.strokeType && r({ strokeType: w }), rt.emitMethod(
13137
13112
  ot.MainEngine,
13138
13113
  B.SetColorNode,
13139
- { workIds: [H], strokeType: m, workState: P.Done, viewId: n == null ? void 0 : n.viewId }
13114
+ { workIds: [H], strokeType: w, workState: P.Done, viewId: n == null ? void 0 : n.viewId }
13140
13115
  );
13141
13116
  },
13142
13117
  color: c
@@ -13146,15 +13121,15 @@ const Aw = (a) => {
13146
13121
  {
13147
13122
  className: "font-colors-menu",
13148
13123
  style: d,
13149
- onPointerUp: (m) => {
13150
- m.stopPropagation(), m.nativeEvent.stopImmediatePropagation();
13124
+ onPointerUp: (w) => {
13125
+ w.stopPropagation(), w.nativeEvent.stopImmediatePropagation();
13151
13126
  }
13152
13127
  },
13153
13128
  p,
13154
13129
  g,
13155
13130
  /* @__PURE__ */ k.createElement("div", { className: "font-colors-line" }),
13156
- o.concat().map((m, S) => {
13157
- const T = Xe(...m);
13131
+ o.concat().map((w, S) => {
13132
+ const T = Xe(...w);
13158
13133
  return /* @__PURE__ */ k.createElement(
13159
13134
  ki,
13160
13135
  {
@@ -13163,11 +13138,11 @@ const Aw = (a) => {
13163
13138
  activeColor: c,
13164
13139
  onPointerUpHandler: (N) => {
13165
13140
  N.stopPropagation(), l(T);
13166
- const w = Lt(T, h);
13167
- s != null && s.strokeColor && (s.strokeColor = w, r({ strokeColor: w })), rt.emitMethod(
13141
+ const m = Lt(T, h);
13142
+ s != null && s.strokeColor && (s.strokeColor = m, r({ strokeColor: m })), rt.emitMethod(
13168
13143
  ot.MainEngine,
13169
13144
  B.SetColorNode,
13170
- { workIds: [H], workState: P.Done, strokeColor: w, viewId: n == null ? void 0 : n.viewId }
13145
+ { workIds: [H], workState: P.Done, strokeColor: m, viewId: n == null ? void 0 : n.viewId }
13171
13146
  );
13172
13147
  }
13173
13148
  }
@@ -13179,14 +13154,14 @@ const Aw = (a) => {
13179
13154
  "div",
13180
13155
  {
13181
13156
  className: `button normal-button font-colors-icon ${i && "active"}`,
13182
- onPointerUp: (m) => {
13183
- m.stopPropagation(), m.nativeEvent.stopImmediatePropagation(), t(!i);
13157
+ onPointerUp: (w) => {
13158
+ w.stopPropagation(), w.nativeEvent.stopImmediatePropagation(), t(!i);
13184
13159
  }
13185
13160
  },
13186
13161
  v,
13187
13162
  M
13188
13163
  );
13189
- }, Uw = (a) => {
13164
+ }, Um = (a) => {
13190
13165
  const { open: i, setOpen: t, floatBarRef: e } = a, { floatBarData: s, floatBarColors: o, mananger: n, setFloatBarData: r } = xt(Ct), [c, l] = nt(), [h, u] = nt(1);
13191
13166
  yt(() => {
13192
13167
  if (s != null && s.fillColor) {
@@ -13204,13 +13179,13 @@ const Aw = (a) => {
13204
13179
  return M.top = "inherit", M.bottom = 50, M;
13205
13180
  }
13206
13181
  }
13207
- }, [e == null ? void 0 : e.current, s, n == null ? void 0 : n.height]), f = X(() => c && c !== "transparent" ? /* @__PURE__ */ k.createElement(Ci, { key: "fillColors", opacity: h || 0, activeColor: c, setCurOpacity: (M, v, m) => {
13208
- m === P.Start && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !0), m === P.Done && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !1), u(M);
13182
+ }, [e == null ? void 0 : e.current, s, n == null ? void 0 : n.height]), f = X(() => c && c !== "transparent" ? /* @__PURE__ */ k.createElement(Ci, { key: "fillColors", opacity: h || 0, activeColor: c, setCurOpacity: (M, v, w) => {
13183
+ w === P.Start && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !0), w === P.Done && (n != null && n.control.room) && (n.control.room.disableDeviceInputs = !1), u(M);
13209
13184
  const S = Lt(v, M);
13210
13185
  s != null && s.fillColor && (s.fillColor = S, r({ fillColor: S })), rt.emitMethod(
13211
13186
  ot.MainEngine,
13212
13187
  B.SetColorNode,
13213
- { workIds: [H], fillColor: c && Lt(v, M), workState: m, viewId: n == null ? void 0 : n.viewId }
13188
+ { workIds: [H], fillColor: c && Lt(v, M), workState: w, viewId: n == null ? void 0 : n.viewId }
13214
13189
  );
13215
13190
  } }) : null, [c, h, n == null ? void 0 : n.control.room, n == null ? void 0 : n.viewId, s]), g = X(() => i ? /* @__PURE__ */ k.createElement(
13216
13191
  "div",
@@ -13237,16 +13212,16 @@ const Aw = (a) => {
13237
13212
  }
13238
13213
  ),
13239
13214
  o.map((M, v) => {
13240
- const m = Xe(...M);
13215
+ const w = Xe(...M);
13241
13216
  return /* @__PURE__ */ k.createElement(
13242
13217
  ki,
13243
13218
  {
13244
13219
  key: v,
13245
- color: m,
13220
+ color: w,
13246
13221
  activeColor: c,
13247
13222
  onPointerUpHandler: (S) => {
13248
- S.cancelable && S.preventDefault(), S.stopPropagation(), l(m);
13249
- const T = Lt(m, h);
13223
+ S.cancelable && S.preventDefault(), S.stopPropagation(), l(w);
13224
+ const T = Lt(w, h);
13250
13225
  s != null && s.fillColor && (s.fillColor = T, r({ fillColor: T })), rt.emitMethod(
13251
13226
  ot.MainEngine,
13252
13227
  B.SetColorNode,
@@ -13272,27 +13247,27 @@ const Aw = (a) => {
13272
13247
  p,
13273
13248
  g
13274
13249
  );
13275
- }, Bw = (a) => {
13250
+ }, Bm = (a) => {
13276
13251
  const { open: i, setOpen: t, textOpt: e, workIds: s, floatBarRef: o } = a, { floatBarColors: n, mananger: r, setFloatBarData: c, floatBarData: l } = xt(Ct), [h, u] = nt(), [d, f] = nt(1);
13277
13252
  yt(() => {
13278
13253
  if (e != null && e.fontColor) {
13279
- const [m, S] = (e == null ? void 0 : e.fontColor) === "transparent" && ["transparent", 0] || Ti(e.fontColor);
13280
- u(m), f(S);
13254
+ const [w, S] = (e == null ? void 0 : e.fontColor) === "transparent" && ["transparent", 0] || Ti(e.fontColor);
13255
+ u(w), f(S);
13281
13256
  }
13282
13257
  }, [e == null ? void 0 : e.fontColor]);
13283
13258
  const g = X(() => {
13284
13259
  if (o != null && o.current && _(l == null ? void 0 : l.y) && (r != null && r.height)) {
13285
13260
  if (o.current.offsetTop && o.current.offsetTop + l.y > 180) {
13286
- const m = {};
13287
- return m.top = "inherit", m.bottom = 50, m;
13261
+ const w = {};
13262
+ return w.top = "inherit", w.bottom = 50, w;
13288
13263
  } else if (!o.current.offsetTop && (r == null ? void 0 : r.height) - o.current.offsetTop - l.y < 120) {
13289
- const m = {};
13290
- return m.top = "inherit", m.bottom = 50, m;
13264
+ const w = {};
13265
+ return w.top = "inherit", w.bottom = 50, w;
13291
13266
  }
13292
13267
  }
13293
- }, [o == null ? void 0 : o.current, l, r]), p = X(() => h && h !== "transparent" ? /* @__PURE__ */ k.createElement(Ci, { key: "fontColors", opacity: d, activeColor: h, setCurOpacity: (m, S, T) => {
13294
- T === P.Start && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !0), T === P.Done && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !1), f(m);
13295
- const N = Lt(S, m);
13268
+ }, [o == null ? void 0 : o.current, l, r]), p = X(() => h && h !== "transparent" ? /* @__PURE__ */ k.createElement(Ci, { key: "fontColors", opacity: d, activeColor: h, setCurOpacity: (w, S, T) => {
13269
+ T === P.Start && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !0), T === P.Done && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !1), f(w);
13270
+ const N = Lt(S, w);
13296
13271
  l != null && l.textOpt && (l.textOpt.fontColor = N, c({ textOpt: l.textOpt })), rt.emitMethod(
13297
13272
  ot.MainEngine,
13298
13273
  B.SetColorNode,
@@ -13308,12 +13283,12 @@ const Aw = (a) => {
13308
13283
  {
13309
13284
  className: "font-colors-menu",
13310
13285
  style: g,
13311
- onPointerUp: (m) => {
13312
- m.stopPropagation(), m.nativeEvent.stopImmediatePropagation();
13286
+ onPointerUp: (w) => {
13287
+ w.stopPropagation(), w.nativeEvent.stopImmediatePropagation();
13313
13288
  }
13314
13289
  },
13315
- n.map((m, S) => {
13316
- const T = Xe(...m);
13290
+ n.map((w, S) => {
13291
+ const T = Xe(...w);
13317
13292
  return /* @__PURE__ */ k.createElement(
13318
13293
  ki,
13319
13294
  {
@@ -13322,11 +13297,11 @@ const Aw = (a) => {
13322
13297
  activeColor: h,
13323
13298
  onPointerUpHandler: (N) => {
13324
13299
  N.stopPropagation(), u(T);
13325
- const w = Lt(T, d);
13326
- l != null && l.textOpt && (l.textOpt.fontColor = w, c({ textOpt: l.textOpt })), rt.emitMethod(
13300
+ const m = Lt(T, d);
13301
+ l != null && l.textOpt && (l.textOpt.fontColor = m, c({ textOpt: l.textOpt })), rt.emitMethod(
13327
13302
  ot.MainEngine,
13328
13303
  B.SetColorNode,
13329
- { workIds: s || [H], workState: P.Done, fontColor: w, viewId: r == null ? void 0 : r.viewId }
13304
+ { workIds: s || [H], workState: P.Done, fontColor: m, viewId: r == null ? void 0 : r.viewId }
13330
13305
  );
13331
13306
  }
13332
13307
  }
@@ -13334,48 +13309,48 @@ const Aw = (a) => {
13334
13309
  }),
13335
13310
  p
13336
13311
  ) : null, [i, n, p, h, d, l == null ? void 0 : l.textOpt, s, r == null ? void 0 : r.viewId, g]), v = X(() => {
13337
- const m = h && h !== "transparent" && Lt(h, d) || "transparent";
13338
- return /* @__PURE__ */ k.createElement("div", { className: "color-bar" }, /* @__PURE__ */ k.createElement("div", { className: "color-bar-color", style: { backgroundColor: m } }));
13312
+ const w = h && h !== "transparent" && Lt(h, d) || "transparent";
13313
+ return /* @__PURE__ */ k.createElement("div", { className: "color-bar" }, /* @__PURE__ */ k.createElement("div", { className: "color-bar-color", style: { backgroundColor: w } }));
13339
13314
  }, [h, d]);
13340
13315
  return /* @__PURE__ */ k.createElement(
13341
13316
  "div",
13342
13317
  {
13343
13318
  className: `button normal-button font-colors-icon ${i && "active"}`,
13344
- onPointerUp: (m) => {
13345
- m.stopPropagation(), m.nativeEvent.stopImmediatePropagation(), t(!i);
13319
+ onPointerUp: (w) => {
13320
+ w.stopPropagation(), w.nativeEvent.stopImmediatePropagation(), t(!i);
13346
13321
  }
13347
13322
  },
13348
13323
  /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt("font-colors") }),
13349
13324
  v,
13350
13325
  M
13351
13326
  );
13352
- }, Fw = (a) => {
13327
+ }, Fm = (a) => {
13353
13328
  const { open: i, setOpen: t, textOpt: e, workIds: s, floatBarRef: o } = a, { floatBarColors: n, mananger: r, setFloatBarData: c, floatBarData: l } = xt(Ct), [h, u] = nt(), [d, f] = nt(1);
13354
13329
  yt(() => {
13355
13330
  if (e != null && e.fontBgColor) {
13356
- const [m, S] = (e == null ? void 0 : e.fontBgColor) === "transparent" && ["transparent", 1] || Ti(e.fontBgColor);
13357
- u(m), f(S);
13331
+ const [w, S] = (e == null ? void 0 : e.fontBgColor) === "transparent" && ["transparent", 1] || Ti(e.fontBgColor);
13332
+ u(w), f(S);
13358
13333
  }
13359
13334
  }, [e == null ? void 0 : e.fontBgColor]);
13360
13335
  const g = X(() => {
13361
13336
  if (o != null && o.current && _(l == null ? void 0 : l.y) && (r != null && r.height)) {
13362
13337
  if (o.current.offsetTop && o.current.offsetTop + l.y > 180) {
13363
- const m = {};
13364
- return m.top = "inherit", m.bottom = 50, m;
13338
+ const w = {};
13339
+ return w.top = "inherit", w.bottom = 50, w;
13365
13340
  } else if (!o.current.offsetTop && (r == null ? void 0 : r.height) - o.current.offsetTop - l.y < 120) {
13366
- const m = {};
13367
- return m.top = "inherit", m.bottom = 50, m;
13341
+ const w = {};
13342
+ return w.top = "inherit", w.bottom = 50, w;
13368
13343
  }
13369
13344
  }
13370
- }, [o == null ? void 0 : o.current, l, r]), p = X(() => h && h !== "transparent" ? /* @__PURE__ */ k.createElement(Ci, { key: "fontBgColor", opacity: d || 0, activeColor: h, setCurOpacity: (m, S, T) => {
13371
- T === P.Start && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !0), T === P.Done && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !1), f(m);
13372
- const N = Lt(S, m);
13345
+ }, [o == null ? void 0 : o.current, l, r]), p = X(() => h && h !== "transparent" ? /* @__PURE__ */ k.createElement(Ci, { key: "fontBgColor", opacity: d || 0, activeColor: h, setCurOpacity: (w, S, T) => {
13346
+ T === P.Start && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !0), T === P.Done && (r != null && r.control.room) && (r.control.room.disableDeviceInputs = !1), f(w);
13347
+ const N = Lt(S, w);
13373
13348
  l != null && l.textOpt && (l.textOpt.fontBgColor = N, c({ textOpt: l.textOpt })), rt.emitMethod(
13374
13349
  ot.MainEngine,
13375
13350
  B.SetColorNode,
13376
13351
  {
13377
13352
  workIds: s || [H],
13378
- fontBgColor: h && Lt(S, m),
13353
+ fontBgColor: h && Lt(S, w),
13379
13354
  workState: T,
13380
13355
  viewId: r == null ? void 0 : r.viewId
13381
13356
  }
@@ -13385,16 +13360,16 @@ const Aw = (a) => {
13385
13360
  {
13386
13361
  className: "font-colors-menu",
13387
13362
  style: g,
13388
- onPointerUp: (m) => {
13389
- m.stopPropagation(), m.nativeEvent.stopImmediatePropagation();
13363
+ onPointerUp: (w) => {
13364
+ w.stopPropagation(), w.nativeEvent.stopImmediatePropagation();
13390
13365
  }
13391
13366
  },
13392
13367
  /* @__PURE__ */ k.createElement(
13393
13368
  gn,
13394
13369
  {
13395
13370
  activeColor: h,
13396
- onPointerUpHandler: (m) => {
13397
- m.stopPropagation();
13371
+ onPointerUpHandler: (w) => {
13372
+ w.stopPropagation();
13398
13373
  const S = "transparent";
13399
13374
  u(S), l != null && l.textOpt && (l.textOpt.fontBgColor = S, c({ textOpt: l.textOpt })), rt.emitMethod(
13400
13375
  ot.MainEngine,
@@ -13404,8 +13379,8 @@ const Aw = (a) => {
13404
13379
  }
13405
13380
  }
13406
13381
  ),
13407
- n.map((m, S) => {
13408
- const T = Xe(...m);
13382
+ n.map((w, S) => {
13383
+ const T = Xe(...w);
13409
13384
  return /* @__PURE__ */ k.createElement(
13410
13385
  ki,
13411
13386
  {
@@ -13414,8 +13389,8 @@ const Aw = (a) => {
13414
13389
  activeColor: h,
13415
13390
  onPointerUpHandler: (N) => {
13416
13391
  N.stopPropagation(), u(T);
13417
- const w = Lt(T, d);
13418
- l != null && l.textOpt && (l.textOpt.fontBgColor = w, c({ textOpt: l.textOpt })), rt.emitMethod(
13392
+ const m = Lt(T, d);
13393
+ l != null && l.textOpt && (l.textOpt.fontBgColor = m, c({ textOpt: l.textOpt })), rt.emitMethod(
13419
13394
  ot.MainEngine,
13420
13395
  B.SetColorNode,
13421
13396
  { workIds: s || [H], workState: P.Done, fontBgColor: Lt(T, d), viewId: r == null ? void 0 : r.viewId }
@@ -13426,22 +13401,22 @@ const Aw = (a) => {
13426
13401
  }),
13427
13402
  p
13428
13403
  ) : null, [i, n, p, d, h, l == null ? void 0 : l.textOpt, s, r == null ? void 0 : r.viewId, g]), v = X(() => {
13429
- const m = h && h !== "transparent" && Lt(h, d) || "transparent";
13430
- return /* @__PURE__ */ k.createElement("div", { className: "color-bar", style: { marginTop: 0 } }, /* @__PURE__ */ k.createElement("div", { className: "color-bar-color", style: { backgroundColor: m } }));
13404
+ const w = h && h !== "transparent" && Lt(h, d) || "transparent";
13405
+ return /* @__PURE__ */ k.createElement("div", { className: "color-bar", style: { marginTop: 0 } }, /* @__PURE__ */ k.createElement("div", { className: "color-bar-color", style: { backgroundColor: w } }));
13431
13406
  }, [h, d]);
13432
13407
  return /* @__PURE__ */ k.createElement(
13433
13408
  "div",
13434
13409
  {
13435
13410
  className: `button normal-button font-colors-icon ${i && "active"}`,
13436
- onPointerUp: (m) => {
13437
- m.stopPropagation(), m.nativeEvent.stopImmediatePropagation(), t(!i);
13411
+ onPointerUp: (w) => {
13412
+ w.stopPropagation(), w.nativeEvent.stopImmediatePropagation(), t(!i);
13438
13413
  }
13439
13414
  },
13440
- /* @__PURE__ */ k.createElement(Ow, null),
13415
+ /* @__PURE__ */ k.createElement(Om, null),
13441
13416
  v,
13442
13417
  M
13443
13418
  );
13444
- }, $w = (a) => {
13419
+ }, $m = (a) => {
13445
13420
  const { bold: i, setBold: t, workIds: e, viewId: s } = a, o = (n) => {
13446
13421
  const r = i === "bold" ? "normal" : "bold";
13447
13422
  n == null || n.stopPropagation(), t(r), rt.emitMethod(
@@ -13458,7 +13433,7 @@ const Aw = (a) => {
13458
13433
  },
13459
13434
  /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt(i === "bold" ? "bold-active" : "bold") })
13460
13435
  );
13461
- }, Vw = (a) => {
13436
+ }, Vm = (a) => {
13462
13437
  const { underline: i, setUnderline: t, workIds: e, viewId: s } = a, o = (n) => {
13463
13438
  const r = !i;
13464
13439
  n == null || n.stopPropagation(), t(r), rt.emitMethod(
@@ -13475,7 +13450,7 @@ const Aw = (a) => {
13475
13450
  },
13476
13451
  /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt(i ? "underline-active" : "underline") })
13477
13452
  );
13478
- }, Hw = (a) => {
13453
+ }, Hm = (a) => {
13479
13454
  const { lineThrough: i, setLineThrough: t, workIds: e, viewId: s } = a, o = (n) => {
13480
13455
  const r = !i;
13481
13456
  n == null || n.stopPropagation(), t(r), rt.emitMethod(
@@ -13485,7 +13460,7 @@ const Aw = (a) => {
13485
13460
  );
13486
13461
  };
13487
13462
  return /* @__PURE__ */ k.createElement("div", { className: "font-style-button", onPointerUp: o }, /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt(i ? "line-through-active" : "line-through") }));
13488
- }, Qw = (a) => {
13463
+ }, Qm = (a) => {
13489
13464
  const { italic: i, setItalic: t, workIds: e, viewId: s } = a, o = (n) => {
13490
13465
  const r = i === "italic" ? "normal" : "italic";
13491
13466
  n == null || n.stopPropagation(), t(r), rt.emitMethod(
@@ -13495,7 +13470,7 @@ const Aw = (a) => {
13495
13470
  );
13496
13471
  };
13497
13472
  return /* @__PURE__ */ k.createElement("div", { className: "font-style-button", onPointerUp: o }, /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt(i === "italic" ? "italic-active" : "italic") }));
13498
- }, Gw = (a) => {
13473
+ }, Gm = (a) => {
13499
13474
  const { open: i, setOpen: t, textOpt: e, workIds: s, style: o, floatBarRef: n } = a, { mananger: r, floatBarData: c } = xt(Ct), [l, h] = nt("normal"), [u, d] = nt("normal"), [f, g] = nt(!1), [p, M] = nt(!1);
13500
13475
  yt(() => {
13501
13476
  e != null && e.bold && h(e.bold), Ut(e == null ? void 0 : e.underline) && g(e.underline || !1), Ut(e == null ? void 0 : e.lineThrough) && M(e.lineThrough || !1), e != null && e.italic && d(e.italic);
@@ -13510,7 +13485,7 @@ const Aw = (a) => {
13510
13485
  return S.top = "inherit", S.bottom = 50, S;
13511
13486
  }
13512
13487
  }
13513
- }, [o, n == null ? void 0 : n.current, c, r]), m = X(() => i ? /* @__PURE__ */ k.createElement(
13488
+ }, [o, n == null ? void 0 : n.current, c, r]), w = X(() => i ? /* @__PURE__ */ k.createElement(
13514
13489
  "div",
13515
13490
  {
13516
13491
  className: "font-style-menu",
@@ -13519,10 +13494,10 @@ const Aw = (a) => {
13519
13494
  S.stopPropagation(), S.nativeEvent.stopImmediatePropagation();
13520
13495
  }
13521
13496
  },
13522
- /* @__PURE__ */ k.createElement($w, { workIds: s || [H], bold: l, setBold: h, viewId: r == null ? void 0 : r.viewId }),
13523
- /* @__PURE__ */ k.createElement(Vw, { workIds: s || [H], underline: f, setUnderline: g, viewId: r == null ? void 0 : r.viewId }),
13524
- /* @__PURE__ */ k.createElement(Hw, { workIds: s || [H], lineThrough: p, setLineThrough: M, viewId: r == null ? void 0 : r.viewId }),
13525
- /* @__PURE__ */ k.createElement(Qw, { workIds: s || [H], italic: u, setItalic: d, viewId: r == null ? void 0 : r.viewId })
13497
+ /* @__PURE__ */ k.createElement($m, { workIds: s || [H], bold: l, setBold: h, viewId: r == null ? void 0 : r.viewId }),
13498
+ /* @__PURE__ */ k.createElement(Vm, { workIds: s || [H], underline: f, setUnderline: g, viewId: r == null ? void 0 : r.viewId }),
13499
+ /* @__PURE__ */ k.createElement(Hm, { workIds: s || [H], lineThrough: p, setLineThrough: M, viewId: r == null ? void 0 : r.viewId }),
13500
+ /* @__PURE__ */ k.createElement(Qm, { workIds: s || [H], italic: u, setItalic: d, viewId: r == null ? void 0 : r.viewId })
13526
13501
  ) : null, [i, s, l, r == null ? void 0 : r.viewId, f, p, u, v]);
13527
13502
  return /* @__PURE__ */ k.createElement(
13528
13503
  "div",
@@ -13533,7 +13508,7 @@ const Aw = (a) => {
13533
13508
  }
13534
13509
  },
13535
13510
  /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt(i ? "font-style-active" : "font-style") }),
13536
- m
13511
+ w
13537
13512
  );
13538
13513
  }, te = Object.freeze([
13539
13514
  12,
@@ -13559,7 +13534,7 @@ const Aw = (a) => {
13559
13534
  "right",
13560
13535
  "rightTop",
13561
13536
  "rightBottom"
13562
- ], Zw = (a) => {
13537
+ ], Zm = (a) => {
13563
13538
  const { style: i, onClickHandler: t } = a;
13564
13539
  return /* @__PURE__ */ k.createElement(
13565
13540
  "div",
@@ -13582,7 +13557,7 @@ const Aw = (a) => {
13582
13557
  e
13583
13558
  ))
13584
13559
  );
13585
- }, Xw = (a) => {
13560
+ }, Xm = (a) => {
13586
13561
  const i = De(null), { open: t, setOpen: e, textOpt: s, workIds: o, floatBarRef: n } = a, { mananger: r, floatBarData: c } = xt(Ct), [l, h] = nt(0), [u, d] = nt(), f = te.length - 1;
13587
13562
  yt(() => {
13588
13563
  s != null && s.fontSize && (h(s.fontSize), i.current && (i.current.value = s.fontSize.toString()));
@@ -13607,8 +13582,8 @@ const Aw = (a) => {
13607
13582
  }
13608
13583
  const M = (S) => {
13609
13584
  var T;
13610
- (T = i.current) == null || T.blur(), e(!1), m(S);
13611
- }, v = X(() => t ? /* @__PURE__ */ k.createElement(Zw, { onClickHandler: M, style: g }) : null, [t, M, g]), m = (S) => {
13585
+ (T = i.current) == null || T.blur(), e(!1), w(S);
13586
+ }, v = X(() => t ? /* @__PURE__ */ k.createElement(Zm, { onClickHandler: M, style: g }) : null, [t, M, g]), w = (S) => {
13612
13587
  S > te[f] && (S = te[f]), S < te[0] && (S = te[0]), p(S);
13613
13588
  };
13614
13589
  return yt(() => () => {
@@ -13644,8 +13619,8 @@ const Aw = (a) => {
13644
13619
  onKeyUp: (S) => {
13645
13620
  var T;
13646
13621
  if (i.current) {
13647
- const N = i.current.value, w = parseInt(N);
13648
- isNaN(w) ? i.current.value = "0" : i.current.value = w.toString(), w && S.key === "Enter" && (m(w), (T = i.current) == null || T.blur(), e(!1));
13622
+ const N = i.current.value, m = parseInt(N);
13623
+ isNaN(m) ? i.current.value = "0" : i.current.value = m.toString(), m && S.key === "Enter" && (w(m), (T = i.current) == null || T.blur(), e(!1));
13649
13624
  }
13650
13625
  },
13651
13626
  onFocus: () => {
@@ -13661,7 +13636,7 @@ const Aw = (a) => {
13661
13636
  {
13662
13637
  className: "font-size-add",
13663
13638
  onPointerUp: () => {
13664
- m(l + te[0]);
13639
+ w(l + te[0]);
13665
13640
  }
13666
13641
  }
13667
13642
  ), /* @__PURE__ */ k.createElement(
@@ -13669,13 +13644,13 @@ const Aw = (a) => {
13669
13644
  {
13670
13645
  className: "font-size-cut",
13671
13646
  onPointerUp: () => {
13672
- m(l - te[0]);
13647
+ w(l - te[0]);
13673
13648
  }
13674
13649
  }
13675
13650
  )),
13676
13651
  v
13677
13652
  );
13678
- }, Jw = (a) => {
13653
+ }, Jm = (a) => {
13679
13654
  const { workIds: i, mananger: t, islocked: e } = a;
13680
13655
  return /* @__PURE__ */ k.createElement(
13681
13656
  "div",
@@ -13752,10 +13727,10 @@ const Aw = (a) => {
13752
13727
  }
13753
13728
  ))
13754
13729
  );
13755
- }, qw = (a) => {
13730
+ }, qm = (a) => {
13756
13731
  const { icon: i, min: t, max: e, step: s, value: o, onInputHandler: n } = a;
13757
- return /* @__PURE__ */ k.createElement("div", { className: "button input-button" }, /* @__PURE__ */ k.createElement("img", { src: Dt(i) }), /* @__PURE__ */ k.createElement(Kw, { min: t, max: e, step: s, value: o, onInputHandler: n }));
13758
- }, Kw = (a) => {
13732
+ return /* @__PURE__ */ k.createElement("div", { className: "button input-button" }, /* @__PURE__ */ k.createElement("img", { src: Dt(i) }), /* @__PURE__ */ k.createElement(Km, { min: t, max: e, step: s, value: o, onInputHandler: n }));
13733
+ }, Km = (a) => {
13759
13734
  const { value: i, min: t, max: e, onInputHandler: s } = a, [o, n] = nt({ x: 0, y: 0 });
13760
13735
  yt(() => {
13761
13736
  n({ x: i * 100, y: 0 });
@@ -13801,7 +13776,7 @@ const Aw = (a) => {
13801
13776
  /* @__PURE__ */ k.createElement("div", { className: "circle", onClick: c })
13802
13777
  ))
13803
13778
  );
13804
- }, _w = (a) => {
13779
+ }, _m = (a) => {
13805
13780
  const { icon: i, value: t, onChangeHandler: e, style: s } = a, [o, n] = nt(0), [r, c] = nt(), l = De(null), h = Cn((f) => {
13806
13781
  f >= Te.length && (f = 0), f < 0 && (f = Te.length - 1), n(f), e(Te[f]), c(!1), l.current && (l.current.value = Te[f]);
13807
13782
  }, [e]), u = X(() => {
@@ -13813,7 +13788,7 @@ const Aw = (a) => {
13813
13788
  yt(() => {
13814
13789
  t && (n(Te.indexOf(t)), l.current && (l.current.value = t));
13815
13790
  }, [t]);
13816
- const d = X(() => r ? /* @__PURE__ */ k.createElement(tm, { options: Te, onClickHandler: h, style: u }) : null, [r, h, u]);
13791
+ const d = X(() => r ? /* @__PURE__ */ k.createElement(tw, { options: Te, onClickHandler: h, style: u }) : null, [r, h, u]);
13817
13792
  return /* @__PURE__ */ k.createElement("div", { className: "button input-button" }, /* @__PURE__ */ k.createElement("img", { src: Dt(i) }), /* @__PURE__ */ k.createElement(
13818
13793
  "input",
13819
13794
  {
@@ -13845,7 +13820,7 @@ const Aw = (a) => {
13845
13820
  }
13846
13821
  }
13847
13822
  )), d);
13848
- }, tm = (a) => {
13823
+ }, tw = (a) => {
13849
13824
  const { options: i, style: t, onClickHandler: e } = a;
13850
13825
  return /* @__PURE__ */ k.createElement(
13851
13826
  "div",
@@ -13868,7 +13843,7 @@ const Aw = (a) => {
13868
13843
  s
13869
13844
  ))
13870
13845
  );
13871
- }, em = (a) => {
13846
+ }, ew = (a) => {
13872
13847
  const { mananger: i, innerRatio: t, innerVerticeStep: e, vertices: s } = a, o = (c) => {
13873
13848
  rt.emitMethod(
13874
13849
  ot.MainEngine,
@@ -13903,8 +13878,8 @@ const Aw = (a) => {
13903
13878
  }
13904
13879
  );
13905
13880
  };
13906
- return /* @__PURE__ */ k.createElement(k.Fragment, null, /* @__PURE__ */ k.createElement(Vi, { value: s, icon: "polygon-vertex", min: 3, max: 100, step: 1, onInputHandler: o }), /* @__PURE__ */ k.createElement(Vi, { value: e, icon: "star-innerVertex", min: 1, max: 100, step: 1, onInputHandler: n }), /* @__PURE__ */ k.createElement(qw, { value: t, icon: "star-innerRatio", min: 0.1, max: 1, step: 0.1, onInputHandler: r }));
13907
- }, im = (a) => {
13881
+ return /* @__PURE__ */ k.createElement(k.Fragment, null, /* @__PURE__ */ k.createElement(Vi, { value: s, icon: "polygon-vertex", min: 3, max: 100, step: 1, onInputHandler: o }), /* @__PURE__ */ k.createElement(Vi, { value: e, icon: "star-innerVertex", min: 1, max: 100, step: 1, onInputHandler: n }), /* @__PURE__ */ k.createElement(qm, { value: t, icon: "star-innerRatio", min: 0.1, max: 1, step: 0.1, onInputHandler: r }));
13882
+ }, iw = (a) => {
13908
13883
  const { mananger: i, vertices: t } = a, e = (s) => {
13909
13884
  rt.emitMethod(
13910
13885
  ot.MainEngine,
@@ -13918,7 +13893,7 @@ const Aw = (a) => {
13918
13893
  );
13919
13894
  };
13920
13895
  return /* @__PURE__ */ k.createElement(Vi, { value: t, icon: "polygon-vertex", min: 3, max: 100, step: 1, onInputHandler: e });
13921
- }, sm = (a) => {
13896
+ }, sw = (a) => {
13922
13897
  const { mananger: i, placement: t } = a, e = (s) => {
13923
13898
  rt.emitMethod(
13924
13899
  ot.MainEngine,
@@ -13931,18 +13906,18 @@ const Aw = (a) => {
13931
13906
  }
13932
13907
  );
13933
13908
  };
13934
- return /* @__PURE__ */ k.createElement(_w, { value: t, icon: "speechBallon-placement", onChangeHandler: e });
13909
+ return /* @__PURE__ */ k.createElement(_m, { value: t, icon: "speechBallon-placement", onChangeHandler: e });
13935
13910
  }, Ai = (a) => {
13936
13911
  const { icon: i, isActive: t, onPointerUpHandler: e } = a;
13937
13912
  return /* @__PURE__ */ k.createElement("div", { className: `button tab-button ${t ? "active" : ""}`, onPointerUp: e }, /* @__PURE__ */ k.createElement("img", { src: Dt(i) }));
13938
- }, om = (a) => {
13913
+ }, ow = (a) => {
13939
13914
  const { toolsTypes: i, style: t, mananger: e, shapeOpt: s } = a, [o, n] = nt();
13940
13915
  yt(() => {
13941
13916
  i.includes(I.Polygon) ? n(I.Polygon) : i.includes(I.Star) ? n(I.Star) : n(I.SpeechBalloon);
13942
13917
  }, [i]);
13943
13918
  const r = (u, d) => {
13944
13919
  d == null || d.stopPropagation(), n(u);
13945
- }, c = X(() => o === I.Polygon && e && s.vertices ? /* @__PURE__ */ k.createElement(im, { vertices: s.vertices, mananger: e }) : null, [e, o, s]), l = X(() => o === I.Star && e && s.vertices && s.innerVerticeStep && s.innerRatio ? /* @__PURE__ */ k.createElement(em, { mananger: e, vertices: s.vertices, innerVerticeStep: s.innerVerticeStep, innerRatio: s.innerRatio }) : null, [e, o, s]), h = X(() => o === I.SpeechBalloon && e && s.placement ? /* @__PURE__ */ k.createElement(sm, { mananger: e, placement: s.placement }) : null, [e, o, s]);
13920
+ }, c = X(() => o === I.Polygon && e && s.vertices ? /* @__PURE__ */ k.createElement(iw, { vertices: s.vertices, mananger: e }) : null, [e, o, s]), l = X(() => o === I.Star && e && s.vertices && s.innerVerticeStep && s.innerRatio ? /* @__PURE__ */ k.createElement(ew, { mananger: e, vertices: s.vertices, innerVerticeStep: s.innerVerticeStep, innerRatio: s.innerRatio }) : null, [e, o, s]), h = X(() => o === I.SpeechBalloon && e && s.placement ? /* @__PURE__ */ k.createElement(sw, { mananger: e, placement: s.placement }) : null, [e, o, s]);
13946
13921
  return /* @__PURE__ */ k.createElement(
13947
13922
  "div",
13948
13923
  {
@@ -13955,7 +13930,7 @@ const Aw = (a) => {
13955
13930
  /* @__PURE__ */ k.createElement("div", { className: "shapeOpt-sub-menu-tabs" }, i.includes(I.Polygon) && /* @__PURE__ */ k.createElement(Ai, { isActive: o === I.Polygon, icon: o === I.Polygon ? "polygon-active" : "polygon", onPointerUpHandler: r.bind(void 0, I.Polygon) }) || null, i.includes(I.Star) && /* @__PURE__ */ k.createElement(Ai, { isActive: o === I.Star, icon: o === I.Star ? "star-active" : "star", onPointerUpHandler: r.bind(void 0, I.Star) }) || null, i.includes(I.SpeechBalloon) && /* @__PURE__ */ k.createElement(Ai, { isActive: o === I.SpeechBalloon, icon: o === I.SpeechBalloon ? "speechBallon-active" : "speechBallon", onPointerUpHandler: r.bind(void 0, I.SpeechBalloon) }) || null),
13956
13931
  /* @__PURE__ */ k.createElement("div", { className: "shapeOpt-sub-menu-content" }, c, l, h)
13957
13932
  );
13958
- }, nm = (a) => {
13933
+ }, nw = (a) => {
13959
13934
  const { open: i, setOpen: t, floatBarRef: e, toolsTypes: s, shapeOpt: o } = a, { floatBarData: n, mananger: r } = xt(Ct), [c, l] = nt([]), [h, u] = nt(), d = X(() => {
13960
13935
  if (e != null && e.current && _(n == null ? void 0 : n.x) && _(n == null ? void 0 : n.y) && (r != null && r.height)) {
13961
13936
  if (e.current.offsetTop && e.current.offsetTop + n.y > 200) {
@@ -13966,7 +13941,7 @@ const Aw = (a) => {
13966
13941
  return p.top = "inherit", p.bottom = 50, p;
13967
13942
  }
13968
13943
  }
13969
- }, [e, n == null ? void 0 : n.x, n == null ? void 0 : n.y, r == null ? void 0 : r.height]), f = X(() => i && s && r && o ? (r.control.room && !r.control.room.disableDeviceInputs && (u(r.control.room.disableDeviceInputs), r.control.room.disableDeviceInputs = !0), /* @__PURE__ */ k.createElement(om, { shapeOpt: o, style: d, toolsTypes: s, mananger: r })) : (r != null && r.control.room && Ut(h) && (r.control.room.disableDeviceInputs = h), null), [i, d, s, r, o]), g = (p) => {
13944
+ }, [e, n == null ? void 0 : n.x, n == null ? void 0 : n.y, r == null ? void 0 : r.height]), f = X(() => i && s && r && o ? (r.control.room && !r.control.room.disableDeviceInputs && (u(r.control.room.disableDeviceInputs), r.control.room.disableDeviceInputs = !0), /* @__PURE__ */ k.createElement(ow, { shapeOpt: o, style: d, toolsTypes: s, mananger: r })) : (r != null && r.control.room && Ut(h) && (r.control.room.disableDeviceInputs = h), null), [i, d, s, r, o]), g = (p) => {
13970
13945
  p.stopPropagation(), p.nativeEvent.stopImmediatePropagation(), t(!i);
13971
13946
  };
13972
13947
  return yt(() => {
@@ -13989,12 +13964,12 @@ const Aw = (a) => {
13989
13964
  ), [l, h] = k.useState(), u = De(null);
13990
13965
  yt(() => {
13991
13966
  var L, D, A, E;
13992
- const N = {}, w = (o == null ? void 0 : o.w) || ((L = i == null ? void 0 : i.boxSize) == null ? void 0 : L[0]) || 0, C = (o == null ? void 0 : o.h) || ((D = i == null ? void 0 : i.boxSize) == null ? void 0 : D[1]) || 0;
13993
- if (s && w && C && (n != null && n.width) && (n != null && n.height)) {
13967
+ const N = {}, m = (o == null ? void 0 : o.w) || ((L = i == null ? void 0 : i.boxSize) == null ? void 0 : L[0]) || 0, C = (o == null ? void 0 : o.h) || ((D = i == null ? void 0 : i.boxSize) == null ? void 0 : D[1]) || 0;
13968
+ if (s && m && C && (n != null && n.width) && (n != null && n.height)) {
13994
13969
  if (s.y < 60 ? s.y + C < n.height - 60 ? N.bottom = -120 : s.y + C < n.height ? N.bottom = -58 : s.y > 0 ? N.top = 62 : N.top = -s.y + 62 : N.top = 0, s.x < 0)
13995
13970
  N.left = -s.x + 3;
13996
- else if (s.x + (((A = u.current) == null ? void 0 : A.offsetWidth) || w) > n.width) {
13997
- const O = n.width - (((E = u.current) == null ? void 0 : E.offsetWidth) || w) - s.x;
13971
+ else if (s.x + (((A = u.current) == null ? void 0 : A.offsetWidth) || m) > n.width) {
13972
+ const O = n.width - (((E = u.current) == null ? void 0 : E.offsetWidth) || m) - s.x;
13998
13973
  N.left = O;
13999
13974
  }
14000
13975
  h(N);
@@ -14002,42 +13977,42 @@ const Aw = (a) => {
14002
13977
  }
14003
13978
  h(void 0);
14004
13979
  }, [u, s, o == null ? void 0 : o.w, o == null ? void 0 : o.h, n == null ? void 0 : n.width, n == null ? void 0 : n.height, i == null ? void 0 : i.boxSize]);
14005
- const d = X(() => o != null && o.fillColor ? /* @__PURE__ */ k.createElement(Uw, { floatBarRef: u, open: r === 3, setOpen: (N) => {
13980
+ const d = X(() => o != null && o.fillColor ? /* @__PURE__ */ k.createElement(Um, { floatBarRef: u, open: r === 3, setOpen: (N) => {
14006
13981
  c(
14007
13982
  N === !0 ? 3 : 0
14008
13983
  /* FillColor */
14009
13984
  );
14010
- } }) : null, [o == null ? void 0 : o.fillColor, r, u]), f = X(() => o != null && o.strokeColor ? /* @__PURE__ */ k.createElement(Yw, { floatBarRef: u, open: r === 2, setOpen: (N) => {
13985
+ } }) : null, [o == null ? void 0 : o.fillColor, r, u]), f = X(() => o != null && o.strokeColor ? /* @__PURE__ */ k.createElement(Ym, { floatBarRef: u, open: r === 2, setOpen: (N) => {
14011
13986
  c(
14012
13987
  N === !0 ? 2 : 0
14013
13988
  /* StrokeColor */
14014
13989
  );
14015
- } }) : null, [o == null ? void 0 : o.strokeColor, r, u]), g = X(() => i != null && i.fontColor && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Bw, { floatBarRef: u, open: r === 4, setOpen: (N) => {
13990
+ } }) : null, [o == null ? void 0 : o.strokeColor, r, u]), g = X(() => i != null && i.fontColor && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Bm, { floatBarRef: u, open: r === 4, setOpen: (N) => {
14016
13991
  c(
14017
13992
  N === !0 ? 4 : 0
14018
13993
  /* TextColor */
14019
13994
  );
14020
- }, textOpt: i, workIds: t }) : null, [i, r, t, n, u]), p = X(() => i != null && i.fontBgColor && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Fw, { floatBarRef: u, open: r === 5, setOpen: (N) => {
13995
+ }, textOpt: i, workIds: t }) : null, [i, r, t, n, u]), p = X(() => i != null && i.fontBgColor && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Fm, { floatBarRef: u, open: r === 5, setOpen: (N) => {
14021
13996
  c(
14022
13997
  N === !0 ? 5 : 0
14023
13998
  /* TextBgColor */
14024
13999
  );
14025
- }, textOpt: i, workIds: t }) : null, [i, r, t, n, u]), M = X(() => i && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Gw, { floatBarRef: u, open: r === 6, setOpen: (N) => {
14000
+ }, textOpt: i, workIds: t }) : null, [i, r, t, n, u]), M = X(() => i && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Gm, { floatBarRef: u, open: r === 6, setOpen: (N) => {
14026
14001
  c(
14027
14002
  N === !0 ? 6 : 0
14028
14003
  /* FontStyle */
14029
14004
  );
14030
- }, textOpt: i, workIds: t, style: l }) : null, [i, r, t, n, l, u]), v = X(() => i && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Xw, { open: r === 7, setOpen: (N) => {
14005
+ }, textOpt: i, workIds: t, style: l }) : null, [i, r, t, n, l, u]), v = X(() => i && (n != null && n.viewId) ? /* @__PURE__ */ k.createElement(Xm, { open: r === 7, setOpen: (N) => {
14031
14006
  c(
14032
14007
  N === !0 ? 7 : 0
14033
14008
  /* FontSize */
14034
14009
  );
14035
- }, textOpt: i, workIds: t, floatBarRef: u }) : null, [i, r, t, n, u]), m = X(() => e ? null : /* @__PURE__ */ k.createElement(Ew, { open: r === 1, setOpen: (N) => {
14010
+ }, textOpt: i, workIds: t, floatBarRef: u }) : null, [i, r, t, n, u]), w = X(() => e ? null : /* @__PURE__ */ k.createElement(Em, { open: r === 1, setOpen: (N) => {
14036
14011
  c(
14037
14012
  N === !0 ? 1 : 0
14038
14013
  /* Layer */
14039
14014
  );
14040
- }, floatBarRef: u }), [e, r, u]), S = X(() => o != null && o.canLock && n ? /* @__PURE__ */ k.createElement(Jw, { workIds: t, mananger: n, islocked: o.isLocked }) : null, [o, n, t]), T = X(() => n && (n != null && n.viewId) && l && (o != null && o.shapeOpt) && (o != null && o.toolsTypes) ? /* @__PURE__ */ k.createElement(nm, { open: r === 8, setOpen: (N) => {
14015
+ }, floatBarRef: u }), [e, r, u]), S = X(() => o != null && o.canLock && n ? /* @__PURE__ */ k.createElement(Jm, { workIds: t, mananger: n, islocked: o.isLocked }) : null, [o, n, t]), T = X(() => n && (n != null && n.viewId) && l && (o != null && o.shapeOpt) && (o != null && o.toolsTypes) ? /* @__PURE__ */ k.createElement(nw, { open: r === 8, setOpen: (N) => {
14041
14016
  c(
14042
14017
  N === !0 ? 8 : 0
14043
14018
  /* ShapeOpt */
@@ -14052,10 +14027,10 @@ const Aw = (a) => {
14052
14027
  onMouseOver: (N) => (N.stopPropagation(), N.cancelable && N.preventDefault(), n == null || n.control.worker.blurCursor(n.viewId), !1),
14053
14028
  onMouseMove: (N) => (N.stopPropagation(), N.cancelable && N.preventDefault(), !1)
14054
14029
  },
14055
- n && /* @__PURE__ */ k.createElement(Aw, { workIds: t, mananger: n }),
14056
- m,
14030
+ n && /* @__PURE__ */ k.createElement(Am, { workIds: t, mananger: n }),
14031
+ w,
14057
14032
  S,
14058
- !!(n != null && n.viewId) && /* @__PURE__ */ k.createElement(jw, { workIds: t, viewId: n.viewId }),
14033
+ !!(n != null && n.viewId) && /* @__PURE__ */ k.createElement(jm, { workIds: t, viewId: n.viewId }),
14059
14034
  T,
14060
14035
  v,
14061
14036
  M,
@@ -14064,7 +14039,7 @@ const Aw = (a) => {
14064
14039
  f,
14065
14040
  d
14066
14041
  );
14067
- }), rm = (a) => {
14042
+ }), rw = (a) => {
14068
14043
  const { data: i, isActive: t, manager: e, workId: s } = a, { opt: o, scale: n, translate: r, x: c, y: l } = i, h = `scale(${n || 1}) ${r && "translate(" + r[0] + "px," + r[1] + "px)" || ""}`, {
14069
14044
  fontSize: u,
14070
14045
  fontFamily: d,
@@ -14073,12 +14048,12 @@ const Aw = (a) => {
14073
14048
  lineThrough: p,
14074
14049
  textAlign: M,
14075
14050
  strokeColor: v,
14076
- lineHeight: m,
14051
+ lineHeight: w,
14077
14052
  bold: S,
14078
14053
  italic: T,
14079
14054
  uid: N,
14080
- workState: w
14081
- } = o, C = u, L = m || C * 1.2, D = {
14055
+ workState: m
14056
+ } = o, C = u, L = w || C * 1.2, D = {
14082
14057
  fontSize: `${C}px`,
14083
14058
  lineHeight: `${L}px`,
14084
14059
  color: g,
@@ -14112,7 +14087,7 @@ const Aw = (a) => {
14112
14087
  transform: h,
14113
14088
  transformOrigin: "left top",
14114
14089
  pointerEvents: "none",
14115
- opacity: w === P.Done ? 0 : 1
14090
+ opacity: m === P.Done ? 0 : 1
14116
14091
  }
14117
14092
  },
14118
14093
  /* @__PURE__ */ k.createElement(
@@ -14125,7 +14100,7 @@ const Aw = (a) => {
14125
14100
  E
14126
14101
  )
14127
14102
  );
14128
- }, am = k.memo(
14103
+ }, aw = k.memo(
14129
14104
  (a) => {
14130
14105
  const { data: i, left: t, top: e, workId: s, updateOptInfo: o } = a, { opt: n, scale: r, translate: c } = i, l = De(null);
14131
14106
  yt(() => {
@@ -14152,15 +14127,15 @@ const Aw = (a) => {
14152
14127
  lineThrough: p,
14153
14128
  textAlign: M,
14154
14129
  strokeColor: v,
14155
- lineHeight: m,
14130
+ lineHeight: w,
14156
14131
  bold: S,
14157
14132
  italic: T
14158
- } = n, N = u, w = m || N * 1.2, C = {
14133
+ } = n, N = u, m = w || N * 1.2, C = {
14159
14134
  fontSize: `${N}px`,
14160
- lineHeight: `${w}px`,
14135
+ lineHeight: `${m}px`,
14161
14136
  color: g,
14162
14137
  borderColor: v,
14163
- minHeight: `${w}px`,
14138
+ minHeight: `${m}px`,
14164
14139
  pointerEvents: "none",
14165
14140
  paddingRight: `${T === "italic" ? Math.round(N * 0.3) : 5}px`
14166
14141
  };
@@ -14202,14 +14177,14 @@ const Aw = (a) => {
14202
14177
  );
14203
14178
  },
14204
14179
  (a, i) => !(a.workId !== i.workId || a.left !== i.left || a.top !== i.top || !ft(a.data, i.data))
14205
- ), cm = (a) => {
14180
+ ), cw = (a) => {
14206
14181
  const { data: i, workId: t, isSelect: e, showFloatBtns: s, handleKeyUp: o, handleFocus: n, updateOptInfo: r, manager: c, runAnimation: l } = a, [h, u] = nt(), { opt: d, scale: f, translate: g, x: p, y: M } = i, {
14207
14182
  fontSize: v,
14208
- fontFamily: m,
14183
+ fontFamily: w,
14209
14184
  underline: S,
14210
14185
  fontColor: T,
14211
14186
  lineThrough: N,
14212
- textAlign: w,
14187
+ textAlign: m,
14213
14188
  strokeColor: C,
14214
14189
  lineHeight: L,
14215
14190
  bold: D,
@@ -14225,8 +14200,8 @@ const Aw = (a) => {
14225
14200
  paddingRight: `${A === "italic" ? Math.round(q * 0.3) : 5}px`,
14226
14201
  borderWidth: `${Math.max(Math.round(1 / (f || 1)), 1)}px`
14227
14202
  };
14228
- return m && (Z.fontFamily = `${m}`), (N || S) && (Z.textDecoration = `${N && "line-through" || ""} ${S && " underline" || ""}`), w && (Z.textAlign = `${w}`), D && (Z.fontWeight = `${D}`), A && (Z.fontStyle = `${A}`), Z;
14229
- }, [D, T, m, v, A, L, N, f, C, w, S]), j = X(() => {
14203
+ return w && (Z.fontFamily = `${w}`), (N || S) && (Z.textDecoration = `${N && "line-through" || ""} ${S && " underline" || ""}`), m && (Z.textAlign = `${m}`), D && (Z.fontWeight = `${D}`), A && (Z.fontStyle = `${A}`), Z;
14204
+ }, [D, T, w, v, A, L, N, f, C, m, S]), j = X(() => {
14230
14205
  const q = `scale(${f || 1}) ${g && "translate(" + g[0] + "px," + g[1] + "px)" || ""}`;
14231
14206
  return {
14232
14207
  left: `${p}px`,
@@ -14318,7 +14293,7 @@ const Aw = (a) => {
14318
14293
  function it(q, dt) {
14319
14294
  const Z = window == null ? void 0 : window.getSelection();
14320
14295
  if (Z != null && Z.rangeCount && q && Z && Z.anchorNode) {
14321
- const $ = Z.anchorOffset, pt = Z.anchorNode.textContent || "", mt = pt.slice(0, $) || "", $t = pt.slice($) || "", Tt = mt.concat(q) || "";
14296
+ const $ = Z.anchorOffset, pt = Z.anchorNode.textContent || "", wt = pt.slice(0, $) || "", $t = pt.slice($) || "", Tt = wt.concat(q) || "";
14322
14297
  ct(Tt, $t, dt);
14323
14298
  }
14324
14299
  }
@@ -14326,16 +14301,16 @@ const Aw = (a) => {
14326
14301
  const $ = window == null ? void 0 : window.getSelection();
14327
14302
  if (!($ != null && $.rangeCount) || !$.anchorNode) return;
14328
14303
  const pt = q.split(/\n/);
14329
- let mt = $.anchorNode.parentNode;
14330
- mt === Z && (mt = $.anchorNode);
14304
+ let wt = $.anchorNode.parentNode;
14305
+ wt === Z && (wt = $.anchorNode);
14331
14306
  const $t = [...Z.childNodes], Tt = [];
14332
14307
  let St, pe = $.anchorOffset;
14333
14308
  for (; $t.length; ) {
14334
14309
  const zt = $t.pop();
14335
14310
  if (zt) {
14336
- if (zt === mt) {
14311
+ if (zt === wt) {
14337
14312
  let Jt = pt[0];
14338
- pt.length === 1 && (pe = pt[0].length, Jt = pt[0].concat(dt)), mt.nodeName === "#text" ? (mt.textContent = Jt, St = mt) : mt.nodeName === "DIV" && (mt.innerText = Jt, St = mt.childNodes[0]);
14313
+ pt.length === 1 && (pe = pt[0].length, Jt = pt[0].concat(dt)), wt.nodeName === "#text" ? (wt.textContent = Jt, St = wt) : wt.nodeName === "DIV" && (wt.innerText = Jt, St = wt.childNodes[0]);
14339
14314
  break;
14340
14315
  }
14341
14316
  Tt.push(zt), Z.removeChild(zt);
@@ -14423,7 +14398,7 @@ class Mn extends k.Component {
14423
14398
  return this.props.editors.forEach((e, s) => {
14424
14399
  if (this.props.selectIds.includes(s) && !(this.props.activeTextId == s) && this.props.box) {
14425
14400
  const { x: n, y: r } = this.props.box, { x: c, y: l } = e, h = `${c - n}px`, u = `${l - r}px`, d = /* @__PURE__ */ k.createElement(
14426
- am,
14401
+ aw,
14427
14402
  {
14428
14403
  left: h,
14429
14404
  top: u,
@@ -14445,7 +14420,7 @@ class Mn extends k.Component {
14445
14420
  return /* @__PURE__ */ k.createElement(k.Fragment, null, this.editorUI);
14446
14421
  }
14447
14422
  }
14448
- class lm extends Mn {
14423
+ class lw extends Mn {
14449
14424
  constructor(t) {
14450
14425
  super(t);
14451
14426
  y(this, "ref");
@@ -14503,7 +14478,7 @@ class lm extends Mn {
14503
14478
  return this.props.editors.forEach((s, o) => {
14504
14479
  if (!(this.props.selectIds.includes(o) && this.props.activeTextId !== o)) {
14505
14480
  const c = this.props.activeTextId == o ? /* @__PURE__ */ k.createElement(
14506
- cm,
14481
+ cw,
14507
14482
  {
14508
14483
  key: o,
14509
14484
  data: s,
@@ -14516,7 +14491,7 @@ class lm extends Mn {
14516
14491
  runAnimation: this.runAnimation.bind(this)
14517
14492
  }
14518
14493
  ) : /* @__PURE__ */ k.createElement(
14519
- rm,
14494
+ rw,
14520
14495
  {
14521
14496
  manager: this.props.manager,
14522
14497
  isActive: s.opt.workState === P.Doing || s.opt.workState === P.Start || !1,
@@ -14535,7 +14510,7 @@ class lm extends Mn {
14535
14510
  return /* @__PURE__ */ k.createElement("div", { className: `${this.props.className}`, ref: this.ref }, this.editorUI);
14536
14511
  }
14537
14512
  }
14538
- const hm = () => {
14513
+ const hw = () => {
14539
14514
  const { floatBarData: a } = xt(Ct);
14540
14515
  return /* @__PURE__ */ k.createElement(
14541
14516
  "div",
@@ -14552,7 +14527,7 @@ const hm = () => {
14552
14527
  /* @__PURE__ */ k.createElement("div", { className: "point RB nwse-resize", style: { backgroundColor: a == null ? void 0 : a.selectorColor } }),
14553
14528
  /* @__PURE__ */ k.createElement("div", { className: "point BC ns-resize", style: { backgroundColor: a == null ? void 0 : a.selectorColor } })
14554
14529
  );
14555
- }, um = () => {
14530
+ }, uw = () => {
14556
14531
  const { floatBarData: a, mananger: i } = xt(Ct), [t, e] = nt(), [s, o] = nt();
14557
14532
  yt(() => {
14558
14533
  const c = [];
@@ -14596,7 +14571,7 @@ const hm = () => {
14596
14571
  n,
14597
14572
  r
14598
14573
  );
14599
- }, dm = () => {
14574
+ }, dw = () => {
14600
14575
  const { floatBarData: a } = xt(Ct);
14601
14576
  return /* @__PURE__ */ k.createElement(
14602
14577
  "div",
@@ -14609,7 +14584,7 @@ const hm = () => {
14609
14584
  /* @__PURE__ */ k.createElement("div", { className: "point RT nesw-resize", style: { backgroundColor: a == null ? void 0 : a.selectorColor } }),
14610
14585
  /* @__PURE__ */ k.createElement("div", { className: "point RB nwse-resize", style: { backgroundColor: a == null ? void 0 : a.selectorColor } })
14611
14586
  );
14612
- }, pm = () => {
14587
+ }, pw = () => {
14613
14588
  const { floatBarData: a } = xt(Ct);
14614
14589
  return /* @__PURE__ */ k.createElement(
14615
14590
  "div",
@@ -14621,55 +14596,55 @@ const hm = () => {
14621
14596
  },
14622
14597
  /* @__PURE__ */ k.createElement("img", { className: "lock", alt: "lock", src: "https://sdk.netless.link/resource/icons/lock.svg" })
14623
14598
  );
14624
- }, fm = (a) => {
14599
+ }, fw = (a) => {
14625
14600
  const { className: i } = a, { floatBarData: t, angle: e, setAngle: s, setOperationType: o, mananger: n } = xt(Ct), [r, c] = nt(), [l, h] = nt(!1), [u, d] = nt(new F()), [f, g] = nt(new F()), [p, M] = nt(!1);
14626
14601
  yt(() => (rt.activeListener(v), () => {
14627
14602
  rt.unmountActiveListener(v);
14628
14603
  }), []), yt(() => {
14629
14604
  if (t) {
14630
- const N = { x: (t == null ? void 0 : t.x) - 20, y: (t == null ? void 0 : t.y) + (t == null ? void 0 : t.h) }, w = { x: (t == null ? void 0 : t.x) + (t == null ? void 0 : t.w) / 2, y: (t == null ? void 0 : t.y) + (t == null ? void 0 : t.h) / 2 };
14631
- g(new F(w.x, w.y)), d(new F(N.x, N.y)), c({ x: N.x, y: N.y });
14605
+ const N = { x: (t == null ? void 0 : t.x) - 20, y: (t == null ? void 0 : t.y) + (t == null ? void 0 : t.h) }, m = { x: (t == null ? void 0 : t.x) + (t == null ? void 0 : t.w) / 2, y: (t == null ? void 0 : t.y) + (t == null ? void 0 : t.h) / 2 };
14606
+ g(new F(m.x, m.y)), d(new F(N.x, N.y)), c({ x: N.x, y: N.y });
14632
14607
  }
14633
14608
  }, [t == null ? void 0 : t.x, t == null ? void 0 : t.y, t == null ? void 0 : t.h]);
14634
14609
  const v = (N) => {
14635
- var w;
14610
+ var m;
14636
14611
  if (!N) {
14637
14612
  M(!0), h(!1), o(B.None);
14638
14613
  return;
14639
14614
  }
14640
- M(!1), (w = n == null ? void 0 : n.control.room) != null && w.disableDeviceInputs && (n.control.room.disableDeviceInputs = !1);
14641
- }, m = (N, w) => {
14615
+ M(!1), (m = n == null ? void 0 : n.control.room) != null && m.disableDeviceInputs && (n.control.room.disableDeviceInputs = !1);
14616
+ }, w = (N, m) => {
14642
14617
  if (N.cancelable && N.preventDefault(), N.stopPropagation(), n != null && n.control.worker.isBusy) {
14643
14618
  M(!0);
14644
14619
  return;
14645
14620
  }
14646
14621
  h(!0);
14647
- const C = Math.round(F.GetAngleByPoints(u, f, new F(w.x, w.y))) || 0;
14622
+ const C = Math.round(F.GetAngleByPoints(u, f, new F(m.x, m.y))) || 0;
14648
14623
  s(C), o(B.RotateNode), n != null && n.control.room && (n.control.room.disableDeviceInputs = !0), rt.emitMethod(
14649
14624
  ot.MainEngine,
14650
14625
  B.RotateNode,
14651
14626
  { workIds: [H], angle: 0, workState: P.Start, viewId: n == null ? void 0 : n.viewId }
14652
14627
  );
14653
- }, S = (N, w) => {
14628
+ }, S = (N, m) => {
14654
14629
  if (T.cancel(), N.cancelable && N.preventDefault(), N.stopPropagation(), n != null && n.control.worker.isBusy) {
14655
14630
  M(!0);
14656
14631
  return;
14657
14632
  }
14658
14633
  h(!1);
14659
- const C = Math.round(F.GetAngleByPoints(u, f, new F(w.x, w.y))) || 0;
14634
+ const C = Math.round(F.GetAngleByPoints(u, f, new F(m.x, m.y))) || 0;
14660
14635
  s(C), o(B.None), n != null && n.control.room && (n.control.room.disableDeviceInputs = !1), rt.emitMethod(
14661
14636
  ot.MainEngine,
14662
14637
  B.RotateNode,
14663
14638
  { workIds: [H], angle: C, workState: P.Done, viewId: n == null ? void 0 : n.viewId }
14664
14639
  );
14665
- }, T = us((N, w) => {
14640
+ }, T = us((N, m) => {
14666
14641
  if (N.cancelable && N.preventDefault(), N.stopPropagation(), n != null && n.control.worker.isBusy) {
14667
14642
  M(!0);
14668
14643
  return;
14669
14644
  }
14670
14645
  h(!0);
14671
- const C = Math.round(F.GetAngleByPoints(u, f, new F(w.x, w.y))) || 0;
14672
- s(C), c({ x: w.x, y: w.y }), o(B.RotateNode), rt.emitMethod(
14646
+ const C = Math.round(F.GetAngleByPoints(u, f, new F(m.x, m.y))) || 0;
14647
+ s(C), c({ x: m.x, y: m.y }), o(B.RotateNode), rt.emitMethod(
14673
14648
  ot.MainEngine,
14674
14649
  B.RotateNode,
14675
14650
  { workIds: [H], angle: C, workState: P.Doing, viewId: n == null ? void 0 : n.viewId }
@@ -14681,7 +14656,7 @@ const hm = () => {
14681
14656
  disabled: p,
14682
14657
  position: r,
14683
14658
  handle: ".appliance-plugin-rotate-mouse-pointer",
14684
- onStart: m,
14659
+ onStart: w,
14685
14660
  onDrag: T,
14686
14661
  onStop: S
14687
14662
  },
@@ -14699,7 +14674,7 @@ const hm = () => {
14699
14674
  /* @__PURE__ */ k.createElement("div", { className: `appliance-plugin-rotate-mouse-pointer ${l ? "active" : ""}` }, /* @__PURE__ */ k.createElement("img", { alt: "icon", src: Dt("rotation") }), /* @__PURE__ */ k.createElement("div", { className: "angle-icon" }, e, "°"))
14700
14675
  )
14701
14676
  );
14702
- }, gm = (a) => {
14677
+ }, gw = (a) => {
14703
14678
  const { floatBarData: i, setOperationType: t, mananger: e } = xt(Ct), { onClickHandle: s } = a, [o, n] = nt(P.Pending), [r, c] = nt(), [l, h] = nt(), [u, d] = nt(!1);
14704
14679
  yt(() => (rt.activeListener(f), () => {
14705
14680
  rt.unmountActiveListener(f);
@@ -14754,7 +14729,7 @@ const hm = () => {
14754
14729
  B.TranslateNode,
14755
14730
  { workIds: [H], position: N, workState: P.Doing, viewId: e == null ? void 0 : e.viewId }
14756
14731
  ));
14757
- }, 100, { trailing: !0 }), v = X(() => !!((i == null ? void 0 : i.scaleType) === lt.none && (i != null && i.canLock)), [i]), m = yi((S) => (M.cancel(), S.stopPropagation(), S.cancelable && S.preventDefault(), (r == null ? void 0 : r.x) === (i == null ? void 0 : i.x) && (r == null ? void 0 : r.y) === (i == null ? void 0 : i.y) && s(S), !1), 100, { trailing: !0 });
14732
+ }, 100, { trailing: !0 }), v = X(() => !!((i == null ? void 0 : i.scaleType) === lt.none && (i != null && i.canLock)), [i]), w = yi((S) => (M.cancel(), S.stopPropagation(), S.cancelable && S.preventDefault(), (r == null ? void 0 : r.x) === (i == null ? void 0 : i.x) && (r == null ? void 0 : r.y) === (i == null ? void 0 : i.y) && s(S), !1), 100, { trailing: !0 });
14758
14733
  return /* @__PURE__ */ k.createElement(
14759
14734
  Ae,
14760
14735
  {
@@ -14778,12 +14753,12 @@ const hm = () => {
14778
14753
  touchAction: "none"
14779
14754
  } : void 0,
14780
14755
  onPointerUp: (S) => {
14781
- S.persist(), m(S);
14756
+ S.persist(), w(S);
14782
14757
  }
14783
14758
  }
14784
14759
  )
14785
14760
  );
14786
- }, ym = (a) => {
14761
+ }, yw = (a) => {
14787
14762
  const { className: i } = a, [t, e] = nt({ x: 0, y: 0, h: 0, w: 0 }), [s, o] = nt(), [n, r] = nt(), [c, l] = nt(), { floatBarData: h, mananger: u } = xt(Ct), [d, f] = nt(), [g, p] = nt(!1);
14788
14763
  yt(() => {
14789
14764
  if (h && u) {
@@ -14806,7 +14781,7 @@ const hm = () => {
14806
14781
  [C.x + C.w, C.y],
14807
14782
  [C.x + C.w, C.y + C.h],
14808
14783
  [C.x, C.y + C.h]
14809
- ], m = (C, L) => {
14784
+ ], w = (C, L) => {
14810
14785
  switch (L) {
14811
14786
  case "top":
14812
14787
  case "topLeft":
@@ -14880,7 +14855,7 @@ const hm = () => {
14880
14855
  }
14881
14856
  }
14882
14857
  j[0] = z.w / t.w, j[1] = z.h / t.h;
14883
- const G = v(z).map((V) => D.control.viewContainerManager.transformToScenePoint(V, D.viewId)), Q = m(G, C);
14858
+ const G = v(z).map((V) => D.control.viewContainerManager.transformToScenePoint(V, D.viewId)), Q = w(G, C);
14884
14859
  return O && (tt[1] = Q[1] - A[1]), E && (tt[0] = Q[0] - A[0]), { scale: j, translate: tt };
14885
14860
  }, T = (C, L) => {
14886
14861
  if (C.cancelable && C.preventDefault(), C.stopPropagation(), u != null && u.control.worker.isBusy) {
@@ -14888,7 +14863,7 @@ const hm = () => {
14888
14863
  return;
14889
14864
  }
14890
14865
  if (h != null && h.w && (h != null && h.h) && u) {
14891
- const D = { x: h.x, y: h.y, w: h.w, h: h.h }, A = v(D), E = A.map((j) => u.control.viewContainerManager.transformToScenePoint(j, u.viewId)), O = m(A, L), z = m(E, L);
14866
+ const D = { x: h.x, y: h.y, w: h.w, h: h.h }, A = v(D), E = A.map((j) => u.control.viewContainerManager.transformToScenePoint(j, u.viewId)), O = w(A, L), z = w(E, L);
14892
14867
  e(D), o(O), r(z), l(L), u != null && u.control.room && (u.control.room.disableDeviceInputs = !0), rt.emitMethod(
14893
14868
  ot.MainEngine,
14894
14869
  B.ScaleNode,
@@ -14911,7 +14886,7 @@ const hm = () => {
14911
14886
  B.ScaleNode,
14912
14887
  { workIds: [H], scale: E, dir: L, translate: O, originPoint: s, scenePoint: n, workState: P.Doing, viewId: u.viewId }
14913
14888
  ));
14914
- }, 100, { trailing: !0 }), w = (C) => {
14889
+ }, 100, { trailing: !0 }), m = (C) => {
14915
14890
  if (N.cancel(), C.cancelable && C.preventDefault(), C.stopPropagation(), !(!u || !s || !n)) {
14916
14891
  if (u != null && u.control.worker.isBusy) {
14917
14892
  p(!0);
@@ -14957,7 +14932,7 @@ const hm = () => {
14957
14932
  lockAspectRatio: (h == null ? void 0 : h.scaleType) === lt.proportional,
14958
14933
  onResizeStart: T,
14959
14934
  onResize: N,
14960
- onResizeStop: w
14935
+ onResizeStop: m
14961
14936
  }
14962
14937
  );
14963
14938
  }, ho = (a) => {
@@ -14965,9 +14940,9 @@ const hm = () => {
14965
14940
  yt(() => (rt.activeListener(g), () => {
14966
14941
  rt.unmountActiveListener(g);
14967
14942
  }), []);
14968
- const g = (m) => {
14943
+ const g = (w) => {
14969
14944
  var S;
14970
- if (!m || r != null && r.isLocked) {
14945
+ if (!w || r != null && r.isLocked) {
14971
14946
  f(!0), u(P.Pending), o(B.None);
14972
14947
  return;
14973
14948
  }
@@ -14976,8 +14951,8 @@ const hm = () => {
14976
14951
  yt(() => {
14977
14952
  _(t.x) && _(t.y) && (h === P.Pending || h === P.Done) && l({ x: t.x, y: t.y });
14978
14953
  }, [t, h]);
14979
- const p = (m) => {
14980
- if (m.cancelable && m.preventDefault(), m.stopPropagation(), n != null && n.control.worker.isBusy) {
14954
+ const p = (w) => {
14955
+ if (w.cancelable && w.preventDefault(), w.stopPropagation(), n != null && n.control.worker.isBusy) {
14981
14956
  f(!0), u(P.Pending);
14982
14957
  return;
14983
14958
  }
@@ -14986,30 +14961,30 @@ const hm = () => {
14986
14961
  B.SetPoint,
14987
14962
  { workId: H, pointMap: e, workState: P.Start, viewId: n == null ? void 0 : n.viewId }
14988
14963
  ));
14989
- }, M = se((m, S) => {
14990
- if (m.cancelable && m.preventDefault(), m.stopPropagation(), n != null && n.control.worker.isBusy) {
14964
+ }, M = se((w, S) => {
14965
+ if (w.cancelable && w.preventDefault(), w.stopPropagation(), n != null && n.control.worker.isBusy) {
14991
14966
  f(!0), u(P.Pending);
14992
14967
  return;
14993
14968
  }
14994
14969
  const T = { x: S.x, y: S.y };
14995
14970
  if ((T.x !== (t == null ? void 0 : t.x) || T.y !== (t == null ? void 0 : t.y)) && (n != null && n.control.viewContainerManager)) {
14996
- const N = n.control.viewContainerManager.transformToScenePoint([T.x, T.y], n.viewId), w = e.get(i);
14997
- w && s === "start" ? w[0] = N : w && s === "end" && (w[1] = N), u(P.Doing), rt.emitMethod(
14971
+ const N = n.control.viewContainerManager.transformToScenePoint([T.x, T.y], n.viewId), m = e.get(i);
14972
+ m && s === "start" ? m[0] = N : m && s === "end" && (m[1] = N), u(P.Doing), rt.emitMethod(
14998
14973
  ot.MainEngine,
14999
14974
  B.SetPoint,
15000
14975
  { workId: H, pointMap: e, workState: P.Doing, viewId: n == null ? void 0 : n.viewId }
15001
14976
  );
15002
14977
  }
15003
- }, 100, { trailing: !0 }), v = (m, S) => {
15004
- if (M.cancel(), m.cancelable && m.preventDefault(), n != null && n.control.worker.isBusy) {
14978
+ }, 100, { trailing: !0 }), v = (w, S) => {
14979
+ if (M.cancel(), w.cancelable && w.preventDefault(), n != null && n.control.worker.isBusy) {
15005
14980
  f(!0), u(P.Pending);
15006
14981
  return;
15007
14982
  }
15008
- m.stopPropagation(), o(B.None), u(P.Done);
14983
+ w.stopPropagation(), o(B.None), u(P.Done);
15009
14984
  const T = { x: S.x, y: S.y };
15010
14985
  if (n != null && n.control.viewContainerManager) {
15011
- const N = n.control.viewContainerManager.transformToScenePoint([T.x, T.y], n.viewId), w = e.get(i);
15012
- w && s === "start" ? w[0] = N : w && s === "end" && (w[1] = N), n != null && n.control.room && (n.control.room.disableDeviceInputs = !1), rt.emitMethod(
14986
+ const N = n.control.viewContainerManager.transformToScenePoint([T.x, T.y], n.viewId), m = e.get(i);
14987
+ m && s === "start" ? m[0] = N : m && s === "end" && (m[1] = N), n != null && n.control.room && (n.control.room.disableDeviceInputs = !1), rt.emitMethod(
15013
14988
  ot.MainEngine,
15014
14989
  B.SetPoint,
15015
14990
  { workId: H, pointMap: e, workState: P.Done, viewId: n == null ? void 0 : n.viewId }
@@ -15036,7 +15011,7 @@ const hm = () => {
15036
15011
  }
15037
15012
  )
15038
15013
  );
15039
- }, Mm = (a) => {
15014
+ }, Mw = (a) => {
15040
15015
  const { className: i } = a, { floatBarData: t, mananger: e } = xt(Ct), [s, o] = nt(), [n, r] = nt(), [c, l] = nt(/* @__PURE__ */ new Map());
15041
15016
  yt(() => {
15042
15017
  const d = [];
@@ -15053,8 +15028,8 @@ const hm = () => {
15053
15028
  }, [e, t == null ? void 0 : t.points, t == null ? void 0 : t.selectIds, c]);
15054
15029
  const h = X(() => s && (t != null && t.selectIds) ? /* @__PURE__ */ k.createElement(ho, { pos: s, type: "start", id: t.selectIds[0], pointMap: c }) : null, [s, t == null ? void 0 : t.selectIds, c]), u = X(() => n && (t != null && t.selectIds) ? /* @__PURE__ */ k.createElement(ho, { pos: n, type: "end", id: t.selectIds[0], pointMap: c }) : null, [n, t == null ? void 0 : t.selectIds, c]);
15055
15030
  return /* @__PURE__ */ k.createElement("div", { className: `${i}` }, h, u);
15056
- }, wm = k.forwardRef((a, i) => {
15057
- const { floatBarData: t, operationType: e } = xt(Ct), s = X(() => (t == null ? void 0 : t.scaleType) !== lt.all || e === B.RotateNode ? null : /* @__PURE__ */ k.createElement(hm, null), [t, e]), o = X(() => (t == null ? void 0 : t.scaleType) !== lt.both || e === B.RotateNode ? null : /* @__PURE__ */ k.createElement(um, null), [t, e]), n = X(() => (t == null ? void 0 : t.scaleType) !== lt.proportional || e === B.RotateNode ? null : /* @__PURE__ */ k.createElement(dm, null), [t, e]), r = X(() => (t == null ? void 0 : t.scaleType) === lt.none && (t != null && t.canLock) ? /* @__PURE__ */ k.createElement(pm, null) : null, [t]);
15031
+ }, mw = k.forwardRef((a, i) => {
15032
+ const { floatBarData: t, operationType: e } = xt(Ct), s = X(() => (t == null ? void 0 : t.scaleType) !== lt.all || e === B.RotateNode ? null : /* @__PURE__ */ k.createElement(hw, null), [t, e]), o = X(() => (t == null ? void 0 : t.scaleType) !== lt.both || e === B.RotateNode ? null : /* @__PURE__ */ k.createElement(uw, null), [t, e]), n = X(() => (t == null ? void 0 : t.scaleType) !== lt.proportional || e === B.RotateNode ? null : /* @__PURE__ */ k.createElement(dw, null), [t, e]), r = X(() => (t == null ? void 0 : t.scaleType) === lt.none && (t != null && t.canLock) ? /* @__PURE__ */ k.createElement(pw, null) : null, [t]);
15058
15033
  return /* @__PURE__ */ k.createElement(
15059
15034
  "div",
15060
15035
  {
@@ -15072,12 +15047,12 @@ const hm = () => {
15072
15047
  n,
15073
15048
  a.children
15074
15049
  );
15075
- }), mm = k.forwardRef((a, i) => {
15050
+ }), ww = k.forwardRef((a, i) => {
15076
15051
  var f;
15077
15052
  const { floatBarData: t, operationType: e, mananger: s } = xt(Ct), { editors: o, activeTextId: n, isHide: r } = a, c = X(() => {
15078
15053
  var g;
15079
- return t != null && t.canRotate && ((g = t == null ? void 0 : t.selectIds) == null ? void 0 : g.length) === 1 && (e === B.None || e === B.RotateNode) ? /* @__PURE__ */ k.createElement(fm, { className: Et.RotateBtn }) : null;
15080
- }, [t == null ? void 0 : t.canRotate, (f = t == null ? void 0 : t.selectIds) == null ? void 0 : f.length, e]), l = X(() => ((t == null ? void 0 : t.scaleType) === lt.all || (t == null ? void 0 : t.scaleType) === lt.proportional) && (e === B.None || e === B.ScaleNode) && _(t == null ? void 0 : t.x) && _(t == null ? void 0 : t.y) ? /* @__PURE__ */ k.createElement(ym, { className: Et.ResizeBtn }) : null, [t == null ? void 0 : t.scaleType, e, t == null ? void 0 : t.x, t == null ? void 0 : t.y]), h = X(() => (t == null ? void 0 : t.scaleType) === lt.both && (e === B.None || e === B.SetPoint) ? /* @__PURE__ */ k.createElement(Mm, { className: Et.ResizeTowBox }) : null, [t == null ? void 0 : t.scaleType, e]), u = X(() => {
15054
+ return t != null && t.canRotate && ((g = t == null ? void 0 : t.selectIds) == null ? void 0 : g.length) === 1 && (e === B.None || e === B.RotateNode) ? /* @__PURE__ */ k.createElement(fw, { className: Et.RotateBtn }) : null;
15055
+ }, [t == null ? void 0 : t.canRotate, (f = t == null ? void 0 : t.selectIds) == null ? void 0 : f.length, e]), l = X(() => ((t == null ? void 0 : t.scaleType) === lt.all || (t == null ? void 0 : t.scaleType) === lt.proportional) && (e === B.None || e === B.ScaleNode) && _(t == null ? void 0 : t.x) && _(t == null ? void 0 : t.y) ? /* @__PURE__ */ k.createElement(yw, { className: Et.ResizeBtn }) : null, [t == null ? void 0 : t.scaleType, e, t == null ? void 0 : t.x, t == null ? void 0 : t.y]), h = X(() => (t == null ? void 0 : t.scaleType) === lt.both && (e === B.None || e === B.SetPoint) ? /* @__PURE__ */ k.createElement(Mw, { className: Et.ResizeTowBox }) : null, [t == null ? void 0 : t.scaleType, e]), u = X(() => {
15081
15056
  const g = (t == null ? void 0 : t.selectIds) || [];
15082
15057
  return o && s && g && _(t == null ? void 0 : t.x) && _(t == null ? void 0 : t.y) && _(t == null ? void 0 : t.w) && _(t == null ? void 0 : t.h) ? /* @__PURE__ */ k.createElement(
15083
15058
  Mn,
@@ -15115,8 +15090,8 @@ const hm = () => {
15115
15090
  s == null || s.control.worker.blurCursor(s.viewId);
15116
15091
  }
15117
15092
  },
15118
- /* @__PURE__ */ k.createElement(wm, { ref: i }, /* @__PURE__ */ k.createElement(k.Fragment, null, u)),
15119
- /* @__PURE__ */ k.createElement(gm, { onClickHandle: (g) => {
15093
+ /* @__PURE__ */ k.createElement(mw, { ref: i }, /* @__PURE__ */ k.createElement(k.Fragment, null, u)),
15094
+ /* @__PURE__ */ k.createElement(gw, { onClickHandle: (g) => {
15120
15095
  if (s && (o != null && o.size)) {
15121
15096
  const p = s.getPoint(g.nativeEvent);
15122
15097
  p && s.control.textEditorManager.computeTextActive(p, s.viewId);
@@ -15127,8 +15102,8 @@ const hm = () => {
15127
15102
  h,
15128
15103
  d
15129
15104
  );
15130
- }), vm = k.memo(mm, (a, i) => !!ft(a, i)), Im = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAYAAADFeBvrAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAYISURBVHgB7ZpNSCtXFIBPEuvz+dMGpYUKD/sWFX+Qti6kK7Hqpm6e9q0rIoIUFUShPLV10VZx4+JZqa9v20LBhdq9fyBUCtKNPH8qYl2IOw3G38Rkek4y15y5uTOZJDOWggcOSSYzN/ebc+45554JwIM8iBCPyTEP+86T4vyMfsRN4b+nQTKIJp0vzuGvlpID7os8EQNEIBD4oKio6Bm9DwaDv/v9/n/076JgbtWUYPchwrW8qD7UnOvr6wFNkpubm+/wu7f0c7y6mrnlvQufxB0Iau7V1dX3BDA/P6/V1dVpzc3N2uLiIofK1c8VYHys/wRKBUN3/hGHqaysNOjc3FwMis6hc0FtLTHuvYLxCCZgci8uLn4wg5Gh6Fy8Jk+/NkcCAlAAuUkoW4g0B+d5tLS05O/r67O8eGxsDNra2uDy8nKsoKCAwCIQDxQa0yTxgrvCYXyTk5Ml+Orf2dlJeeHIyAigFSE/P38ELfUNqNdSkjgF5FF89jL1TU1NlQwODl5gZPujp6cHWltbUw7Koc7Pz8mkZpHPFeFrJuZeqLnoMoPoZqe0JjDP/IZgnyLUG/o8NDRkuo5Ua2pjY6MC4oFCFf1cA0oKzRSOp6enRfTaGh0d/QxBt+1CUVgnOTs7+xrHfQzGyOcKkK3QTJMnQffZ6e/v/xwttmsHqqmpKXbdycnJCxy7ABLh3FEgVZ6hZJhnFZoFFMF0d3c/w7v+dyookXBnZ2c/xvHfhriVcvXfdBRItsxjnOhYqjwjoAimq6vrCysoGofk+Ph4Esd/F/UdiFtJAGUd2DygTpp5dmBUUJ2dnc9VUALm8PDwJY7/BPU9VD8k3M4RC6kskxZMKigKIMLN9vf3p3H8DyWgfEhEOwOQD9IXOTz7EObbwsLC4YWFBRgeHrY9ECXYo6MjaGlpKWlsbPxkYGDgRW1tbSEWquVlZWXBzc3Nl1VVVa8hXiXc6ioqBqGaPDk7AACJTRZ3NS9lcUp86cJwoSQ7Pj4Op6enfxUXF3/V0NCQv7q6GsCvwrqGUG/01xAD4+VQTOxaSF43d5bBOisrGBJRCtXX17+/trb268rKSgASFgmz97KFkmo6OztWuVyPweiWGc4WRkhFRQVEIpHg8vJyQAIQVlLBROVxvBYQHsXnO8tk62ZcyN0wecLBwcEvYHSzEPscBqOLCRhLC4n9uqaA8UAWAcAKhtbQ3t7eTHl5+Y9gtAp3twhT056CDMQ7MRzIFTeTYKb1yYYVQFH9VdzsqNmYKpfTJBDX3Ixgdnd3XyHMT2AMALJlBBSPaMpNngrIsTyTCgaj288YDGakictrxizvKFNOjgSSBLS+vv6UYHDb7DgMVgsChjTEgCIKGG4ZU+EWkgNBzN1qamq+pAMTExPgFMzW1tZrhHkFyWE5KxgSszx0527RaDRmOSpRshEOU11dPQPG8CwHARHJlMnTSrwSRFIlfXt7m3V5ngJGuJtqzaQtZkFBVNJezN5ZAdmwjKo2k9tVtrcI3OXk4tPgcg7ChCDZ1URgMOu72Xa5VFHOkymQhWVU60YVmjN6wiC7k6p+S1syCACOwJBYFaexV+yhBekNPsMBO6KAEeE4BMaCU67RsoYhSbXgaT//ht709vZCaWmp6YkEbLFmVJWzas04+iBL7EKpm0J7duqu0B7+CTUpNJuyvb1NCfMj1CqI9wLKUOlOUMeG+gGFkHii4HizUF4z/KFUrPsJ8WbEIyx7nnZ0dDynME6BAuce09iFHo+GrnmGltltb2//E4wVAN82y7vOjKOZXSBhJdHNiT3TYWD8OY2PTUJkdd7MkJMnT5wZVQF2RFX6yBMUdzPMvvfqxz3sXHF+GNT9ANXit/10O1sgHkZvdQAOKvs9B5L7ARELGAAXLSTvM8QExTE+YbHe+HURhZp1aRyF4CJXClbbWwGketgkW9VsY+YaiBCVhfgE+XvxRwgZSM4jUVCDZFQ9pytmXR8hUTB2gnidx4XffVWydN0yQjwmx/jkAZJBrIBI5J7ZvQGZWUgVSuU/EqmOAzicKNMVu816DdRWUV1/7xAP8n+SfwF3Du3NF2sYhwAAAABJRU5ErkJggg==", Nm = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='40px'%20height='40px'%20viewBox='0%200%2040%2040'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3c!--%20Generator:%20Sketch%2060.1%20(88133)%20-%20https://sketch.com%20--%3e%3ctitle%3eshape-cursor%3c/title%3e%3cdesc%3eCreated%20with%20Sketch.%3c/desc%3e%3cdefs%3e%3cpath%20d='M20,21.5%20C20.2454599,21.5%2020.4496084,21.6768752%2020.4919443,21.9101244%20L20.5,22%20L20.5,27%20C20.5,27.2761424%2020.2761424,27.5%2020,27.5%20C19.7545401,27.5%2019.5503916,27.3231248%2019.5080557,27.0898756%20L19.5,27%20L19.5,22%20C19.5,21.7238576%2019.7238576,21.5%2020,21.5%20Z%20M27,19.5%20C27.2761424,19.5%2027.5,19.7238576%2027.5,20%20C27.5,20.2454599%2027.3231248,20.4496084%2027.0898756,20.4919443%20L27,20.5%20L22,20.5%20C21.7238576,20.5%2021.5,20.2761424%2021.5,20%20C21.5,19.7545401%2021.6768752,19.5503916%2021.9101244,19.5080557%20L22,19.5%20L27,19.5%20Z%20M18,19.5%20C18.2761424,19.5%2018.5,19.7238576%2018.5,20%20C18.5,20.2454599%2018.3231248,20.4496084%2018.0898756,20.4919443%20L18,20.5%20L13,20.5%20C12.7238576,20.5%2012.5,20.2761424%2012.5,20%20C12.5,19.7545401%2012.6768752,19.5503916%2012.9101244,19.5080557%20L13,19.5%20L18,19.5%20Z%20M20,12.5%20C20.2454599,12.5%2020.4496084,12.6768752%2020.4919443,12.9101244%20L20.5,13%20L20.5,18%20C20.5,18.2761424%2020.2761424,18.5%2020,18.5%20C19.7545401,18.5%2019.5503916,18.3231248%2019.5080557,18.0898756%20L19.5,18%20L19.5,13%20C19.5,12.7238576%2019.7238576,12.5%2020,12.5%20Z'%20id='path-1'%3e%3c/path%3e%3cfilter%20x='-64.6%25'%20y='-59.5%25'%20width='229.3%25'%20height='246.1%25'%20filterUnits='objectBoundingBox'%20id='filter-2'%3e%3cfeMorphology%20radius='1'%20operator='dilate'%20in='SourceAlpha'%20result='shadowSpreadOuter1'%3e%3c/feMorphology%3e%3cfeOffset%20dx='0'%20dy='2'%20in='shadowSpreadOuter1'%20result='shadowOffsetOuter1'%3e%3c/feOffset%3e%3cfeGaussianBlur%20stdDeviation='3'%20in='shadowOffsetOuter1'%20result='shadowBlurOuter1'%3e%3c/feGaussianBlur%3e%3cfeComposite%20in='shadowBlurOuter1'%20in2='SourceAlpha'%20operator='out'%20result='shadowBlurOuter1'%3e%3c/feComposite%3e%3cfeColorMatrix%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200.16%200'%20type='matrix'%20in='shadowBlurOuter1'%3e%3c/feColorMatrix%3e%3c/filter%3e%3c/defs%3e%3cg%20id='页面-4'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Whiteboard-Guidelines'%20transform='translate(-344.000000,%20-751.000000)'%3e%3cg%20id='shape-cursor'%20transform='translate(344.000000,%20751.000000)'%3e%3crect%20id='矩形备份-44'%20fill='%23FFFFFF'%20opacity='0.01'%20x='0'%20y='0'%20width='40'%20height='40'%20rx='2'%3e%3c/rect%3e%3cg%20id='形状结合'%20fill-rule='nonzero'%3e%3cuse%20fill='black'%20fill-opacity='1'%20filter='url(%23filter-2)'%20xlink:href='%23path-1'%3e%3c/use%3e%3cpath%20stroke='%23FFFFFF'%20stroke-width='1'%20d='M20,21%20C20.4854103,21%2020.898085,21.3479993%2020.9899479,21.8654877%20L21,22%20L21,27%20C21,27.5522847%2020.5522847,28%2020,28%20C19.5145897,28%2019.101915,27.6520007%2019.0100521,27.1345123%20L19,27%20L19,22%20C19,21.4477153%2019.4477153,21%2020,21%20Z%20M27,19%20C27.5522847,19%2028,19.4477153%2028,20%20C28,20.4854103%2027.6520007,20.898085%2027.1345123,20.9899479%20L27,21%20L22,21%20C21.4477153,21%2021,20.5522847%2021,20%20C21,19.5145897%2021.3479993,19.101915%2021.8654877,19.0100521%20L22,19%20L27,19%20Z%20M18,19%20C18.5522847,19%2019,19.4477153%2019,20%20C19,20.4854103%2018.6520007,20.898085%2018.1345123,20.9899479%20L18,21%20L13,21%20C12.4477153,21%2012,20.5522847%2012,20%20C12,19.5145897%2012.3479993,19.101915%2012.8654877,19.0100521%20L13,19%20L18,19%20Z%20M20,12%20C20.4854103,12%2020.898085,12.3479993%2020.9899479,12.8654877%20L21,13%20L21,18%20C21,18.5522847%2020.5522847,19%2020,19%20C19.5145897,19%2019.101915,18.6520007%2019.0100521,18.1345123%20L19,18%20L19,13%20C19,12.4477153%2019.4477153,12%2020,12%20Z'%20fill='%23212324'%20fill-rule='evenodd'%3e%3c/path%3e%3c/g%3e%3crect%20id='矩形'%20fill='%23FFFFFF'%20x='18.5'%20y='17'%20width='3'%20height='6'%3e%3c/rect%3e%3crect%20id='矩形'%20fill='%23FFFFFF'%20x='17'%20y='18.5'%20width='6'%20height='3'%3e%3c/rect%3e%3cpath%20d='M20,21.5%20C20.2454599,21.5%2020.4496084,21.6768752%2020.4919443,21.9101244%20L20.5,22%20L20.5,27%20C20.5,27.2761424%2020.2761424,27.5%2020,27.5%20C19.7545401,27.5%2019.5503916,27.3231248%2019.5080557,27.0898756%20L19.5,27%20L19.5,22%20C19.5,21.7238576%2019.7238576,21.5%2020,21.5%20Z%20M27,19.5%20C27.2761424,19.5%2027.5,19.7238576%2027.5,20%20C27.5,20.2454599%2027.3231248,20.4496084%2027.0898756,20.4919443%20L27,20.5%20L22,20.5%20C21.7238576,20.5%2021.5,20.2761424%2021.5,20%20C21.5,19.7545401%2021.6768752,19.5503916%2021.9101244,19.5080557%20L22,19.5%20L27,19.5%20Z%20M18,19.5%20C18.2761424,19.5%2018.5,19.7238576%2018.5,20%20C18.5,20.2454599%2018.3231248,20.4496084%2018.0898756,20.4919443%20L18,20.5%20L13,20.5%20C12.7238576,20.5%2012.5,20.2761424%2012.5,20%20C12.5,19.7545401%2012.6768752,19.5503916%2012.9101244,19.5080557%20L13,19.5%20L18,19.5%20Z%20M20,12.5%20C20.2454599,12.5%2020.4496084,12.6768752%2020.4919443,12.9101244%20L20.5,13%20L20.5,18%20C20.5,18.2761424%2020.2761424,18.5%2020,18.5%20C19.7545401,18.5%2019.5503916,18.3231248%2019.5080557,18.0898756%20L19.5,18%20L19.5,13%20C19.5,12.7238576%2019.7238576,12.5%2020,12.5%20Z'%20id='形状结合'%20fill='%23212324'%20fill-rule='nonzero'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", Sm = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='47px'%20height='40px'%20viewBox='0%200%2047%2040'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3c!--%20Generator:%20Sketch%2060.1%20(88133)%20-%20https://sketch.com%20--%3e%3ctitle%3etext-cursor%3c/title%3e%3cdesc%3eCreated%20with%20Sketch.%3c/desc%3e%3cdefs%3e%3cpath%20d='M16,26.5%20C15.7238576,26.5%2015.5,26.2761424%2015.5,26%20C15.5,25.7545401%2015.6768752,25.5503916%2015.9101244,25.5080557%20L16,25.5%20L19.5,25.5%20L19.5,14.5%20L16,14.5%20C15.7238576,14.5%2015.5,14.2761424%2015.5,14%20C15.5,13.7545401%2015.6768752,13.5503916%2015.9101244,13.5080557%20L16,13.5%20L24,13.5%20C24.2761424,13.5%2024.5,13.7238576%2024.5,14%20C24.5,14.2454599%2024.3231248,14.4496084%2024.0898756,14.4919443%20L24,14.5%20L20.5,14.5%20L20.5,25.5%20L24,25.5%20C24.2761424,25.5%2024.5,25.7238576%2024.5,26%20C24.5,26.2454599%2024.3231248,26.4496084%2024.0898756,26.4919443%20L24,26.5%20L16,26.5%20Z'%20id='path-1'%3e%3c/path%3e%3cfilter%20x='-284.0%25'%20y='-81.5%25'%20width='668.1%25'%20height='293.9%25'%20filterUnits='objectBoundingBox'%20id='filter-2'%3e%3cfeMorphology%20radius='1'%20operator='dilate'%20in='SourceAlpha'%20result='shadowSpreadOuter1'%3e%3c/feMorphology%3e%3cfeOffset%20dx='0'%20dy='2'%20in='shadowSpreadOuter1'%20result='shadowOffsetOuter1'%3e%3c/feOffset%3e%3cfeGaussianBlur%20stdDeviation='3'%20in='shadowOffsetOuter1'%20result='shadowBlurOuter1'%3e%3c/feGaussianBlur%3e%3cfeComposite%20in='shadowBlurOuter1'%20in2='SourceAlpha'%20operator='out'%20result='shadowBlurOuter1'%3e%3c/feComposite%3e%3cfeColorMatrix%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200.16%200'%20type='matrix'%20in='shadowBlurOuter1'%3e%3c/feColorMatrix%3e%3c/filter%3e%3c/defs%3e%3cg%20id='页面-4'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Whiteboard-Guidelines'%20transform='translate(-388.000000,%20-672.000000)'%3e%3cg%20id='text-cursor'%20transform='translate(392.000000,%20672.000000)'%3e%3crect%20id='矩形备份-40'%20fill='%23FFFFFF'%20opacity='0.01'%20x='0'%20y='0'%20width='40'%20height='40'%20rx='2'%3e%3c/rect%3e%3cg%20id='形状结合'%20fill-rule='nonzero'%3e%3cuse%20fill='black'%20fill-opacity='1'%20filter='url(%23filter-2)'%20xlink:href='%23path-1'%3e%3c/use%3e%3cpath%20stroke='%23FFFFFF'%20stroke-width='1'%20d='M19,25%20L19,15%20L16,15%20C15.4477153,15%2015,14.5522847%2015,14%20C15,13.5145897%2015.3479993,13.101915%2015.8654877,13.0100521%20L16,13%20L24,13%20C24.5522847,13%2025,13.4477153%2025,14%20C25,14.4854103%2024.6520007,14.898085%2024.1345123,14.9899479%20L24,15%20L21,15%20L21,25%20L24,25%20C24.5522847,25%2025,25.4477153%2025,26%20C25,26.4854103%2024.6520007,26.898085%2024.1345123,26.9899479%20L24,27%20L16,27%20C15.4477153,27%2015,26.5522847%2015,26%20C15,25.5145897%2015.3479993,25.101915%2015.8654877,25.0100521%20L16,25%20L19,25%20Z'%20fill='%23212324'%20fill-rule='evenodd'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", Tm = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAYAAADFeBvrAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAgrSURBVHgB7ZprTBRXFIDP7gIt8lQppTwE5V0KaAn6o1pqNGkDDTEmTUhsgKRp+gNJw68CFkLbVC2QkDS+gD8KJdWmARvbFBNNWpuIRGPFWBXQRMPDqIki+KLATs+ZnTvcvXtnX8w2beJJToaduTP3fHPOPffcOwC8kP+2WCDwIvahGFxTuN8KmNSZmULPNjLeqF9F8rdPkIEGEn+r+vjx46LQ0NA8/Dsader58+e/h4WFDWntFO7ot6fMFAt3JLWi2lCDpqamCux2+2+KROj82NhYGrXT2lu5Z/DP/deFByElA4Pv3LlTiHY/nJ6eVnbv3q1s2bJFyc7OVrZu3arU1dUp4+PjxPUQoT+g9tp9PkMFgpo9kxljHRoaWp2Xl3duYmIiurKyEvDoclNCQgIcPnxYPc7MzHwcGRnZhaft4Ag7O9fUbRhaITCie4lgcnNzT7qDIaHz27dvh+vXr0NEREQneqoCHKFnAR+8ZCaQGGq2CxcurCGYycnJZHcwTNAzUFFRoUJFRUV1IFQ5OKBsXB9uxSwgl0TQ3d29Yt26dccwoyVXV1d7hGEiQmGi2AzOUHx/hob4K2yuYS9G987s7OwPISEh7xPM6dOnwVfBsIMjR45AZmbmo5s3b76Xnp7+J55egMVxBSAZT0v1ED+76yn66dOnLQSzd+9ev2BIyFP0MjBco1JTU/sxfFeDazp3cYgZHmKqdoaGNISHh9fv378fSJcqlPV6e3sBJ+I/goOD34VFL0k95Y+HxPHCYGxmw5DQ2NuzZw8EBQVtunXr1jvgwUP+hhz/QDXMMCNVE8zx48dNg2FCz6QQjI2N/RA8VBFmANnu3btXihnpG8pM9fX1EAi5du0aeWkVOAMBCF7yN+R0z4yOjq6NiYlpp9CgdBtIwXpPH6vgDKWLt0CygtM6MDCwBuUYZSKaOCksAiVY9wFOBePgDOOytPAGSKzNVCCC2bBhw69YdK7ypgpYimzbtk2dl7CM+hFcveOUHDylbTFO1YdhFbByx44dA1QFUP0VSJj4+Hjo6+sDq9U6iEmHKvFZTedQ50GYbN15SITVlwNlZWUnLRZL8s6dOwMOQ9UCTtKTra2ttdppt9V2kMF5cbmsjxuM43bMNrmUzc6fP6+GQiDGDoOJi4ubwb4qm5ubafyIE6nLxGqTPEsGo1cBOGNX0TyDYafC0CyOaxcVziyh53Z2dkJycvLMvn37PmpoaBgFR4jxYSbWdVIgI89Iq4CjR48CZjlYv369+tssqI6ODsjPz4f+/v668vLycxrEHHfkYdwC8SB6mGEV8Cl64cuuri5oa2tTG+EyGjZu3AiXLl1qefDgwV8lJSUFZkDV1tZCcXExXLx4sbWoqKgPFj0zx8GI9ZwO5W4M6ekZYeqpaqbqmaSqqkpNpcPDw4dwzfM9nrLduHEjEs+X0XV/Sx96LnqE1kLtBQUF3eDwCO8dGQyzV5rl+JyuegfXI29jRotiRlKnpFghHMzKyjqotVXS0tLacKPjF3bdHxjSq1evduAkepAD+ZsDYlC8V5w8ZBVg+PPq2MGMlkInqE4joTf45MmT4YyMjAPcA+ltLSQlJX2BafxnX6HI29QeK44TOTk57mCYZ0QoJ8OBM4yB6dkNkwGlSygsLFQvYtYB3BTMxFL+M+0eFgZqp4mJiU2+QKGX1fGIk/QIrn0aYXGsyDxjmAyMhO2jhaCGoUbX1NSkLSwsPMJqV8Fspu6lIZS6OYhjiOLwdU7fQM1HfRPD7wS1obZ0j0xpb4726Z49ezaJf2/S7s9ATUGNR41BjdJseRnke3WGwhrRTS9pD1mOGoeG15BxOOfoxuCkp0Ih6NeaEaSZGlieJyiCoc1FgsGldokGk8nBvAKOrWIGQ5uPsm0tt0BWDiicAaGuGhkZ+YqMw9StGzU4OKhCnT179hNsswY1FTXdE5QEJhc1S3tGogazXLOBwQSBl3tzIhQPtAL1VQJCTcNx8y1vHIUghSKFZE9PT7H2dlM1b+Wgrr1y5Uq77J75+fnplpaWMg2ch4nlYEI5z7hdensDpI4hrYNErcMMXJ32koG4ztf3pultz83NjWG99Ra2WQ0OL2VjZjwgeufUqVOqV8+cOdPIwdBLSNJeHg8TAh5WqJ6EfSmgt7IMNRJ1JThiOlnrOAMHshprmMKdoGSCpb9s3B3SYLIFGIqICJB7xisYi+RvfiypXw40DWGdlJaWRmMd141hk8V2OWm7ieYTXhBc3+BgaZyqAISjOYxSMVvXsBTNlzdiNQDgRao2AtK3pjggpmrqbGpqSsLPIN/dv38/gaBwUjTshMHcvn27JyUlpRmc5xpPMD599LIYnLNyUKKndKjGxsakXbt2deMCLIE8IVvs0YRM1fjdu3d/wrXN5+BcnzEgvor2uN3rjzAYMp5lPEoQlE5fA0fWo8GfhlCbKVFQ1pKNIfzcOHH58mWqaimVUwJI0+6n59D4pIlzmdZPMPiZzXjDjX47Le5g0Uu8x2zgPqWyKpjVe7x3+AUbq9NYjQbgp2dsBud5o8TP7d5kHAWcQchQfoEmLgn8HjOiBIF7o5hI1x6CEbLNP3bdqYAF44JzyWLzcN1i8DcT/o3awbm8Fz3DAy2A62INwPV/E3wWdx5inmBHuwChCBD6R2JwHge80TIQRQLjt7e8DTkGZgfX8cUMZTDAteFDkveaIlzjX9ySQs8X18r2t2VHUURPKoICmDR+eCO9aSdmOIub3/w9RgpgUpiJhvraXpa6jZKHGEqyusw0GLFzX+5RhN/8kYnMSNMMfyH/V/kHST6OYVElTPAAAAAASUVORK5CYII=";
15131
- class km extends k.Component {
15105
+ }), vw = k.memo(ww, (a, i) => !!ft(a, i)), Iw = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAYAAADFeBvrAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAYISURBVHgB7ZpNSCtXFIBPEuvz+dMGpYUKD/sWFX+Qti6kK7Hqpm6e9q0rIoIUFUShPLV10VZx4+JZqa9v20LBhdq9fyBUCtKNPH8qYl2IOw3G38Rkek4y15y5uTOZJDOWggcOSSYzN/ebc+45554JwIM8iBCPyTEP+86T4vyMfsRN4b+nQTKIJp0vzuGvlpID7os8EQNEIBD4oKio6Bm9DwaDv/v9/n/076JgbtWUYPchwrW8qD7UnOvr6wFNkpubm+/wu7f0c7y6mrnlvQufxB0Iau7V1dX3BDA/P6/V1dVpzc3N2uLiIofK1c8VYHys/wRKBUN3/hGHqaysNOjc3FwMis6hc0FtLTHuvYLxCCZgci8uLn4wg5Gh6Fy8Jk+/NkcCAlAAuUkoW4g0B+d5tLS05O/r67O8eGxsDNra2uDy8nKsoKCAwCIQDxQa0yTxgrvCYXyTk5Ml+Orf2dlJeeHIyAigFSE/P38ELfUNqNdSkjgF5FF89jL1TU1NlQwODl5gZPujp6cHWltbUw7Koc7Pz8mkZpHPFeFrJuZeqLnoMoPoZqe0JjDP/IZgnyLUG/o8NDRkuo5Ua2pjY6MC4oFCFf1cA0oKzRSOp6enRfTaGh0d/QxBt+1CUVgnOTs7+xrHfQzGyOcKkK3QTJMnQffZ6e/v/xwttmsHqqmpKXbdycnJCxy7ABLh3FEgVZ6hZJhnFZoFFMF0d3c/w7v+dyookXBnZ2c/xvHfhriVcvXfdBRItsxjnOhYqjwjoAimq6vrCysoGofk+Ph4Esd/F/UdiFtJAGUd2DygTpp5dmBUUJ2dnc9VUALm8PDwJY7/BPU9VD8k3M4RC6kskxZMKigKIMLN9vf3p3H8DyWgfEhEOwOQD9IXOTz7EObbwsLC4YWFBRgeHrY9ECXYo6MjaGlpKWlsbPxkYGDgRW1tbSEWquVlZWXBzc3Nl1VVVa8hXiXc6ioqBqGaPDk7AACJTRZ3NS9lcUp86cJwoSQ7Pj4Op6enfxUXF3/V0NCQv7q6GsCvwrqGUG/01xAD4+VQTOxaSF43d5bBOisrGBJRCtXX17+/trb268rKSgASFgmz97KFkmo6OztWuVyPweiWGc4WRkhFRQVEIpHg8vJyQAIQVlLBROVxvBYQHsXnO8tk62ZcyN0wecLBwcEvYHSzEPscBqOLCRhLC4n9uqaA8UAWAcAKhtbQ3t7eTHl5+Y9gtAp3twhT056CDMQ7MRzIFTeTYKb1yYYVQFH9VdzsqNmYKpfTJBDX3Ixgdnd3XyHMT2AMALJlBBSPaMpNngrIsTyTCgaj288YDGakictrxizvKFNOjgSSBLS+vv6UYHDb7DgMVgsChjTEgCIKGG4ZU+EWkgNBzN1qamq+pAMTExPgFMzW1tZrhHkFyWE5KxgSszx0527RaDRmOSpRshEOU11dPQPG8CwHARHJlMnTSrwSRFIlfXt7m3V5ngJGuJtqzaQtZkFBVNJezN5ZAdmwjKo2k9tVtrcI3OXk4tPgcg7ChCDZ1URgMOu72Xa5VFHOkymQhWVU60YVmjN6wiC7k6p+S1syCACOwJBYFaexV+yhBekNPsMBO6KAEeE4BMaCU67RsoYhSbXgaT//ht709vZCaWmp6YkEbLFmVJWzas04+iBL7EKpm0J7duqu0B7+CTUpNJuyvb1NCfMj1CqI9wLKUOlOUMeG+gGFkHii4HizUF4z/KFUrPsJ8WbEIyx7nnZ0dDynME6BAuce09iFHo+GrnmGltltb2//E4wVAN82y7vOjKOZXSBhJdHNiT3TYWD8OY2PTUJkdd7MkJMnT5wZVQF2RFX6yBMUdzPMvvfqxz3sXHF+GNT9ANXit/10O1sgHkZvdQAOKvs9B5L7ARELGAAXLSTvM8QExTE+YbHe+HURhZp1aRyF4CJXClbbWwGketgkW9VsY+YaiBCVhfgE+XvxRwgZSM4jUVCDZFQ9pytmXR8hUTB2gnidx4XffVWydN0yQjwmx/jkAZJBrIBI5J7ZvQGZWUgVSuU/EqmOAzicKNMVu816DdRWUV1/7xAP8n+SfwF3Du3NF2sYhwAAAABJRU5ErkJggg==", Nw = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='40px'%20height='40px'%20viewBox='0%200%2040%2040'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3c!--%20Generator:%20Sketch%2060.1%20(88133)%20-%20https://sketch.com%20--%3e%3ctitle%3eshape-cursor%3c/title%3e%3cdesc%3eCreated%20with%20Sketch.%3c/desc%3e%3cdefs%3e%3cpath%20d='M20,21.5%20C20.2454599,21.5%2020.4496084,21.6768752%2020.4919443,21.9101244%20L20.5,22%20L20.5,27%20C20.5,27.2761424%2020.2761424,27.5%2020,27.5%20C19.7545401,27.5%2019.5503916,27.3231248%2019.5080557,27.0898756%20L19.5,27%20L19.5,22%20C19.5,21.7238576%2019.7238576,21.5%2020,21.5%20Z%20M27,19.5%20C27.2761424,19.5%2027.5,19.7238576%2027.5,20%20C27.5,20.2454599%2027.3231248,20.4496084%2027.0898756,20.4919443%20L27,20.5%20L22,20.5%20C21.7238576,20.5%2021.5,20.2761424%2021.5,20%20C21.5,19.7545401%2021.6768752,19.5503916%2021.9101244,19.5080557%20L22,19.5%20L27,19.5%20Z%20M18,19.5%20C18.2761424,19.5%2018.5,19.7238576%2018.5,20%20C18.5,20.2454599%2018.3231248,20.4496084%2018.0898756,20.4919443%20L18,20.5%20L13,20.5%20C12.7238576,20.5%2012.5,20.2761424%2012.5,20%20C12.5,19.7545401%2012.6768752,19.5503916%2012.9101244,19.5080557%20L13,19.5%20L18,19.5%20Z%20M20,12.5%20C20.2454599,12.5%2020.4496084,12.6768752%2020.4919443,12.9101244%20L20.5,13%20L20.5,18%20C20.5,18.2761424%2020.2761424,18.5%2020,18.5%20C19.7545401,18.5%2019.5503916,18.3231248%2019.5080557,18.0898756%20L19.5,18%20L19.5,13%20C19.5,12.7238576%2019.7238576,12.5%2020,12.5%20Z'%20id='path-1'%3e%3c/path%3e%3cfilter%20x='-64.6%25'%20y='-59.5%25'%20width='229.3%25'%20height='246.1%25'%20filterUnits='objectBoundingBox'%20id='filter-2'%3e%3cfeMorphology%20radius='1'%20operator='dilate'%20in='SourceAlpha'%20result='shadowSpreadOuter1'%3e%3c/feMorphology%3e%3cfeOffset%20dx='0'%20dy='2'%20in='shadowSpreadOuter1'%20result='shadowOffsetOuter1'%3e%3c/feOffset%3e%3cfeGaussianBlur%20stdDeviation='3'%20in='shadowOffsetOuter1'%20result='shadowBlurOuter1'%3e%3c/feGaussianBlur%3e%3cfeComposite%20in='shadowBlurOuter1'%20in2='SourceAlpha'%20operator='out'%20result='shadowBlurOuter1'%3e%3c/feComposite%3e%3cfeColorMatrix%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200.16%200'%20type='matrix'%20in='shadowBlurOuter1'%3e%3c/feColorMatrix%3e%3c/filter%3e%3c/defs%3e%3cg%20id='页面-4'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Whiteboard-Guidelines'%20transform='translate(-344.000000,%20-751.000000)'%3e%3cg%20id='shape-cursor'%20transform='translate(344.000000,%20751.000000)'%3e%3crect%20id='矩形备份-44'%20fill='%23FFFFFF'%20opacity='0.01'%20x='0'%20y='0'%20width='40'%20height='40'%20rx='2'%3e%3c/rect%3e%3cg%20id='形状结合'%20fill-rule='nonzero'%3e%3cuse%20fill='black'%20fill-opacity='1'%20filter='url(%23filter-2)'%20xlink:href='%23path-1'%3e%3c/use%3e%3cpath%20stroke='%23FFFFFF'%20stroke-width='1'%20d='M20,21%20C20.4854103,21%2020.898085,21.3479993%2020.9899479,21.8654877%20L21,22%20L21,27%20C21,27.5522847%2020.5522847,28%2020,28%20C19.5145897,28%2019.101915,27.6520007%2019.0100521,27.1345123%20L19,27%20L19,22%20C19,21.4477153%2019.4477153,21%2020,21%20Z%20M27,19%20C27.5522847,19%2028,19.4477153%2028,20%20C28,20.4854103%2027.6520007,20.898085%2027.1345123,20.9899479%20L27,21%20L22,21%20C21.4477153,21%2021,20.5522847%2021,20%20C21,19.5145897%2021.3479993,19.101915%2021.8654877,19.0100521%20L22,19%20L27,19%20Z%20M18,19%20C18.5522847,19%2019,19.4477153%2019,20%20C19,20.4854103%2018.6520007,20.898085%2018.1345123,20.9899479%20L18,21%20L13,21%20C12.4477153,21%2012,20.5522847%2012,20%20C12,19.5145897%2012.3479993,19.101915%2012.8654877,19.0100521%20L13,19%20L18,19%20Z%20M20,12%20C20.4854103,12%2020.898085,12.3479993%2020.9899479,12.8654877%20L21,13%20L21,18%20C21,18.5522847%2020.5522847,19%2020,19%20C19.5145897,19%2019.101915,18.6520007%2019.0100521,18.1345123%20L19,18%20L19,13%20C19,12.4477153%2019.4477153,12%2020,12%20Z'%20fill='%23212324'%20fill-rule='evenodd'%3e%3c/path%3e%3c/g%3e%3crect%20id='矩形'%20fill='%23FFFFFF'%20x='18.5'%20y='17'%20width='3'%20height='6'%3e%3c/rect%3e%3crect%20id='矩形'%20fill='%23FFFFFF'%20x='17'%20y='18.5'%20width='6'%20height='3'%3e%3c/rect%3e%3cpath%20d='M20,21.5%20C20.2454599,21.5%2020.4496084,21.6768752%2020.4919443,21.9101244%20L20.5,22%20L20.5,27%20C20.5,27.2761424%2020.2761424,27.5%2020,27.5%20C19.7545401,27.5%2019.5503916,27.3231248%2019.5080557,27.0898756%20L19.5,27%20L19.5,22%20C19.5,21.7238576%2019.7238576,21.5%2020,21.5%20Z%20M27,19.5%20C27.2761424,19.5%2027.5,19.7238576%2027.5,20%20C27.5,20.2454599%2027.3231248,20.4496084%2027.0898756,20.4919443%20L27,20.5%20L22,20.5%20C21.7238576,20.5%2021.5,20.2761424%2021.5,20%20C21.5,19.7545401%2021.6768752,19.5503916%2021.9101244,19.5080557%20L22,19.5%20L27,19.5%20Z%20M18,19.5%20C18.2761424,19.5%2018.5,19.7238576%2018.5,20%20C18.5,20.2454599%2018.3231248,20.4496084%2018.0898756,20.4919443%20L18,20.5%20L13,20.5%20C12.7238576,20.5%2012.5,20.2761424%2012.5,20%20C12.5,19.7545401%2012.6768752,19.5503916%2012.9101244,19.5080557%20L13,19.5%20L18,19.5%20Z%20M20,12.5%20C20.2454599,12.5%2020.4496084,12.6768752%2020.4919443,12.9101244%20L20.5,13%20L20.5,18%20C20.5,18.2761424%2020.2761424,18.5%2020,18.5%20C19.7545401,18.5%2019.5503916,18.3231248%2019.5080557,18.0898756%20L19.5,18%20L19.5,13%20C19.5,12.7238576%2019.7238576,12.5%2020,12.5%20Z'%20id='形状结合'%20fill='%23212324'%20fill-rule='nonzero'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", Sw = "data:image/svg+xml,%3c?xml%20version='1.0'%20encoding='UTF-8'?%3e%3csvg%20width='47px'%20height='40px'%20viewBox='0%200%2047%2040'%20version='1.1'%20xmlns='http://www.w3.org/2000/svg'%20xmlns:xlink='http://www.w3.org/1999/xlink'%3e%3c!--%20Generator:%20Sketch%2060.1%20(88133)%20-%20https://sketch.com%20--%3e%3ctitle%3etext-cursor%3c/title%3e%3cdesc%3eCreated%20with%20Sketch.%3c/desc%3e%3cdefs%3e%3cpath%20d='M16,26.5%20C15.7238576,26.5%2015.5,26.2761424%2015.5,26%20C15.5,25.7545401%2015.6768752,25.5503916%2015.9101244,25.5080557%20L16,25.5%20L19.5,25.5%20L19.5,14.5%20L16,14.5%20C15.7238576,14.5%2015.5,14.2761424%2015.5,14%20C15.5,13.7545401%2015.6768752,13.5503916%2015.9101244,13.5080557%20L16,13.5%20L24,13.5%20C24.2761424,13.5%2024.5,13.7238576%2024.5,14%20C24.5,14.2454599%2024.3231248,14.4496084%2024.0898756,14.4919443%20L24,14.5%20L20.5,14.5%20L20.5,25.5%20L24,25.5%20C24.2761424,25.5%2024.5,25.7238576%2024.5,26%20C24.5,26.2454599%2024.3231248,26.4496084%2024.0898756,26.4919443%20L24,26.5%20L16,26.5%20Z'%20id='path-1'%3e%3c/path%3e%3cfilter%20x='-284.0%25'%20y='-81.5%25'%20width='668.1%25'%20height='293.9%25'%20filterUnits='objectBoundingBox'%20id='filter-2'%3e%3cfeMorphology%20radius='1'%20operator='dilate'%20in='SourceAlpha'%20result='shadowSpreadOuter1'%3e%3c/feMorphology%3e%3cfeOffset%20dx='0'%20dy='2'%20in='shadowSpreadOuter1'%20result='shadowOffsetOuter1'%3e%3c/feOffset%3e%3cfeGaussianBlur%20stdDeviation='3'%20in='shadowOffsetOuter1'%20result='shadowBlurOuter1'%3e%3c/feGaussianBlur%3e%3cfeComposite%20in='shadowBlurOuter1'%20in2='SourceAlpha'%20operator='out'%20result='shadowBlurOuter1'%3e%3c/feComposite%3e%3cfeColorMatrix%20values='0%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200%200.16%200'%20type='matrix'%20in='shadowBlurOuter1'%3e%3c/feColorMatrix%3e%3c/filter%3e%3c/defs%3e%3cg%20id='页面-4'%20stroke='none'%20stroke-width='1'%20fill='none'%20fill-rule='evenodd'%3e%3cg%20id='Whiteboard-Guidelines'%20transform='translate(-388.000000,%20-672.000000)'%3e%3cg%20id='text-cursor'%20transform='translate(392.000000,%20672.000000)'%3e%3crect%20id='矩形备份-40'%20fill='%23FFFFFF'%20opacity='0.01'%20x='0'%20y='0'%20width='40'%20height='40'%20rx='2'%3e%3c/rect%3e%3cg%20id='形状结合'%20fill-rule='nonzero'%3e%3cuse%20fill='black'%20fill-opacity='1'%20filter='url(%23filter-2)'%20xlink:href='%23path-1'%3e%3c/use%3e%3cpath%20stroke='%23FFFFFF'%20stroke-width='1'%20d='M19,25%20L19,15%20L16,15%20C15.4477153,15%2015,14.5522847%2015,14%20C15,13.5145897%2015.3479993,13.101915%2015.8654877,13.0100521%20L16,13%20L24,13%20C24.5522847,13%2025,13.4477153%2025,14%20C25,14.4854103%2024.6520007,14.898085%2024.1345123,14.9899479%20L24,15%20L21,15%20L21,25%20L24,25%20C24.5522847,25%2025,25.4477153%2025,26%20C25,26.4854103%2024.6520007,26.898085%2024.1345123,26.9899479%20L24,27%20L16,27%20C15.4477153,27%2015,26.5522847%2015,26%20C15,25.5145897%2015.3479993,25.101915%2015.8654877,25.0100521%20L16,25%20L19,25%20Z'%20fill='%23212324'%20fill-rule='evenodd'%3e%3c/path%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/g%3e%3c/svg%3e", Tw = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADQAAAA0CAYAAADFeBvrAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAgrSURBVHgB7ZprTBRXFIDP7gIt8lQppTwE5V0KaAn6o1pqNGkDDTEmTUhsgKRp+gNJw68CFkLbVC2QkDS+gD8KJdWmARvbFBNNWpuIRGPFWBXQRMPDqIki+KLATs+ZnTvcvXtnX8w2beJJToaduTP3fHPOPffcOwC8kP+2WCDwIvahGFxTuN8KmNSZmULPNjLeqF9F8rdPkIEGEn+r+vjx46LQ0NA8/Dsader58+e/h4WFDWntFO7ot6fMFAt3JLWi2lCDpqamCux2+2+KROj82NhYGrXT2lu5Z/DP/deFByElA4Pv3LlTiHY/nJ6eVnbv3q1s2bJFyc7OVrZu3arU1dUp4+PjxPUQoT+g9tp9PkMFgpo9kxljHRoaWp2Xl3duYmIiurKyEvDoclNCQgIcPnxYPc7MzHwcGRnZhaft4Ag7O9fUbRhaITCie4lgcnNzT7qDIaHz27dvh+vXr0NEREQneqoCHKFnAR+8ZCaQGGq2CxcurCGYycnJZHcwTNAzUFFRoUJFRUV1IFQ5OKBsXB9uxSwgl0TQ3d29Yt26dccwoyVXV1d7hGEiQmGi2AzOUHx/hob4K2yuYS9G987s7OwPISEh7xPM6dOnwVfBsIMjR45AZmbmo5s3b76Xnp7+J55egMVxBSAZT0v1ED+76yn66dOnLQSzd+9ev2BIyFP0MjBco1JTU/sxfFeDazp3cYgZHmKqdoaGNISHh9fv378fSJcqlPV6e3sBJ+I/goOD34VFL0k95Y+HxPHCYGxmw5DQ2NuzZw8EBQVtunXr1jvgwUP+hhz/QDXMMCNVE8zx48dNg2FCz6QQjI2N/RA8VBFmANnu3btXihnpG8pM9fX1EAi5du0aeWkVOAMBCF7yN+R0z4yOjq6NiYlpp9CgdBtIwXpPH6vgDKWLt0CygtM6MDCwBuUYZSKaOCksAiVY9wFOBePgDOOytPAGSKzNVCCC2bBhw69YdK7ypgpYimzbtk2dl7CM+hFcveOUHDylbTFO1YdhFbByx44dA1QFUP0VSJj4+Hjo6+sDq9U6iEmHKvFZTedQ50GYbN15SITVlwNlZWUnLRZL8s6dOwMOQ9UCTtKTra2ttdppt9V2kMF5cbmsjxuM43bMNrmUzc6fP6+GQiDGDoOJi4ubwb4qm5ubafyIE6nLxGqTPEsGo1cBOGNX0TyDYafC0CyOaxcVziyh53Z2dkJycvLMvn37PmpoaBgFR4jxYSbWdVIgI89Iq4CjR48CZjlYv369+tssqI6ODsjPz4f+/v668vLycxrEHHfkYdwC8SB6mGEV8Cl64cuuri5oa2tTG+EyGjZu3AiXLl1qefDgwV8lJSUFZkDV1tZCcXExXLx4sbWoqKgPFj0zx8GI9ZwO5W4M6ekZYeqpaqbqmaSqqkpNpcPDw4dwzfM9nrLduHEjEs+X0XV/Sx96LnqE1kLtBQUF3eDwCO8dGQyzV5rl+JyuegfXI29jRotiRlKnpFghHMzKyjqotVXS0tLacKPjF3bdHxjSq1evduAkepAD+ZsDYlC8V5w8ZBVg+PPq2MGMlkInqE4joTf45MmT4YyMjAPcA+ltLSQlJX2BafxnX6HI29QeK44TOTk57mCYZ0QoJ8OBM4yB6dkNkwGlSygsLFQvYtYB3BTMxFL+M+0eFgZqp4mJiU2+QKGX1fGIk/QIrn0aYXGsyDxjmAyMhO2jhaCGoUbX1NSkLSwsPMJqV8Fspu6lIZS6OYhjiOLwdU7fQM1HfRPD7wS1obZ0j0xpb4726Z49ezaJf2/S7s9ATUGNR41BjdJseRnke3WGwhrRTS9pD1mOGoeG15BxOOfoxuCkp0Ih6NeaEaSZGlieJyiCoc1FgsGldokGk8nBvAKOrWIGQ5uPsm0tt0BWDiicAaGuGhkZ+YqMw9StGzU4OKhCnT179hNsswY1FTXdE5QEJhc1S3tGogazXLOBwQSBl3tzIhQPtAL1VQJCTcNx8y1vHIUghSKFZE9PT7H2dlM1b+Wgrr1y5Uq77J75+fnplpaWMg2ch4nlYEI5z7hdensDpI4hrYNErcMMXJ32koG4ztf3pultz83NjWG99Ra2WQ0OL2VjZjwgeufUqVOqV8+cOdPIwdBLSNJeHg8TAh5WqJ6EfSmgt7IMNRJ1JThiOlnrOAMHshprmMKdoGSCpb9s3B3SYLIFGIqICJB7xisYi+RvfiypXw40DWGdlJaWRmMd141hk8V2OWm7ieYTXhBc3+BgaZyqAISjOYxSMVvXsBTNlzdiNQDgRao2AtK3pjggpmrqbGpqSsLPIN/dv38/gaBwUjTshMHcvn27JyUlpRmc5xpPMD599LIYnLNyUKKndKjGxsakXbt2deMCLIE8IVvs0YRM1fjdu3d/wrXN5+BcnzEgvor2uN3rjzAYMp5lPEoQlE5fA0fWo8GfhlCbKVFQ1pKNIfzcOHH58mWqaimVUwJI0+6n59D4pIlzmdZPMPiZzXjDjX47Le5g0Uu8x2zgPqWyKpjVe7x3+AUbq9NYjQbgp2dsBud5o8TP7d5kHAWcQchQfoEmLgn8HjOiBIF7o5hI1x6CEbLNP3bdqYAF44JzyWLzcN1i8DcT/o3awbm8Fz3DAy2A62INwPV/E3wWdx5inmBHuwChCBD6R2JwHge80TIQRQLjt7e8DTkGZgfX8cUMZTDAteFDkveaIlzjX9ySQs8X18r2t2VHUURPKoICmDR+eCO9aSdmOIub3/w9RgpgUpiJhvraXpa6jZKHGEqyusw0GLFzX+5RhN/8kYnMSNMMfyH/V/kHST6OYVElTPAAAAAASUVORK5CYII=";
15106
+ class kw extends k.Component {
15132
15107
  constructor(t) {
15133
15108
  super(t);
15134
15109
  y(this, "renderAvatar", (t) => {
@@ -15190,20 +15165,20 @@ class km extends k.Component {
15190
15165
  opacity: this.getOpacity(t),
15191
15166
  backgroundColor: this.getCursorBackgroundColor(t),
15192
15167
  color: this.getCursorTextColor(t)
15193
- }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-pencil-image", src: Im, alt: "pencilCursor" }))));
15168
+ }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-pencil-image", src: Iw, alt: "pencilCursor" }))));
15194
15169
  case at.eraser:
15195
15170
  case at.pencilEraser:
15196
15171
  return /* @__PURE__ */ k.createElement("div", { className: "cursor-box" }, /* @__PURE__ */ k.createElement("div", { className: "cursor-mid cursor-pencil-offset", style: { transform: "translate(-50%, -90%)", marginLeft: "0px" } }, /* @__PURE__ */ k.createElement("div", { className: "cursor-name" }, /* @__PURE__ */ k.createElement("div", { style: {
15197
15172
  opacity: this.getOpacity(t),
15198
15173
  backgroundColor: this.getCursorBackgroundColor(t),
15199
15174
  color: this.getCursorTextColor(t)
15200
- }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-pencil-image", src: Tm, alt: "pencilEraser" }))));
15175
+ }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-pencil-image", src: Tw, alt: "pencilEraser" }))));
15201
15176
  case at.text:
15202
15177
  return /* @__PURE__ */ k.createElement("div", { className: "cursor-box" }, /* @__PURE__ */ k.createElement("div", { className: "cursor-mid cursor-pencil-offset", style: { transform: "translate(-50%, -65%)", marginLeft: "0px" } }, /* @__PURE__ */ k.createElement("div", { className: "cursor-name" }, /* @__PURE__ */ k.createElement("div", { style: {
15203
15178
  opacity: this.getOpacity(t),
15204
15179
  backgroundColor: this.getCursorBackgroundColor(t),
15205
15180
  color: this.getCursorTextColor(t)
15206
- }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-arrow-image", src: Sm, alt: "textCursor" }))));
15181
+ }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-arrow-image", src: Sw, alt: "textCursor" }))));
15207
15182
  case at.rectangle:
15208
15183
  case at.arrow:
15209
15184
  case at.straight:
@@ -15213,18 +15188,18 @@ class km extends k.Component {
15213
15188
  opacity: this.getOpacity(t),
15214
15189
  backgroundColor: this.getCursorBackgroundColor(t),
15215
15190
  color: this.getCursorTextColor(t)
15216
- }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-arrow-image", src: Nm, alt: "shapeCursor" }))));
15191
+ }, className: this.getThemeClass(t) }, this.renderAvatar(t), e, this.renderTag(t))), /* @__PURE__ */ k.createElement("div", null, /* @__PURE__ */ k.createElement("img", { className: "cursor-arrow-image", src: Nw, alt: "shapeCursor" }))));
15217
15192
  default:
15218
15193
  return null;
15219
15194
  }
15220
15195
  }
15221
15196
  }
15222
- const Cm = (a) => {
15197
+ const Cw = (a) => {
15223
15198
  const { className: i, info: t } = a, { roomMember: e, ...s } = t || {};
15224
15199
  return /* @__PURE__ */ k.createElement("div", { className: `${i}`, style: s ? {
15225
15200
  transform: `translate(${s.x}px, ${s.y}px)`
15226
- } : { display: "none" } }, e && /* @__PURE__ */ k.createElement(km, { roomMember: e }));
15227
- }, bm = (a) => {
15201
+ } : { display: "none" } }, e && /* @__PURE__ */ k.createElement(kw, { roomMember: e }));
15202
+ }, bw = (a) => {
15228
15203
  const { className: i, manager: t } = a, [e, s] = nt();
15229
15204
  yt(() => (t.internalMsgEmitter.on([ot.Cursor, t.viewId], o), () => {
15230
15205
  t.internalMsgEmitter.off([ot.Cursor, t.viewId], o);
@@ -15236,13 +15211,13 @@ const Cm = (a) => {
15236
15211
  if (e != null && e.length) {
15237
15212
  const r = e.map((c) => {
15238
15213
  var l;
15239
- return c.roomMember ? /* @__PURE__ */ k.createElement(Cm, { key: (l = c.roomMember) == null ? void 0 : l.memberId, className: i, info: c }) : null;
15214
+ return c.roomMember ? /* @__PURE__ */ k.createElement(Cw, { key: (l = c.roomMember) == null ? void 0 : l.memberId, className: i, info: c }) : null;
15240
15215
  });
15241
15216
  return /* @__PURE__ */ k.createElement(k.Fragment, null, r);
15242
15217
  }
15243
15218
  return null;
15244
15219
  }, [e]);
15245
- }, xm = (a) => {
15220
+ }, xw = (a) => {
15246
15221
  const { viewId: i, miniMapCanvas: t, highlightColor: e, miniMapManager: s, contianer: o } = a, [n, r] = nt();
15247
15222
  yt(() => (c(), s.listener.addListener([i, "viewCameraUpate"], c), s.listener.emitAsync([i, "miniMapCreate"], !0), () => {
15248
15223
  s.listener.removeListener([i, "viewCameraUpate"], c);
@@ -15251,19 +15226,19 @@ const Cm = (a) => {
15251
15226
  const u = s.maps.get(i);
15252
15227
  u && l(u.miniMapCamera, u.viewCamera);
15253
15228
  }, l = (u, d) => {
15254
- const { width: f, height: g } = o.getBoundingClientRect(), p = Math.min(f / u.width, g / u.height), M = d.width / d.scale, v = d.height / d.scale, m = [d.centerX, d.centerY], S = [u.centerX, u.centerY], T = [m[0] - S[0], m[1] - S[1]], N = Math.min(u.scale * p, u.scale * p), w = [T[0] * N, T[1] * N, M, v, N];
15255
- r(w);
15229
+ const { width: f, height: g } = o.getBoundingClientRect(), p = Math.min(f / u.width, g / u.height), M = d.width / d.scale, v = d.height / d.scale, w = [d.centerX, d.centerY], S = [u.centerX, u.centerY], T = [w[0] - S[0], w[1] - S[1]], N = Math.min(u.scale * p, u.scale * p), m = [T[0] * N, T[1] * N, M, v, N];
15230
+ r(m);
15256
15231
  }, h = (u) => {
15257
15232
  var d;
15258
15233
  if (s.control.renderControl.isWritable) {
15259
15234
  const f = u.nativeEvent.target || u.nativeEvent.srcElement;
15260
15235
  if (f && u.nativeEvent && n) {
15261
- const { width: g, height: p } = f.getBoundingClientRect(), [M, v] = [g / 2, p / 2], [m, S] = [(u.nativeEvent.offsetX - M) / n[4], (u.nativeEvent.offsetY - v) / n[4]], T = s.maps.get(i);
15236
+ const { width: g, height: p } = f.getBoundingClientRect(), [M, v] = [g / 2, p / 2], [w, S] = [(u.nativeEvent.offsetX - M) / n[4], (u.nativeEvent.offsetY - v) / n[4]], T = s.maps.get(i);
15262
15237
  if (T != null && T.viewCamera) {
15263
- const [N, w] = [T.miniMapCamera.centerX + m, T.miniMapCamera.centerY + S];
15238
+ const [N, m] = [T.miniMapCamera.centerX + w, T.miniMapCamera.centerY + S];
15264
15239
  (d = s.control.room) == null || d.moveCamera({
15265
15240
  centerX: N,
15266
- centerY: w,
15241
+ centerY: m,
15267
15242
  animationMode: "immediately"
15268
15243
  });
15269
15244
  }
@@ -15291,7 +15266,7 @@ const Cm = (a) => {
15291
15266
  transform: `translate(calc(-50% + ${n[0]}px), calc(-50% + ${n[1]}px))`,
15292
15267
  pointerEvents: "none"
15293
15268
  } }));
15294
- }, Lm = (a) => {
15269
+ }, Lw = (a) => {
15295
15270
  const { miniMapManager: i, active: t, className: e } = a, s = X(() => {
15296
15271
  const o = i.maps;
15297
15272
  if (t) {
@@ -15300,7 +15275,7 @@ const Cm = (a) => {
15300
15275
  const { miniMapCamera: r, viewCamera: c, ...l } = n;
15301
15276
  if (l.contianer && r && c) {
15302
15277
  const h = i.highlightColor;
15303
- return bn(/* @__PURE__ */ k.createElement(xm, { viewId: t, ...l, highlightColor: h, miniMapManager: i }), l.contianer);
15278
+ return bn(/* @__PURE__ */ k.createElement(xw, { viewId: t, ...l, highlightColor: h, miniMapManager: i }), l.contianer);
15304
15279
  }
15305
15280
  }
15306
15281
  }
@@ -15422,7 +15397,7 @@ class gs extends k.Component {
15422
15397
  setOperationType: this.setOperationType.bind(this),
15423
15398
  setFloatBarData: this.setFloatBarData.bind(this)
15424
15399
  } }, this.state.showFloatBar && /* @__PURE__ */ k.createElement(
15425
- vm,
15400
+ vw,
15426
15401
  {
15427
15402
  ref: this.props.refs.floatBarRef,
15428
15403
  editors: this.state.editors,
@@ -15430,7 +15405,7 @@ class gs extends k.Component {
15430
15405
  isHide: t
15431
15406
  }
15432
15407
  ) || null, ((c = this.state.editors) == null ? void 0 : c.size) && /* @__PURE__ */ k.createElement(
15433
- lm,
15408
+ lw,
15434
15409
  {
15435
15410
  className: Et.TextEditorContainer,
15436
15411
  showFloatBtns: t,
@@ -15439,10 +15414,10 @@ class gs extends k.Component {
15439
15414
  editors: this.state.editors,
15440
15415
  activeTextId: this.state.activeTextId
15441
15416
  }
15442
- ) || null), /* @__PURE__ */ k.createElement(bm, { className: Et.CursorBox, manager: this.props.mananger }), /* @__PURE__ */ k.createElement(Lm, { className: Et.MiniMapBox, active: this.state.activeMiniMapViewId, miniMapManager: this.props.mananger.control.miniMapManager }));
15417
+ ) || null), /* @__PURE__ */ k.createElement(bw, { className: Et.CursorBox, manager: this.props.mananger }), /* @__PURE__ */ k.createElement(Lw, { className: Et.MiniMapBox, active: this.state.activeMiniMapViewId, miniMapManager: this.props.mananger.control.miniMapManager }));
15443
15418
  }
15444
15419
  }
15445
- class zm extends fn {
15420
+ class zw extends fn {
15446
15421
  constructor(t, e) {
15447
15422
  super(t, e);
15448
15423
  y(this, "width", 1e3);
@@ -15492,7 +15467,7 @@ class zm extends fn {
15492
15467
  } }), e), this.control.room && this.bindDisplayerEvent(this.eventTragetElement), this;
15493
15468
  }
15494
15469
  }
15495
- class Pm extends ww {
15470
+ class Pw extends mm {
15496
15471
  constructor(t, e, s) {
15497
15472
  super(t, e, s);
15498
15473
  y(this, "dpr", ae());
@@ -15575,7 +15550,7 @@ class Ht extends Ve {
15575
15550
  const e = t.divElement;
15576
15551
  if (!e || !t.focusScenePath || !(t.focusScenePath || t.scenePath))
15577
15552
  return;
15578
- const o = new zm(this.control, bt.InternalMsgEmitter), n = t.size.width || o.width, r = t.size.height || o.height, l = {
15553
+ const o = new zw(this.control, bt.InternalMsgEmitter), n = t.size.width || o.width, r = t.size.height || o.height, l = {
15579
15554
  dpr: o.dpr,
15580
15555
  originalPoint: [n / 2, r / 2],
15581
15556
  offscreenCanvasOpt: {
@@ -15656,7 +15631,7 @@ class Ht extends Ve {
15656
15631
  }, 0);
15657
15632
  });
15658
15633
  }
15659
- const r = new Pm(e, this.control, bt.InternalMsgEmitter), c = s.size.width || r.width, l = s.size.height || r.height, u = {
15634
+ const r = new Pw(e, this.control, bt.InternalMsgEmitter), c = s.size.width || r.width, l = s.size.height || r.height, u = {
15660
15635
  dpr: r.dpr,
15661
15636
  originalPoint: [c / 2, l / 2],
15662
15637
  offscreenCanvasOpt: {
@@ -15950,41 +15925,41 @@ const Y = class Y extends go {
15950
15925
  maxScreenshotWidth: 10 * 1024,
15951
15926
  maxScreenshotHeight: 10 * 1024,
15952
15927
  getBoundingRectAsync: async function(p) {
15953
- var m;
15928
+ var w;
15954
15929
  Y.logger.info("[ApplianceMultiPlugin] getBoundingRectAsync");
15955
- const M = (t.mainView || s).getBoundingRect(p), v = await ((m = Y.currentManager) == null ? void 0 : m.getBoundingRect(p));
15930
+ const M = (t.mainView || s).getBoundingRect(p), v = await ((w = Y.currentManager) == null ? void 0 : w.getBoundingRect(p));
15956
15931
  return !M.width || !M.height ? v : ds(M, v);
15957
15932
  },
15958
- screenshotToCanvasAsync: async function(p, M, v, m, S, T) {
15933
+ screenshotToCanvasAsync: async function(p, M, v, w, S, T) {
15959
15934
  var A;
15960
15935
  Y.logger.info("[ApplianceMultiPlugin] screenshotToCanvasAsync");
15961
- let N = v, w = m, C = S.scale;
15962
- N > this.maxScreenshotWidth && (C = this.maxScreenshotWidth / N * C, N = this.maxScreenshotWidth), w > this.maxScreenshotHeight && (C = Math.min(this.maxScreenshotHeight / w * C, C), w = this.maxScreenshotHeight), S.scale = C;
15936
+ let N = v, m = w, C = S.scale;
15937
+ N > this.maxScreenshotWidth && (C = this.maxScreenshotWidth / N * C, N = this.maxScreenshotWidth), m > this.maxScreenshotHeight && (C = Math.min(this.maxScreenshotHeight / m * C, C), m = this.maxScreenshotHeight), S.scale = C;
15963
15938
  const L = document.createElement("canvas"), D = L.getContext("2d");
15964
- L.width = N * (T || 1), L.height = w * (T || 1), D && ((t.mainView || s).screenshotToCanvas(D, M, N, w, S, T), p.drawImage(L, Math.floor((v - N) / 2), Math.floor((m - w) / 2), N * (T || 1), w * (T || 1), 0, 0, N, w), L.remove()), Y.currentManager && await ((A = Y.currentManager) == null ? void 0 : A.screenshotToCanvas(p, M, N, w, S, Math.floor((v - N) / 2), Math.floor((m - w) / 2)));
15939
+ L.width = N * (T || 1), L.height = m * (T || 1), D && ((t.mainView || s).screenshotToCanvas(D, M, N, m, S, T), p.drawImage(L, Math.floor((v - N) / 2), Math.floor((w - m) / 2), N * (T || 1), m * (T || 1), 0, 0, N, m), L.remove()), Y.currentManager && await ((A = Y.currentManager) == null ? void 0 : A.screenshotToCanvas(p, M, N, m, S, Math.floor((v - N) / 2), Math.floor((w - m) / 2)));
15965
15940
  },
15966
- scenePreviewAsync: async function(p, M, v, m, S) {
15967
- Y.logger.info("[ApplianceMultiPlugin] scenePreviewAsync"), (t.mainView || s).scenePreview(p, M, v, m, S);
15941
+ scenePreviewAsync: async function(p, M, v, w, S) {
15942
+ Y.logger.info("[ApplianceMultiPlugin] scenePreviewAsync"), (t.mainView || s).scenePreview(p, M, v, w, S);
15968
15943
  const T = document.createElement("img");
15969
15944
  T.className = "appliance-plugin-fill-scene-snapshot-img", M.append(T), getComputedStyle(M).position || (M.style.position = "relative"), Y.currentManager && await Y.currentManager.scenePreview(p, T);
15970
15945
  },
15971
- fillSceneSnapshotAsync: async function(p, M, v, m, S) {
15972
- Y.logger.info("[ApplianceMultiPlugin] fillSceneSnapshotAsync"), M.innerHTML = "", (t.mainView || s).fillSceneSnapshot(p, M, v, m, S);
15973
- const T = v || t.mainView.size.width, N = m || t.mainView.size.height;
15974
- let w = await this.getBoundingRectAsync(p);
15975
- w || (w = {
15946
+ fillSceneSnapshotAsync: async function(p, M, v, w, S) {
15947
+ Y.logger.info("[ApplianceMultiPlugin] fillSceneSnapshotAsync"), M.innerHTML = "", (t.mainView || s).fillSceneSnapshot(p, M, v, w, S);
15948
+ const T = v || t.mainView.size.width, N = w || t.mainView.size.height;
15949
+ let m = await this.getBoundingRectAsync(p);
15950
+ m || (m = {
15976
15951
  originX: 0,
15977
15952
  originY: 0,
15978
15953
  width: T,
15979
15954
  height: N
15980
15955
  });
15981
- let C = Math.max(w == null ? void 0 : w.width, T), L = Math.max(w == null ? void 0 : w.height, N), D = 1;
15956
+ let C = Math.max(m == null ? void 0 : m.width, T), L = Math.max(m == null ? void 0 : m.height, N), D = 1;
15982
15957
  const A = C > T && Math.min(T / C, D) || D, E = L > N && Math.min(N / L, D) || D;
15983
15958
  A <= E ? (C = A < 1 && T || C, L = Math.floor(L * A) + 1, D = A) : A > E && (L = E < 1 && N || L, C = Math.floor(C * E) + 1, D = E);
15984
15959
  const O = {
15985
15960
  scale: D,
15986
- centerX: w.originX + w.width / 2,
15987
- centerY: w.originY + w.height / 2
15961
+ centerX: m.originX + m.width / 2,
15962
+ centerY: m.originY + m.height / 2
15988
15963
  }, z = document.createElement("canvas"), j = z.getContext("2d");
15989
15964
  z.width = C, z.height = L, j && await this.screenshotToCanvasAsync(j, p, C, L, O, devicePixelRatio);
15990
15965
  const tt = document.createElement("img");
@@ -16196,7 +16171,7 @@ y(Y, "kind", "appliance-multi-plugin"), y(Y, "currentManager"), y(Y, "logger", {
16196
16171
  Y.logger.info("[ApplianceMultiPlugin] refresh ApplianceMultiManager object"), n.setWindowManager(t), Y.currentManager = n, t.room && t.room.logger.info(`[ApplianceMultiPlugin] use ${ns}`);
16197
16172
  });
16198
16173
  let uo = Y;
16199
- class Dm extends fn {
16174
+ class Dw extends fn {
16200
16175
  constructor(t, e) {
16201
16176
  super(t, e);
16202
16177
  y(this, "width", 1e3);
@@ -16247,7 +16222,7 @@ class ne extends Ve {
16247
16222
  bindMainView() {
16248
16223
  if (!this.control.divMainView)
16249
16224
  return;
16250
- const t = new Dm(this.control, bt.InternalMsgEmitter);
16225
+ const t = new Dw(this.control, bt.InternalMsgEmitter);
16251
16226
  this.focuedViewId = Mt;
16252
16227
  const { width: e, height: s, dpr: o } = t, n = {
16253
16228
  dpr: o,
@@ -16471,22 +16446,22 @@ const R = class R extends go {
16471
16446
  const p = t.getBoundingRect(g), M = await ((v = R.currentManager) == null ? void 0 : v.getBoundingRect(g));
16472
16447
  return !p.width || !p.height ? M : ds(p, M);
16473
16448
  },
16474
- screenshotToCanvasAsync: async function(g, p, M, v, m, S) {
16449
+ screenshotToCanvasAsync: async function(g, p, M, v, w, S) {
16475
16450
  var D;
16476
16451
  R.logger.info("[ApplianceSinglePlugin] screenshotToCanvasAsync");
16477
- let T = M, N = v, w = m.scale;
16478
- T > this.maxScreenshotWidth && (w = this.maxScreenshotWidth / T * w, T = this.maxScreenshotWidth), N > this.maxScreenshotHeight && (w = Math.min(this.maxScreenshotHeight / N * w, w), N = this.maxScreenshotHeight), m.scale = w;
16452
+ let T = M, N = v, m = w.scale;
16453
+ T > this.maxScreenshotWidth && (m = this.maxScreenshotWidth / T * m, T = this.maxScreenshotWidth), N > this.maxScreenshotHeight && (m = Math.min(this.maxScreenshotHeight / N * m, m), N = this.maxScreenshotHeight), w.scale = m;
16479
16454
  const C = document.createElement("canvas"), L = C.getContext("2d");
16480
- C.width = T * (S || 1), C.height = N * (S || 1), L && (t.screenshotToCanvas(L, p, T, N, m, S), g.drawImage(C, Math.floor((M - T) / 2), Math.floor((v - N) / 2), T * (S || 1), N * (S || 1), 0, 0, T, N), C.remove()), R.currentManager && await ((D = R.currentManager) == null ? void 0 : D.screenshotToCanvas(g, p, T, N, m, Math.floor((M - T) / 2), Math.floor((v - N) / 2)));
16455
+ C.width = T * (S || 1), C.height = N * (S || 1), L && (t.screenshotToCanvas(L, p, T, N, w, S), g.drawImage(C, Math.floor((M - T) / 2), Math.floor((v - N) / 2), T * (S || 1), N * (S || 1), 0, 0, T, N), C.remove()), R.currentManager && await ((D = R.currentManager) == null ? void 0 : D.screenshotToCanvas(g, p, T, N, w, Math.floor((M - T) / 2), Math.floor((v - N) / 2)));
16481
16456
  },
16482
- scenePreviewAsync: async function(g, p, M, v, m) {
16483
- R.logger.info("[ApplianceSinglePlugin] scenePreviewAsync"), t.scenePreview(g, p, M, v, m);
16457
+ scenePreviewAsync: async function(g, p, M, v, w) {
16458
+ R.logger.info("[ApplianceSinglePlugin] scenePreviewAsync"), t.scenePreview(g, p, M, v, w);
16484
16459
  const S = document.createElement("img");
16485
16460
  S.className = "appliance-plugin-fill-scene-snapshot-img", p.append(S), getComputedStyle(p).position || (p.style.position = "relative"), R.currentManager && await R.currentManager.scenePreview(g, S);
16486
16461
  },
16487
- fillSceneSnapshotAsync: async function(g, p, M, v, m) {
16462
+ fillSceneSnapshotAsync: async function(g, p, M, v, w) {
16488
16463
  var tt, et;
16489
- R.logger.info("[ApplianceSinglePlugin] fillSceneSnapshotAsync"), p.innerHTML = "", t.fillSceneSnapshot(g, p, M, v, m);
16464
+ R.logger.info("[ApplianceSinglePlugin] fillSceneSnapshotAsync"), p.innerHTML = "", t.fillSceneSnapshot(g, p, M, v, w);
16490
16465
  const S = M || ((tt = t.state.cameraState) == null ? void 0 : tt.width) || 0, T = v || ((et = t.state.cameraState) == null ? void 0 : et.height) || 0;
16491
16466
  let N = await this.getBoundingRectAsync(g);
16492
16467
  N || (N = {
@@ -16495,15 +16470,15 @@ const R = class R extends go {
16495
16470
  width: S,
16496
16471
  height: T
16497
16472
  });
16498
- let w = Math.max(N == null ? void 0 : N.width, S), C = Math.max(N == null ? void 0 : N.height, T), L = 1;
16499
- const D = w > S && Math.min(S / w, L) || L, A = C > T && Math.min(T / C, L) || L;
16500
- D <= A ? (w = D < 1 && S || w, C = Math.floor(C * D) + 1, L = D) : D > A && (C = A < 1 && T || C, w = Math.floor(w * A) + 1, L = A);
16473
+ let m = Math.max(N == null ? void 0 : N.width, S), C = Math.max(N == null ? void 0 : N.height, T), L = 1;
16474
+ const D = m > S && Math.min(S / m, L) || L, A = C > T && Math.min(T / C, L) || L;
16475
+ D <= A ? (m = D < 1 && S || m, C = Math.floor(C * D) + 1, L = D) : D > A && (C = A < 1 && T || C, m = Math.floor(m * A) + 1, L = A);
16501
16476
  const E = {
16502
16477
  scale: L,
16503
16478
  centerX: N.originX + N.width / 2,
16504
16479
  centerY: N.originY + N.height / 2
16505
16480
  }, O = document.createElement("canvas"), z = O.getContext("2d");
16506
- O.width = w, O.height = C, z && await this.screenshotToCanvasAsync(z, g, w, C, E, devicePixelRatio);
16481
+ O.width = m, O.height = C, z && await this.screenshotToCanvasAsync(z, g, m, C, E, devicePixelRatio);
16507
16482
  const j = document.createElement("img");
16508
16483
  j.className = "appliance-plugin-fill-scene-snapshot-img", j.src = O.toDataURL(), j.onload = () => {
16509
16484
  O.remove();
@@ -16740,7 +16715,7 @@ const Le = class Le extends k.Component {
16740
16715
  };
16741
16716
  y(Le, "emiter");
16742
16717
  let fo = Le;
16743
- class Zm extends gw {
16718
+ class Zw extends gm {
16744
16719
  constructor(t) {
16745
16720
  super();
16746
16721
  y(this, "kind", "autoDraw");
@@ -16906,7 +16881,7 @@ class Zm extends gw {
16906
16881
  export {
16907
16882
  uo as A,
16908
16883
  Nt as B,
16909
- Qm as C,
16884
+ Qw as C,
16910
16885
  Ot as D,
16911
16886
  P as E,
16912
16887
  ti as F,
@@ -16917,8 +16892,8 @@ export {
16917
16892
  Rt as K,
16918
16893
  ee as L,
16919
16894
  Mt as M,
16920
- Zm as N,
16921
- gw as P,
16895
+ Zw as N,
16896
+ gm as P,
16922
16897
  Vt as S,
16923
16898
  hs as T,
16924
16899
  gg as V,
@@ -16932,15 +16907,15 @@ export {
16932
16907
  B as h,
16933
16908
  RM as i,
16934
16909
  ze as j,
16935
- Gm as k,
16910
+ Gw as k,
16936
16911
  ei as l,
16937
16912
  ht as m,
16938
- we as n,
16913
+ me as n,
16939
16914
  Wt as o,
16940
16915
  Ve as p,
16941
16916
  xi as q,
16942
- Vm as r,
16943
- Hm as s,
16917
+ Vw as r,
16918
+ Hw as s,
16944
16919
  Ie as t,
16945
16920
  po as u,
16946
16921
  fo as v,