mind-elixir 5.11.1-beta.2 → 5.11.1-beta.4

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.
@@ -100,7 +100,7 @@ function oe(e, t, n, o) {
100
100
  function B() {
101
101
  return ((/* @__PURE__ */ new Date()).getTime().toString(16) + Math.random().toString(16).substring(2)).substring(2, 18);
102
102
  }
103
- const ft = function() {
103
+ const pt = function() {
104
104
  const e = B();
105
105
  return {
106
106
  topic: this.newTopicName,
@@ -148,7 +148,7 @@ const L = (e, t) => {
148
148
  }, De = (e, t) => {
149
149
  const n = e.x - t.x, o = e.y - t.y;
150
150
  return Math.sqrt(n * n + o * o);
151
- }, ut = function(e, t) {
151
+ }, gt = function(e, t) {
152
152
  if (!t)
153
153
  return ie(e), e;
154
154
  let n = e.querySelector(".insert-preview");
@@ -165,11 +165,11 @@ const L = (e, t) => {
165
165
  if (!(e && e.tagName === "ME-TPC" && e !== n && !o && e.nodeObj.parent)) return !1;
166
166
  }
167
167
  return !0;
168
- }, pt = function(e) {
168
+ }, mt = function(e) {
169
169
  const t = document.createElement("div");
170
170
  return t.className = "mind-elixir-ghost", e.container.appendChild(t), t;
171
171
  };
172
- class gt {
172
+ class yt {
173
173
  mind;
174
174
  isMoving = !1;
175
175
  interval = null;
@@ -186,19 +186,19 @@ class gt {
186
186
  this.isMoving = !1, this.interval && (clearInterval(this.interval), this.interval = null);
187
187
  }
188
188
  }
189
- function mt(e) {
189
+ function bt(e) {
190
190
  return {
191
191
  isDragging: !1,
192
192
  insertType: null,
193
193
  meet: null,
194
- ghost: pt(e),
195
- edgeMoveController: new gt(e),
194
+ ghost: mt(e),
195
+ edgeMoveController: new yt(e),
196
196
  startX: 0,
197
197
  startY: 0,
198
198
  pointerId: null
199
199
  };
200
200
  }
201
- const yt = 5;
201
+ const vt = 5;
202
202
  function Me(e, t, n, o = !1) {
203
203
  if (e.spacePressed) return !1;
204
204
  const s = n.target;
@@ -222,11 +222,11 @@ function Je(e, t) {
222
222
  s.parentElement.parentElement.style.opacity = "0.5";
223
223
  e.panHelper.clear();
224
224
  }
225
- function bt(e, t, n) {
225
+ function wt(e, t, n) {
226
226
  const { dragged: o } = e;
227
227
  if (!o || t.pointerId !== n.pointerId) return;
228
228
  const s = n.clientX - t.startX, i = n.clientY - t.startY, l = Math.sqrt(s * s + i * i);
229
- if (!t.isDragging && l > yt && Je(e, t), !t.isDragging) return;
229
+ if (!t.isDragging && l > vt && Je(e, t), !t.isDragging) return;
230
230
  const c = e.container.getBoundingClientRect();
231
231
  Ue(t.ghost, n.clientX - c.x, n.clientY - c.y), n.clientX < c.x + 50 ? t.edgeMoveController.move(1, 0) : n.clientX > c.x + c.width - 50 ? t.edgeMoveController.move(-1, 0) : n.clientY < c.y + 50 ? t.edgeMoveController.move(0, 1) : n.clientY > c.y + c.height - 50 ? t.edgeMoveController.move(0, -1) : t.edgeMoveController.stop(), ie(t.meet);
232
232
  const r = 12 * e.scaleVal, a = document.elementFromPoint(n.clientX, n.clientY - r);
@@ -243,9 +243,9 @@ function bt(e, t, n) {
243
243
  } else
244
244
  t.insertType = null, t.meet = null;
245
245
  }
246
- t.meet && ut(t.meet, t.insertType);
246
+ t.meet && gt(t.meet, t.insertType);
247
247
  }
248
- function vt(e, t, n) {
248
+ function xt(e, t, n) {
249
249
  const { dragged: o } = e;
250
250
  if (!(!o || t.pointerId !== n.pointerId)) {
251
251
  t.edgeMoveController.stop();
@@ -263,14 +263,14 @@ function Ae(e, t) {
263
263
  t.meet && ie(t.meet), t.ghost.style.display = "none", t.ghost.innerHTML = "", e.dragged = null, t.isDragging = !1, t.insertType = null, t.meet = null, t.pointerId = null;
264
264
  }
265
265
  }
266
- function wt(e) {
266
+ function Et(e) {
267
267
  return () => {
268
268
  };
269
269
  }
270
270
  const O = {
271
271
  LHS: "lhs",
272
272
  RHS: "rhs"
273
- }, xt = function() {
273
+ }, Ct = function() {
274
274
  this.nodes.innerHTML = "";
275
275
  const e = this.createTopic(this.nodeData);
276
276
  be.call(this, e, this.nodeData), e.draggable = !1;
@@ -283,8 +283,8 @@ const O = {
283
283
  i.direction === 0 ? o += 1 : i.direction === 1 ? s += 1 : o <= s ? (i.direction = 0, o += 1) : (i.direction = 1, s += 1);
284
284
  });
285
285
  }
286
- Et(this, n, t);
287
- }, Et = function(e, t, n) {
286
+ St(this, n, t);
287
+ }, St = function(e, t, n) {
288
288
  const o = document.createElement("me-main");
289
289
  o.className = O.LHS;
290
290
  const s = document.createElement("me-main");
@@ -294,7 +294,7 @@ const O = {
294
294
  e.direction === 2 ? l.direction === 0 ? o.appendChild(c) : s.appendChild(c) : e.direction === 0 ? o.appendChild(c) : s.appendChild(c);
295
295
  }
296
296
  e.nodes.appendChild(o), e.nodes.appendChild(n), e.nodes.appendChild(s), e.nodes.appendChild(e.lines), e.nodes.appendChild(e.labelContainer);
297
- }, Ct = function(e, t) {
297
+ }, Nt = function(e, t) {
298
298
  const n = document.createElement("me-children");
299
299
  for (let o = 0; o < t.length; o++) {
300
300
  const s = t[o], { grp: i } = e.createWrapper(s);
@@ -341,23 +341,23 @@ const O = {
341
341
  typeof o == "string" ? s.textContent = o : (s.textContent = o.text, o.className && (s.className = o.className), o.style && Object.assign(s.style, o.style)), n.appendChild(s);
342
342
  }), e.appendChild(n), e.tags = n;
343
343
  } else e.tags && (e.tags = void 0);
344
- }, St = function(e, t) {
344
+ }, Tt = function(e, t) {
345
345
  const n = document.createElement("me-wrapper"), { p: o, tpc: s } = this.createParent(e);
346
346
  if (n.appendChild(o), !t && e.children && e.children.length > 0) {
347
347
  const i = ve(e.expanded);
348
348
  if (o.appendChild(i), e.expanded !== !1) {
349
- const l = Ct(this, e.children);
349
+ const l = Nt(this, e.children);
350
350
  n.appendChild(l);
351
351
  }
352
352
  }
353
353
  return { grp: n, top: o, tpc: s };
354
- }, Nt = function(e) {
354
+ }, kt = function(e) {
355
355
  const t = document.createElement("me-parent"), n = this.createTopic(e);
356
356
  return be.call(this, n, e), t.appendChild(n), { p: t, tpc: n };
357
- }, Tt = function(e) {
357
+ }, _t = function(e) {
358
358
  const t = document.createElement("me-children");
359
359
  return t.append(...e), t;
360
- }, kt = function(e) {
360
+ }, Dt = function(e) {
361
361
  const t = document.createElement("me-tpc");
362
362
  return t.nodeObj = e, t.dataset.nodeid = "me" + e.id, t;
363
363
  };
@@ -367,7 +367,7 @@ function Qe(e) {
367
367
  const n = window.getSelection();
368
368
  n && (n.removeAllRanges(), n.addRange(t));
369
369
  }
370
- const _t = function(e) {
370
+ const Lt = function(e) {
371
371
  if (!e) return;
372
372
  const t = document.createElement("div"), n = e.nodeObj, o = n.topic, { offsetLeft: s, offsetTop: i } = L(this.nodes, e);
373
373
  this.nodes.appendChild(t), t.id = "input-box", t.textContent = o, t.contentEditable = "plaintext-only", t.spellcheck = !1;
@@ -409,13 +409,13 @@ const _t = function(e) {
409
409
  const t = e.parent?.children, n = t?.indexOf(e) ?? 0;
410
410
  return { siblings: t, index: n };
411
411
  };
412
- function Dt(e) {
412
+ function Mt(e) {
413
413
  const { siblings: t, index: n } = K(e);
414
414
  if (t === void 0) return;
415
415
  const o = t[n];
416
416
  n === 0 ? (t[n] = t[t.length - 1], t[t.length - 1] = o) : (t[n] = t[n - 1], t[n - 1] = o);
417
417
  }
418
- function Lt(e) {
418
+ function At(e) {
419
419
  const { siblings: t, index: n } = K(e);
420
420
  if (t === void 0) return;
421
421
  const o = t[n];
@@ -425,15 +425,15 @@ function et(e) {
425
425
  const { siblings: t, index: n } = K(e);
426
426
  return t === void 0 ? 0 : (t.splice(n, 1), t.length);
427
427
  }
428
- function Mt(e, t, n) {
428
+ function Pt(e, t, n) {
429
429
  const { siblings: o, index: s } = K(n);
430
430
  o !== void 0 && (t === "before" ? o.splice(s, 0, e) : o.splice(s + 1, 0, e));
431
431
  }
432
- function At(e, t) {
432
+ function Ot(e, t) {
433
433
  const { siblings: n, index: o } = K(e);
434
434
  n !== void 0 && (n[o] = t, t.children = [e]);
435
435
  }
436
- function Pt(e, t, n) {
436
+ function Ht(e, t, n) {
437
437
  if (et(t), n.parent?.parent || (t.direction = n.direction), e === "in")
438
438
  n.children ? n.children.push(t) : n.children = [t];
439
439
  else {
@@ -443,7 +443,7 @@ function Pt(e, t, n) {
443
443
  e === "before" ? o.splice(s, 0, t) : o.splice(s + 1, 0, t);
444
444
  }
445
445
  }
446
- const Ot = function({ map: e, direction: t }, n) {
446
+ const $t = function({ map: e, direction: t }, n) {
447
447
  if (t === 0)
448
448
  return 0;
449
449
  if (t === 1)
@@ -462,8 +462,8 @@ const Ot = function({ map: e, direction: t }, n) {
462
462
  s.appendChild(ve(!0)), s.insertAdjacentElement("afterend", i);
463
463
  }
464
464
  e.linkDiv(n.offsetParent);
465
- } else s.tagName === "ME-ROOT" && (Ot(e, o.nodeObj) === 0 ? e.container.querySelector(".lhs")?.appendChild(n) : e.container.querySelector(".rhs")?.appendChild(n), e.linkDiv());
466
- }, Ht = function(e, t) {
465
+ } else s.tagName === "ME-ROOT" && ($t(e, o.nodeObj) === 0 ? e.container.querySelector(".lhs")?.appendChild(n) : e.container.querySelector(".rhs")?.appendChild(n), e.linkDiv());
466
+ }, jt = function(e, t) {
467
467
  const n = e.parentNode;
468
468
  if (t === 0) {
469
469
  const o = n.parentNode.parentNode;
@@ -476,7 +476,7 @@ const Ot = function({ map: e, direction: t }, n) {
476
476
  }, G = function(e) {
477
477
  const n = e.parentElement.parentElement.lastElementChild;
478
478
  n?.tagName === "svg" && n?.remove();
479
- }, $t = function(e, t) {
479
+ }, It = function(e, t) {
480
480
  const n = e.nodeObj, o = ge(n);
481
481
  o.style && t.style && (t.style = Object.assign(o.style, t.style));
482
482
  const s = Object.assign(n, t);
@@ -493,7 +493,7 @@ const Ot = function({ map: e, direction: t }, n) {
493
493
  o.children ? o.children.push(s) : o.children = [s], R(e.nodeData);
494
494
  const { grp: i, top: l } = e.createWrapper(s);
495
495
  return tt(e, t, i), { newTop: l, newNodeObj: s };
496
- }, jt = function(e, t, n) {
496
+ }, Rt = function(e, t, n) {
497
497
  const o = t || this.currentNode;
498
498
  if (!o) return;
499
499
  const s = o.nodeObj;
@@ -514,14 +514,14 @@ const Ot = function({ map: e, direction: t }, n) {
514
514
  const a = o.closest("me-main").className === O.LHS ? 0 : 1;
515
515
  i.direction = a;
516
516
  }
517
- Mt(i, e, s), R(this.nodeData);
517
+ Pt(i, e, s), R(this.nodeData);
518
518
  const l = o.parentElement, { grp: c, top: r } = this.createWrapper(i);
519
519
  l.parentElement.insertAdjacentElement(nt[e], c), this.linkDiv(c.offsetParent), n || this.editTopic(r.firstChild), this.bus.fire("operation", {
520
520
  name: "insertSibling",
521
521
  type: e,
522
522
  obj: i
523
523
  }), this.selectNode(r.firstChild, !0);
524
- }, It = function(e, t) {
524
+ }, Bt = function(e, t) {
525
525
  const n = e || this.currentNode;
526
526
  if (!n) return;
527
527
  G(n);
@@ -529,7 +529,7 @@ const Ot = function({ map: e, direction: t }, n) {
529
529
  if (!o.parent)
530
530
  return;
531
531
  const s = t || this.generateNewObj();
532
- At(o, s), R(this.nodeData);
532
+ Ot(o, s), R(this.nodeData);
533
533
  const i = n.parentElement.parentElement, { grp: l, top: c } = this.createWrapper(s, !0);
534
534
  c.appendChild(ve(!0)), i.insertAdjacentElement("afterend", l);
535
535
  const r = this.createChildren([i]);
@@ -537,7 +537,7 @@ const Ot = function({ map: e, direction: t }, n) {
537
537
  name: "insertParent",
538
538
  obj: s
539
539
  });
540
- }, Rt = function(e, t) {
540
+ }, Wt = function(e, t) {
541
541
  const n = e || this.currentNode;
542
542
  if (!n) return;
543
543
  const o = we(this, n, t);
@@ -547,7 +547,7 @@ const Ot = function({ map: e, direction: t }, n) {
547
547
  name: "addChild",
548
548
  obj: i
549
549
  }), t || this.editTopic(s.firstChild), this.selectNode(s.firstChild, !0);
550
- }, Bt = function(e, t) {
550
+ }, Yt = function(e, t) {
551
551
  const n = ge(e.nodeObj);
552
552
  pe(n);
553
553
  const o = we(this, t, n);
@@ -557,7 +557,7 @@ const Ot = function({ map: e, direction: t }, n) {
557
557
  name: "copyNode",
558
558
  obj: s
559
559
  });
560
- }, Wt = function(e, t) {
560
+ }, Xt = function(e, t) {
561
561
  const n = [];
562
562
  for (let o = 0; o < e.length; o++) {
563
563
  const s = e[o], i = ge(s.nodeObj);
@@ -571,31 +571,31 @@ const Ot = function({ map: e, direction: t }, n) {
571
571
  name: "copyNodes",
572
572
  objs: n
573
573
  });
574
- }, Yt = function(e) {
574
+ }, Ft = function(e) {
575
575
  const t = e || this.currentNode;
576
576
  if (!t) return;
577
577
  const n = t.nodeObj;
578
- Dt(n);
578
+ Mt(n);
579
579
  const o = t.parentNode.parentNode;
580
580
  o.parentNode.insertBefore(o, o.previousSibling), this.linkDiv(), this.bus.fire("operation", {
581
581
  name: "moveUpNode",
582
582
  obj: n
583
583
  });
584
- }, Xt = function(e) {
584
+ }, Kt = function(e) {
585
585
  const t = e || this.currentNode;
586
586
  if (!t) return;
587
587
  const n = t.nodeObj;
588
- Lt(n);
588
+ At(n);
589
589
  const o = t.parentNode.parentNode;
590
590
  o.nextSibling ? o.nextSibling.insertAdjacentElement("afterend", o) : o.parentNode.prepend(o), this.linkDiv(), this.bus.fire("operation", {
591
591
  name: "moveDownNode",
592
592
  obj: n
593
593
  });
594
- }, Ft = function(e) {
594
+ }, Vt = function(e) {
595
595
  if (e = me(e), e.length === 0) return;
596
596
  for (const n of e) {
597
597
  const o = n.nodeObj, s = et(o);
598
- Ht(n, s);
598
+ jt(n, s);
599
599
  }
600
600
  const t = e[e.length - 1];
601
601
  this.selectNode(this.findEle(t.nodeObj.parent.id)), this.linkDiv(), this.bus.fire("operation", {
@@ -609,7 +609,7 @@ const Ot = function({ map: e, direction: t }, n) {
609
609
  const i = [];
610
610
  for (const c of e) {
611
611
  const r = c.nodeObj;
612
- if (Pt(t, r, s), R(o.nodeData), t === "in") {
612
+ if (Ht(t, r, s), R(o.nodeData), t === "in") {
613
613
  const a = c.parentElement;
614
614
  tt(o, n, a.parentElement);
615
615
  } else {
@@ -627,36 +627,36 @@ const Ot = function({ map: e, direction: t }, n) {
627
627
  objs: e.map((c) => c.nodeObj),
628
628
  toObj: s
629
629
  });
630
- }, Kt = function(e, t) {
630
+ }, zt = function(e, t) {
631
631
  xe(e, "in", t, this);
632
- }, Vt = function(e, t) {
632
+ }, Gt = function(e, t) {
633
633
  xe(e, "before", t, this);
634
- }, zt = function(e, t) {
634
+ }, qt = function(e, t) {
635
635
  xe(e, "after", t, this);
636
- }, Gt = function(e) {
636
+ }, Ut = function(e) {
637
637
  const t = e || this.currentNode;
638
638
  t && (t.nodeObj.dangerouslySetInnerHTML || this.editTopic(t));
639
- }, qt = function(e, t) {
639
+ }, Jt = function(e, t) {
640
640
  e.text.textContent = t, e.nodeObj.topic = t, this.linkDiv();
641
641
  }, ot = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
642
642
  __proto__: null,
643
- addChild: Rt,
644
- beginEdit: Gt,
645
- copyNode: Bt,
646
- copyNodes: Wt,
647
- insertParent: It,
648
- insertSibling: jt,
649
- moveDownNode: Xt,
650
- moveNodeAfter: zt,
651
- moveNodeBefore: Vt,
652
- moveNodeIn: Kt,
653
- moveUpNode: Yt,
654
- removeNodes: Ft,
655
- reshapeNode: $t,
643
+ addChild: Wt,
644
+ beginEdit: Ut,
645
+ copyNode: Yt,
646
+ copyNodes: Xt,
647
+ insertParent: Bt,
648
+ insertSibling: Rt,
649
+ moveDownNode: Kt,
650
+ moveNodeAfter: qt,
651
+ moveNodeBefore: Gt,
652
+ moveNodeIn: zt,
653
+ moveUpNode: Ft,
654
+ removeNodes: Vt,
655
+ reshapeNode: It,
656
656
  rmSubline: G,
657
- setNodeTopic: qt
657
+ setNodeTopic: Jt
658
658
  }, Symbol.toStringTag, { value: "Module" }));
659
- function Ut(e) {
659
+ function Zt(e) {
660
660
  return {
661
661
  nodeData: e.isFocusMode ? e.nodeDataBackup : e.nodeData,
662
662
  arrows: e.arrows,
@@ -665,44 +665,44 @@ function Ut(e) {
665
665
  theme: e.theme
666
666
  };
667
667
  }
668
- const Jt = function(e) {
668
+ const Qt = function(e) {
669
669
  const t = this.container, n = e.getBoundingClientRect(), o = t.getBoundingClientRect();
670
670
  if (n.top > o.bottom - 50 || n.bottom < o.top + 50 || n.left > o.right - 50 || n.right < o.left + 50) {
671
671
  const i = n.left + n.width / 2, l = n.top + n.height / 2, c = o.left + o.width / 2, r = o.top + o.height / 2, a = i - c, d = l - r;
672
672
  this.move(-a, -d, !0);
673
673
  }
674
- }, Zt = function(e, t, n) {
674
+ }, en = function(e, t, n) {
675
675
  this.clearSelection(), this.scrollIntoView(e), this.selection?.select(e), t && this.bus.fire("selectNewNode", e.nodeObj);
676
- }, Qt = function(e) {
676
+ }, tn = function(e) {
677
677
  this.selection?.select(e);
678
- }, en = function(e) {
678
+ }, nn = function(e) {
679
679
  this.selection?.deselect(e);
680
- }, tn = function() {
680
+ }, on = function() {
681
681
  this.unselectNodes(this.currentNodes), this.unselectSummary(), this.unselectArrow();
682
682
  }, Ee = function(e) {
683
683
  return JSON.stringify(e, (t, n) => {
684
684
  if (!(t === "parent" && typeof n != "string"))
685
685
  return n;
686
686
  });
687
- }, nn = function() {
688
- const e = Ut(this);
687
+ }, sn = function() {
688
+ const e = Zt(this);
689
689
  return Ee(e);
690
- }, on = function() {
690
+ }, rn = function() {
691
691
  return JSON.parse(this.getDataString());
692
- }, sn = function() {
692
+ }, ln = function() {
693
693
  this.editable = !0;
694
- }, rn = function() {
694
+ }, cn = function() {
695
695
  this.editable = !1;
696
- }, ln = function(e, t = { x: 0, y: 0 }) {
696
+ }, an = function(e, t = { x: 0, y: 0 }) {
697
697
  if (e < this.scaleMin && e < this.scaleVal || e > this.scaleMax && e > this.scaleVal) return;
698
698
  const n = this.container.getBoundingClientRect(), o = t.x ? t.x - n.left - n.width / 2 : 0, s = t.y ? t.y - n.top - n.height / 2 : 0, { dx: i, dy: l } = Ce(this), c = this.map.style.transform, { x: r, y: a } = ye(c), d = r - i, h = a - l, u = this.scaleVal, b = (-o + d) * (1 - e / u), v = (-s + h) * (1 - e / u);
699
699
  this.map.style.transform = `translate3d(${r - b}px, ${a - v}px, 0) scale(${e})`, this.scaleVal = e, this.bus.fire("scale", e);
700
- }, cn = function() {
700
+ }, dn = function() {
701
701
  const e = this.nodes.offsetHeight / this.container.offsetHeight, t = this.nodes.offsetWidth / this.container.offsetWidth, n = 1 / Math.max(1, Math.max(e, t));
702
702
  this.scaleVal = n;
703
703
  const { dx: o, dy: s } = Ce(this, !0);
704
704
  this.map.style.transform = `translate3d(${o}px, ${s}px, 0) scale(${n})`, this.bus.fire("scale", n);
705
- }, an = function(e, t, n = !1) {
705
+ }, hn = function(e, t, n = !1) {
706
706
  const { map: o, scaleVal: s, bus: i, container: l, nodes: c } = this;
707
707
  if (n && o.style.transition === "transform 0.3s")
708
708
  return;
@@ -730,22 +730,22 @@ const Jt = function(e) {
730
730
  i = n.offsetWidth / 2 - a - d / 2, l = n.offsetHeight / 2 - r - h / 2, o.style.transformOrigin = `${a + d / 2}px 50%`;
731
731
  }
732
732
  return { dx: i, dy: l };
733
- }, dn = function() {
733
+ }, fn = function() {
734
734
  const { map: e, container: t } = this, { dx: n, dy: o } = Ce(this);
735
735
  t.scrollTop = 0, t.scrollLeft = 0, e.style.transform = `translate3d(${n}px, ${o}px, 0) scale(${this.scaleVal})`;
736
- }, hn = function(e) {
736
+ }, un = function(e) {
737
737
  e(this);
738
- }, fn = function(e) {
738
+ }, pn = function(e) {
739
739
  e.nodeObj.parent && (this.clearSelection(), this.tempDirection === null && (this.tempDirection = this.direction), this.isFocusMode || (this.nodeDataBackup = this.nodeData, this.isFocusMode = !0), this.nodeData = e.nodeObj, this.initRight(), this.toCenter());
740
- }, un = function() {
740
+ }, gn = function() {
741
741
  this.isFocusMode = !1, this.tempDirection !== null && (this.nodeData = this.nodeDataBackup, this.direction = this.tempDirection, this.tempDirection = null, this.refresh(), this.toCenter());
742
- }, pn = function() {
742
+ }, mn = function() {
743
743
  this.direction = 0, this.refresh(), this.toCenter(), this.bus.fire("changeDirection", this.direction);
744
- }, gn = function() {
744
+ }, yn = function() {
745
745
  this.direction = 1, this.refresh(), this.toCenter(), this.bus.fire("changeDirection", this.direction);
746
- }, mn = function() {
746
+ }, bn = function() {
747
747
  this.direction = 2, this.refresh(), this.toCenter(), this.bus.fire("changeDirection", this.direction);
748
- }, yn = function(e, t) {
748
+ }, vn = function(e, t) {
749
749
  const n = e.nodeObj;
750
750
  typeof t == "boolean" ? n.expanded = t : n.expanded !== !1 ? n.expanded = !1 : n.expanded = !0;
751
751
  const o = e.getBoundingClientRect(), s = {
@@ -765,7 +765,7 @@ const Jt = function(e) {
765
765
  y: c.top
766
766
  }, a = s.x - r.x, d = s.y - r.y;
767
767
  this.move(a, d), this.bus.fire("expandNode", n);
768
- }, bn = function(e, t) {
768
+ }, wn = function(e, t) {
769
769
  const n = e.nodeObj, o = e.getBoundingClientRect(), s = {
770
770
  x: o.left,
771
771
  y: o.top
@@ -776,50 +776,50 @@ const Jt = function(e) {
776
776
  y: i.top
777
777
  }, c = s.x - l.x, r = s.y - l.y;
778
778
  this.move(c, r);
779
- }, vn = function(e) {
779
+ }, xn = function(e) {
780
780
  this.clearSelection(), e && (e = JSON.parse(JSON.stringify(e)), this.nodeData = e.nodeData, this.arrows = e.arrows || [], this.summaries = e.summaries || [], e.theme && this.changeTheme(e.theme)), R(this.nodeData), this.layout(), this.linkDiv();
781
- }, wn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
781
+ }, En = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
782
782
  __proto__: null,
783
- cancelFocus: un,
784
- clearSelection: tn,
785
- disableEdit: rn,
786
- enableEdit: sn,
787
- expandNode: yn,
788
- expandNodeAll: bn,
789
- focusNode: fn,
790
- getData: on,
791
- getDataString: nn,
792
- initLeft: pn,
793
- initRight: gn,
794
- initSide: mn,
795
- install: hn,
796
- move: an,
797
- refresh: vn,
798
- scale: ln,
799
- scaleFit: cn,
800
- scrollIntoView: Jt,
801
- selectNode: Zt,
802
- selectNodes: Qt,
783
+ cancelFocus: gn,
784
+ clearSelection: on,
785
+ disableEdit: cn,
786
+ enableEdit: ln,
787
+ expandNode: vn,
788
+ expandNodeAll: wn,
789
+ focusNode: pn,
790
+ getData: rn,
791
+ getDataString: sn,
792
+ initLeft: mn,
793
+ initRight: yn,
794
+ initSide: bn,
795
+ install: un,
796
+ move: hn,
797
+ refresh: xn,
798
+ scale: an,
799
+ scaleFit: dn,
800
+ scrollIntoView: Qt,
801
+ selectNode: en,
802
+ selectNodes: tn,
803
803
  stringifyData: Ee,
804
- toCenter: dn,
805
- unselectNodes: en
806
- }, Symbol.toStringTag, { value: "Module" })), Pe = "MIND-ELIXIR-WAIT-COPY", xn = 40, En = 10, Cn = ({ deltaMode: e, deltaY: t, viewportHeight: n }) => e === WheelEvent.DOM_DELTA_LINE ? t * xn : e === WheelEvent.DOM_DELTA_PAGE ? t * n : t, Sn = ({ deltaMode: e, deltaY: t, scaleSensitivity: n, viewportHeight: o }) => {
807
- const i = -Cn({ deltaMode: e, deltaY: t, viewportHeight: o }) / En * n;
804
+ toCenter: fn,
805
+ unselectNodes: nn
806
+ }, Symbol.toStringTag, { value: "Module" })), Pe = "MIND-ELIXIR-WAIT-COPY", Cn = 40, Sn = 10, Nn = ({ deltaMode: e, deltaY: t, viewportHeight: n }) => e === WheelEvent.DOM_DELTA_LINE ? t * Cn : e === WheelEvent.DOM_DELTA_PAGE ? t * n : t, Tn = ({ deltaMode: e, deltaY: t, scaleSensitivity: n, viewportHeight: o }) => {
807
+ const i = -Nn({ deltaMode: e, deltaY: t, viewportHeight: o }) / Sn * n;
808
808
  return Math.max(-n, Math.min(n, i));
809
809
  }, st = (e, t, n) => {
810
810
  t !== 0 && e.scale(e.scaleVal + t, n);
811
- }, Nn = (e, t) => {
811
+ }, kn = (e, t) => {
812
812
  const n = e.map.querySelectorAll(`.${t}>me-wrapper>me-parent>me-tpc`);
813
813
  n.length !== 0 && e.selectNode(n[Math.ceil(n.length / 2) - 1]);
814
- }, Tn = (e) => {
814
+ }, _n = (e) => {
815
815
  e.selectNode(e.map.querySelector("me-root>me-tpc"));
816
- }, kn = function(e, t) {
816
+ }, Dn = function(e, t) {
817
817
  const n = t.parentElement.parentElement.parentElement.previousSibling;
818
818
  if (n) {
819
819
  const o = n.firstChild;
820
820
  e.selectNode(o);
821
821
  }
822
- }, _n = function(e, t) {
822
+ }, Ln = function(e, t) {
823
823
  const n = t.parentElement.nextSibling;
824
824
  if (n && n.firstChild) {
825
825
  const o = n.firstChild.firstChild.firstChild;
@@ -829,7 +829,7 @@ const Jt = function(e) {
829
829
  const n = e.currentNode || e.currentNodes?.[0];
830
830
  if (!n) return;
831
831
  const o = n.nodeObj, s = n.offsetParent.offsetParent.parentElement;
832
- o.parent ? s.className === t ? _n(e, n) : o.parent?.parent ? kn(e, n) : Tn(e) : Nn(e, t);
832
+ o.parent ? s.className === t ? Ln(e, n) : o.parent?.parent ? Dn(e, n) : _n(e) : kn(e, t);
833
833
  }, He = function(e, t) {
834
834
  const n = e.currentNode;
835
835
  if (!n || !n.nodeObj.parent) return;
@@ -838,8 +838,8 @@ const Jt = function(e) {
838
838
  }, $e = function(e, t, n) {
839
839
  const o = t === "in" ? e.scaleSensitivity : -e.scaleSensitivity;
840
840
  st(e, o, n);
841
- }, Dn = (e, t) => {
842
- const n = Sn({
841
+ }, Mn = (e, t) => {
842
+ const n = Tn({
843
843
  deltaMode: t.deltaMode,
844
844
  deltaY: t.deltaY,
845
845
  scaleSensitivity: e.scaleSensitivity,
@@ -847,7 +847,7 @@ const Jt = function(e) {
847
847
  });
848
848
  st(e, n, { x: t.clientX, y: t.clientY });
849
849
  };
850
- function Ln(e, t) {
850
+ function An(e, t) {
851
851
  t = t === !0 ? {} : t;
852
852
  const n = () => {
853
853
  e.currentArrow ? e.removeArrow() : e.currentSummary ? e.removeSummary(e.currentSummary.summaryObj.id) : e.currentNodes && e.removeNodes(e.currentNodes);
@@ -959,7 +959,7 @@ function Ln(e, t) {
959
959
  e.pasteHandler && e.pasteHandler(r);
960
960
  });
961
961
  }
962
- function Mn(e) {
962
+ function Pn(e) {
963
963
  const { panHelper: t, container: n } = e;
964
964
  let o = null;
965
965
  e.spacePressed = !1;
@@ -1015,7 +1015,7 @@ function Mn(e) {
1015
1015
  clear() {
1016
1016
  this.activePointers.clear(), this.lastDistance = null;
1017
1017
  }
1018
- }, c = mt(e), r = {
1018
+ }, c = bt(e), r = {
1019
1019
  timer: null,
1020
1020
  startPos: null,
1021
1021
  pointerId: null,
@@ -1074,7 +1074,7 @@ function Mn(e) {
1074
1074
  }
1075
1075
  if (e.ptState === i.Pinch) return;
1076
1076
  const y = f.target;
1077
- if (y.className === "map-container" && f.button === 0 && f.pointerType === "mouse") {
1077
+ if (e.editable && y.className === "map-container" && f.button === 0 && f.pointerType === "mouse") {
1078
1078
  e.ptState = i.BoxSelect;
1079
1079
  return;
1080
1080
  }
@@ -1082,7 +1082,8 @@ function Mn(e) {
1082
1082
  if (te(y)) {
1083
1083
  e.selection?.cancel();
1084
1084
  const E = e.currentNodes || [];
1085
- f.ctrlKey || f.metaKey || e.mobileMultiSelect ? E.includes(y) ? o = y : ((e.currentArrow || e.currentSummary) && e.clearSelection(), e.selection?.select(y)) : E.includes(y) || e.selectNode(y), f.pointerType === "touch" ? (e.ptState = i.DragWait, r.start(f, (T) => {
1085
+ if (f.ctrlKey || f.metaKey || e.mobileMultiSelect ? E.includes(y) ? o = y : ((e.currentArrow || e.currentSummary) && e.clearSelection(), e.selection?.select(y)) : E.includes(y) || e.selectNode(y), !e.editable) return;
1086
+ f.pointerType === "touch" ? (e.ptState = i.DragWait, r.start(f, (T) => {
1086
1087
  Me(e, c, T, !0) && (e.ptState = i.Drag, y.setPointerCapture(T.pointerId));
1087
1088
  })) : Me(e, c, f, !1) && (e.ptState = i.Drag, y.setPointerCapture(f.pointerId));
1088
1089
  } else
@@ -1096,7 +1097,7 @@ function Mn(e) {
1096
1097
  r.handleMove(f), r.timer === null && (e.ptState = i.Idle);
1097
1098
  break;
1098
1099
  case i.Drag:
1099
- bt(e, c, f);
1100
+ wt(e, c, f);
1100
1101
  break;
1101
1102
  case i.Pan:
1102
1103
  t.handlePointerMove(f);
@@ -1110,7 +1111,7 @@ function Mn(e) {
1110
1111
  r.clear();
1111
1112
  break;
1112
1113
  case i.Drag:
1113
- vt(e, c, f);
1114
+ xt(e, c, f);
1114
1115
  break;
1115
1116
  case i.Pan:
1116
1117
  t.handlePointerUp(f);
@@ -1126,7 +1127,7 @@ function Mn(e) {
1126
1127
  te(y) && !y.classList.contains("selected") && e.selectNode(y), e.bus.fire("showContextMenu", f);
1127
1128
  }, 200);
1128
1129
  }, m = (f) => {
1129
- if (f.stopPropagation(), f.preventDefault(), f.ctrlKey || f.metaKey) return Dn(e, f);
1130
+ if (f.stopPropagation(), f.preventDefault(), f.ctrlKey || f.metaKey) return Mn(e, f);
1130
1131
  if (f.shiftKey) return e.move(-f.deltaY, 0);
1131
1132
  e.move(-f.deltaX, -f.deltaY);
1132
1133
  }, w = (f) => {
@@ -1147,7 +1148,7 @@ function Mn(e) {
1147
1148
  { dom: n, evt: "keyup", func: C }
1148
1149
  ]);
1149
1150
  }
1150
- function An() {
1151
+ function On() {
1151
1152
  return {
1152
1153
  handlers: {},
1153
1154
  addListener: function(e, t) {
@@ -1194,7 +1195,7 @@ const M = "http://www.w3.org/2000/svg", re = function(e) {
1194
1195
  }, je = function() {
1195
1196
  const e = document.createElementNS(M, "line");
1196
1197
  return e.setAttribute("stroke", "#4dc4ff"), e.setAttribute("fill", "none"), e.setAttribute("stroke-width", "2"), e.setAttribute("opacity", "0.45"), e;
1197
- }, Pn = function(e, t, n, o) {
1198
+ }, Hn = function(e, t, n, o) {
1198
1199
  const s = document.createElementNS(M, "g");
1199
1200
  return [
1200
1201
  {
@@ -1253,7 +1254,7 @@ const M = "http://www.w3.org/2000/svg", re = function(e) {
1253
1254
  obj: n
1254
1255
  }));
1255
1256
  });
1256
- }, On = function(e) {
1257
+ }, $n = function(e) {
1257
1258
  const t = this.map.querySelector("me-root"), n = t.offsetTop, o = t.offsetLeft, s = t.offsetWidth, i = t.offsetHeight, l = this.map.querySelectorAll("me-main > me-wrapper");
1258
1259
  this.lines.innerHTML = "";
1259
1260
  for (let c = 0; c < l.length; c++) {
@@ -1278,7 +1279,7 @@ const M = "http://www.w3.org/2000/svg", re = function(e) {
1278
1279
  continue;
1279
1280
  lt(e, t, C, b, s);
1280
1281
  }
1281
- }, Hn = {
1282
+ }, jn = {
1282
1283
  addChild: "Add child",
1283
1284
  addParent: "Add parent",
1284
1285
  addSibling: "Add sibling",
@@ -1292,11 +1293,11 @@ const M = "http://www.w3.org/2000/svg", re = function(e) {
1292
1293
  clickTips: "Please click the target node",
1293
1294
  summary: "Summary"
1294
1295
  };
1295
- function $n(e, t) {
1296
+ function In(e, t) {
1296
1297
  const n = {
1297
1298
  focus: !0,
1298
1299
  link: !0,
1299
- locale: Hn
1300
+ locale: jn
1300
1301
  };
1301
1302
  t = t === !0 ? n : Object.assign(n, t);
1302
1303
  const o = (y) => {
@@ -1364,7 +1365,7 @@ function $n(e, t) {
1364
1365
  l.onclick = null, c.onclick = null, r.onclick = null, a.onclick = null, d.onclick = null, h.onclick = null, u.onclick = null, b.onclick = null, v.onclick = null, g.onclick = null, w.onclick = null, e.container.oncontextmenu = null;
1365
1366
  };
1366
1367
  }
1367
- const jn = function(e) {
1368
+ const Rn = function(e) {
1368
1369
  return ["createSummary", "removeSummary", "finishEditSummary"].includes(e.name) ? {
1369
1370
  type: "summary",
1370
1371
  value: e.obj.id
@@ -1379,7 +1380,7 @@ const jn = function(e) {
1379
1380
  value: [e.obj.id]
1380
1381
  };
1381
1382
  };
1382
- function In(e) {
1383
+ function Bn(e) {
1383
1384
  let t = [], n = -1, o = e.getData(), s = [];
1384
1385
  e.undo = function() {
1385
1386
  if (n > -1) {
@@ -1412,7 +1413,7 @@ function In(e) {
1412
1413
  prev: o,
1413
1414
  operation: r.name,
1414
1415
  currentSelected: s.map((h) => h.id),
1415
- currentTarget: jn(r),
1416
+ currentTarget: Rn(r),
1416
1417
  next: a
1417
1418
  };
1418
1419
  t.push(d), o = a, n = t.length - 1;
@@ -1425,19 +1426,19 @@ function In(e) {
1425
1426
  e.bus.removeListener("operation", i), e.bus.removeListener("selectNodes", c), e.container.removeEventListener("keydown", l);
1426
1427
  };
1427
1428
  }
1428
- const Rn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169394918" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2021" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M851.91168 328.45312c-59.97056 0-108.6208 48.47104-108.91264 108.36992l-137.92768 38.4a109.14304 109.14304 0 0 0-63.46752-46.58688l1.39264-137.11872c47.29344-11.86816 82.31936-54.66624 82.31936-105.64096 0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.76288-108.91776 108.91776c0 49.18784 32.60928 90.75712 77.38368 104.27392l-1.41312 138.87488a109.19936 109.19936 0 0 0-63.50336 48.55808l-138.93632-39.48544 0.01024-0.72704c0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.75776-108.91776 108.91776c0 60.15488 48.76288 108.91264 108.91776 108.91264 39.3984 0 73.91232-20.92032 93.03552-52.2496l139.19232 39.552-0.00512 0.2304c0 25.8304 9.00096 49.5616 24.02816 68.23424l-90.14272 132.63872a108.7488 108.7488 0 0 0-34.2528-5.504c-60.15488 0-108.91776 48.768-108.91776 108.91776 0 60.16 48.76288 108.91776 108.91776 108.91776 60.16 0 108.92288-48.75776 108.92288-108.91776 0-27.14624-9.9328-51.968-26.36288-71.04l89.04704-131.03104a108.544 108.544 0 0 0 37.6832 6.70208 108.672 108.672 0 0 0 36.48512-6.272l93.13792 132.57216a108.48256 108.48256 0 0 0-24.69888 69.0688c0 60.16 48.768 108.92288 108.91776 108.92288 60.16 0 108.91776-48.76288 108.91776-108.92288 0-60.14976-48.75776-108.91776-108.91776-108.91776a108.80512 108.80512 0 0 0-36.69504 6.3488l-93.07136-132.48a108.48768 108.48768 0 0 0 24.79616-72.22784l136.09984-37.888c18.99008 31.93856 53.84192 53.3504 93.69088 53.3504 60.16 0 108.92288-48.75776 108.92288-108.91264-0.00512-60.15488-48.77312-108.92288-108.92288-108.92288z" p-id="2022"></path></svg>', Bn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169375313" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1775" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M639 463.30000001L639 285.1c0-36.90000001-26.4-68.5-61.3-68.5l-150.2 0c-1.5 0-3 0.1-4.5 0.3-10.2-38.7-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c42 0 77.3-28.6 87.5-67.39999999 1.4 0.3 2.9 0.4 4.5 0.39999999L577.7 263.6c6.8 0 14.3 8.9 14.3 21.49999999l0 427.00000001c0 12.7-7.40000001 21.5-14.30000001 21.5l-150.19999999 0c-1.5 0-3 0.2-4.5 0.4-10.2-38.8-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.4 0 49.9 40.5 90.6 90.5 90.59999999 42 0 77.3-28.6 87.5-67.39999999 1.4 0.2 2.9 0.4 4.49999999 0.4L577.7 780.7c34.80000001 0 61.3-31.6 61.3-68.50000001L639 510.3l79.1 0c10.4 38.5 45.49999999 67 87.4 67 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-41.79999999 0-77.00000001 28.4-87.4 67L639 463.30000001z" fill="currentColor" p-id="1776"></path></svg>', Wn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169667709" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3037" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M385 560.69999999L385 738.9c0 36.90000001 26.4 68.5 61.3 68.5l150.2 0c1.5 0 3-0.1 4.5-0.3 10.2 38.7 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-42 0-77.3 28.6-87.5 67.39999999-1.4-0.3-2.9-0.4-4.5-0.39999999L446.3 760.4c-6.8 0-14.3-8.9-14.3-21.49999999l0-427.00000001c0-12.7 7.40000001-21.5 14.30000001-21.5l150.19999999 0c1.5 0 3-0.2 4.5-0.4 10.2 38.8 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.4 0-49.9-40.5-90.6-90.5-90.59999999-42 0-77.3 28.6-87.5 67.39999999-1.4-0.2-2.9-0.4-4.49999999-0.4L446.3 243.3c-34.80000001 0-61.3 31.6-61.3 68.50000001L385 513.7l-79.1 0c-10.4-38.5-45.49999999-67-87.4-67-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c41.79999999 0 77.00000001-28.4 87.4-67L385 560.69999999z" fill="currentColor" p-id="3038"></path></svg>', Yn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169402629" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2170" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M639.328 416c8.032 0 16.096-3.008 22.304-9.056l202.624-197.184-0.8 143.808c-0.096 17.696 14.144 32.096 31.808 32.192 0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808l1.248-222.208c0-0.672-0.352-1.248-0.384-1.92 0.032-0.512 0.288-0.896 0.288-1.408 0.032-17.664-14.272-32-31.968-32.032L671.552 96l-0.032 0c-17.664 0-31.968 14.304-32 31.968C639.488 145.632 653.824 160 671.488 160l151.872 0.224-206.368 200.8c-12.672 12.32-12.928 32.608-0.64 45.248C622.656 412.736 630.976 416 639.328 416z" p-id="2171"></path><path d="M896.032 639.552 896.032 639.552c-17.696 0-32 14.304-32.032 31.968l-0.224 151.872-200.832-206.4c-12.32-12.64-32.576-12.96-45.248-0.64-12.672 12.352-12.928 32.608-0.64 45.248l197.184 202.624-143.808-0.8c-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808-0.096 17.696 14.144 32.096 31.808 32.192l222.24 1.248c0.064 0 0.128 0 0.192 0 0.64 0 1.12-0.32 1.76-0.352 0.512 0.032 0.896 0.288 1.408 0.288l0.032 0c17.664 0 31.968-14.304 32-31.968L928 671.584C928.032 653.952 913.728 639.584 896.032 639.552z" p-id="2172"></path><path d="M209.76 159.744l143.808 0.8c0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808 0.096-17.696-14.144-32.096-31.808-32.192L131.68 95.328c-0.064 0-0.128 0-0.192 0-0.672 0-1.248 0.352-1.888 0.384-0.448 0-0.8-0.256-1.248-0.256 0 0-0.032 0-0.032 0-17.664 0-31.968 14.304-32 31.968L96 352.448c-0.032 17.664 14.272 32 31.968 32.032 0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968l0.224-151.936 200.832 206.4c6.272 6.464 14.624 9.696 22.944 9.696 8.032 0 16.096-3.008 22.304-9.056 12.672-12.32 12.96-32.608 0.64-45.248L209.76 159.744z" p-id="2173"></path><path d="M362.368 617.056l-202.624 197.184 0.8-143.808c0.096-17.696-14.144-32.096-31.808-32.192-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808l-1.248 222.24c0 0.704 0.352 1.312 0.384 2.016 0 0.448-0.256 0.832-0.256 1.312-0.032 17.664 14.272 32 31.968 32.032L352.448 928c0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968s-14.272-32-31.968-32.032l-151.936-0.224 206.4-200.832c12.672-12.352 12.96-32.608 0.64-45.248S375.008 604.704 362.368 617.056z" p-id="2174"></path></svg>', Xn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169573443" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2883" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M514.133333 488.533333m-106.666666 0a106.666667 106.666667 0 1 0 213.333333 0 106.666667 106.666667 0 1 0-213.333333 0Z" fill="currentColor" p-id="2884"></path><path d="M512 64C264.533333 64 64 264.533333 64 512c0 236.8 183.466667 428.8 416 445.866667v-134.4c-53.333333-59.733333-200.533333-230.4-200.533333-334.933334 0-130.133333 104.533333-234.666667 234.666666-234.666666s234.666667 104.533333 234.666667 234.666666c0 61.866667-49.066667 153.6-145.066667 270.933334l-59.733333 68.266666V960C776.533333 942.933333 960 748.8 960 512c0-247.466667-200.533333-448-448-448z" fill="currentColor" p-id="2885"></path></svg>', Fn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169419447" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2480" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M863.328 482.56l-317.344-1.12L545.984 162.816c0-17.664-14.336-32-32-32s-32 14.336-32 32l0 318.4L159.616 480.064c-0.032 0-0.064 0-0.096 0-17.632 0-31.936 14.24-32 31.904C127.424 529.632 141.728 544 159.392 544.064l322.592 1.152 0 319.168c0 17.696 14.336 32 32 32s32-14.304 32-32l0-318.944 317.088 1.12c0.064 0 0.096 0 0.128 0 17.632 0 31.936-14.24 32-31.904C895.264 496.992 880.96 482.624 863.328 482.56z" p-id="2481"></path></svg>', Kn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169426515" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2730" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M863.744 544 163.424 544c-17.664 0-32-14.336-32-32s14.336-32 32-32l700.32 0c17.696 0 32 14.336 32 32S881.44 544 863.744 544z" p-id="2731"></path></svg>', Vn = {
1429
- side: Rn,
1430
- left: Bn,
1431
- right: Wn,
1432
- full: Yn,
1433
- living: Xn,
1434
- zoomin: Fn,
1435
- zoomout: Kn
1429
+ const Wn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169394918" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2021" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M851.91168 328.45312c-59.97056 0-108.6208 48.47104-108.91264 108.36992l-137.92768 38.4a109.14304 109.14304 0 0 0-63.46752-46.58688l1.39264-137.11872c47.29344-11.86816 82.31936-54.66624 82.31936-105.64096 0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.76288-108.91776 108.91776c0 49.18784 32.60928 90.75712 77.38368 104.27392l-1.41312 138.87488a109.19936 109.19936 0 0 0-63.50336 48.55808l-138.93632-39.48544 0.01024-0.72704c0-60.15488-48.76288-108.91776-108.91776-108.91776s-108.91776 48.75776-108.91776 108.91776c0 60.15488 48.76288 108.91264 108.91776 108.91264 39.3984 0 73.91232-20.92032 93.03552-52.2496l139.19232 39.552-0.00512 0.2304c0 25.8304 9.00096 49.5616 24.02816 68.23424l-90.14272 132.63872a108.7488 108.7488 0 0 0-34.2528-5.504c-60.15488 0-108.91776 48.768-108.91776 108.91776 0 60.16 48.76288 108.91776 108.91776 108.91776 60.16 0 108.92288-48.75776 108.92288-108.91776 0-27.14624-9.9328-51.968-26.36288-71.04l89.04704-131.03104a108.544 108.544 0 0 0 37.6832 6.70208 108.672 108.672 0 0 0 36.48512-6.272l93.13792 132.57216a108.48256 108.48256 0 0 0-24.69888 69.0688c0 60.16 48.768 108.92288 108.91776 108.92288 60.16 0 108.91776-48.76288 108.91776-108.92288 0-60.14976-48.75776-108.91776-108.91776-108.91776a108.80512 108.80512 0 0 0-36.69504 6.3488l-93.07136-132.48a108.48768 108.48768 0 0 0 24.79616-72.22784l136.09984-37.888c18.99008 31.93856 53.84192 53.3504 93.69088 53.3504 60.16 0 108.92288-48.75776 108.92288-108.91264-0.00512-60.15488-48.77312-108.92288-108.92288-108.92288z" p-id="2022"></path></svg>', Yn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169375313" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1775" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M639 463.30000001L639 285.1c0-36.90000001-26.4-68.5-61.3-68.5l-150.2 0c-1.5 0-3 0.1-4.5 0.3-10.2-38.7-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c42 0 77.3-28.6 87.5-67.39999999 1.4 0.3 2.9 0.4 4.5 0.39999999L577.7 263.6c6.8 0 14.3 8.9 14.3 21.49999999l0 427.00000001c0 12.7-7.40000001 21.5-14.30000001 21.5l-150.19999999 0c-1.5 0-3 0.2-4.5 0.4-10.2-38.8-45.5-67.3-87.5-67.3-50 0-90.5 40.5-90.5 90.4 0 49.9 40.5 90.6 90.5 90.59999999 42 0 77.3-28.6 87.5-67.39999999 1.4 0.2 2.9 0.4 4.49999999 0.4L577.7 780.7c34.80000001 0 61.3-31.6 61.3-68.50000001L639 510.3l79.1 0c10.4 38.5 45.49999999 67 87.4 67 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-41.79999999 0-77.00000001 28.4-87.4 67L639 463.30000001z" fill="currentColor" p-id="1776"></path></svg>', Xn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169667709" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3037" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M385 560.69999999L385 738.9c0 36.90000001 26.4 68.5 61.3 68.5l150.2 0c1.5 0 3-0.1 4.5-0.3 10.2 38.7 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.5s-40.5-90.5-90.5-90.5c-42 0-77.3 28.6-87.5 67.39999999-1.4-0.3-2.9-0.4-4.5-0.39999999L446.3 760.4c-6.8 0-14.3-8.9-14.3-21.49999999l0-427.00000001c0-12.7 7.40000001-21.5 14.30000001-21.5l150.19999999 0c1.5 0 3-0.2 4.5-0.4 10.2 38.8 45.5 67.3 87.5 67.3 50 0 90.5-40.5 90.5-90.4 0-49.9-40.5-90.6-90.5-90.59999999-42 0-77.3 28.6-87.5 67.39999999-1.4-0.2-2.9-0.4-4.49999999-0.4L446.3 243.3c-34.80000001 0-61.3 31.6-61.3 68.50000001L385 513.7l-79.1 0c-10.4-38.5-45.49999999-67-87.4-67-50 0-90.5 40.5-90.5 90.5s40.5 90.5 90.5 90.5c41.79999999 0 77.00000001-28.4 87.4-67L385 560.69999999z" fill="currentColor" p-id="3038"></path></svg>', Fn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169402629" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2170" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M639.328 416c8.032 0 16.096-3.008 22.304-9.056l202.624-197.184-0.8 143.808c-0.096 17.696 14.144 32.096 31.808 32.192 0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808l1.248-222.208c0-0.672-0.352-1.248-0.384-1.92 0.032-0.512 0.288-0.896 0.288-1.408 0.032-17.664-14.272-32-31.968-32.032L671.552 96l-0.032 0c-17.664 0-31.968 14.304-32 31.968C639.488 145.632 653.824 160 671.488 160l151.872 0.224-206.368 200.8c-12.672 12.32-12.928 32.608-0.64 45.248C622.656 412.736 630.976 416 639.328 416z" p-id="2171"></path><path d="M896.032 639.552 896.032 639.552c-17.696 0-32 14.304-32.032 31.968l-0.224 151.872-200.832-206.4c-12.32-12.64-32.576-12.96-45.248-0.64-12.672 12.352-12.928 32.608-0.64 45.248l197.184 202.624-143.808-0.8c-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808-0.096 17.696 14.144 32.096 31.808 32.192l222.24 1.248c0.064 0 0.128 0 0.192 0 0.64 0 1.12-0.32 1.76-0.352 0.512 0.032 0.896 0.288 1.408 0.288l0.032 0c17.664 0 31.968-14.304 32-31.968L928 671.584C928.032 653.952 913.728 639.584 896.032 639.552z" p-id="2172"></path><path d="M209.76 159.744l143.808 0.8c0.064 0 0.128 0 0.192 0 17.6 0 31.904-14.208 32-31.808 0.096-17.696-14.144-32.096-31.808-32.192L131.68 95.328c-0.064 0-0.128 0-0.192 0-0.672 0-1.248 0.352-1.888 0.384-0.448 0-0.8-0.256-1.248-0.256 0 0-0.032 0-0.032 0-17.664 0-31.968 14.304-32 31.968L96 352.448c-0.032 17.664 14.272 32 31.968 32.032 0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968l0.224-151.936 200.832 206.4c6.272 6.464 14.624 9.696 22.944 9.696 8.032 0 16.096-3.008 22.304-9.056 12.672-12.32 12.96-32.608 0.64-45.248L209.76 159.744z" p-id="2173"></path><path d="M362.368 617.056l-202.624 197.184 0.8-143.808c0.096-17.696-14.144-32.096-31.808-32.192-0.064 0-0.128 0-0.192 0-17.6 0-31.904 14.208-32 31.808l-1.248 222.24c0 0.704 0.352 1.312 0.384 2.016 0 0.448-0.256 0.832-0.256 1.312-0.032 17.664 14.272 32 31.968 32.032L352.448 928c0 0 0.032 0 0.032 0 17.664 0 31.968-14.304 32-31.968s-14.272-32-31.968-32.032l-151.936-0.224 206.4-200.832c12.672-12.352 12.96-32.608 0.64-45.248S375.008 604.704 362.368 617.056z" p-id="2174"></path></svg>', Kn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169573443" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2883" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M514.133333 488.533333m-106.666666 0a106.666667 106.666667 0 1 0 213.333333 0 106.666667 106.666667 0 1 0-213.333333 0Z" fill="currentColor" p-id="2884"></path><path d="M512 64C264.533333 64 64 264.533333 64 512c0 236.8 183.466667 428.8 416 445.866667v-134.4c-53.333333-59.733333-200.533333-230.4-200.533333-334.933334 0-130.133333 104.533333-234.666667 234.666666-234.666666s234.666667 104.533333 234.666667 234.666666c0 61.866667-49.066667 153.6-145.066667 270.933334l-59.733333 68.266666V960C776.533333 942.933333 960 748.8 960 512c0-247.466667-200.533333-448-448-448z" fill="currentColor" p-id="2885"></path></svg>', Vn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169419447" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2480" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M863.328 482.56l-317.344-1.12L545.984 162.816c0-17.664-14.336-32-32-32s-32 14.336-32 32l0 318.4L159.616 480.064c-0.032 0-0.064 0-0.096 0-17.632 0-31.936 14.24-32 31.904C127.424 529.632 141.728 544 159.392 544.064l322.592 1.152 0 319.168c0 17.696 14.336 32 32 32s32-14.304 32-32l0-318.944 317.088 1.12c0.064 0 0.096 0 0.128 0 17.632 0 31.936-14.24 32-31.904C895.264 496.992 880.96 482.624 863.328 482.56z" p-id="2481"></path></svg>', zn = '<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1750169426515" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2730" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M863.744 544 163.424 544c-17.664 0-32-14.336-32-32s14.336-32 32-32l700.32 0c17.696 0 32 14.336 32 32S881.44 544 863.744 544z" p-id="2731"></path></svg>', Gn = {
1430
+ side: Wn,
1431
+ left: Yn,
1432
+ right: Xn,
1433
+ full: Fn,
1434
+ living: Kn,
1435
+ zoomin: Vn,
1436
+ zoomout: zn
1436
1437
  }, I = (e, t) => {
1437
1438
  const n = document.createElement("span");
1438
- return n.id = e, n.innerHTML = Vn[t], n;
1439
+ return n.id = e, n.innerHTML = Gn[t], n;
1439
1440
  };
1440
- function zn(e) {
1441
+ function qn(e) {
1441
1442
  const t = document.createElement("div"), n = I("fullscreen", "full"), o = I("toCenter", "living"), s = I("zoomout", "zoomout"), i = I("zoomin", "zoomin");
1442
1443
  t.appendChild(n), t.appendChild(o), t.appendChild(s), t.appendChild(i), t.className = "mind-elixir-toolbar rb";
1443
1444
  let l = null;
@@ -1465,7 +1466,7 @@ function zn(e) {
1465
1466
  e.scale(e.scaleVal + e.scaleSensitivity);
1466
1467
  }, t;
1467
1468
  }
1468
- function Gn(e) {
1469
+ function Un(e) {
1469
1470
  const t = document.createElement("div"), n = I("tbltl", "left"), o = I("tbltr", "right"), s = I("tblts", "side");
1470
1471
  return t.appendChild(n), t.appendChild(o), t.appendChild(s), t.className = "mind-elixir-toolbar lt", n.onclick = () => {
1471
1472
  e.initLeft();
@@ -1475,10 +1476,10 @@ function Gn(e) {
1475
1476
  e.initSide();
1476
1477
  }, t;
1477
1478
  }
1478
- function qn(e) {
1479
- e.container.append(zn(e)), e.container.append(Gn(e));
1479
+ function Jn(e) {
1480
+ e.container.append(qn(e)), e.container.append(Un(e));
1480
1481
  }
1481
- class Un {
1482
+ class Zn {
1482
1483
  _listeners = /* @__PURE__ */ new Map();
1483
1484
  addEventListener(t, n) {
1484
1485
  const o = this._listeners.get(t) ?? /* @__PURE__ */ new Set();
@@ -1509,7 +1510,7 @@ const Ie = (e, t = "px") => typeof e == "number" ? e + t : e, $ = ({ style: e },
1509
1510
  }, Re = (e = 0, t = 0, n = 0, o = 0) => {
1510
1511
  const s = { x: e, y: t, width: n, height: o, top: t, left: e, right: e + n, bottom: t + o };
1511
1512
  return { ...s, toJSON: () => JSON.stringify(s) };
1512
- }, Jn = (e) => {
1513
+ }, Qn = (e) => {
1513
1514
  let t, n = -1, o = !1;
1514
1515
  return {
1515
1516
  next: (...s) => {
@@ -1532,7 +1533,7 @@ const Ie = (e, t = "px") => typeof e == "number" ? e + t : e, $ = ({ style: e },
1532
1533
  case "touch":
1533
1534
  return e.right >= t.left && e.left <= t.right && e.bottom >= t.top && e.top <= t.bottom;
1534
1535
  }
1535
- }, Zn = () => matchMedia("(hover: none), (pointer: coarse)").matches, Qn = () => "safari" in window, he = (e) => Array.isArray(e) ? e : [e], ct = (e) => (t, n, o, s = {}) => {
1536
+ }, eo = () => matchMedia("(hover: none), (pointer: coarse)").matches, to = () => "safari" in window, he = (e) => Array.isArray(e) ? e : [e], ct = (e) => (t, n, o, s = {}) => {
1536
1537
  (t instanceof HTMLCollection || t instanceof NodeList) && (t = Array.from(t)), n = he(n), t = he(t);
1537
1538
  for (const i of t)
1538
1539
  if (i)
@@ -1541,7 +1542,7 @@ const Ie = (e, t = "px") => typeof e == "number" ? e + t : e, $ = ({ style: e },
1541
1542
  }, W = ct("addEventListener"), P = ct("removeEventListener"), J = (e) => {
1542
1543
  const { clientX: t, clientY: n, target: o } = e.touches?.[0] ?? e;
1543
1544
  return { x: t, y: n, target: o };
1544
- }, Y = (e, t = document) => he(e).map((n) => typeof n == "string" ? Array.from(t.querySelectorAll(n)) : n instanceof Element ? n : null).flat().filter(Boolean), eo = (e, t) => t.some((n) => typeof n == "number" ? e.button === n : typeof n == "object" ? n.button !== e.button ? !1 : n.modifiers.every((o) => {
1545
+ }, Y = (e, t = document) => he(e).map((n) => typeof n == "string" ? Array.from(t.querySelectorAll(n)) : n instanceof Element ? n : null).flat().filter(Boolean), no = (e, t) => t.some((n) => typeof n == "number" ? e.button === n : typeof n == "object" ? n.button !== e.button ? !1 : n.modifiers.every((o) => {
1545
1546
  switch (o) {
1546
1547
  case "alt":
1547
1548
  return e.altKey;
@@ -1556,7 +1557,7 @@ const Ie = (e, t = "px") => typeof e == "number" ? e + t : e, $ = ({ style: e },
1556
1557
  touched: [],
1557
1558
  changed: { added: [], removed: [] }
1558
1559
  });
1559
- class to extends Un {
1560
+ class oo extends Zn {
1560
1561
  static version = "mind-elixir-fork";
1561
1562
  // Options
1562
1563
  _options;
@@ -1638,7 +1639,7 @@ class to extends Un {
1638
1639
  // https://stackoverflow.com/a/38268846
1639
1640
  pointerEvents: "none",
1640
1641
  zIndex: "1"
1641
- }), this._frame = Jn((i) => {
1642
+ }), this._frame = Qn((i) => {
1642
1643
  this._recalculateSelectionAreaRect(), this._updateElementSelection(), this._emitEvent("move", i), this._redrawSelectionArea();
1643
1644
  }), this.enable();
1644
1645
  }
@@ -1648,7 +1649,7 @@ class to extends Un {
1648
1649
  }
1649
1650
  _onTapStart(t, n = !1) {
1650
1651
  const { x: o, y: s, target: i } = J(t), { document: l, startAreas: c, boundaries: r, behaviour: a, features: d } = this._options, h = i.getBoundingClientRect();
1651
- if (!eo(t, a.triggers))
1652
+ if (!no(t, a.triggers))
1652
1653
  return;
1653
1654
  const u = Y(c, l), b = Y(r, l);
1654
1655
  this._targetElement = b.find((m) => Be(m.getBoundingClientRect(), h));
@@ -1756,7 +1757,7 @@ class to extends Un {
1756
1757
  }
1757
1758
  _handleMoveEvent(t) {
1758
1759
  const { features: n } = this._options;
1759
- (n.touch && Zn() || this._scrollAvailable && Qn()) && t.preventDefault();
1760
+ (n.touch && eo() || this._scrollAvailable && to()) && t.preventDefault();
1760
1761
  }
1761
1762
  _onScroll() {
1762
1763
  const {
@@ -1944,8 +1945,8 @@ class to extends Un {
1944
1945
  this._selection.stored = s.filter((c) => !l.includes(c)), this._selection.selected = o.filter((c) => !l.includes(c)), this._selection.changed.added = [], this._selection.changed.removed.push(...l.filter((c) => !i.removed.includes(c))), this._latestElement = void 0, n || (this._emitEvent("move", null), this._emitEvent("stop", null));
1945
1946
  }
1946
1947
  }
1947
- function no(e) {
1948
- const t = e.mouseSelectionButton === 2 ? [2] : [0], n = new to({
1948
+ function so(e) {
1949
+ const t = e.mouseSelectionButton === 2 ? [2] : [0], n = new oo({
1949
1950
  selectables: [".map-container me-tpc"],
1950
1951
  boundaries: [e.container],
1951
1952
  container: e.selectionContainer,
@@ -2008,7 +2009,7 @@ function no(e) {
2008
2009
  );
2009
2010
  e.selection = n;
2010
2011
  }
2011
- const oo = function(e, t = !0) {
2012
+ const io = function(e, t = !0) {
2012
2013
  this.theme = e;
2013
2014
  const o = {
2014
2015
  ...(e.type === "dark" ? ue : fe).cssVar,
@@ -2019,7 +2020,7 @@ const oo = function(e, t = !0) {
2019
2020
  this.container.style.setProperty(l, o[l]);
2020
2021
  }
2021
2022
  t && this.refresh();
2022
- }, so = function(e) {
2023
+ }, ro = function(e) {
2023
2024
  return {
2024
2025
  dom: e,
2025
2026
  moved: !1,
@@ -2055,15 +2056,15 @@ const oo = function(e, t = !0) {
2055
2056
  }
2056
2057
  };
2057
2058
  }, Ke = {
2058
- create: so
2059
- }, io = "#4dc4ff";
2060
- function at(e, t, n, o, s, i, l, c) {
2059
+ create: ro
2060
+ }, at = "#4dc4ff";
2061
+ function dt(e, t, n, o, s, i, l, c) {
2061
2062
  return {
2062
2063
  x: e / 8 + n * 3 / 8 + s * 3 / 8 + l / 8,
2063
2064
  y: t / 8 + o * 3 / 8 + i * 3 / 8 + c / 8
2064
2065
  };
2065
2066
  }
2066
- function ro(e, t, n) {
2067
+ function lo(e, t, n) {
2067
2068
  e && (e.dataset.x = t.toString(), e.dataset.y = n.toString(), re(e));
2068
2069
  }
2069
2070
  function Z(e, t, n, o, s) {
@@ -2100,8 +2101,8 @@ function Ve(e, t, n, o, s, i, l, c, r, a) {
2100
2101
  }
2101
2102
  }
2102
2103
  }
2103
- const { x: b, y: v } = at(t, n, o, s, i, l, c, r);
2104
- if (e.labelEl && ro(e.labelEl, b, v), a.style?.labelColor) {
2104
+ const { x: b, y: v } = dt(t, n, o, s, i, l, c, r);
2105
+ if (e.labelEl && lo(e.labelEl, b, v), a.style?.labelColor) {
2105
2106
  const p = e.labelEl;
2106
2107
  p && (p.style.color = a.style.labelColor);
2107
2108
  }
@@ -2126,7 +2127,7 @@ function X(e) {
2126
2127
  y: n
2127
2128
  };
2128
2129
  }
2129
- const lo = function(e, t, n) {
2130
+ const co = function(e, t, n) {
2130
2131
  const o = L(e.nodes, t), s = L(e.nodes, n), i = o.offsetLeft + t.offsetWidth / 2, l = o.offsetTop + t.offsetHeight / 2, c = s.offsetLeft + n.offsetWidth / 2, r = s.offsetTop + n.offsetHeight / 2, a = c - i, d = r - l, h = Math.sqrt(a * a + d * d), u = Math.max(50, Math.min(200, h * 0.3)), b = Math.abs(a), v = Math.abs(d);
2131
2132
  let p, g;
2132
2133
  if (h < 150) {
@@ -2150,7 +2151,7 @@ const lo = function(e, t, n) {
2150
2151
  if (!t || !n)
2151
2152
  return;
2152
2153
  if (!o.delta1 || !o.delta2) {
2153
- const S = lo(e, t, n);
2154
+ const S = co(e, t, n);
2154
2155
  o.delta1 = S.delta1, o.delta2 = S.delta2;
2155
2156
  }
2156
2157
  const i = se(e, t, o.delta1), l = se(e, n, o.delta2), { x: c, y: r } = X(i), { ctrlX: a, ctrlY: d } = i, { ctrlX: h, ctrlY: u } = l, { x: b, y: v } = X(l), p = oe(h, u, b, v);
@@ -2162,7 +2163,7 @@ const lo = function(e, t, n) {
2162
2163
  if (!S) return;
2163
2164
  m = `M ${S.x1} ${S.y1} L ${c} ${r} L ${S.x2} ${S.y2}`;
2164
2165
  }
2165
- const w = Pn(`M ${c} ${r} C ${a} ${d} ${h} ${u} ${b} ${v}`, g, m, o.style), { x: C, y: N } = at(c, r, a, d, h, u, b, v), f = o.style?.labelColor || "rgb(235, 95, 82)", y = "a-" + o.id;
2166
+ const w = Hn(`M ${c} ${r} C ${a} ${d} ${h} ${u} ${b} ${v}`, g, m, o.style), { x: C, y: N } = dt(c, r, a, d, h, u, b, v), f = o.style?.labelColor || "rgb(235, 95, 82)", y = "a-" + o.id;
2166
2167
  w.id = y;
2167
2168
  const x = e.markdown ? e.markdown(o.label, o) : o.label, E = de(x, C, N, {
2168
2169
  anchor: "middle",
@@ -2170,8 +2171,8 @@ const lo = function(e, t, n) {
2170
2171
  dataType: "arrow",
2171
2172
  svgId: y
2172
2173
  });
2173
- w.labelEl = E, w.arrowObj = o, w.dataset.linkid = o.id, e.labelContainer.appendChild(E), e.arrowSvg.appendChild(w), re(E), s || (e.arrows.push(o), e.currentArrow = w, dt(e, o, i, l));
2174
- }, co = function(e, t, n = {}) {
2174
+ w.labelEl = E, w.arrowObj = o, w.dataset.linkid = o.id, e.labelContainer.appendChild(E), e.arrowSvg.appendChild(w), re(E), s || (e.arrows.push(o), e.currentArrow = w, ft(e, o, i, l));
2175
+ }, ao = function(e, t, n = {}) {
2175
2176
  const o = {
2176
2177
  id: B(),
2177
2178
  label: "Custom Link",
@@ -2183,14 +2184,14 @@ const lo = function(e, t, n) {
2183
2184
  name: "createArrow",
2184
2185
  obj: o
2185
2186
  });
2186
- }, ao = function(e) {
2187
+ }, ho = function(e) {
2187
2188
  le(this);
2188
2189
  const t = { ...e, id: B() };
2189
2190
  Se(this, this.findEle(t.from), this.findEle(t.to), t), this.bus.fire("operation", {
2190
2191
  name: "createArrow",
2191
2192
  obj: t
2192
2193
  });
2193
- }, ho = function(e) {
2194
+ }, fo = function(e) {
2194
2195
  let t;
2195
2196
  if (e ? t = e : t = this.currentArrow, !t) return;
2196
2197
  le(this);
@@ -2201,11 +2202,11 @@ const lo = function(e, t, n) {
2201
2202
  id: n
2202
2203
  }
2203
2204
  });
2204
- }, fo = function(e) {
2205
+ }, uo = function(e) {
2205
2206
  this.currentArrow = e;
2206
2207
  const t = e.arrowObj, n = this.findEle(t.from), o = this.findEle(t.to), s = se(this, n, t.delta1), i = se(this, o, t.delta2);
2207
- dt(this, t, s, i), this.bus.fire("selectArrow", t);
2208
- }, uo = function() {
2208
+ this.editable ? ft(this, t, s, i) : ht(e, at), this.bus.fire("selectArrow", t);
2209
+ }, po = function() {
2209
2210
  le(this), this.currentArrow = null, this.bus.fire("unselectArrow");
2210
2211
  }, ce = function(e, t) {
2211
2212
  const n = document.createElementNS(M, "path");
@@ -2217,7 +2218,7 @@ const lo = function(e, t, n) {
2217
2218
  "stroke-linecap": "round",
2218
2219
  "stroke-linejoin": "round"
2219
2220
  }), n;
2220
- }, po = function(e, t) {
2221
+ }, ht = function(e, t) {
2221
2222
  const n = document.createElementNS(M, "g");
2222
2223
  n.setAttribute("class", "arrow-highlight"), n.setAttribute("opacity", "0.45");
2223
2224
  const o = ce(e.line.getAttribute("d"), t);
@@ -2238,10 +2239,10 @@ const lo = function(e, t, n) {
2238
2239
  n.length >= 1 && n[0].setAttribute("d", e.line.getAttribute("d")), n.length >= 2 && n[1].setAttribute("d", e.arrow1.getAttribute("d")), n.length >= 3 && e.arrow2.getAttribute("d") && n[2].setAttribute("d", e.arrow2.getAttribute("d"));
2239
2240
  }, le = function(e) {
2240
2241
  e.helper1?.destroy(), e.helper2?.destroy(), e.linkController.style.display = "none", e.P2.style.display = "none", e.P3.style.display = "none", e.currentArrow && go(e.currentArrow);
2241
- }, dt = function(e, t, n, o) {
2242
+ }, ft = function(e, t, n, o) {
2242
2243
  const { linkController: s, P2: i, P3: l, line1: c, line2: r, nodes: a, map: d, currentArrow: h, bus: u } = e;
2243
2244
  if (!h) return;
2244
- s.style.display = "initial", i.style.display = "initial", l.style.display = "initial", a.appendChild(s), a.appendChild(i), a.appendChild(l), po(h, io);
2245
+ s.style.display = "initial", i.style.display = "initial", l.style.display = "initial", a.appendChild(s), a.appendChild(i), a.appendChild(l), ht(h, at);
2245
2246
  let { x: b, y: v } = X(n), { ctrlX: p, ctrlY: g } = n, { ctrlX: m, ctrlY: w } = o, { x: C, y: N } = X(o);
2246
2247
  i.style.cssText = `top:${g}px;left:${p}px;`, l.style.cssText = `top:${w}px;left:${m}px;`, Z(c, b, v, p, g), Z(r, m, w, C, N), e.helper1 = Ke.create(i), e.helper2 = Ke.create(l), e.helper1.init(d, (f, y) => {
2247
2248
  p = p + f / e.scaleVal, g = g + y / e.scaleVal;
@@ -2272,14 +2273,14 @@ function vo() {
2272
2273
  }
2273
2274
  const wo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2274
2275
  __proto__: null,
2275
- createArrow: co,
2276
- createArrowFrom: ao,
2276
+ createArrow: ao,
2277
+ createArrowFrom: ho,
2277
2278
  editArrowLabel: bo,
2278
- removeArrow: ho,
2279
+ removeArrow: fo,
2279
2280
  renderArrow: yo,
2280
- selectArrow: fo,
2281
+ selectArrow: uo,
2281
2282
  tidyArrow: vo,
2282
- unselectArrow: uo
2283
+ unselectArrow: po
2283
2284
  }, Symbol.toStringTag, { value: "Module" })), xo = function(e) {
2284
2285
  if (e.length === 0) throw new Error("No selected node.");
2285
2286
  if (e.length === 1) {
@@ -2556,31 +2557,31 @@ function zo(e, t) {
2556
2557
  o && !await o.apply(this, n) || e.apply(this, n);
2557
2558
  };
2558
2559
  }
2559
- const Ge = Object.keys(ot), ht = {};
2560
+ const Ge = Object.keys(ot), ut = {};
2560
2561
  for (let e = 0; e < Ge.length; e++) {
2561
2562
  const t = Ge[e];
2562
- ht[t] = zo(ot[t], t);
2563
+ ut[t] = zo(ot[t], t);
2563
2564
  }
2564
2565
  const Go = {
2565
2566
  getObjById: ne,
2566
- generateNewObj: ft,
2567
- layout: xt,
2568
- linkDiv: On,
2569
- editTopic: _t,
2570
- createWrapper: St,
2571
- createParent: Nt,
2572
- createChildren: Tt,
2573
- createTopic: kt,
2567
+ generateNewObj: pt,
2568
+ layout: Ct,
2569
+ linkDiv: $n,
2570
+ editTopic: Lt,
2571
+ createWrapper: Tt,
2572
+ createParent: kt,
2573
+ createChildren: _t,
2574
+ createTopic: Dt,
2574
2575
  findEle: Ze,
2575
- changeTheme: oo,
2576
- ...wn,
2577
- ...ht,
2576
+ changeTheme: io,
2577
+ ...En,
2578
+ ...ut,
2578
2579
  ...wo,
2579
2580
  ...Ao,
2580
2581
  ...Vo,
2581
2582
  init(e) {
2582
2583
  if (e = JSON.parse(JSON.stringify(e)), !e || !e.nodeData) return new Error("MindElixir: `data` is required");
2583
- e.direction !== void 0 && (this.direction = e.direction), this.changeTheme(e.theme || this.theme, !1), this.nodeData = e.nodeData, R(this.nodeData), this.arrows = e.arrows || [], this.summaries = e.summaries || [], this.tidyArrow(), this.toolBar && qn(this), this.keypress && Ln(this, this.keypress), no(this), this.disposable.push(wt()), this.contextMenu && this.disposable.push($n(this, this.contextMenu)), this.allowUndo && this.disposable.push(In(this)), this.layout(), this.linkDiv(), this.toCenter();
2584
+ e.direction !== void 0 && (this.direction = e.direction), this.changeTheme(e.theme || this.theme, !1), this.nodeData = e.nodeData, R(this.nodeData), this.arrows = e.arrows || [], this.summaries = e.summaries || [], this.tidyArrow(), this.toolBar && Jn(this), this.keypress && An(this, this.keypress), so(this), this.disposable.push(Et()), this.contextMenu && this.disposable.push(In(this, this.contextMenu)), this.allowUndo && this.disposable.push(Bn(this)), this.layout(), this.linkDiv(), this.toCenter();
2584
2585
  },
2585
2586
  destroy() {
2586
2587
  this.disposable.forEach((e) => e()), this.el && (this.el.innerHTML = ""), this.el = void 0, this.nodeData = void 0, this.arrows = void 0, this.summaries = void 0, this.currentArrow = void 0, this.currentNodes = void 0, this.currentSummary = void 0, this.theme = void 0, this.direction = void 0, this.bus = void 0, this.container = void 0, this.map = void 0, this.lines = void 0, this.linkController = void 0, this.arrowSvg = void 0, this.P2 = void 0, this.P3 = void 0, this.line1 = void 0, this.line2 = void 0, this.nodes = void 0, this.selection?.destroy(), this.selection = void 0;
@@ -2610,7 +2611,7 @@ function Uo({ pT: e, pL: t, pW: n, pH: o, cT: s, cL: i, cW: l, cH: c, direction:
2610
2611
  const m = Math.abs(h - b) / 300 * d;
2611
2612
  return r === O.LHS ? (g = t, v = g + d, p = g - d, u = i + d, `M ${v} ${h} C ${g} ${h} ${g + m} ${b} ${p} ${b} H ${u}`) : (g = t + n, v = g - d, p = g + d, u = i + l - d, `M ${v} ${h} C ${g} ${h} ${g - m} ${b} ${p} ${b} H ${u}`);
2612
2613
  }
2613
- const Jo = "5.11.1-beta.2";
2614
+ const Jo = "5.11.1-beta.4";
2614
2615
  function Zo(e) {
2615
2616
  return {
2616
2617
  x: 0,
@@ -2667,11 +2668,11 @@ function A({
2667
2668
  let E = null;
2668
2669
  const S = Object.prototype.toString.call(e);
2669
2670
  if (S === "[object HTMLDivElement]" ? E = e : S === "[object String]" && (E = document.querySelector(e)), !E) throw new Error("MindElixir: el is not a valid element");
2670
- E.style.position = "relative", E.innerHTML = "", this.el = E, this.disposable = [], this.before = r || {}, this.newTopicName = a || "New Node", this.contextMenu = o ?? !0, this.toolBar = s ?? !0, this.keypress = i ?? !0, this.mouseSelectionButton = l ?? 0, this.direction = t ?? 1, this.editable = n ?? !0, this.allowUndo = d ?? !0, this.scaleSensitivity = g ?? 0.1, this.scaleMax = m ?? 1.4, this.scaleMin = w ?? 0.2, this.generateMainBranch = h || qo, this.generateSubBranch = u || Uo, this.overflowHidden = b ?? !1, this.alignment = p ?? "root", this.handleWheel = C ?? !0, this.markdown = N || void 0, this.imageProxy = f || void 0, this.currentNodes = [], this.currentArrow = null, this.scaleVal = 1, this.tempDirection = null, this.mobileMultiSelect = x ?? !1, this.panHelper = Zo(this), this.bus = An(), this.container = document.createElement("div"), this.selectionContainer = c || this.container, this.container.className = "map-container";
2671
+ E.style.position = "relative", E.innerHTML = "", this.el = E, this.disposable = [], this.before = r || {}, this.newTopicName = a || "New Node", this.contextMenu = o ?? !0, this.toolBar = s ?? !0, this.keypress = i ?? !0, this.mouseSelectionButton = l ?? 0, this.direction = t ?? 1, this.editable = n ?? !0, this.allowUndo = d ?? !0, this.scaleSensitivity = g ?? 0.1, this.scaleMax = m ?? 1.4, this.scaleMin = w ?? 0.2, this.generateMainBranch = h || qo, this.generateSubBranch = u || Uo, this.overflowHidden = b ?? !1, this.alignment = p ?? "root", this.handleWheel = C ?? !0, this.markdown = N || void 0, this.imageProxy = f || void 0, this.currentNodes = [], this.currentArrow = null, this.scaleVal = 1, this.tempDirection = null, this.mobileMultiSelect = x ?? !1, this.panHelper = Zo(this), this.bus = On(), this.container = document.createElement("div"), this.selectionContainer = c || this.container, this.container.className = "map-container";
2671
2672
  const T = window.matchMedia("(prefers-color-scheme: dark)");
2672
2673
  this.theme = v || (T.matches ? ue : fe);
2673
2674
  const _ = document.createElement("div");
2674
- _.className = "map-canvas", this.map = _, this.container.setAttribute("tabindex", "0"), this.container.appendChild(this.map), this.el.appendChild(this.container), this.nodes = document.createElement("me-nodes"), this.lines = z("lines"), this.summarySvg = z("summary"), this.linkController = z("linkcontroller"), this.P2 = document.createElement("div"), this.P3 = document.createElement("div"), this.P2.className = this.P3.className = "circle", this.P2.style.display = this.P3.style.display = "none", this.line1 = je(), this.line2 = je(), this.linkController.appendChild(this.line1), this.linkController.appendChild(this.line2), this.arrowSvg = z("topiclinks"), this.labelContainer = document.createElement("div"), this.labelContainer.className = "label-container", this.map.appendChild(this.nodes), this.overflowHidden ? this.container.style.overflow = "hidden" : this.disposable.push(Mn(this)), y && (this.pasteHandler = y);
2675
+ _.className = "map-canvas", this.map = _, this.container.setAttribute("tabindex", "0"), this.container.appendChild(this.map), this.el.appendChild(this.container), this.nodes = document.createElement("me-nodes"), this.lines = z("lines"), this.summarySvg = z("summary"), this.linkController = z("linkcontroller"), this.P2 = document.createElement("div"), this.P3 = document.createElement("div"), this.P2.className = this.P3.className = "circle", this.P2.style.display = this.P3.style.display = "none", this.line1 = je(), this.line2 = je(), this.linkController.appendChild(this.line1), this.linkController.appendChild(this.line2), this.arrowSvg = z("topiclinks"), this.labelContainer = document.createElement("div"), this.labelContainer.className = "label-container", this.map.appendChild(this.nodes), this.overflowHidden ? this.container.style.overflow = "hidden" : this.disposable.push(Pn(this)), y && (this.pasteHandler = y);
2675
2676
  }
2676
2677
  A.prototype = Go;
2677
2678
  Object.defineProperty(A.prototype, "currentNode", {