quixotic-gol 0.1.12 → 0.1.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,5 +1,5 @@
1
- import { useRef as ut, useState as He, useCallback as Me, useEffect as Le, forwardRef as Tr, useImperativeHandle as Vr } from "react";
2
- import { jsx as Bt, jsxs as fe } from "react/jsx-runtime";
1
+ import { useRef as ft, useState as He, useCallback as Me, useEffect as Le, forwardRef as Tr, useImperativeHandle as Vr } from "react";
2
+ import { jsx as Nt, jsxs as he } from "react/jsx-runtime";
3
3
  const za = 500;
4
4
  function ja(t) {
5
5
  return JSON.stringify(JSON.stringify(t)).slice(1, -1);
@@ -19,9 +19,9 @@ function ke() {
19
19
  if (!(n = arguments[t] + "") || n in r || /[\s.]/.test(n)) throw new Error("illegal type: " + n);
20
20
  r[n] = [];
21
21
  }
22
- return new se(r);
22
+ return new ce(r);
23
23
  }
24
- function se(t) {
24
+ function ce(t) {
25
25
  this._ = t;
26
26
  }
27
27
  function Hr(t, e) {
@@ -31,8 +31,8 @@ function Hr(t, e) {
31
31
  return { type: r, name: n };
32
32
  });
33
33
  }
34
- se.prototype = ke.prototype = {
35
- constructor: se,
34
+ ce.prototype = ke.prototype = {
35
+ constructor: ce,
36
36
  on: function(t, e) {
37
37
  var r = this._, n = Hr(t + "", r), o, a = -1, i = n.length;
38
38
  if (arguments.length < 2) {
@@ -48,7 +48,7 @@ se.prototype = ke.prototype = {
48
48
  copy: function() {
49
49
  var t = {}, e = this._;
50
50
  for (var r in e) t[r] = e[r].slice();
51
- return new se(t);
51
+ return new ce(t);
52
52
  },
53
53
  call: function(t, e) {
54
54
  if ((o = arguments.length - 2) > 0) for (var r = new Array(o), n = 0, o, a; n < o; ++n) r[n] = arguments[n + 2];
@@ -81,7 +81,7 @@ const Ke = {
81
81
  xml: "http://www.w3.org/XML/1998/namespace",
82
82
  xmlns: "http://www.w3.org/2000/xmlns/"
83
83
  };
84
- function ge(t) {
84
+ function we(t) {
85
85
  var e = t += "", r = e.indexOf(":");
86
86
  return r >= 0 && (e = t.slice(0, r)) !== "xmlns" && (t = t.slice(r + 1)), Ke.hasOwnProperty(e) ? { space: Ke[e], local: t } : t;
87
87
  }
@@ -97,7 +97,7 @@ function Qr(t) {
97
97
  };
98
98
  }
99
99
  function vr(t) {
100
- var e = ge(t);
100
+ var e = we(t);
101
101
  return (e.local ? Qr : Kr)(e);
102
102
  }
103
103
  function Zr() {
@@ -112,7 +112,7 @@ function Jr(t) {
112
112
  for (var e = this._groups, r = e.length, n = new Array(r), o = 0; o < r; ++o)
113
113
  for (var a = e[o], i = a.length, c = n[o] = new Array(i), l, s, u = 0; u < i; ++u)
114
114
  (l = a[u]) && (s = t.call(l, l.__data__, u, a)) && ("__data__" in l && (s.__data__ = l.__data__), c[u] = s);
115
- return new yt(n, this._parents);
115
+ return new gt(n, this._parents);
116
116
  }
117
117
  function Ar(t) {
118
118
  return t == null ? [] : Array.isArray(t) ? t : Array.from(t);
@@ -120,7 +120,7 @@ function Ar(t) {
120
120
  function tn() {
121
121
  return [];
122
122
  }
123
- function yr(t) {
123
+ function mr(t) {
124
124
  return t == null ? tn : function() {
125
125
  return this.querySelectorAll(t);
126
126
  };
@@ -131,13 +131,13 @@ function en(t) {
131
131
  };
132
132
  }
133
133
  function rn(t) {
134
- typeof t == "function" ? t = en(t) : t = yr(t);
134
+ typeof t == "function" ? t = en(t) : t = mr(t);
135
135
  for (var e = this._groups, r = e.length, n = [], o = [], a = 0; a < r; ++a)
136
136
  for (var i = e[a], c = i.length, l, s = 0; s < c; ++s)
137
137
  (l = i[s]) && (n.push(t.call(l, l.__data__, s, i)), o.push(l));
138
- return new yt(n, o);
138
+ return new gt(n, o);
139
139
  }
140
- function mr(t) {
140
+ function yr(t) {
141
141
  return function() {
142
142
  return this.matches(t);
143
143
  };
@@ -172,23 +172,23 @@ function fn(t) {
172
172
  return this.selectAll(t == null ? ln : un(typeof t == "function" ? t : gr(t)));
173
173
  }
174
174
  function hn(t) {
175
- typeof t != "function" && (t = mr(t));
175
+ typeof t != "function" && (t = yr(t));
176
176
  for (var e = this._groups, r = e.length, n = new Array(r), o = 0; o < r; ++o)
177
177
  for (var a = e[o], i = a.length, c = n[o] = [], l, s = 0; s < i; ++s)
178
178
  (l = a[s]) && t.call(l, l.__data__, s, a) && c.push(l);
179
- return new yt(n, this._parents);
179
+ return new gt(n, this._parents);
180
180
  }
181
181
  function wr(t) {
182
182
  return new Array(t.length);
183
183
  }
184
184
  function dn() {
185
- return new yt(this._enter || this._groups.map(wr), this._parents);
185
+ return new gt(this._enter || this._groups.map(wr), this._parents);
186
186
  }
187
- function he(t, e) {
187
+ function de(t, e) {
188
188
  this.ownerDocument = t.ownerDocument, this.namespaceURI = t.namespaceURI, this._next = null, this._parent = t, this.__data__ = e;
189
189
  }
190
- he.prototype = {
191
- constructor: he,
190
+ de.prototype = {
191
+ constructor: de,
192
192
  appendChild: function(t) {
193
193
  return this._parent.insertBefore(t, this._next);
194
194
  },
@@ -209,42 +209,42 @@ function pn(t) {
209
209
  }
210
210
  function vn(t, e, r, n, o, a) {
211
211
  for (var i = 0, c, l = e.length, s = a.length; i < s; ++i)
212
- (c = e[i]) ? (c.__data__ = a[i], n[i] = c) : r[i] = new he(t, a[i]);
212
+ (c = e[i]) ? (c.__data__ = a[i], n[i] = c) : r[i] = new de(t, a[i]);
213
213
  for (; i < l; ++i)
214
214
  (c = e[i]) && (o[i] = c);
215
215
  }
216
- function yn(t, e, r, n, o, a, i) {
217
- var c, l, s = /* @__PURE__ */ new Map(), u = e.length, d = a.length, p = new Array(u), g;
216
+ function mn(t, e, r, n, o, a, i) {
217
+ var c, l, s = /* @__PURE__ */ new Map(), u = e.length, d = a.length, m = new Array(u), w;
218
218
  for (c = 0; c < u; ++c)
219
- (l = e[c]) && (p[c] = g = i.call(l, l.__data__, c, e) + "", s.has(g) ? o[c] = l : s.set(g, l));
219
+ (l = e[c]) && (m[c] = w = i.call(l, l.__data__, c, e) + "", s.has(w) ? o[c] = l : s.set(w, l));
220
220
  for (c = 0; c < d; ++c)
221
- g = i.call(t, a[c], c, a) + "", (l = s.get(g)) ? (n[c] = l, l.__data__ = a[c], s.delete(g)) : r[c] = new he(t, a[c]);
221
+ w = i.call(t, a[c], c, a) + "", (l = s.get(w)) ? (n[c] = l, l.__data__ = a[c], s.delete(w)) : r[c] = new de(t, a[c]);
222
222
  for (c = 0; c < u; ++c)
223
- (l = e[c]) && s.get(p[c]) === l && (o[c] = l);
223
+ (l = e[c]) && s.get(m[c]) === l && (o[c] = l);
224
224
  }
225
- function mn(t) {
225
+ function yn(t) {
226
226
  return t.__data__;
227
227
  }
228
228
  function gn(t, e) {
229
- if (!arguments.length) return Array.from(this, mn);
230
- var r = e ? yn : vn, n = this._parents, o = this._groups;
229
+ if (!arguments.length) return Array.from(this, yn);
230
+ var r = e ? mn : vn, n = this._parents, o = this._groups;
231
231
  typeof t != "function" && (t = pn(t));
232
232
  for (var a = o.length, i = new Array(a), c = new Array(a), l = new Array(a), s = 0; s < a; ++s) {
233
- var u = n[s], d = o[s], p = d.length, g = wn(t.call(u, u && u.__data__, s, n)), R = g.length, B = c[s] = new Array(R), $ = i[s] = new Array(R), Y = l[s] = new Array(p);
234
- r(u, d, B, $, Y, g, e);
235
- for (var J = 0, j = 0, A, O; J < R; ++J)
236
- if (A = B[J]) {
237
- for (J >= j && (j = J + 1); !(O = $[j]) && ++j < R; ) ;
238
- A._next = O || null;
233
+ var u = n[s], d = o[s], m = d.length, w = wn(t.call(u, u && u.__data__, s, n)), _ = w.length, B = c[s] = new Array(_), V = i[s] = new Array(_), x = l[s] = new Array(m);
234
+ r(u, d, B, V, x, w, e);
235
+ for (var K = 0, Z = 0, et, N; K < _; ++K)
236
+ if (et = B[K]) {
237
+ for (K >= Z && (Z = K + 1); !(N = V[Z]) && ++Z < _; ) ;
238
+ et._next = N || null;
239
239
  }
240
240
  }
241
- return i = new yt(i, n), i._enter = c, i._exit = l, i;
241
+ return i = new gt(i, n), i._enter = c, i._exit = l, i;
242
242
  }
243
243
  function wn(t) {
244
244
  return typeof t == "object" && "length" in t ? t : Array.from(t);
245
245
  }
246
246
  function xn() {
247
- return new yt(this._exit || this._groups.map(wr), this._parents);
247
+ return new gt(this._exit || this._groups.map(wr), this._parents);
248
248
  }
249
249
  function En(t, e, r) {
250
250
  var n = this.enter(), o = this, a = this.exit();
@@ -252,11 +252,11 @@ function En(t, e, r) {
252
252
  }
253
253
  function bn(t) {
254
254
  for (var e = t.selection ? t.selection() : t, r = this._groups, n = e._groups, o = r.length, a = n.length, i = Math.min(o, a), c = new Array(o), l = 0; l < i; ++l)
255
- for (var s = r[l], u = n[l], d = s.length, p = c[l] = new Array(d), g, R = 0; R < d; ++R)
256
- (g = s[R] || u[R]) && (p[R] = g);
255
+ for (var s = r[l], u = n[l], d = s.length, m = c[l] = new Array(d), w, _ = 0; _ < d; ++_)
256
+ (w = s[_] || u[_]) && (m[_] = w);
257
257
  for (; l < o; ++l)
258
258
  c[l] = r[l];
259
- return new yt(c, this._parents);
259
+ return new gt(c, this._parents);
260
260
  }
261
261
  function Mn() {
262
262
  for (var t = this._groups, e = -1, r = t.length; ++e < r; )
@@ -266,15 +266,15 @@ function Mn() {
266
266
  }
267
267
  function Fn(t) {
268
268
  t || (t = Cn);
269
- function e(d, p) {
270
- return d && p ? t(d.__data__, p.__data__) : !d - !p;
269
+ function e(d, m) {
270
+ return d && m ? t(d.__data__, m.__data__) : !d - !m;
271
271
  }
272
272
  for (var r = this._groups, n = r.length, o = new Array(n), a = 0; a < n; ++a) {
273
273
  for (var i = r[a], c = i.length, l = o[a] = new Array(c), s, u = 0; u < c; ++u)
274
274
  (s = i[u]) && (l[u] = s);
275
275
  l.sort(e);
276
276
  }
277
- return new yt(o, this._parents).order();
277
+ return new gt(o, this._parents).order();
278
278
  }
279
279
  function Cn(t, e) {
280
280
  return t < e ? -1 : t > e ? 1 : t >= e ? 0 : NaN;
@@ -341,7 +341,7 @@ function Un(t, e) {
341
341
  };
342
342
  }
343
343
  function In(t, e) {
344
- var r = ge(t);
344
+ var r = we(t);
345
345
  if (arguments.length < 2) {
346
346
  var n = this.node();
347
347
  return r.local ? n.getAttributeNS(r.space, r.local) : n.getAttribute(r);
@@ -368,9 +368,9 @@ function jn(t, e, r) {
368
368
  };
369
369
  }
370
370
  function Gn(t, e, r) {
371
- return arguments.length > 1 ? this.each((e == null ? kn : typeof e == "function" ? jn : zn)(t, e, r ?? "")) : jt(this.node(), t);
371
+ return arguments.length > 1 ? this.each((e == null ? kn : typeof e == "function" ? jn : zn)(t, e, r ?? "")) : Gt(this.node(), t);
372
372
  }
373
- function jt(t, e) {
373
+ function Gt(t, e) {
374
374
  return t.style.getPropertyValue(e) || xr(t).getComputedStyle(t, null).getPropertyValue(e);
375
375
  }
376
376
  function On(t) {
@@ -515,12 +515,12 @@ function vo() {
515
515
  var t = this.cloneNode(!1), e = this.parentNode;
516
516
  return e ? e.insertBefore(t, this.nextSibling) : t;
517
517
  }
518
- function yo() {
518
+ function mo() {
519
519
  var t = this.cloneNode(!0), e = this.parentNode;
520
520
  return e ? e.insertBefore(t, this.nextSibling) : t;
521
521
  }
522
- function mo(t) {
523
- return this.select(t ? yo : vo);
522
+ function yo(t) {
523
+ return this.select(t ? mo : vo);
524
524
  }
525
525
  function go(t) {
526
526
  return arguments.length ? this.property("__data__", t) : this.node().__data__;
@@ -597,17 +597,17 @@ function* Ro() {
597
597
  (i = n[o]) && (yield i);
598
598
  }
599
599
  var _r = [null];
600
- function yt(t, e) {
600
+ function gt(t, e) {
601
601
  this._groups = t, this._parents = e;
602
602
  }
603
- function At() {
604
- return new yt([[document.documentElement]], _r);
603
+ function te() {
604
+ return new gt([[document.documentElement]], _r);
605
605
  }
606
606
  function Lo() {
607
607
  return this;
608
608
  }
609
- yt.prototype = At.prototype = {
610
- constructor: yt,
609
+ gt.prototype = te.prototype = {
610
+ constructor: gt,
611
611
  select: Jr,
612
612
  selectAll: rn,
613
613
  selectChild: sn,
@@ -638,21 +638,21 @@ yt.prototype = At.prototype = {
638
638
  append: lo,
639
639
  insert: fo,
640
640
  remove: po,
641
- clone: mo,
641
+ clone: yo,
642
642
  datum: go,
643
643
  on: Mo,
644
644
  dispatch: _o,
645
645
  [Symbol.iterator]: Ro
646
646
  };
647
647
  function at(t) {
648
- return typeof t == "string" ? new yt([[document.querySelector(t)]], [document.documentElement]) : new yt([[t]], _r);
648
+ return typeof t == "string" ? new gt([[document.querySelector(t)]], [document.documentElement]) : new gt([[t]], _r);
649
649
  }
650
650
  function Yo(t) {
651
651
  let e;
652
652
  for (; e = t.sourceEvent; ) t = e;
653
653
  return t;
654
654
  }
655
- function Nt(t, e) {
655
+ function Xt(t, e) {
656
656
  if (t = Yo(t), e === void 0 && (e = t.currentTarget), e) {
657
657
  var r = e.ownerSVGElement || e;
658
658
  if (r.createSVGPoint) {
@@ -688,9 +688,9 @@ function Rr(t, e) {
688
688
  for (var n in e) r[n] = e[n];
689
689
  return r;
690
690
  }
691
- function te() {
691
+ function ee() {
692
692
  }
693
- var Kt = 0.7, de = 1 / Kt, zt = "\\s*([+-]?\\d+)\\s*", Qt = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", Ft = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", Po = /^#([0-9a-f]{3,8})$/, No = new RegExp(`^rgb\\(${zt},${zt},${zt}\\)$`), $o = new RegExp(`^rgb\\(${Ft},${Ft},${Ft}\\)$`), Xo = new RegExp(`^rgba\\(${zt},${zt},${zt},${Qt}\\)$`), So = new RegExp(`^rgba\\(${Ft},${Ft},${Ft},${Qt}\\)$`), Uo = new RegExp(`^hsl\\(${Qt},${Ft},${Ft}\\)$`), Io = new RegExp(`^hsla\\(${Qt},${Ft},${Ft},${Qt}\\)$`), Qe = {
693
+ var Qt = 0.7, pe = 1 / Qt, jt = "\\s*([+-]?\\d+)\\s*", Zt = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*", Ct = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*", Po = /^#([0-9a-f]{3,8})$/, No = new RegExp(`^rgb\\(${jt},${jt},${jt}\\)$`), $o = new RegExp(`^rgb\\(${Ct},${Ct},${Ct}\\)$`), Xo = new RegExp(`^rgba\\(${jt},${jt},${jt},${Zt}\\)$`), So = new RegExp(`^rgba\\(${Ct},${Ct},${Ct},${Zt}\\)$`), Uo = new RegExp(`^hsl\\(${Zt},${Ct},${Ct}\\)$`), Io = new RegExp(`^hsla\\(${Zt},${Ct},${Ct},${Zt}\\)$`), Qe = {
694
694
  aliceblue: 15792383,
695
695
  antiquewhite: 16444375,
696
696
  aqua: 65535,
@@ -840,7 +840,7 @@ var Kt = 0.7, de = 1 / Kt, zt = "\\s*([+-]?\\d+)\\s*", Qt = "\\s*([+-]?(?:\\d*\\
840
840
  yellow: 16776960,
841
841
  yellowgreen: 10145074
842
842
  };
843
- Ge(te, Zt, {
843
+ Ge(ee, Jt, {
844
844
  copy(t) {
845
845
  return Object.assign(new this.constructor(), this, t);
846
846
  },
@@ -867,37 +867,37 @@ function zo() {
867
867
  function Je() {
868
868
  return this.rgb().formatRgb();
869
869
  }
870
- function Zt(t) {
870
+ function Jt(t) {
871
871
  var e, r;
872
- return t = (t + "").trim().toLowerCase(), (e = Po.exec(t)) ? (r = e[1].length, e = parseInt(e[1], 16), r === 6 ? Ae(e) : r === 3 ? new ft(e >> 8 & 15 | e >> 4 & 240, e >> 4 & 15 | e & 240, (e & 15) << 4 | e & 15, 1) : r === 8 ? re(e >> 24 & 255, e >> 16 & 255, e >> 8 & 255, (e & 255) / 255) : r === 4 ? re(e >> 12 & 15 | e >> 8 & 240, e >> 8 & 15 | e >> 4 & 240, e >> 4 & 15 | e & 240, ((e & 15) << 4 | e & 15) / 255) : null) : (e = No.exec(t)) ? new ft(e[1], e[2], e[3], 1) : (e = $o.exec(t)) ? new ft(e[1] * 255 / 100, e[2] * 255 / 100, e[3] * 255 / 100, 1) : (e = Xo.exec(t)) ? re(e[1], e[2], e[3], e[4]) : (e = So.exec(t)) ? re(e[1] * 255 / 100, e[2] * 255 / 100, e[3] * 255 / 100, e[4]) : (e = Uo.exec(t)) ? rr(e[1], e[2] / 100, e[3] / 100, 1) : (e = Io.exec(t)) ? rr(e[1], e[2] / 100, e[3] / 100, e[4]) : Qe.hasOwnProperty(t) ? Ae(Qe[t]) : t === "transparent" ? new ft(NaN, NaN, NaN, 0) : null;
872
+ return t = (t + "").trim().toLowerCase(), (e = Po.exec(t)) ? (r = e[1].length, e = parseInt(e[1], 16), r === 6 ? Ae(e) : r === 3 ? new ht(e >> 8 & 15 | e >> 4 & 240, e >> 4 & 15 | e & 240, (e & 15) << 4 | e & 15, 1) : r === 8 ? ne(e >> 24 & 255, e >> 16 & 255, e >> 8 & 255, (e & 255) / 255) : r === 4 ? ne(e >> 12 & 15 | e >> 8 & 240, e >> 8 & 15 | e >> 4 & 240, e >> 4 & 15 | e & 240, ((e & 15) << 4 | e & 15) / 255) : null) : (e = No.exec(t)) ? new ht(e[1], e[2], e[3], 1) : (e = $o.exec(t)) ? new ht(e[1] * 255 / 100, e[2] * 255 / 100, e[3] * 255 / 100, 1) : (e = Xo.exec(t)) ? ne(e[1], e[2], e[3], e[4]) : (e = So.exec(t)) ? ne(e[1] * 255 / 100, e[2] * 255 / 100, e[3] * 255 / 100, e[4]) : (e = Uo.exec(t)) ? rr(e[1], e[2] / 100, e[3] / 100, 1) : (e = Io.exec(t)) ? rr(e[1], e[2] / 100, e[3] / 100, e[4]) : Qe.hasOwnProperty(t) ? Ae(Qe[t]) : t === "transparent" ? new ht(NaN, NaN, NaN, 0) : null;
873
873
  }
874
874
  function Ae(t) {
875
- return new ft(t >> 16 & 255, t >> 8 & 255, t & 255, 1);
875
+ return new ht(t >> 16 & 255, t >> 8 & 255, t & 255, 1);
876
876
  }
877
- function re(t, e, r, n) {
878
- return n <= 0 && (t = e = r = NaN), new ft(t, e, r, n);
877
+ function ne(t, e, r, n) {
878
+ return n <= 0 && (t = e = r = NaN), new ht(t, e, r, n);
879
879
  }
880
880
  function jo(t) {
881
- return t instanceof te || (t = Zt(t)), t ? (t = t.rgb(), new ft(t.r, t.g, t.b, t.opacity)) : new ft();
881
+ return t instanceof ee || (t = Jt(t)), t ? (t = t.rgb(), new ht(t.r, t.g, t.b, t.opacity)) : new ht();
882
882
  }
883
883
  function Pe(t, e, r, n) {
884
- return arguments.length === 1 ? jo(t) : new ft(t, e, r, n ?? 1);
884
+ return arguments.length === 1 ? jo(t) : new ht(t, e, r, n ?? 1);
885
885
  }
886
- function ft(t, e, r, n) {
886
+ function ht(t, e, r, n) {
887
887
  this.r = +t, this.g = +e, this.b = +r, this.opacity = +n;
888
888
  }
889
- Ge(ft, Pe, Rr(te, {
889
+ Ge(ht, Pe, Rr(ee, {
890
890
  brighter(t) {
891
- return t = t == null ? de : Math.pow(de, t), new ft(this.r * t, this.g * t, this.b * t, this.opacity);
891
+ return t = t == null ? pe : Math.pow(pe, t), new ht(this.r * t, this.g * t, this.b * t, this.opacity);
892
892
  },
893
893
  darker(t) {
894
- return t = t == null ? Kt : Math.pow(Kt, t), new ft(this.r * t, this.g * t, this.b * t, this.opacity);
894
+ return t = t == null ? Qt : Math.pow(Qt, t), new ht(this.r * t, this.g * t, this.b * t, this.opacity);
895
895
  },
896
896
  rgb() {
897
897
  return this;
898
898
  },
899
899
  clamp() {
900
- return new ft(St(this.r), St(this.g), St(this.b), pe(this.opacity));
900
+ return new ht(It(this.r), It(this.g), It(this.b), ve(this.opacity));
901
901
  },
902
902
  displayable() {
903
903
  return -0.5 <= this.r && this.r < 255.5 && -0.5 <= this.g && this.g < 255.5 && -0.5 <= this.b && this.b < 255.5 && 0 <= this.opacity && this.opacity <= 1;
@@ -910,51 +910,51 @@ Ge(ft, Pe, Rr(te, {
910
910
  toString: er
911
911
  }));
912
912
  function tr() {
913
- return `#${Xt(this.r)}${Xt(this.g)}${Xt(this.b)}`;
913
+ return `#${Ut(this.r)}${Ut(this.g)}${Ut(this.b)}`;
914
914
  }
915
915
  function Go() {
916
- return `#${Xt(this.r)}${Xt(this.g)}${Xt(this.b)}${Xt((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;
916
+ return `#${Ut(this.r)}${Ut(this.g)}${Ut(this.b)}${Ut((isNaN(this.opacity) ? 1 : this.opacity) * 255)}`;
917
917
  }
918
918
  function er() {
919
- const t = pe(this.opacity);
920
- return `${t === 1 ? "rgb(" : "rgba("}${St(this.r)}, ${St(this.g)}, ${St(this.b)}${t === 1 ? ")" : `, ${t})`}`;
919
+ const t = ve(this.opacity);
920
+ return `${t === 1 ? "rgb(" : "rgba("}${It(this.r)}, ${It(this.g)}, ${It(this.b)}${t === 1 ? ")" : `, ${t})`}`;
921
921
  }
922
- function pe(t) {
922
+ function ve(t) {
923
923
  return isNaN(t) ? 1 : Math.max(0, Math.min(1, t));
924
924
  }
925
- function St(t) {
925
+ function It(t) {
926
926
  return Math.max(0, Math.min(255, Math.round(t) || 0));
927
927
  }
928
- function Xt(t) {
929
- return t = St(t), (t < 16 ? "0" : "") + t.toString(16);
928
+ function Ut(t) {
929
+ return t = It(t), (t < 16 ? "0" : "") + t.toString(16);
930
930
  }
931
931
  function rr(t, e, r, n) {
932
- return n <= 0 ? t = e = r = NaN : r <= 0 || r >= 1 ? t = e = NaN : e <= 0 && (t = NaN), new wt(t, e, r, n);
932
+ return n <= 0 ? t = e = r = NaN : r <= 0 || r >= 1 ? t = e = NaN : e <= 0 && (t = NaN), new Mt(t, e, r, n);
933
933
  }
934
934
  function Lr(t) {
935
- if (t instanceof wt) return new wt(t.h, t.s, t.l, t.opacity);
936
- if (t instanceof te || (t = Zt(t)), !t) return new wt();
937
- if (t instanceof wt) return t;
935
+ if (t instanceof Mt) return new Mt(t.h, t.s, t.l, t.opacity);
936
+ if (t instanceof ee || (t = Jt(t)), !t) return new Mt();
937
+ if (t instanceof Mt) return t;
938
938
  t = t.rgb();
939
939
  var e = t.r / 255, r = t.g / 255, n = t.b / 255, o = Math.min(e, r, n), a = Math.max(e, r, n), i = NaN, c = a - o, l = (a + o) / 2;
940
- return c ? (e === a ? i = (r - n) / c + (r < n) * 6 : r === a ? i = (n - e) / c + 2 : i = (e - r) / c + 4, c /= l < 0.5 ? a + o : 2 - a - o, i *= 60) : c = l > 0 && l < 1 ? 0 : i, new wt(i, c, l, t.opacity);
940
+ return c ? (e === a ? i = (r - n) / c + (r < n) * 6 : r === a ? i = (n - e) / c + 2 : i = (e - r) / c + 4, c /= l < 0.5 ? a + o : 2 - a - o, i *= 60) : c = l > 0 && l < 1 ? 0 : i, new Mt(i, c, l, t.opacity);
941
941
  }
942
942
  function Oo(t, e, r, n) {
943
- return arguments.length === 1 ? Lr(t) : new wt(t, e, r, n ?? 1);
943
+ return arguments.length === 1 ? Lr(t) : new Mt(t, e, r, n ?? 1);
944
944
  }
945
- function wt(t, e, r, n) {
945
+ function Mt(t, e, r, n) {
946
946
  this.h = +t, this.s = +e, this.l = +r, this.opacity = +n;
947
947
  }
948
- Ge(wt, Oo, Rr(te, {
948
+ Ge(Mt, Oo, Rr(ee, {
949
949
  brighter(t) {
950
- return t = t == null ? de : Math.pow(de, t), new wt(this.h, this.s, this.l * t, this.opacity);
950
+ return t = t == null ? pe : Math.pow(pe, t), new Mt(this.h, this.s, this.l * t, this.opacity);
951
951
  },
952
952
  darker(t) {
953
- return t = t == null ? Kt : Math.pow(Kt, t), new wt(this.h, this.s, this.l * t, this.opacity);
953
+ return t = t == null ? Qt : Math.pow(Qt, t), new Mt(this.h, this.s, this.l * t, this.opacity);
954
954
  },
955
955
  rgb() {
956
956
  var t = this.h % 360 + (this.h < 0) * 360, e = isNaN(t) || isNaN(this.s) ? 0 : this.s, r = this.l, n = r + (r < 0.5 ? r : 1 - r) * e, o = 2 * r - n;
957
- return new ft(
957
+ return new ht(
958
958
  Fe(t >= 240 ? t - 240 : t + 120, o, n),
959
959
  Fe(t, o, n),
960
960
  Fe(t < 120 ? t + 240 : t - 120, o, n),
@@ -962,20 +962,20 @@ Ge(wt, Oo, Rr(te, {
962
962
  );
963
963
  },
964
964
  clamp() {
965
- return new wt(nr(this.h), ne(this.s), ne(this.l), pe(this.opacity));
965
+ return new Mt(nr(this.h), oe(this.s), oe(this.l), ve(this.opacity));
966
966
  },
967
967
  displayable() {
968
968
  return (0 <= this.s && this.s <= 1 || isNaN(this.s)) && 0 <= this.l && this.l <= 1 && 0 <= this.opacity && this.opacity <= 1;
969
969
  },
970
970
  formatHsl() {
971
- const t = pe(this.opacity);
972
- return `${t === 1 ? "hsl(" : "hsla("}${nr(this.h)}, ${ne(this.s) * 100}%, ${ne(this.l) * 100}%${t === 1 ? ")" : `, ${t})`}`;
971
+ const t = ve(this.opacity);
972
+ return `${t === 1 ? "hsl(" : "hsla("}${nr(this.h)}, ${oe(this.s) * 100}%, ${oe(this.l) * 100}%${t === 1 ? ")" : `, ${t})`}`;
973
973
  }
974
974
  }));
975
975
  function nr(t) {
976
976
  return t = (t || 0) % 360, t < 0 ? t + 360 : t;
977
977
  }
978
- function ne(t) {
978
+ function oe(t) {
979
979
  return Math.max(0, Math.min(1, t || 0));
980
980
  }
981
981
  function Fe(t, e, r) {
@@ -1011,7 +1011,7 @@ const or = (function t(e) {
1011
1011
  }
1012
1012
  return n.gamma = t, n;
1013
1013
  })(1);
1014
- function Dt(t, e) {
1014
+ function Pt(t, e) {
1015
1015
  return t = +t, e = +e, function(r) {
1016
1016
  return t * (1 - r) + e * r;
1017
1017
  };
@@ -1030,7 +1030,7 @@ function qo(t) {
1030
1030
  function Ko(t, e) {
1031
1031
  var r = Ne.lastIndex = Ce.lastIndex = 0, n, o, a, i = -1, c = [], l = [];
1032
1032
  for (t = t + "", e = e + ""; (n = Ne.exec(t)) && (o = Ce.exec(e)); )
1033
- (a = o.index) > r && (a = e.slice(r, a), c[i] ? c[i] += a : c[++i] = a), (n = n[0]) === (o = o[0]) ? c[i] ? c[i] += o : c[++i] = o : (c[++i] = null, l.push({ i, x: Dt(n, o) })), r = Ce.lastIndex;
1033
+ (a = o.index) > r && (a = e.slice(r, a), c[i] ? c[i] += a : c[++i] = a), (n = n[0]) === (o = o[0]) ? c[i] ? c[i] += o : c[++i] = o : (c[++i] = null, l.push({ i, x: Pt(n, o) })), r = Ce.lastIndex;
1034
1034
  return r < e.length && (a = e.slice(r), c[i] ? c[i] += a : c[++i] = a), c.length < 2 ? l[0] ? qo(l[0].x) : Ho(e) : (e = l.length, function(s) {
1035
1035
  for (var u = 0, d; u < e; ++u) c[(d = l[u]).i] = d.x(s);
1036
1036
  return c.join("");
@@ -1055,40 +1055,40 @@ function Br(t, e, r, n, o, a) {
1055
1055
  scaleY: c
1056
1056
  };
1057
1057
  }
1058
- var oe;
1058
+ var ie;
1059
1059
  function Qo(t) {
1060
1060
  const e = new (typeof DOMMatrix == "function" ? DOMMatrix : WebKitCSSMatrix)(t + "");
1061
1061
  return e.isIdentity ? $e : Br(e.a, e.b, e.c, e.d, e.e, e.f);
1062
1062
  }
1063
1063
  function Zo(t) {
1064
- return t == null || (oe || (oe = document.createElementNS("http://www.w3.org/2000/svg", "g")), oe.setAttribute("transform", t), !(t = oe.transform.baseVal.consolidate())) ? $e : (t = t.matrix, Br(t.a, t.b, t.c, t.d, t.e, t.f));
1064
+ return t == null || (ie || (ie = document.createElementNS("http://www.w3.org/2000/svg", "g")), ie.setAttribute("transform", t), !(t = ie.transform.baseVal.consolidate())) ? $e : (t = t.matrix, Br(t.a, t.b, t.c, t.d, t.e, t.f));
1065
1065
  }
1066
1066
  function Pr(t, e, r, n) {
1067
1067
  function o(s) {
1068
1068
  return s.length ? s.pop() + " " : "";
1069
1069
  }
1070
- function a(s, u, d, p, g, R) {
1071
- if (s !== d || u !== p) {
1072
- var B = g.push("translate(", null, e, null, r);
1073
- R.push({ i: B - 4, x: Dt(s, d) }, { i: B - 2, x: Dt(u, p) });
1074
- } else (d || p) && g.push("translate(" + d + e + p + r);
1070
+ function a(s, u, d, m, w, _) {
1071
+ if (s !== d || u !== m) {
1072
+ var B = w.push("translate(", null, e, null, r);
1073
+ _.push({ i: B - 4, x: Pt(s, d) }, { i: B - 2, x: Pt(u, m) });
1074
+ } else (d || m) && w.push("translate(" + d + e + m + r);
1075
1075
  }
1076
- function i(s, u, d, p) {
1077
- s !== u ? (s - u > 180 ? u += 360 : u - s > 180 && (s += 360), p.push({ i: d.push(o(d) + "rotate(", null, n) - 2, x: Dt(s, u) })) : u && d.push(o(d) + "rotate(" + u + n);
1076
+ function i(s, u, d, m) {
1077
+ s !== u ? (s - u > 180 ? u += 360 : u - s > 180 && (s += 360), m.push({ i: d.push(o(d) + "rotate(", null, n) - 2, x: Pt(s, u) })) : u && d.push(o(d) + "rotate(" + u + n);
1078
1078
  }
1079
- function c(s, u, d, p) {
1080
- s !== u ? p.push({ i: d.push(o(d) + "skewX(", null, n) - 2, x: Dt(s, u) }) : u && d.push(o(d) + "skewX(" + u + n);
1079
+ function c(s, u, d, m) {
1080
+ s !== u ? m.push({ i: d.push(o(d) + "skewX(", null, n) - 2, x: Pt(s, u) }) : u && d.push(o(d) + "skewX(" + u + n);
1081
1081
  }
1082
- function l(s, u, d, p, g, R) {
1083
- if (s !== d || u !== p) {
1084
- var B = g.push(o(g) + "scale(", null, ",", null, ")");
1085
- R.push({ i: B - 4, x: Dt(s, d) }, { i: B - 2, x: Dt(u, p) });
1086
- } else (d !== 1 || p !== 1) && g.push(o(g) + "scale(" + d + "," + p + ")");
1082
+ function l(s, u, d, m, w, _) {
1083
+ if (s !== d || u !== m) {
1084
+ var B = w.push(o(w) + "scale(", null, ",", null, ")");
1085
+ _.push({ i: B - 4, x: Pt(s, d) }, { i: B - 2, x: Pt(u, m) });
1086
+ } else (d !== 1 || m !== 1) && w.push(o(w) + "scale(" + d + "," + m + ")");
1087
1087
  }
1088
1088
  return function(s, u) {
1089
- var d = [], p = [];
1090
- return s = t(s), u = t(u), a(s.translateX, s.translateY, u.translateX, u.translateY, d, p), i(s.rotate, u.rotate, d, p), c(s.skewX, u.skewX, d, p), l(s.scaleX, s.scaleY, u.scaleX, u.scaleY, d, p), s = u = null, function(g) {
1091
- for (var R = -1, B = p.length, $; ++R < B; ) d[($ = p[R]).i] = $.x(g);
1089
+ var d = [], m = [];
1090
+ return s = t(s), u = t(u), a(s.translateX, s.translateY, u.translateX, u.translateY, d, m), i(s.rotate, u.rotate, d, m), c(s.skewX, u.skewX, d, m), l(s.scaleX, s.scaleY, u.scaleX, u.scaleY, d, m), s = u = null, function(w) {
1091
+ for (var _ = -1, B = m.length, V; ++_ < B; ) d[(V = m[_]).i] = V.x(w);
1092
1092
  return d.join("");
1093
1093
  };
1094
1094
  };
@@ -1105,97 +1105,97 @@ function ri(t) {
1105
1105
  }
1106
1106
  const ni = (function t(e, r, n) {
1107
1107
  function o(a, i) {
1108
- var c = a[0], l = a[1], s = a[2], u = i[0], d = i[1], p = i[2], g = u - c, R = d - l, B = g * g + R * R, $, Y;
1108
+ var c = a[0], l = a[1], s = a[2], u = i[0], d = i[1], m = i[2], w = u - c, _ = d - l, B = w * w + _ * _, V, x;
1109
1109
  if (B < ti)
1110
- Y = Math.log(p / s) / e, $ = function(et) {
1110
+ x = Math.log(m / s) / e, V = function(nt) {
1111
1111
  return [
1112
- c + et * g,
1113
- l + et * R,
1114
- s * Math.exp(e * et * Y)
1112
+ c + nt * w,
1113
+ l + nt * _,
1114
+ s * Math.exp(e * nt * x)
1115
1115
  ];
1116
1116
  };
1117
1117
  else {
1118
- var J = Math.sqrt(B), j = (p * p - s * s + n * B) / (2 * s * r * J), A = (p * p - s * s - n * B) / (2 * p * r * J), O = Math.log(Math.sqrt(j * j + 1) - j), U = Math.log(Math.sqrt(A * A + 1) - A);
1119
- Y = (U - O) / e, $ = function(et) {
1120
- var nt = et * Y, G = ar(O), F = s / (r * J) * (G * ri(e * nt + O) - ei(O));
1118
+ var K = Math.sqrt(B), Z = (m * m - s * s + n * B) / (2 * s * r * K), et = (m * m - s * s - n * B) / (2 * m * r * K), N = Math.log(Math.sqrt(Z * Z + 1) - Z), $ = Math.log(Math.sqrt(et * et + 1) - et);
1119
+ x = ($ - N) / e, V = function(nt) {
1120
+ var it = nt * x, A = ar(N), R = s / (r * K) * (A * ri(e * it + N) - ei(N));
1121
1121
  return [
1122
- c + F * g,
1123
- l + F * R,
1124
- s * G / ar(e * nt + O)
1122
+ c + R * w,
1123
+ l + R * _,
1124
+ s * A / ar(e * it + N)
1125
1125
  ];
1126
1126
  };
1127
1127
  }
1128
- return $.duration = Y * 1e3 * e / Math.SQRT2, $;
1128
+ return V.duration = x * 1e3 * e / Math.SQRT2, V;
1129
1129
  }
1130
1130
  return o.rho = function(a) {
1131
1131
  var i = Math.max(1e-3, +a), c = i * i, l = c * c;
1132
1132
  return t(i, c, l);
1133
1133
  }, o;
1134
1134
  })(Math.SQRT2, 2, 4);
1135
- var Gt = 0, Wt = 0, Tt = 0, Nr = 1e3, ve, Ht, ye = 0, Ut = 0, we = 0, Jt = typeof performance == "object" && performance.now ? performance : Date, $r = typeof window == "object" && window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : function(t) {
1135
+ var Ot = 0, Ht = 0, Vt = 0, Nr = 1e3, me, qt, ye = 0, kt = 0, xe = 0, At = typeof performance == "object" && performance.now ? performance : Date, $r = typeof window == "object" && window.requestAnimationFrame ? window.requestAnimationFrame.bind(window) : function(t) {
1136
1136
  setTimeout(t, 17);
1137
1137
  };
1138
1138
  function Oe() {
1139
- return Ut || ($r(oi), Ut = Jt.now() + we);
1139
+ return kt || ($r(oi), kt = At.now() + xe);
1140
1140
  }
1141
1141
  function oi() {
1142
- Ut = 0;
1142
+ kt = 0;
1143
1143
  }
1144
- function me() {
1144
+ function ge() {
1145
1145
  this._call = this._time = this._next = null;
1146
1146
  }
1147
- me.prototype = Xr.prototype = {
1148
- constructor: me,
1147
+ ge.prototype = Xr.prototype = {
1148
+ constructor: ge,
1149
1149
  restart: function(t, e, r) {
1150
1150
  if (typeof t != "function") throw new TypeError("callback is not a function");
1151
- r = (r == null ? Oe() : +r) + (e == null ? 0 : +e), !this._next && Ht !== this && (Ht ? Ht._next = this : ve = this, Ht = this), this._call = t, this._time = r, Xe();
1151
+ r = (r == null ? Oe() : +r) + (e == null ? 0 : +e), !this._next && qt !== this && (qt ? qt._next = this : me = this, qt = this), this._call = t, this._time = r, Xe();
1152
1152
  },
1153
1153
  stop: function() {
1154
1154
  this._call && (this._call = null, this._time = 1 / 0, Xe());
1155
1155
  }
1156
1156
  };
1157
1157
  function Xr(t, e, r) {
1158
- var n = new me();
1158
+ var n = new ge();
1159
1159
  return n.restart(t, e, r), n;
1160
1160
  }
1161
1161
  function ii() {
1162
- Oe(), ++Gt;
1163
- for (var t = ve, e; t; )
1164
- (e = Ut - t._time) >= 0 && t._call.call(void 0, e), t = t._next;
1165
- --Gt;
1162
+ Oe(), ++Ot;
1163
+ for (var t = me, e; t; )
1164
+ (e = kt - t._time) >= 0 && t._call.call(void 0, e), t = t._next;
1165
+ --Ot;
1166
1166
  }
1167
1167
  function sr() {
1168
- Ut = (ye = Jt.now()) + we, Gt = Wt = 0;
1168
+ kt = (ye = At.now()) + xe, Ot = Ht = 0;
1169
1169
  try {
1170
1170
  ii();
1171
1171
  } finally {
1172
- Gt = 0, si(), Ut = 0;
1172
+ Ot = 0, si(), kt = 0;
1173
1173
  }
1174
1174
  }
1175
1175
  function ai() {
1176
- var t = Jt.now(), e = t - ye;
1177
- e > Nr && (we -= e, ye = t);
1176
+ var t = At.now(), e = t - ye;
1177
+ e > Nr && (xe -= e, ye = t);
1178
1178
  }
1179
1179
  function si() {
1180
- for (var t, e = ve, r, n = 1 / 0; e; )
1181
- e._call ? (n > e._time && (n = e._time), t = e, e = e._next) : (r = e._next, e._next = null, e = t ? t._next = r : ve = r);
1182
- Ht = t, Xe(n);
1180
+ for (var t, e = me, r, n = 1 / 0; e; )
1181
+ e._call ? (n > e._time && (n = e._time), t = e, e = e._next) : (r = e._next, e._next = null, e = t ? t._next = r : me = r);
1182
+ qt = t, Xe(n);
1183
1183
  }
1184
1184
  function Xe(t) {
1185
- if (!Gt) {
1186
- Wt && (Wt = clearTimeout(Wt));
1187
- var e = t - Ut;
1188
- e > 24 ? (t < 1 / 0 && (Wt = setTimeout(sr, t - Jt.now() - we)), Tt && (Tt = clearInterval(Tt))) : (Tt || (ye = Jt.now(), Tt = setInterval(ai, Nr)), Gt = 1, $r(sr));
1185
+ if (!Ot) {
1186
+ Ht && (Ht = clearTimeout(Ht));
1187
+ var e = t - kt;
1188
+ e > 24 ? (t < 1 / 0 && (Ht = setTimeout(sr, t - At.now() - xe)), Vt && (Vt = clearInterval(Vt))) : (Vt || (ye = At.now(), Vt = setInterval(ai, Nr)), Ot = 1, $r(sr));
1189
1189
  }
1190
1190
  }
1191
1191
  function cr(t, e, r) {
1192
- var n = new me();
1192
+ var n = new ge();
1193
1193
  return e = e == null ? 0 : +e, n.restart((o) => {
1194
1194
  n.stop(), t(o + e);
1195
1195
  }, e, r), n;
1196
1196
  }
1197
- var ci = ke("start", "end", "cancel", "interrupt"), li = [], Sr = 0, lr = 1, Se = 2, ce = 3, ur = 4, Ue = 5, le = 6;
1198
- function xe(t, e, r, n, o, a) {
1197
+ var ci = ke("start", "end", "cancel", "interrupt"), li = [], Sr = 0, lr = 1, Se = 2, le = 3, ur = 4, Ue = 5, ue = 6;
1198
+ function Ee(t, e, r, n, o, a) {
1199
1199
  var i = t.__transition;
1200
1200
  if (!i) t.__transition = {};
1201
1201
  else if (r in i) return;
@@ -1216,16 +1216,16 @@ function xe(t, e, r, n, o, a) {
1216
1216
  });
1217
1217
  }
1218
1218
  function Te(t, e) {
1219
- var r = xt(t, e);
1219
+ var r = Ft(t, e);
1220
1220
  if (r.state > Sr) throw new Error("too late; already scheduled");
1221
1221
  return r;
1222
1222
  }
1223
- function Ct(t, e) {
1224
- var r = xt(t, e);
1225
- if (r.state > ce) throw new Error("too late; already running");
1223
+ function _t(t, e) {
1224
+ var r = Ft(t, e);
1225
+ if (r.state > le) throw new Error("too late; already running");
1226
1226
  return r;
1227
1227
  }
1228
- function xt(t, e) {
1228
+ function Ft(t, e) {
1229
1229
  var r = t.__transition;
1230
1230
  if (!r || !(r = r[e])) throw new Error("transition not found");
1231
1231
  return r;
@@ -1237,33 +1237,33 @@ function ui(t, e, r) {
1237
1237
  r.state = lr, r.timer.restart(i, r.delay, r.time), r.delay <= s && i(s - r.delay);
1238
1238
  }
1239
1239
  function i(s) {
1240
- var u, d, p, g;
1240
+ var u, d, m, w;
1241
1241
  if (r.state !== lr) return l();
1242
1242
  for (u in n)
1243
- if (g = n[u], g.name === r.name) {
1244
- if (g.state === ce) return cr(i);
1245
- g.state === ur ? (g.state = le, g.timer.stop(), g.on.call("interrupt", t, t.__data__, g.index, g.group), delete n[u]) : +u < e && (g.state = le, g.timer.stop(), g.on.call("cancel", t, t.__data__, g.index, g.group), delete n[u]);
1243
+ if (w = n[u], w.name === r.name) {
1244
+ if (w.state === le) return cr(i);
1245
+ w.state === ur ? (w.state = ue, w.timer.stop(), w.on.call("interrupt", t, t.__data__, w.index, w.group), delete n[u]) : +u < e && (w.state = ue, w.timer.stop(), w.on.call("cancel", t, t.__data__, w.index, w.group), delete n[u]);
1246
1246
  }
1247
1247
  if (cr(function() {
1248
- r.state === ce && (r.state = ur, r.timer.restart(c, r.delay, r.time), c(s));
1248
+ r.state === le && (r.state = ur, r.timer.restart(c, r.delay, r.time), c(s));
1249
1249
  }), r.state = Se, r.on.call("start", t, t.__data__, r.index, r.group), r.state === Se) {
1250
- for (r.state = ce, o = new Array(p = r.tween.length), u = 0, d = -1; u < p; ++u)
1251
- (g = r.tween[u].value.call(t, t.__data__, r.index, r.group)) && (o[++d] = g);
1250
+ for (r.state = le, o = new Array(m = r.tween.length), u = 0, d = -1; u < m; ++u)
1251
+ (w = r.tween[u].value.call(t, t.__data__, r.index, r.group)) && (o[++d] = w);
1252
1252
  o.length = d + 1;
1253
1253
  }
1254
1254
  }
1255
1255
  function c(s) {
1256
- for (var u = s < r.duration ? r.ease.call(null, s / r.duration) : (r.timer.restart(l), r.state = Ue, 1), d = -1, p = o.length; ++d < p; )
1256
+ for (var u = s < r.duration ? r.ease.call(null, s / r.duration) : (r.timer.restart(l), r.state = Ue, 1), d = -1, m = o.length; ++d < m; )
1257
1257
  o[d].call(t, u);
1258
1258
  r.state === Ue && (r.on.call("end", t, t.__data__, r.index, r.group), l());
1259
1259
  }
1260
1260
  function l() {
1261
- r.state = le, r.timer.stop(), delete n[e];
1261
+ r.state = ue, r.timer.stop(), delete n[e];
1262
1262
  for (var s in n) return;
1263
1263
  delete t.__transition;
1264
1264
  }
1265
1265
  }
1266
- function ue(t, e) {
1266
+ function fe(t, e) {
1267
1267
  var r = t.__transition, n, o, a = !0, i;
1268
1268
  if (r) {
1269
1269
  e = e == null ? null : e + "";
@@ -1272,20 +1272,20 @@ function ue(t, e) {
1272
1272
  a = !1;
1273
1273
  continue;
1274
1274
  }
1275
- o = n.state > Se && n.state < Ue, n.state = le, n.timer.stop(), n.on.call(o ? "interrupt" : "cancel", t, t.__data__, n.index, n.group), delete r[i];
1275
+ o = n.state > Se && n.state < Ue, n.state = ue, n.timer.stop(), n.on.call(o ? "interrupt" : "cancel", t, t.__data__, n.index, n.group), delete r[i];
1276
1276
  }
1277
1277
  a && delete t.__transition;
1278
1278
  }
1279
1279
  }
1280
1280
  function fi(t) {
1281
1281
  return this.each(function() {
1282
- ue(this, t);
1282
+ fe(this, t);
1283
1283
  });
1284
1284
  }
1285
1285
  function hi(t, e) {
1286
1286
  var r, n;
1287
1287
  return function() {
1288
- var o = Ct(this, t), a = o.tween;
1288
+ var o = _t(this, t), a = o.tween;
1289
1289
  if (a !== r) {
1290
1290
  n = r = a;
1291
1291
  for (var i = 0, c = n.length; i < c; ++i)
@@ -1301,7 +1301,7 @@ function di(t, e, r) {
1301
1301
  var n, o;
1302
1302
  if (typeof r != "function") throw new Error();
1303
1303
  return function() {
1304
- var a = Ct(this, t), i = a.tween;
1304
+ var a = _t(this, t), i = a.tween;
1305
1305
  if (i !== n) {
1306
1306
  o = (n = i).slice();
1307
1307
  for (var c = { name: e, value: r }, l = 0, s = o.length; l < s; ++l)
@@ -1317,7 +1317,7 @@ function di(t, e, r) {
1317
1317
  function pi(t, e) {
1318
1318
  var r = this._id;
1319
1319
  if (t += "", arguments.length < 2) {
1320
- for (var n = xt(this.node(), r).tween, o = 0, a = n.length, i; o < a; ++o)
1320
+ for (var n = Ft(this.node(), r).tween, o = 0, a = n.length, i; o < a; ++o)
1321
1321
  if ((i = n[o]).name === t)
1322
1322
  return i.value;
1323
1323
  return null;
@@ -1327,27 +1327,27 @@ function pi(t, e) {
1327
1327
  function Ve(t, e, r) {
1328
1328
  var n = t._id;
1329
1329
  return t.each(function() {
1330
- var o = Ct(this, n);
1330
+ var o = _t(this, n);
1331
1331
  (o.value || (o.value = {}))[e] = r.apply(this, arguments);
1332
1332
  }), function(o) {
1333
- return xt(o, n).value[e];
1333
+ return Ft(o, n).value[e];
1334
1334
  };
1335
1335
  }
1336
1336
  function Ur(t, e) {
1337
1337
  var r;
1338
- return (typeof e == "number" ? Dt : e instanceof Zt ? or : (r = Zt(e)) ? (e = r, or) : Ko)(t, e);
1338
+ return (typeof e == "number" ? Pt : e instanceof Jt ? or : (r = Jt(e)) ? (e = r, or) : Ko)(t, e);
1339
1339
  }
1340
1340
  function vi(t) {
1341
1341
  return function() {
1342
1342
  this.removeAttribute(t);
1343
1343
  };
1344
1344
  }
1345
- function yi(t) {
1345
+ function mi(t) {
1346
1346
  return function() {
1347
1347
  this.removeAttributeNS(t.space, t.local);
1348
1348
  };
1349
1349
  }
1350
- function mi(t, e, r) {
1350
+ function yi(t, e, r) {
1351
1351
  var n, o = r + "", a;
1352
1352
  return function() {
1353
1353
  var i = this.getAttribute(t);
@@ -1376,8 +1376,8 @@ function xi(t, e, r) {
1376
1376
  };
1377
1377
  }
1378
1378
  function Ei(t, e) {
1379
- var r = ge(t), n = r === "transform" ? Ao : Ur;
1380
- return this.attrTween(t, typeof e == "function" ? (r.local ? xi : wi)(r, n, Ve(this, "attr." + t, e)) : e == null ? (r.local ? yi : vi)(r) : (r.local ? gi : mi)(r, n, e));
1379
+ var r = we(t), n = r === "transform" ? Ao : Ur;
1380
+ return this.attrTween(t, typeof e == "function" ? (r.local ? xi : wi)(r, n, Ve(this, "attr." + t, e)) : e == null ? (r.local ? mi : vi)(r) : (r.local ? gi : yi)(r, n, e));
1381
1381
  }
1382
1382
  function bi(t, e) {
1383
1383
  return function(r) {
@@ -1410,7 +1410,7 @@ function _i(t, e) {
1410
1410
  if (arguments.length < 2) return (r = this.tween(r)) && r._value;
1411
1411
  if (e == null) return this.tween(r, null);
1412
1412
  if (typeof e != "function") throw new Error();
1413
- var n = ge(t);
1413
+ var n = we(t);
1414
1414
  return this.tween(r, (n.local ? Fi : Ci)(n, e));
1415
1415
  }
1416
1416
  function Ri(t, e) {
@@ -1425,37 +1425,37 @@ function Li(t, e) {
1425
1425
  }
1426
1426
  function Yi(t) {
1427
1427
  var e = this._id;
1428
- return arguments.length ? this.each((typeof t == "function" ? Ri : Li)(e, t)) : xt(this.node(), e).delay;
1428
+ return arguments.length ? this.each((typeof t == "function" ? Ri : Li)(e, t)) : Ft(this.node(), e).delay;
1429
1429
  }
1430
1430
  function Di(t, e) {
1431
1431
  return function() {
1432
- Ct(this, t).duration = +e.apply(this, arguments);
1432
+ _t(this, t).duration = +e.apply(this, arguments);
1433
1433
  };
1434
1434
  }
1435
1435
  function Bi(t, e) {
1436
1436
  return e = +e, function() {
1437
- Ct(this, t).duration = e;
1437
+ _t(this, t).duration = e;
1438
1438
  };
1439
1439
  }
1440
1440
  function Pi(t) {
1441
1441
  var e = this._id;
1442
- return arguments.length ? this.each((typeof t == "function" ? Di : Bi)(e, t)) : xt(this.node(), e).duration;
1442
+ return arguments.length ? this.each((typeof t == "function" ? Di : Bi)(e, t)) : Ft(this.node(), e).duration;
1443
1443
  }
1444
1444
  function Ni(t, e) {
1445
1445
  if (typeof e != "function") throw new Error();
1446
1446
  return function() {
1447
- Ct(this, t).ease = e;
1447
+ _t(this, t).ease = e;
1448
1448
  };
1449
1449
  }
1450
1450
  function $i(t) {
1451
1451
  var e = this._id;
1452
- return arguments.length ? this.each(Ni(e, t)) : xt(this.node(), e).ease;
1452
+ return arguments.length ? this.each(Ni(e, t)) : Ft(this.node(), e).ease;
1453
1453
  }
1454
1454
  function Xi(t, e) {
1455
1455
  return function() {
1456
1456
  var r = e.apply(this, arguments);
1457
1457
  if (typeof r != "function") throw new Error();
1458
- Ct(this, t).ease = r;
1458
+ _t(this, t).ease = r;
1459
1459
  };
1460
1460
  }
1461
1461
  function Si(t) {
@@ -1463,20 +1463,20 @@ function Si(t) {
1463
1463
  return this.each(Xi(this._id, t));
1464
1464
  }
1465
1465
  function Ui(t) {
1466
- typeof t != "function" && (t = mr(t));
1466
+ typeof t != "function" && (t = yr(t));
1467
1467
  for (var e = this._groups, r = e.length, n = new Array(r), o = 0; o < r; ++o)
1468
1468
  for (var a = e[o], i = a.length, c = n[o] = [], l, s = 0; s < i; ++s)
1469
1469
  (l = a[s]) && t.call(l, l.__data__, s, a) && c.push(l);
1470
- return new Yt(n, this._parents, this._name, this._id);
1470
+ return new Dt(n, this._parents, this._name, this._id);
1471
1471
  }
1472
1472
  function Ii(t) {
1473
1473
  if (t._id !== this._id) throw new Error();
1474
1474
  for (var e = this._groups, r = t._groups, n = e.length, o = r.length, a = Math.min(n, o), i = new Array(n), c = 0; c < a; ++c)
1475
- for (var l = e[c], s = r[c], u = l.length, d = i[c] = new Array(u), p, g = 0; g < u; ++g)
1476
- (p = l[g] || s[g]) && (d[g] = p);
1475
+ for (var l = e[c], s = r[c], u = l.length, d = i[c] = new Array(u), m, w = 0; w < u; ++w)
1476
+ (m = l[w] || s[w]) && (d[w] = m);
1477
1477
  for (; c < n; ++c)
1478
1478
  i[c] = e[c];
1479
- return new Yt(i, this._parents, this._name, this._id);
1479
+ return new Dt(i, this._parents, this._name, this._id);
1480
1480
  }
1481
1481
  function ki(t) {
1482
1482
  return (t + "").trim().split(/^|\s+/).every(function(e) {
@@ -1485,7 +1485,7 @@ function ki(t) {
1485
1485
  });
1486
1486
  }
1487
1487
  function zi(t, e, r) {
1488
- var n, o, a = ki(e) ? Te : Ct;
1488
+ var n, o, a = ki(e) ? Te : _t;
1489
1489
  return function() {
1490
1490
  var i = a(this, t), c = i.on;
1491
1491
  c !== n && (o = (n = c).copy()).on(e, r), i.on = o;
@@ -1493,7 +1493,7 @@ function zi(t, e, r) {
1493
1493
  }
1494
1494
  function ji(t, e) {
1495
1495
  var r = this._id;
1496
- return arguments.length < 2 ? xt(this.node(), r).on.on(t) : this.each(zi(r, t, e));
1496
+ return arguments.length < 2 ? Ft(this.node(), r).on.on(t) : this.each(zi(r, t, e));
1497
1497
  }
1498
1498
  function Gi(t) {
1499
1499
  return function() {
@@ -1509,30 +1509,30 @@ function Ti(t) {
1509
1509
  var e = this._name, r = this._id;
1510
1510
  typeof t != "function" && (t = ze(t));
1511
1511
  for (var n = this._groups, o = n.length, a = new Array(o), i = 0; i < o; ++i)
1512
- for (var c = n[i], l = c.length, s = a[i] = new Array(l), u, d, p = 0; p < l; ++p)
1513
- (u = c[p]) && (d = t.call(u, u.__data__, p, c)) && ("__data__" in u && (d.__data__ = u.__data__), s[p] = d, xe(s[p], e, r, p, s, xt(u, r)));
1514
- return new Yt(a, this._parents, e, r);
1512
+ for (var c = n[i], l = c.length, s = a[i] = new Array(l), u, d, m = 0; m < l; ++m)
1513
+ (u = c[m]) && (d = t.call(u, u.__data__, m, c)) && ("__data__" in u && (d.__data__ = u.__data__), s[m] = d, Ee(s[m], e, r, m, s, Ft(u, r)));
1514
+ return new Dt(a, this._parents, e, r);
1515
1515
  }
1516
1516
  function Vi(t) {
1517
1517
  var e = this._name, r = this._id;
1518
- typeof t != "function" && (t = yr(t));
1518
+ typeof t != "function" && (t = mr(t));
1519
1519
  for (var n = this._groups, o = n.length, a = [], i = [], c = 0; c < o; ++c)
1520
1520
  for (var l = n[c], s = l.length, u, d = 0; d < s; ++d)
1521
1521
  if (u = l[d]) {
1522
- for (var p = t.call(u, u.__data__, d, l), g, R = xt(u, r), B = 0, $ = p.length; B < $; ++B)
1523
- (g = p[B]) && xe(g, e, r, B, p, R);
1524
- a.push(p), i.push(u);
1522
+ for (var m = t.call(u, u.__data__, d, l), w, _ = Ft(u, r), B = 0, V = m.length; B < V; ++B)
1523
+ (w = m[B]) && Ee(w, e, r, B, m, _);
1524
+ a.push(m), i.push(u);
1525
1525
  }
1526
- return new Yt(a, i, e, r);
1526
+ return new Dt(a, i, e, r);
1527
1527
  }
1528
- var Wi = At.prototype.constructor;
1528
+ var Wi = te.prototype.constructor;
1529
1529
  function Hi() {
1530
1530
  return new Wi(this._groups, this._parents);
1531
1531
  }
1532
1532
  function qi(t, e) {
1533
1533
  var r, n, o;
1534
1534
  return function() {
1535
- var a = jt(this, t), i = (this.style.removeProperty(t), jt(this, t));
1535
+ var a = Gt(this, t), i = (this.style.removeProperty(t), Gt(this, t));
1536
1536
  return a === i ? null : a === r && i === n ? o : o = e(r = a, n = i);
1537
1537
  };
1538
1538
  }
@@ -1544,21 +1544,21 @@ function Ir(t) {
1544
1544
  function Ki(t, e, r) {
1545
1545
  var n, o = r + "", a;
1546
1546
  return function() {
1547
- var i = jt(this, t);
1547
+ var i = Gt(this, t);
1548
1548
  return i === o ? null : i === n ? a : a = e(n = i, r);
1549
1549
  };
1550
1550
  }
1551
1551
  function Qi(t, e, r) {
1552
1552
  var n, o, a;
1553
1553
  return function() {
1554
- var i = jt(this, t), c = r(this), l = c + "";
1555
- return c == null && (l = c = (this.style.removeProperty(t), jt(this, t))), i === l ? null : i === n && l === o ? a : (o = l, a = e(n = i, c));
1554
+ var i = Gt(this, t), c = r(this), l = c + "";
1555
+ return c == null && (l = c = (this.style.removeProperty(t), Gt(this, t))), i === l ? null : i === n && l === o ? a : (o = l, a = e(n = i, c));
1556
1556
  };
1557
1557
  }
1558
1558
  function Zi(t, e) {
1559
1559
  var r, n, o, a = "style." + e, i = "end." + a, c;
1560
1560
  return function() {
1561
- var l = Ct(this, t), s = l.on, u = l.value[a] == null ? c || (c = Ir(e)) : void 0;
1561
+ var l = _t(this, t), s = l.on, u = l.value[a] == null ? c || (c = Ir(e)) : void 0;
1562
1562
  (s !== r || o !== u) && (n = (r = s).copy()).on(i, o = u), l.on = n;
1563
1563
  };
1564
1564
  }
@@ -1624,15 +1624,15 @@ function ca() {
1624
1624
  for (var t = this._name, e = this._id, r = kr(), n = this._groups, o = n.length, a = 0; a < o; ++a)
1625
1625
  for (var i = n[a], c = i.length, l, s = 0; s < c; ++s)
1626
1626
  if (l = i[s]) {
1627
- var u = xt(l, e);
1628
- xe(l, t, r, s, i, {
1627
+ var u = Ft(l, e);
1628
+ Ee(l, t, r, s, i, {
1629
1629
  time: u.time + u.delay + u.duration,
1630
1630
  delay: 0,
1631
1631
  duration: u.duration,
1632
1632
  ease: u.ease
1633
1633
  });
1634
1634
  }
1635
- return new Yt(n, this._parents, t, r);
1635
+ return new Dt(n, this._parents, t, r);
1636
1636
  }
1637
1637
  function la() {
1638
1638
  var t, e, r = this, n = r._id, o = r.size();
@@ -1641,35 +1641,35 @@ function la() {
1641
1641
  --o === 0 && a();
1642
1642
  } };
1643
1643
  r.each(function() {
1644
- var s = Ct(this, n), u = s.on;
1644
+ var s = _t(this, n), u = s.on;
1645
1645
  u !== t && (e = (t = u).copy(), e._.cancel.push(c), e._.interrupt.push(c), e._.end.push(l)), s.on = e;
1646
1646
  }), o === 0 && a();
1647
1647
  });
1648
1648
  }
1649
1649
  var ua = 0;
1650
- function Yt(t, e, r, n) {
1650
+ function Dt(t, e, r, n) {
1651
1651
  this._groups = t, this._parents = e, this._name = r, this._id = n;
1652
1652
  }
1653
1653
  function kr() {
1654
1654
  return ++ua;
1655
1655
  }
1656
- var Rt = At.prototype;
1657
- Yt.prototype = {
1658
- constructor: Yt,
1656
+ var Lt = te.prototype;
1657
+ Dt.prototype = {
1658
+ constructor: Dt,
1659
1659
  select: Ti,
1660
1660
  selectAll: Vi,
1661
- selectChild: Rt.selectChild,
1662
- selectChildren: Rt.selectChildren,
1661
+ selectChild: Lt.selectChild,
1662
+ selectChildren: Lt.selectChildren,
1663
1663
  filter: Ui,
1664
1664
  merge: Ii,
1665
1665
  selection: Hi,
1666
1666
  transition: ca,
1667
- call: Rt.call,
1668
- nodes: Rt.nodes,
1669
- node: Rt.node,
1670
- size: Rt.size,
1671
- empty: Rt.empty,
1672
- each: Rt.each,
1667
+ call: Lt.call,
1668
+ nodes: Lt.nodes,
1669
+ node: Lt.node,
1670
+ size: Lt.size,
1671
+ empty: Lt.empty,
1672
+ each: Lt.each,
1673
1673
  on: ji,
1674
1674
  attr: Ei,
1675
1675
  attrTween: _i,
@@ -1684,7 +1684,7 @@ Yt.prototype = {
1684
1684
  ease: $i,
1685
1685
  easeVarying: Si,
1686
1686
  end: la,
1687
- [Symbol.iterator]: Rt[Symbol.iterator]
1687
+ [Symbol.iterator]: Lt[Symbol.iterator]
1688
1688
  };
1689
1689
  function fa(t) {
1690
1690
  return ((t *= 2) <= 1 ? t * t * t : (t -= 2) * t * t + 2) / 2;
@@ -1704,15 +1704,15 @@ function da(t, e) {
1704
1704
  }
1705
1705
  function pa(t) {
1706
1706
  var e, r;
1707
- t instanceof Yt ? (e = t._id, t = t._name) : (e = kr(), (r = ha).time = Oe(), t = t == null ? null : t + "");
1707
+ t instanceof Dt ? (e = t._id, t = t._name) : (e = kr(), (r = ha).time = Oe(), t = t == null ? null : t + "");
1708
1708
  for (var n = this._groups, o = n.length, a = 0; a < o; ++a)
1709
1709
  for (var i = n[a], c = i.length, l, s = 0; s < c; ++s)
1710
- (l = i[s]) && xe(l, t, e, s, i, r || da(l, e));
1711
- return new Yt(n, this._parents, t, e);
1710
+ (l = i[s]) && Ee(l, t, e, s, i, r || da(l, e));
1711
+ return new Dt(n, this._parents, t, e);
1712
1712
  }
1713
- At.prototype.interrupt = fi;
1714
- At.prototype.transition = pa;
1715
- const ie = (t) => () => t;
1713
+ te.prototype.interrupt = fi;
1714
+ te.prototype.transition = pa;
1715
+ const ae = (t) => () => t;
1716
1716
  function va(t, {
1717
1717
  sourceEvent: e,
1718
1718
  target: r,
@@ -1727,16 +1727,16 @@ function va(t, {
1727
1727
  _: { value: o }
1728
1728
  });
1729
1729
  }
1730
- function Lt(t, e, r) {
1730
+ function Yt(t, e, r) {
1731
1731
  this.k = t, this.x = e, this.y = r;
1732
1732
  }
1733
- Lt.prototype = {
1734
- constructor: Lt,
1733
+ Yt.prototype = {
1734
+ constructor: Yt,
1735
1735
  scale: function(t) {
1736
- return t === 1 ? this : new Lt(this.k * t, this.x, this.y);
1736
+ return t === 1 ? this : new Yt(this.k * t, this.x, this.y);
1737
1737
  },
1738
1738
  translate: function(t, e) {
1739
- return t === 0 & e === 0 ? this : new Lt(this.k, this.x + this.k * t, this.y + this.k * e);
1739
+ return t === 0 & e === 0 ? this : new Yt(this.k, this.x + this.k * t, this.y + this.k * e);
1740
1740
  },
1741
1741
  apply: function(t) {
1742
1742
  return [t[0] * this.k + this.x, t[1] * this.k + this.y];
@@ -1766,27 +1766,27 @@ Lt.prototype = {
1766
1766
  return "translate(" + this.x + "," + this.y + ") scale(" + this.k + ")";
1767
1767
  }
1768
1768
  };
1769
- var Pt = new Lt(1, 0, 0);
1770
- qt.prototype = Lt.prototype;
1771
- function qt(t) {
1772
- for (; !t.__zoom; ) if (!(t = t.parentNode)) return Pt;
1769
+ var $t = new Yt(1, 0, 0);
1770
+ Kt.prototype = Yt.prototype;
1771
+ function Kt(t) {
1772
+ for (; !t.__zoom; ) if (!(t = t.parentNode)) return $t;
1773
1773
  return t.__zoom;
1774
1774
  }
1775
1775
  function _e(t) {
1776
1776
  t.stopImmediatePropagation();
1777
1777
  }
1778
- function Vt(t) {
1778
+ function Wt(t) {
1779
1779
  t.preventDefault(), t.stopImmediatePropagation();
1780
1780
  }
1781
- function ya(t) {
1781
+ function ma(t) {
1782
1782
  return (!t.ctrlKey || t.type === "wheel") && !t.button;
1783
1783
  }
1784
- function ma() {
1784
+ function ya() {
1785
1785
  var t = this;
1786
1786
  return t instanceof SVGElement ? (t = t.ownerSVGElement || t, t.hasAttribute("viewBox") ? (t = t.viewBox.baseVal, [[t.x, t.y], [t.x + t.width, t.y + t.height]]) : [[0, 0], [t.width.baseVal.value, t.height.baseVal.value]]) : [[0, 0], [t.clientWidth, t.clientHeight]];
1787
1787
  }
1788
1788
  function fr() {
1789
- return this.__zoom || Pt;
1789
+ return this.__zoom || $t;
1790
1790
  }
1791
1791
  function ga(t) {
1792
1792
  return -t.deltaY * (t.deltaMode === 1 ? 0.05 : t.deltaMode ? 1 : 2e-3) * (t.ctrlKey ? 10 : 1);
@@ -1802,202 +1802,202 @@ function xa(t, e, r) {
1802
1802
  );
1803
1803
  }
1804
1804
  function We() {
1805
- var t = ya, e = ma, r = xa, n = ga, o = wa, a = [0, 1 / 0], i = [[-1 / 0, -1 / 0], [1 / 0, 1 / 0]], c = 250, l = ni, s = ke("start", "zoom", "end"), u, d, p, g = 500, R = 150, B = 0, $ = 10;
1806
- function Y(f) {
1807
- f.property("__zoom", fr).on("wheel.zoom", nt, { passive: !1 }).on("mousedown.zoom", G).on("dblclick.zoom", F).filter(o).on("touchstart.zoom", H).on("touchmove.zoom", Q).on("touchend.zoom touchcancel.zoom", N).style("-webkit-tap-highlight-color", "rgba(0,0,0,0)");
1805
+ var t = ma, e = ya, r = xa, n = ga, o = wa, a = [0, 1 / 0], i = [[-1 / 0, -1 / 0], [1 / 0, 1 / 0]], c = 250, l = ni, s = ke("start", "zoom", "end"), u, d, m, w = 500, _ = 150, B = 0, V = 10;
1806
+ function x(f) {
1807
+ f.property("__zoom", fr).on("wheel.zoom", it, { passive: !1 }).on("mousedown.zoom", A).on("dblclick.zoom", R).filter(o).on("touchstart.zoom", U).on("touchmove.zoom", W).on("touchend.zoom touchcancel.zoom", P).style("-webkit-tap-highlight-color", "rgba(0,0,0,0)");
1808
1808
  }
1809
- Y.transform = function(f, M, v, D) {
1809
+ x.transform = function(f, b, y, D) {
1810
1810
  var X = f.selection ? f.selection() : f;
1811
- X.property("__zoom", fr), f !== X ? O(f, M, v, D) : X.interrupt().each(function() {
1812
- U(this, arguments).event(D).start().zoom(null, typeof M == "function" ? M.apply(this, arguments) : M).end();
1811
+ X.property("__zoom", fr), f !== X ? N(f, b, y, D) : X.interrupt().each(function() {
1812
+ $(this, arguments).event(D).start().zoom(null, typeof b == "function" ? b.apply(this, arguments) : b).end();
1813
1813
  });
1814
- }, Y.scaleBy = function(f, M, v, D) {
1815
- Y.scaleTo(f, function() {
1816
- var X = this.__zoom.k, I = typeof M == "function" ? M.apply(this, arguments) : M;
1817
- return X * I;
1818
- }, v, D);
1819
- }, Y.scaleTo = function(f, M, v, D) {
1820
- Y.transform(f, function() {
1821
- var X = e.apply(this, arguments), I = this.__zoom, P = v == null ? A(X) : typeof v == "function" ? v.apply(this, arguments) : v, h = I.invert(P), w = typeof M == "function" ? M.apply(this, arguments) : M;
1822
- return r(j(J(I, w), P, h), X, i);
1823
- }, v, D);
1824
- }, Y.translateBy = function(f, M, v, D) {
1825
- Y.transform(f, function() {
1814
+ }, x.scaleBy = function(f, b, y, D) {
1815
+ x.scaleTo(f, function() {
1816
+ var X = this.__zoom.k, S = typeof b == "function" ? b.apply(this, arguments) : b;
1817
+ return X * S;
1818
+ }, y, D);
1819
+ }, x.scaleTo = function(f, b, y, D) {
1820
+ x.transform(f, function() {
1821
+ var X = e.apply(this, arguments), S = this.__zoom, z = y == null ? et(X) : typeof y == "function" ? y.apply(this, arguments) : y, G = S.invert(z), p = typeof b == "function" ? b.apply(this, arguments) : b;
1822
+ return r(Z(K(S, p), z, G), X, i);
1823
+ }, y, D);
1824
+ }, x.translateBy = function(f, b, y, D) {
1825
+ x.transform(f, function() {
1826
1826
  return r(this.__zoom.translate(
1827
- typeof M == "function" ? M.apply(this, arguments) : M,
1828
- typeof v == "function" ? v.apply(this, arguments) : v
1827
+ typeof b == "function" ? b.apply(this, arguments) : b,
1828
+ typeof y == "function" ? y.apply(this, arguments) : y
1829
1829
  ), e.apply(this, arguments), i);
1830
1830
  }, null, D);
1831
- }, Y.translateTo = function(f, M, v, D, X) {
1832
- Y.transform(f, function() {
1833
- var I = e.apply(this, arguments), P = this.__zoom, h = D == null ? A(I) : typeof D == "function" ? D.apply(this, arguments) : D;
1834
- return r(Pt.translate(h[0], h[1]).scale(P.k).translate(
1835
- typeof M == "function" ? -M.apply(this, arguments) : -M,
1836
- typeof v == "function" ? -v.apply(this, arguments) : -v
1837
- ), I, i);
1831
+ }, x.translateTo = function(f, b, y, D, X) {
1832
+ x.transform(f, function() {
1833
+ var S = e.apply(this, arguments), z = this.__zoom, G = D == null ? et(S) : typeof D == "function" ? D.apply(this, arguments) : D;
1834
+ return r($t.translate(G[0], G[1]).scale(z.k).translate(
1835
+ typeof b == "function" ? -b.apply(this, arguments) : -b,
1836
+ typeof y == "function" ? -y.apply(this, arguments) : -y
1837
+ ), S, i);
1838
1838
  }, D, X);
1839
1839
  };
1840
- function J(f, M) {
1841
- return M = Math.max(a[0], Math.min(a[1], M)), M === f.k ? f : new Lt(M, f.x, f.y);
1840
+ function K(f, b) {
1841
+ return b = Math.max(a[0], Math.min(a[1], b)), b === f.k ? f : new Yt(b, f.x, f.y);
1842
1842
  }
1843
- function j(f, M, v) {
1844
- var D = M[0] - v[0] * f.k, X = M[1] - v[1] * f.k;
1845
- return D === f.x && X === f.y ? f : new Lt(f.k, D, X);
1843
+ function Z(f, b, y) {
1844
+ var D = b[0] - y[0] * f.k, X = b[1] - y[1] * f.k;
1845
+ return D === f.x && X === f.y ? f : new Yt(f.k, D, X);
1846
1846
  }
1847
- function A(f) {
1847
+ function et(f) {
1848
1848
  return [(+f[0][0] + +f[1][0]) / 2, (+f[0][1] + +f[1][1]) / 2];
1849
1849
  }
1850
- function O(f, M, v, D) {
1850
+ function N(f, b, y, D) {
1851
1851
  f.on("start.zoom", function() {
1852
- U(this, arguments).event(D).start();
1852
+ $(this, arguments).event(D).start();
1853
1853
  }).on("interrupt.zoom end.zoom", function() {
1854
- U(this, arguments).event(D).end();
1854
+ $(this, arguments).event(D).end();
1855
1855
  }).tween("zoom", function() {
1856
- var X = this, I = arguments, P = U(X, I).event(D), h = e.apply(X, I), w = v == null ? A(h) : typeof v == "function" ? v.apply(X, I) : v, E = Math.max(h[1][0] - h[0][0], h[1][1] - h[0][1]), m = X.__zoom, x = typeof M == "function" ? M.apply(X, I) : M, b = l(m.invert(w).concat(E / m.k), x.invert(w).concat(E / x.k));
1857
- return function(y) {
1858
- if (y === 1) y = x;
1856
+ var X = this, S = arguments, z = $(X, S).event(D), G = e.apply(X, S), p = y == null ? et(G) : typeof y == "function" ? y.apply(X, S) : y, h = Math.max(G[1][0] - G[0][0], G[1][1] - G[0][1]), C = X.__zoom, E = typeof b == "function" ? b.apply(X, S) : b, Y = l(C.invert(p).concat(h / C.k), E.invert(p).concat(h / E.k));
1857
+ return function(g) {
1858
+ if (g === 1) g = E;
1859
1859
  else {
1860
- var C = b(y), _ = E / C[2];
1861
- y = new Lt(_, w[0] - C[0] * _, w[1] - C[1] * _);
1860
+ var v = Y(g), L = h / v[2];
1861
+ g = new Yt(L, p[0] - v[0] * L, p[1] - v[1] * L);
1862
1862
  }
1863
- P.zoom(null, y);
1863
+ z.zoom(null, g);
1864
1864
  };
1865
1865
  });
1866
1866
  }
1867
- function U(f, M, v) {
1868
- return !v && f.__zooming || new et(f, M);
1867
+ function $(f, b, y) {
1868
+ return !y && f.__zooming || new nt(f, b);
1869
1869
  }
1870
- function et(f, M) {
1871
- this.that = f, this.args = M, this.active = 0, this.sourceEvent = null, this.extent = e.apply(f, M), this.taps = 0;
1870
+ function nt(f, b) {
1871
+ this.that = f, this.args = b, this.active = 0, this.sourceEvent = null, this.extent = e.apply(f, b), this.taps = 0;
1872
1872
  }
1873
- et.prototype = {
1873
+ nt.prototype = {
1874
1874
  event: function(f) {
1875
1875
  return f && (this.sourceEvent = f), this;
1876
1876
  },
1877
1877
  start: function() {
1878
1878
  return ++this.active === 1 && (this.that.__zooming = this, this.emit("start")), this;
1879
1879
  },
1880
- zoom: function(f, M) {
1881
- return this.mouse && f !== "mouse" && (this.mouse[1] = M.invert(this.mouse[0])), this.touch0 && f !== "touch" && (this.touch0[1] = M.invert(this.touch0[0])), this.touch1 && f !== "touch" && (this.touch1[1] = M.invert(this.touch1[0])), this.that.__zoom = M, this.emit("zoom"), this;
1880
+ zoom: function(f, b) {
1881
+ return this.mouse && f !== "mouse" && (this.mouse[1] = b.invert(this.mouse[0])), this.touch0 && f !== "touch" && (this.touch0[1] = b.invert(this.touch0[0])), this.touch1 && f !== "touch" && (this.touch1[1] = b.invert(this.touch1[0])), this.that.__zoom = b, this.emit("zoom"), this;
1882
1882
  },
1883
1883
  end: function() {
1884
1884
  return --this.active === 0 && (delete this.that.__zooming, this.emit("end")), this;
1885
1885
  },
1886
1886
  emit: function(f) {
1887
- var M = at(this.that).datum();
1887
+ var b = at(this.that).datum();
1888
1888
  s.call(
1889
1889
  f,
1890
1890
  this.that,
1891
1891
  new va(f, {
1892
1892
  sourceEvent: this.sourceEvent,
1893
- target: Y,
1893
+ target: x,
1894
1894
  transform: this.that.__zoom,
1895
1895
  dispatch: s
1896
1896
  }),
1897
- M
1897
+ b
1898
1898
  );
1899
1899
  }
1900
1900
  };
1901
- function nt(f, ...M) {
1901
+ function it(f, ...b) {
1902
1902
  if (!t.apply(this, arguments)) return;
1903
- var v = U(this, M).event(f), D = this.__zoom, X = Math.max(a[0], Math.min(a[1], D.k * Math.pow(2, n.apply(this, arguments)))), I = Nt(f);
1904
- if (v.wheel)
1905
- (v.mouse[0][0] !== I[0] || v.mouse[0][1] !== I[1]) && (v.mouse[1] = D.invert(v.mouse[0] = I)), clearTimeout(v.wheel);
1903
+ var y = $(this, b).event(f), D = this.__zoom, X = Math.max(a[0], Math.min(a[1], D.k * Math.pow(2, n.apply(this, arguments)))), S = Xt(f);
1904
+ if (y.wheel)
1905
+ (y.mouse[0][0] !== S[0] || y.mouse[0][1] !== S[1]) && (y.mouse[1] = D.invert(y.mouse[0] = S)), clearTimeout(y.wheel);
1906
1906
  else {
1907
1907
  if (D.k === X) return;
1908
- v.mouse = [I, D.invert(I)], ue(this), v.start();
1908
+ y.mouse = [S, D.invert(S)], fe(this), y.start();
1909
1909
  }
1910
- Vt(f), v.wheel = setTimeout(P, R), v.zoom("mouse", r(j(J(D, X), v.mouse[0], v.mouse[1]), v.extent, i));
1911
- function P() {
1912
- v.wheel = null, v.end();
1910
+ Wt(f), y.wheel = setTimeout(z, _), y.zoom("mouse", r(Z(K(D, X), y.mouse[0], y.mouse[1]), y.extent, i));
1911
+ function z() {
1912
+ y.wheel = null, y.end();
1913
1913
  }
1914
1914
  }
1915
- function G(f, ...M) {
1916
- if (p || !t.apply(this, arguments)) return;
1917
- var v = f.currentTarget, D = U(this, M, !0).event(f), X = at(f.view).on("mousemove.zoom", w, !0).on("mouseup.zoom", E, !0), I = Nt(f, v), P = f.clientX, h = f.clientY;
1918
- Do(f.view), _e(f), D.mouse = [I, this.__zoom.invert(I)], ue(this), D.start();
1919
- function w(m) {
1920
- if (Vt(m), !D.moved) {
1921
- var x = m.clientX - P, b = m.clientY - h;
1922
- D.moved = x * x + b * b > B;
1915
+ function A(f, ...b) {
1916
+ if (m || !t.apply(this, arguments)) return;
1917
+ var y = f.currentTarget, D = $(this, b, !0).event(f), X = at(f.view).on("mousemove.zoom", p, !0).on("mouseup.zoom", h, !0), S = Xt(f, y), z = f.clientX, G = f.clientY;
1918
+ Do(f.view), _e(f), D.mouse = [S, this.__zoom.invert(S)], fe(this), D.start();
1919
+ function p(C) {
1920
+ if (Wt(C), !D.moved) {
1921
+ var E = C.clientX - z, Y = C.clientY - G;
1922
+ D.moved = E * E + Y * Y > B;
1923
1923
  }
1924
- D.event(m).zoom("mouse", r(j(D.that.__zoom, D.mouse[0] = Nt(m, v), D.mouse[1]), D.extent, i));
1924
+ D.event(C).zoom("mouse", r(Z(D.that.__zoom, D.mouse[0] = Xt(C, y), D.mouse[1]), D.extent, i));
1925
1925
  }
1926
- function E(m) {
1927
- X.on("mousemove.zoom mouseup.zoom", null), Bo(m.view, D.moved), Vt(m), D.event(m).end();
1926
+ function h(C) {
1927
+ X.on("mousemove.zoom mouseup.zoom", null), Bo(C.view, D.moved), Wt(C), D.event(C).end();
1928
1928
  }
1929
1929
  }
1930
- function F(f, ...M) {
1930
+ function R(f, ...b) {
1931
1931
  if (t.apply(this, arguments)) {
1932
- var v = this.__zoom, D = Nt(f.changedTouches ? f.changedTouches[0] : f, this), X = v.invert(D), I = v.k * (f.shiftKey ? 0.5 : 2), P = r(j(J(v, I), D, X), e.apply(this, M), i);
1933
- Vt(f), c > 0 ? at(this).transition().duration(c).call(O, P, D, f) : at(this).call(Y.transform, P, D, f);
1932
+ var y = this.__zoom, D = Xt(f.changedTouches ? f.changedTouches[0] : f, this), X = y.invert(D), S = y.k * (f.shiftKey ? 0.5 : 2), z = r(Z(K(y, S), D, X), e.apply(this, b), i);
1933
+ Wt(f), c > 0 ? at(this).transition().duration(c).call(N, z, D, f) : at(this).call(x.transform, z, D, f);
1934
1934
  }
1935
1935
  }
1936
- function H(f, ...M) {
1936
+ function U(f, ...b) {
1937
1937
  if (t.apply(this, arguments)) {
1938
- var v = f.touches, D = v.length, X = U(this, M, f.changedTouches.length === D).event(f), I, P, h, w;
1939
- for (_e(f), P = 0; P < D; ++P)
1940
- h = v[P], w = Nt(h, this), w = [w, this.__zoom.invert(w), h.identifier], X.touch0 ? !X.touch1 && X.touch0[2] !== w[2] && (X.touch1 = w, X.taps = 0) : (X.touch0 = w, I = !0, X.taps = 1 + !!u);
1941
- u && (u = clearTimeout(u)), I && (X.taps < 2 && (d = w[0], u = setTimeout(function() {
1938
+ var y = f.touches, D = y.length, X = $(this, b, f.changedTouches.length === D).event(f), S, z, G, p;
1939
+ for (_e(f), z = 0; z < D; ++z)
1940
+ G = y[z], p = Xt(G, this), p = [p, this.__zoom.invert(p), G.identifier], X.touch0 ? !X.touch1 && X.touch0[2] !== p[2] && (X.touch1 = p, X.taps = 0) : (X.touch0 = p, S = !0, X.taps = 1 + !!u);
1941
+ u && (u = clearTimeout(u)), S && (X.taps < 2 && (d = p[0], u = setTimeout(function() {
1942
1942
  u = null;
1943
- }, g)), ue(this), X.start());
1943
+ }, w)), fe(this), X.start());
1944
1944
  }
1945
1945
  }
1946
- function Q(f, ...M) {
1946
+ function W(f, ...b) {
1947
1947
  if (this.__zooming) {
1948
- var v = U(this, M).event(f), D = f.changedTouches, X = D.length, I, P, h, w;
1949
- for (Vt(f), I = 0; I < X; ++I)
1950
- P = D[I], h = Nt(P, this), v.touch0 && v.touch0[2] === P.identifier ? v.touch0[0] = h : v.touch1 && v.touch1[2] === P.identifier && (v.touch1[0] = h);
1951
- if (P = v.that.__zoom, v.touch1) {
1952
- var E = v.touch0[0], m = v.touch0[1], x = v.touch1[0], b = v.touch1[1], y = (y = x[0] - E[0]) * y + (y = x[1] - E[1]) * y, C = (C = b[0] - m[0]) * C + (C = b[1] - m[1]) * C;
1953
- P = J(P, Math.sqrt(y / C)), h = [(E[0] + x[0]) / 2, (E[1] + x[1]) / 2], w = [(m[0] + b[0]) / 2, (m[1] + b[1]) / 2];
1954
- } else if (v.touch0) h = v.touch0[0], w = v.touch0[1];
1948
+ var y = $(this, b).event(f), D = f.changedTouches, X = D.length, S, z, G, p;
1949
+ for (Wt(f), S = 0; S < X; ++S)
1950
+ z = D[S], G = Xt(z, this), y.touch0 && y.touch0[2] === z.identifier ? y.touch0[0] = G : y.touch1 && y.touch1[2] === z.identifier && (y.touch1[0] = G);
1951
+ if (z = y.that.__zoom, y.touch1) {
1952
+ var h = y.touch0[0], C = y.touch0[1], E = y.touch1[0], Y = y.touch1[1], g = (g = E[0] - h[0]) * g + (g = E[1] - h[1]) * g, v = (v = Y[0] - C[0]) * v + (v = Y[1] - C[1]) * v;
1953
+ z = K(z, Math.sqrt(g / v)), G = [(h[0] + E[0]) / 2, (h[1] + E[1]) / 2], p = [(C[0] + Y[0]) / 2, (C[1] + Y[1]) / 2];
1954
+ } else if (y.touch0) G = y.touch0[0], p = y.touch0[1];
1955
1955
  else return;
1956
- v.zoom("touch", r(j(P, h, w), v.extent, i));
1956
+ y.zoom("touch", r(Z(z, G, p), y.extent, i));
1957
1957
  }
1958
1958
  }
1959
- function N(f, ...M) {
1959
+ function P(f, ...b) {
1960
1960
  if (this.__zooming) {
1961
- var v = U(this, M).event(f), D = f.changedTouches, X = D.length, I, P;
1962
- for (_e(f), p && clearTimeout(p), p = setTimeout(function() {
1963
- p = null;
1964
- }, g), I = 0; I < X; ++I)
1965
- P = D[I], v.touch0 && v.touch0[2] === P.identifier ? delete v.touch0 : v.touch1 && v.touch1[2] === P.identifier && delete v.touch1;
1966
- if (v.touch1 && !v.touch0 && (v.touch0 = v.touch1, delete v.touch1), v.touch0) v.touch0[1] = this.__zoom.invert(v.touch0[0]);
1967
- else if (v.end(), v.taps === 2 && (P = Nt(P, this), Math.hypot(d[0] - P[0], d[1] - P[1]) < $)) {
1968
- var h = at(this).on("dblclick.zoom");
1969
- h && h.apply(this, arguments);
1961
+ var y = $(this, b).event(f), D = f.changedTouches, X = D.length, S, z;
1962
+ for (_e(f), m && clearTimeout(m), m = setTimeout(function() {
1963
+ m = null;
1964
+ }, w), S = 0; S < X; ++S)
1965
+ z = D[S], y.touch0 && y.touch0[2] === z.identifier ? delete y.touch0 : y.touch1 && y.touch1[2] === z.identifier && delete y.touch1;
1966
+ if (y.touch1 && !y.touch0 && (y.touch0 = y.touch1, delete y.touch1), y.touch0) y.touch0[1] = this.__zoom.invert(y.touch0[0]);
1967
+ else if (y.end(), y.taps === 2 && (z = Xt(z, this), Math.hypot(d[0] - z[0], d[1] - z[1]) < V)) {
1968
+ var G = at(this).on("dblclick.zoom");
1969
+ G && G.apply(this, arguments);
1970
1970
  }
1971
1971
  }
1972
1972
  }
1973
- return Y.wheelDelta = function(f) {
1974
- return arguments.length ? (n = typeof f == "function" ? f : ie(+f), Y) : n;
1975
- }, Y.filter = function(f) {
1976
- return arguments.length ? (t = typeof f == "function" ? f : ie(!!f), Y) : t;
1977
- }, Y.touchable = function(f) {
1978
- return arguments.length ? (o = typeof f == "function" ? f : ie(!!f), Y) : o;
1979
- }, Y.extent = function(f) {
1980
- return arguments.length ? (e = typeof f == "function" ? f : ie([[+f[0][0], +f[0][1]], [+f[1][0], +f[1][1]]]), Y) : e;
1981
- }, Y.scaleExtent = function(f) {
1982
- return arguments.length ? (a[0] = +f[0], a[1] = +f[1], Y) : [a[0], a[1]];
1983
- }, Y.translateExtent = function(f) {
1984
- return arguments.length ? (i[0][0] = +f[0][0], i[1][0] = +f[1][0], i[0][1] = +f[0][1], i[1][1] = +f[1][1], Y) : [[i[0][0], i[0][1]], [i[1][0], i[1][1]]];
1985
- }, Y.constrain = function(f) {
1986
- return arguments.length ? (r = f, Y) : r;
1987
- }, Y.duration = function(f) {
1988
- return arguments.length ? (c = +f, Y) : c;
1989
- }, Y.interpolate = function(f) {
1990
- return arguments.length ? (l = f, Y) : l;
1991
- }, Y.on = function() {
1973
+ return x.wheelDelta = function(f) {
1974
+ return arguments.length ? (n = typeof f == "function" ? f : ae(+f), x) : n;
1975
+ }, x.filter = function(f) {
1976
+ return arguments.length ? (t = typeof f == "function" ? f : ae(!!f), x) : t;
1977
+ }, x.touchable = function(f) {
1978
+ return arguments.length ? (o = typeof f == "function" ? f : ae(!!f), x) : o;
1979
+ }, x.extent = function(f) {
1980
+ return arguments.length ? (e = typeof f == "function" ? f : ae([[+f[0][0], +f[0][1]], [+f[1][0], +f[1][1]]]), x) : e;
1981
+ }, x.scaleExtent = function(f) {
1982
+ return arguments.length ? (a[0] = +f[0], a[1] = +f[1], x) : [a[0], a[1]];
1983
+ }, x.translateExtent = function(f) {
1984
+ return arguments.length ? (i[0][0] = +f[0][0], i[1][0] = +f[1][0], i[0][1] = +f[0][1], i[1][1] = +f[1][1], x) : [[i[0][0], i[0][1]], [i[1][0], i[1][1]]];
1985
+ }, x.constrain = function(f) {
1986
+ return arguments.length ? (r = f, x) : r;
1987
+ }, x.duration = function(f) {
1988
+ return arguments.length ? (c = +f, x) : c;
1989
+ }, x.interpolate = function(f) {
1990
+ return arguments.length ? (l = f, x) : l;
1991
+ }, x.on = function() {
1992
1992
  var f = s.on.apply(s, arguments);
1993
- return f === s ? Y : f;
1994
- }, Y.clickDistance = function(f) {
1995
- return arguments.length ? (B = (f = +f) * f, Y) : Math.sqrt(B);
1996
- }, Y.tapDistance = function(f) {
1997
- return arguments.length ? ($ = +f, Y) : $;
1998
- }, Y;
1999
- }
2000
- const Ee = {
1993
+ return f === s ? x : f;
1994
+ }, x.clickDistance = function(f) {
1995
+ return arguments.length ? (B = (f = +f) * f, x) : Math.sqrt(B);
1996
+ }, x.tapDistance = function(f) {
1997
+ return arguments.length ? (V = +f, x) : V;
1998
+ }, x;
1999
+ }
2000
+ const be = {
2001
2001
  // Edge Routing
2002
2002
  horizontalExtension: 30,
2003
2003
  minEdgeDistance: 50,
@@ -2021,7 +2021,7 @@ const Ee = {
2021
2021
  };
2022
2022
  function Ea(t) {
2023
2023
  return {
2024
- ...Ee,
2024
+ ...be,
2025
2025
  ...t
2026
2026
  };
2027
2027
  }
@@ -2332,13 +2332,13 @@ function Ga(t) {
2332
2332
  if (o && a) {
2333
2333
  const i = a.getBBox(), c = o.parentElement;
2334
2334
  if (c) {
2335
- const l = c.clientWidth, s = c.clientHeight, u = i.width, d = i.height, p = i.x + u / 2, g = i.y + d / 2, R = 0.8 / Math.max(u / l, d / s), B = [
2336
- l / 2 - R * p,
2337
- s / 2 - R * g
2335
+ const l = c.clientWidth, s = c.clientHeight, u = i.width, d = i.height, m = i.x + u / 2, w = i.y + d / 2, _ = 0.8 / Math.max(u / l, d / s), B = [
2336
+ l / 2 - _ * m,
2337
+ s / 2 - _ * w
2338
2338
  ];
2339
2339
  e.call(
2340
2340
  n.transform,
2341
- Pt.translate(B[0], B[1]).scale(R)
2341
+ $t.translate(B[0], B[1]).scale(_)
2342
2342
  );
2343
2343
  }
2344
2344
  }
@@ -2375,10 +2375,10 @@ function Ya(t, e) {
2375
2375
  const u = s.getPosition();
2376
2376
  if (!u) return;
2377
2377
  const d = u[0];
2378
- let p = n.findIndex(
2379
- (g) => Math.abs(d - g) <= 20
2378
+ let m = n.findIndex(
2379
+ (w) => Math.abs(d - w) <= 20
2380
2380
  );
2381
- p === -1 && (p = n.length, n.push(d)), o.set(s._gvid, p);
2381
+ m === -1 && (m = n.length, n.push(d)), o.set(s._gvid, m);
2382
2382
  });
2383
2383
  const a = n.map((s, u) => ({ x: s, i: u })).sort((s, u) => s.x - u.x).map((s, u) => ({ oldIndex: s.i, newIndex: u })), i = /* @__PURE__ */ new Map();
2384
2384
  a.forEach(({ oldIndex: s, newIndex: u }) => {
@@ -2396,8 +2396,8 @@ function Ya(t, e) {
2396
2396
  if (u === void 0) return;
2397
2397
  const d = c.get(u);
2398
2398
  if (!d) return;
2399
- const p = Ra(s);
2400
- p && La(p, d, s.sourceNode);
2399
+ const m = Ra(s);
2400
+ m && La(m, d, s.sourceNode);
2401
2401
  });
2402
2402
  const l = /* @__PURE__ */ new Map();
2403
2403
  return e.forEach((s) => {
@@ -2405,12 +2405,12 @@ function Ya(t, e) {
2405
2405
  const u = o.get(s.sourceNode._gvid), d = o.get(s.targetNode._gvid);
2406
2406
  if (u === void 0 || d === void 0) return;
2407
2407
  s.depth = Math.abs(d - u) - 1, s.depth < 0 && (s.depth = 0);
2408
- const p = Math.min(u, d), g = Math.max(u, d), R = `${p}-${g}`;
2409
- l.has(R) || l.set(R, new Ca(u, d, 0)), l.get(R).addEdge(s);
2408
+ const m = Math.min(u, d), w = Math.max(u, d), _ = `${m}-${w}`;
2409
+ l.has(_) || l.set(_, new Ca(u, d, 0)), l.get(_).addEdge(s);
2410
2410
  }), l.forEach((s) => {
2411
2411
  s.edges.sort((u, d) => {
2412
- const p = u.getStartPoint(), g = u.getEndPoint(), R = p && g ? (p.y + g.y) / 2 : 0, B = d.getStartPoint(), $ = d.getEndPoint();
2413
- return (B && $ ? (B.y + $.y) / 2 : 0) - R;
2412
+ const m = u.getStartPoint(), w = u.getEndPoint(), _ = m && w ? (m.y + w.y) / 2 : 0, B = d.getStartPoint(), V = d.getEndPoint();
2413
+ return (B && V ? (B.y + V.y) / 2 : 0) - _;
2414
2414
  });
2415
2415
  }), { nodeColumnMap: o, nodeColumns: c, edgeColumns: l };
2416
2416
  }
@@ -2437,175 +2437,175 @@ function Ba(t, e) {
2437
2437
  const c = n.indexOf(i);
2438
2438
  r.setBaseEdge(i, c);
2439
2439
  const l = i.getStartPoint(), s = i.getEndPoint(), u = l && s ? (l.y + s.y) / 2 : 0;
2440
- o.forEach((d, p) => {
2440
+ o.forEach((d, m) => {
2441
2441
  if (d === i) return;
2442
- const g = d.getStartPoint(), R = d.getEndPoint();
2443
- (g && R ? (g.y + R.y) / 2 : 0) > u ? d.baseDirection = "above" : d.baseDirection = "below";
2442
+ const w = d.getStartPoint(), _ = d.getEndPoint();
2443
+ (w && _ ? (w.y + _.y) / 2 : 0) > u ? d.baseDirection = "above" : d.baseDirection = "below";
2444
2444
  });
2445
2445
  });
2446
2446
  }
2447
- function ae(t, e, r, n = Ee) {
2447
+ function se(t, e, r, n = be) {
2448
2448
  const o = t.getStartPoint(), a = t.getEndPoint(), i = t.getDirection();
2449
2449
  if (!o || !a || !i || i === "self")
2450
2450
  return;
2451
2451
  const c = { x: o.x, y: e - o.y }, l = { x: a.x, y: e - a.y };
2452
2452
  let s = { x: l.x, y: l.y };
2453
2453
  i === "right" ? s = { x: l.x - n.arrowWidth, y: l.y } : i === "left" && (s = { x: l.x + n.arrowWidth, y: l.y });
2454
- const u = n.horizontalExtension, d = n.minEdgeDistance, p = n.minVerticalSegment, g = (O) => {
2455
- if (O.length < 2) return O;
2456
- const U = [O[0]];
2457
- for (let et = 1; et < O.length; et++) {
2458
- const nt = U[U.length - 1];
2459
- (Math.abs(O[et].x - nt.x) > 0.1 || Math.abs(O[et].y - nt.y) > 0.1) && U.push(O[et]);
2454
+ const u = n.horizontalExtension, d = n.minEdgeDistance, m = n.minVerticalSegment, w = (N) => {
2455
+ if (N.length < 2) return N;
2456
+ const $ = [N[0]];
2457
+ for (let nt = 1; nt < N.length; nt++) {
2458
+ const it = $[$.length - 1];
2459
+ (Math.abs(N[nt].x - it.x) > 0.1 || Math.abs(N[nt].y - it.y) > 0.1) && $.push(N[nt]);
2460
2460
  }
2461
- return U;
2461
+ return $;
2462
2462
  };
2463
- let R;
2463
+ let _;
2464
2464
  const B = t.baseDirection === void 0;
2465
- t.baseDirection === "above" ? R = Math.min(c.y, s.y) : t.baseDirection === "below" ? R = Math.max(c.y, s.y) : R = (c.y + s.y) / 2;
2466
- let $ = R;
2465
+ t.baseDirection === "above" ? _ = Math.min(c.y, s.y) : t.baseDirection === "below" ? _ = Math.max(c.y, s.y) : _ = (c.y + s.y) / 2;
2466
+ let V = _;
2467
2467
  if (!B && r && r.midY !== void 0) {
2468
2468
  if (t.baseDirection === "above") {
2469
- const O = r.midY - d;
2470
- $ > O && ($ = O);
2469
+ const N = r.midY - d;
2470
+ V > N && (V = N);
2471
2471
  } else if (t.baseDirection === "below") {
2472
- const O = r.midY + d;
2473
- $ < O && ($ = O);
2472
+ const N = r.midY + d;
2473
+ V < N && (V = N);
2474
2474
  }
2475
2475
  }
2476
- const Y = Math.abs(c.y - s.y) < 5, J = (O, U) => {
2477
- const et = Math.abs(c.y - U), nt = Math.abs(U - s.y), G = i === "right" ? c.x + u : c.x - u, F = i === "right" ? s.x - u : s.x + u;
2478
- let H = [], Q = U;
2479
- switch (O) {
2476
+ const x = Math.abs(c.y - s.y) < 5, K = (N, $) => {
2477
+ const nt = Math.abs(c.y - $), it = Math.abs($ - s.y), A = i === "right" ? c.x + u : c.x - u, R = i === "right" ? s.x - u : s.x + u;
2478
+ let U = [], W = $;
2479
+ switch (N) {
2480
2480
  case "straight":
2481
- if (Y) {
2482
- const M = (c.y + s.y) / 2;
2483
- Math.abs(U - M) < p ? (H = [c, s], Q = M) : (H = [
2481
+ if (x) {
2482
+ const b = (c.y + s.y) / 2;
2483
+ Math.abs($ - b) < m ? (U = [c, s], W = b) : (U = [
2484
2484
  c,
2485
- { x: G, y: c.y },
2485
+ { x: A, y: c.y },
2486
2486
  // H: horizontal extension
2487
- { x: G, y: U },
2487
+ { x: A, y: $ },
2488
2488
  // V: vertical to midY
2489
- { x: F, y: U },
2489
+ { x: R, y: $ },
2490
2490
  // H: horizontal at midY
2491
- { x: F, y: s.y },
2491
+ { x: R, y: s.y },
2492
2492
  // V: vertical to end
2493
2493
  s
2494
2494
  // H: horizontal to end
2495
- ], Q = U);
2495
+ ], W = $);
2496
2496
  } else
2497
2497
  return null;
2498
2498
  break;
2499
2499
  case "2seg":
2500
- et < nt ? Math.abs(U - c.y) < p ? (H = [c, { x: s.x, y: c.y }, s], Q = c.y) : (H = [
2500
+ nt < it ? Math.abs($ - c.y) < m ? (U = [c, { x: s.x, y: c.y }, s], W = c.y) : (U = [
2501
2501
  c,
2502
- { x: G, y: c.y },
2502
+ { x: A, y: c.y },
2503
2503
  // H: horizontal extension
2504
- { x: G, y: U },
2504
+ { x: A, y: $ },
2505
2505
  // V: vertical to midY
2506
- { x: F, y: U },
2506
+ { x: R, y: $ },
2507
2507
  // H: horizontal at midY
2508
- { x: F, y: s.y },
2508
+ { x: R, y: s.y },
2509
2509
  // V: vertical to end
2510
2510
  s
2511
2511
  // H: horizontal to end
2512
- ], Q = U) : Math.abs(U - s.y) < p ? (H = [
2512
+ ], W = $) : Math.abs($ - s.y) < m ? (U = [
2513
2513
  c,
2514
- { x: G, y: c.y },
2514
+ { x: A, y: c.y },
2515
2515
  // H: horizontal extension
2516
- { x: G, y: s.y },
2516
+ { x: A, y: s.y },
2517
2517
  // V: vertical to end.y
2518
2518
  s
2519
2519
  // H: horizontal to end
2520
- ], Q = s.y) : (H = [
2520
+ ], W = s.y) : (U = [
2521
2521
  c,
2522
- { x: G, y: c.y },
2522
+ { x: A, y: c.y },
2523
2523
  // H: horizontal extension
2524
- { x: G, y: U },
2524
+ { x: A, y: $ },
2525
2525
  // V: vertical to midY
2526
- { x: F, y: U },
2526
+ { x: R, y: $ },
2527
2527
  // H: horizontal at midY
2528
- { x: F, y: s.y },
2528
+ { x: R, y: s.y },
2529
2529
  // V: vertical to end
2530
2530
  s
2531
2531
  // H: horizontal to end
2532
- ], Q = U);
2532
+ ], W = $);
2533
2533
  break;
2534
2534
  case "3seg":
2535
- const f = U;
2536
- H = [
2535
+ const f = $;
2536
+ U = [
2537
2537
  c,
2538
- { x: G, y: c.y },
2539
- { x: G, y: f },
2540
- { x: F, y: f },
2541
- { x: F, y: s.y },
2538
+ { x: A, y: c.y },
2539
+ { x: A, y: f },
2540
+ { x: R, y: f },
2541
+ { x: R, y: s.y },
2542
2542
  s
2543
- ], Q = f;
2543
+ ], W = f;
2544
2544
  break;
2545
2545
  case "4seg":
2546
- H = [
2546
+ U = [
2547
2547
  c,
2548
- { x: G, y: c.y },
2548
+ { x: A, y: c.y },
2549
2549
  // H: horizontal extension from start
2550
- { x: G, y: U },
2550
+ { x: A, y: $ },
2551
2551
  // V: vertical to midY
2552
- { x: F, y: U },
2552
+ { x: R, y: $ },
2553
2553
  // H: horizontal at midY to end extension
2554
2554
  s
2555
2555
  // Final segment (may be H or V depending on pathEnd.y vs testMidY)
2556
- ], Q = U;
2556
+ ], W = $;
2557
2557
  break;
2558
2558
  case "5seg":
2559
- if (et < p)
2560
- H = [
2559
+ if (nt < m)
2560
+ U = [
2561
2561
  c,
2562
- { x: G, y: c.y },
2562
+ { x: A, y: c.y },
2563
2563
  // H: horizontal extension
2564
- { x: F, y: U },
2564
+ { x: R, y: $ },
2565
2565
  // H: horizontal at midY (skip V since start.y ≈ testMidY)
2566
- { x: F, y: s.y },
2566
+ { x: R, y: s.y },
2567
2567
  // V: vertical to end Y
2568
2568
  s
2569
2569
  // H: horizontal to end
2570
- ], Q = U;
2571
- else if (nt < p)
2572
- H = [
2570
+ ], W = $;
2571
+ else if (it < m)
2572
+ U = [
2573
2573
  c,
2574
- { x: G, y: c.y },
2574
+ { x: A, y: c.y },
2575
2575
  // H: horizontal extension
2576
- { x: G, y: U },
2576
+ { x: A, y: $ },
2577
2577
  // V: vertical to midY
2578
- { x: F, y: U },
2578
+ { x: R, y: $ },
2579
2579
  // H: horizontal at midY
2580
2580
  s
2581
2581
  // H: horizontal to end (skip V since testMidY ≈ pathEnd.y)
2582
- ], Q = U;
2582
+ ], W = $;
2583
2583
  else
2584
2584
  return null;
2585
2585
  break;
2586
2586
  case "6seg":
2587
- H = [
2587
+ U = [
2588
2588
  c,
2589
- { x: G, y: c.y },
2590
- { x: G, y: U },
2591
- { x: F, y: U },
2592
- { x: F, y: s.y },
2589
+ { x: A, y: c.y },
2590
+ { x: A, y: $ },
2591
+ { x: R, y: $ },
2592
+ { x: R, y: s.y },
2593
2593
  s
2594
- ], Q = U;
2594
+ ], W = $;
2595
2595
  break;
2596
2596
  }
2597
- const N = g(H);
2598
- return N.length > 0 ? { points: N, actualMidY: Q } : null;
2597
+ const P = w(U);
2598
+ return P.length > 0 ? { points: P, actualMidY: W } : null;
2599
2599
  };
2600
- let j;
2601
- B ? j = Y ? ["straight", "3seg"] : ["3seg"] : j = Y ? ["straight", "3seg", "4seg", "5seg", "6seg"] : ["3seg", "4seg", "5seg", "6seg"];
2602
- for (const O of j) {
2603
- const U = J(O, $);
2604
- if (U)
2605
- return { midY: U.actualMidY, points: U.points };
2600
+ let Z;
2601
+ B ? Z = x ? ["straight", "3seg"] : ["3seg"] : Z = x ? ["straight", "3seg", "4seg", "5seg", "6seg"] : ["3seg", "4seg", "5seg", "6seg"];
2602
+ for (const N of Z) {
2603
+ const $ = K(N, V);
2604
+ if ($)
2605
+ return { midY: $.actualMidY, points: $.points };
2606
2606
  }
2607
- const A = J("6seg", $);
2608
- return A ? { midY: A.actualMidY, points: A.points } : void 0;
2607
+ const et = K("6seg", V);
2608
+ return et ? { midY: et.actualMidY, points: et.points } : void 0;
2609
2609
  }
2610
2610
  function hr(t, e) {
2611
2611
  if (t.length < 2) return "";
@@ -2616,239 +2616,239 @@ function hr(t, e) {
2616
2616
  for (let o = 1; o < t.length - 1; o++) {
2617
2617
  const a = t[o - 1], i = t[o], c = t[o + 1], l = Math.sqrt((i.x - a.x) ** 2 + (i.y - a.y) ** 2), s = Math.sqrt((c.x - i.x) ** 2 + (c.y - i.y) ** 2), u = Math.min(l, s) / 2, d = Math.min(e, u);
2618
2618
  if (d > 0) {
2619
- const p = d / l, g = d / s, R = {
2620
- x: i.x - (i.x - a.x) * p,
2621
- y: i.y - (i.y - a.y) * p
2619
+ const m = d / l, w = d / s, _ = {
2620
+ x: i.x - (i.x - a.x) * m,
2621
+ y: i.y - (i.y - a.y) * m
2622
2622
  }, B = {
2623
- x: i.x + (c.x - i.x) * g,
2624
- y: i.y + (c.y - i.y) * g
2623
+ x: i.x + (c.x - i.x) * w,
2624
+ y: i.y + (c.y - i.y) * w
2625
2625
  };
2626
- r.push(`L${R.x},${R.y}`), r.push(`Q${i.x},${i.y} ${B.x},${B.y}`);
2626
+ r.push(`L${_.x},${_.y}`), r.push(`Q${i.x},${i.y} ${B.x},${B.y}`);
2627
2627
  } else
2628
2628
  r.push(`L${i.x},${i.y}`);
2629
2629
  }
2630
2630
  const n = t[t.length - 1];
2631
2631
  return r.push(`L${n.x},${n.y}`), r.join(" ");
2632
2632
  }
2633
- function Pa(t, e, r, n = Ee, o = !0, a = 0, i = 1 / 0, c, l, s, u, d, p, g, R = !1) {
2634
- var U, et, nt, G;
2635
- const B = p != null && t.edgeIndex === p, $ = t.getColor(), Y = e.append("g").attr("class", B ? "edge selected" : "edge").attr("id", `edge_${t._gvid}`).attr("data-edge-id", t.edgeIndex !== void 0 ? String(t.edgeIndex) : "").attr("data-is-base", t.isBaseEdge ? "true" : "false").attr("data-color", $), J = t.getStartPoint(), j = t.getEndPoint(), A = t.getDirection();
2633
+ function Pa(t, e, r, n = be, o = !0, a = 0, i = 1 / 0, c, l, s, u, d, m, w, _ = !1) {
2634
+ var $, nt, it, A;
2635
+ const B = m != null && t.edgeIndex === m, V = t.getColor(), x = e.append("g").attr("class", B ? "edge selected" : "edge").attr("id", `edge_${t._gvid}`).attr("data-edge-id", t.edgeIndex !== void 0 ? String(t.edgeIndex) : "").attr("data-is-base", t.isBaseEdge ? "true" : "false").attr("data-color", V), K = t.getStartPoint(), Z = t.getEndPoint(), et = t.getDirection();
2636
2636
  console.log(
2637
- `Edge ${t._gvid}: direction=${A}, isBase=${t.isBaseEdge}, depth=${t.depth}`,
2637
+ `Edge ${t._gvid}: direction=${et}, isBase=${t.isBaseEdge}, depth=${t.depth}`,
2638
2638
  {
2639
- start: J,
2640
- end: j,
2641
- sourceNode: (U = t.sourceNode) == null ? void 0 : U.name,
2642
- targetNode: (et = t.targetNode) == null ? void 0 : et.name
2639
+ start: K,
2640
+ end: Z,
2641
+ sourceNode: ($ = t.sourceNode) == null ? void 0 : $.name,
2642
+ targetNode: (nt = t.targetNode) == null ? void 0 : nt.name
2643
2643
  }
2644
2644
  );
2645
- const O = n.arrowWidth;
2646
- if (n.arrowHeight, J && j && A) {
2647
- const F = { x: J.x, y: r - J.y }, H = { x: j.x, y: r - j.y }, Q = { x: H.x, y: H.y };
2648
- let N = { x: H.x, y: H.y };
2649
- A === "right" ? N = { x: H.x - O, y: H.y } : A === "left" ? N = { x: H.x + O, y: H.y } : A === "self" && (N = { x: H.x + O, y: H.y });
2645
+ const N = n.arrowWidth;
2646
+ if (n.arrowHeight, K && Z && et) {
2647
+ const R = { x: K.x, y: r - K.y }, U = { x: Z.x, y: r - Z.y }, W = { x: U.x, y: U.y };
2648
+ let P = { x: U.x, y: U.y };
2649
+ et === "right" ? P = { x: U.x - N, y: U.y } : et === "left" ? P = { x: U.x + N, y: U.y } : et === "self" && (P = { x: U.x + N, y: U.y });
2650
2650
  let f;
2651
- const M = n.loopRadius, v = n.horizontalExtension, D = n.cornerRadius;
2651
+ const b = n.loopRadius, y = n.horizontalExtension, D = n.cornerRadius;
2652
2652
  if (o)
2653
- if (A === "self")
2653
+ if (et === "self")
2654
2654
  if (t.virtualNode) {
2655
- const E = t.virtualNode.getPosition();
2656
- if (E) {
2657
- const m = r - E[1];
2658
- t.midY = m;
2659
- const x = [
2660
- F,
2655
+ const h = t.virtualNode.getPosition();
2656
+ if (h) {
2657
+ const C = r - h[1];
2658
+ t.midY = C;
2659
+ const E = [
2660
+ R,
2661
2661
  // leftOut of source node
2662
- { x: F.x - v, y: F.y },
2662
+ { x: R.x - y, y: R.y },
2663
2663
  // Extend left
2664
- { x: F.x - v, y: m },
2664
+ { x: R.x - y, y: C },
2665
2665
  // Go to virtual node height
2666
- { x: N.x + v, y: m },
2666
+ { x: P.x + y, y: C },
2667
2667
  // Horizontal segment through virtual node
2668
- { x: N.x + v, y: N.y },
2668
+ { x: P.x + y, y: P.y },
2669
2669
  // Go down to rightIn
2670
- N
2670
+ P
2671
2671
  // rightIn of source node
2672
2672
  ];
2673
- f = hr(x, D);
2673
+ f = hr(E, D);
2674
2674
  } else {
2675
- const m = F.x - M, x = F.y - M, b = N.x + M, y = N.y - M;
2676
- f = `M${F.x},${F.y} C${m},${x} ${b},${y} ${N.x},${N.y}`;
2675
+ const C = R.x - b, E = R.y - b, Y = P.x + b, g = P.y - b;
2676
+ f = `M${R.x},${R.y} C${C},${E} ${Y},${g} ${P.x},${P.y}`;
2677
2677
  }
2678
2678
  } else {
2679
- const E = F.x - M, m = F.y - M, x = N.x + M, b = N.y - M;
2680
- f = `M${F.x},${F.y} C${E},${m} ${x},${b} ${N.x},${N.y}`;
2679
+ const h = R.x - b, C = R.y - b, E = P.x + b, Y = P.y - b;
2680
+ f = `M${R.x},${R.y} C${h},${C} ${E},${Y} ${P.x},${P.y}`;
2681
2681
  }
2682
2682
  else {
2683
- let E;
2683
+ let h;
2684
2684
  if (t.orthogonalPathPoints && t.orthogonalPathPoints.length > 0)
2685
- E = t.orthogonalPathPoints;
2685
+ h = t.orthogonalPathPoints;
2686
2686
  else {
2687
- const m = Math.abs(F.y - t.midY), x = Math.abs(t.midY - N.y), b = 20, y = m >= b, C = x >= b, _ = A === "right" ? F.x + v : F.x - v, L = A === "right" ? N.x - v : N.x + v;
2688
- if (E = [], !y && !C) {
2689
- const q = (F.y + N.y) / 2;
2690
- E.push(
2691
- F,
2692
- { x: _, y: q },
2693
- { x: L, y: q },
2694
- N
2687
+ const C = Math.abs(R.y - t.midY), E = Math.abs(t.midY - P.y), Y = 20, g = C >= Y, v = E >= Y, L = et === "right" ? R.x + y : R.x - y, M = et === "right" ? P.x - y : P.x + y;
2688
+ if (h = [], !g && !v) {
2689
+ const F = (R.y + P.y) / 2;
2690
+ h.push(
2691
+ R,
2692
+ { x: L, y: F },
2693
+ { x: M, y: F },
2694
+ P
2695
2695
  );
2696
- } else y ? C ? E.push(
2697
- F,
2698
- { x: _, y: F.y },
2699
- { x: _, y: t.midY },
2696
+ } else g ? v ? h.push(
2697
+ R,
2698
+ { x: L, y: R.y },
2700
2699
  { x: L, y: t.midY },
2701
- { x: L, y: N.y },
2702
- N
2703
- ) : E.push(
2704
- F,
2705
- { x: _, y: F.y },
2706
- { x: _, y: t.midY },
2700
+ { x: M, y: t.midY },
2701
+ { x: M, y: P.y },
2702
+ P
2703
+ ) : h.push(
2704
+ R,
2705
+ { x: L, y: R.y },
2707
2706
  { x: L, y: t.midY },
2708
- N
2709
- ) : E.push(
2710
- F,
2711
- { x: _, y: t.midY },
2707
+ { x: M, y: t.midY },
2708
+ P
2709
+ ) : h.push(
2710
+ R,
2712
2711
  { x: L, y: t.midY },
2713
- { x: L, y: N.y },
2714
- N
2712
+ { x: M, y: t.midY },
2713
+ { x: M, y: P.y },
2714
+ P
2715
2715
  );
2716
2716
  }
2717
- f = hr(E, D);
2717
+ f = hr(h, D);
2718
2718
  }
2719
- else if (A === "self") {
2720
- const E = F.x - M, m = F.y - M, x = N.x + M, b = N.y - M;
2721
- f = `M${F.x},${F.y} C${E},${m} ${x},${b} ${N.x},${N.y}`;
2719
+ else if (et === "self") {
2720
+ const h = R.x - b, C = R.y - b, E = P.x + b, Y = P.y - b;
2721
+ f = `M${R.x},${R.y} C${h},${C} ${E},${Y} ${P.x},${P.y}`;
2722
2722
  } else {
2723
- const E = N.x - F.x;
2724
- N.y - F.y;
2725
- const m = 0.4, x = F.x + E * m, b = F.y, y = N.x - E * m, C = N.y;
2726
- f = `M${F.x},${F.y} C${x},${b} ${y},${C} ${N.x},${N.y}`;
2723
+ const h = P.x - R.x;
2724
+ P.y - R.y;
2725
+ const C = 0.4, E = R.x + h * C, Y = R.y, g = P.x - h * C, v = P.y;
2726
+ f = `M${R.x},${R.y} C${E},${Y} ${g},${v} ${P.x},${P.y}`;
2727
2727
  }
2728
- const X = R && t.isBaseEdge ? "#000000" : t.getColor(), I = R && t.isBaseEdge ? 4 : 1.5;
2729
- Y.append("path").attr("d", f).attr("fill", "none").attr("stroke", "transparent").attr("stroke-width", 10).attr("class", "edge-hit-area").style("cursor", "pointer"), Y.append("path").attr("d", f).attr("fill", "none").attr("stroke", X).attr("stroke-width", I).attr("class", "edge-path").style("pointer-events", "none"), Y.on("mouseenter", function() {
2728
+ const X = _ && t.isBaseEdge ? "#000000" : t.getColor(), S = _ && t.isBaseEdge ? 4 : 1.5;
2729
+ x.append("path").attr("d", f).attr("fill", "none").attr("stroke", "transparent").attr("stroke-width", 10).attr("class", "edge-hit-area").style("cursor", "pointer"), x.append("path").attr("d", f).attr("fill", "none").attr("stroke", X).attr("stroke-width", S).attr("class", "edge-path").style("pointer-events", "none"), x.on("mouseenter", function() {
2730
2730
  at(this).raise();
2731
2731
  });
2732
- const P = 12;
2733
- let h = "";
2734
- A === "right" ? h = `translate(${Q.x - P}, ${Q.y - P / 2})` : A === "left" ? h = `translate(${Q.x + P}, ${Q.y + P / 2}) rotate(180)` : A === "self" && (h = `translate(${Q.x + P}, ${Q.y + P / 2}) rotate(180)`), Y.append("use").attr("class", "edge-arrow").attr("href", "#arrow-right").attr("width", P).attr("height", P).attr("transform", h).attr("fill", X).attr("stroke", X).style("stroke-width", 0);
2735
- const w = {
2736
- x: (F.x + N.x) / 2,
2732
+ const z = 12;
2733
+ let G = "";
2734
+ et === "right" ? G = `translate(${W.x - z}, ${W.y - z / 2})` : et === "left" ? G = `translate(${W.x + z}, ${W.y + z / 2}) rotate(180)` : et === "self" && (G = `translate(${W.x + z}, ${W.y + z / 2}) rotate(180)`), x.append("use").attr("class", "edge-arrow").attr("href", "#arrow-right").attr("width", z).attr("height", z).attr("transform", G).attr("fill", X).attr("stroke", X).style("stroke-width", 0);
2735
+ const p = {
2736
+ x: (R.x + P.x) / 2,
2737
2737
  y: t.midY
2738
2738
  };
2739
2739
  if (t.label) {
2740
- let E = "";
2741
- (nt = t.edgeContent) != null && nt.elems && t.edgeContent.elems.length > 0 && (E = t.edgeContent.elems.map((ct) => ct.text).join(" ")), E || (E = _a(t.label).map((mt) => mt.length > 20 ? mt.slice(0, 20) + "..." : mt).join(" "));
2742
- const m = E.length > 60 ? E.slice(0, 60) + "..." : E, x = n.labelFontSize, b = x * 0.6, y = m.length * b, C = x, _ = n.labelPadding, L = 16, q = B ? 16 : 0, rt = t.edgeIndex !== void 0, Z = rt && t.edgeIndex > a, S = rt && t.edgeIndex < i, T = (Z ? L : 0) + (S ? L : 0) + q, z = y + _ * 2 + T, k = C + _ * 2, tt = n.labelCornerRadius, ot = w.y, V = w.x, K = (ct) => at(`g.edge[data-edge-id="${ct}"]`), W = 12, it = Y.append("g").attr("class", "label-area");
2743
- it.append("rect").attr("class", "label-bg").attr("x", V - z / 2).attr("y", ot - k / 2).attr("width", z).attr("height", k).attr("rx", tt).attr("ry", tt).attr("fill", "white").attr("stroke", X).attr("stroke-width", 1);
2744
- const ht = V - z / 2 + L / 2, st = V + z / 2 - L / 2 - q, be = V + z / 2 - q / 2, It = V + (Z ? L / 2 : 0) - (S ? L / 2 : 0) - (B ? q / 2 : 0);
2745
- if (rt && g && Y.style("cursor", "pointer").on("click", function(ct) {
2746
- ct.stopPropagation(), !B && g(t.edgeIndex);
2747
- }), (G = t.edgeContent) != null && G.elems && t.edgeContent.elems.length > 0) {
2748
- const Mt = t.edgeContent.elems.map((lt) => {
2749
- const pt = lt.text.length * 6.2, vt = lt.background && lt.background !== "transparent", Ot = pt + 2;
2750
- return { textWidth: pt, hasBackground: vt, totalWidth: Ot };
2751
- }), _t = Mt.reduce((lt, pt, vt) => lt + pt.totalWidth + (vt > 0, 0), 0);
2752
- let gt = It - _t / 2;
2753
- t.edgeContent.elems.forEach((lt, pt) => {
2754
- const vt = Mt[pt];
2755
- pt > 0 && (gt += 0), vt.hasBackground && it.append("rect").attr("x", gt).attr("y", ot - 10 / 2 - 2).attr("width", vt.totalWidth).attr("height", 14).attr("rx", 2).attr("ry", 2).attr("fill", lt.background).style("pointer-events", "none"), it.append("text").attr("class", "label-text-elem").attr("x", gt + 1).attr("y", ot).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "Inter, Helvetica, Arial").attr("font-size", "10px").attr("font-weight", "500").attr("fill", lt.color && lt.color.length > 0 ? lt.color : X).style("pointer-events", "none").text(lt.text), gt += vt.totalWidth;
2740
+ let h = "";
2741
+ (it = t.edgeContent) != null && it.elems && t.edgeContent.elems.length > 0 && (h = t.edgeContent.elems.map((st) => st.text).join(" ")), h || (h = _a(t.label).map((pt) => pt.length > 20 ? pt.slice(0, 20) + "..." : pt).join(" "));
2742
+ const C = h.length > 60 ? h.slice(0, 60) + "..." : h, E = n.labelFontSize, Y = E * 0.6, g = C.length * Y, v = E, L = n.labelPadding, M = 16, F = B ? 16 : 0, q = t.edgeIndex !== void 0, ot = q && t.edgeIndex > a, Q = q && t.edgeIndex < i, I = (ot ? M : 0) + (Q ? M : 0) + F, k = g + L * 2 + I, O = v + L * 2, j = n.labelCornerRadius, tt = p.y, rt = p.x, J = (st) => at(`g.edge[data-edge-id="${st}"]`), H = 12, T = x.append("g").attr("class", "label-area");
2743
+ T.append("rect").attr("class", "label-bg").attr("x", rt - k / 2).attr("y", tt - O / 2).attr("width", k).attr("height", O).attr("rx", j).attr("ry", j).attr("fill", "white").attr("stroke", X).attr("stroke-width", 1);
2744
+ const lt = rt - k / 2 + M / 2, dt = rt + k / 2 - M / 2 - F, bt = rt + k / 2 - F / 2, ut = rt + (ot ? M / 2 : 0) - (Q ? M / 2 : 0) - (B ? F / 2 : 0);
2745
+ if (q && w && x.style("cursor", "pointer").on("click", function(st) {
2746
+ st.stopPropagation(), !B && w(t.edgeIndex);
2747
+ }), (A = t.edgeContent) != null && A.elems && t.edgeContent.elems.length > 0) {
2748
+ const vt = t.edgeContent.elems.map((ct) => {
2749
+ const mt = ct.text.length * 6.2, yt = ct.background && ct.background !== "transparent", Tt = mt + 2;
2750
+ return { textWidth: mt, hasBackground: yt, totalWidth: Tt };
2751
+ }), Rt = vt.reduce((ct, mt, yt) => ct + mt.totalWidth + (yt > 0, 0), 0);
2752
+ let Et = ut - Rt / 2;
2753
+ t.edgeContent.elems.forEach((ct, mt) => {
2754
+ const yt = vt[mt];
2755
+ mt > 0 && (Et += 0), yt.hasBackground && T.append("rect").attr("x", Et).attr("y", tt - 10 / 2 - 2).attr("width", yt.totalWidth).attr("height", 14).attr("rx", 2).attr("ry", 2).attr("fill", ct.background).style("pointer-events", "none"), T.append("text").attr("class", "label-text-elem").attr("x", Et + 1).attr("y", tt).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "Inter, Helvetica, Arial").attr("font-size", "10px").attr("font-weight", "500").attr("fill", ct.color && ct.color.length > 0 ? ct.color : X).style("pointer-events", "none").text(ct.text), Et += yt.totalWidth;
2756
2756
  });
2757
2757
  } else
2758
- it.append("text").attr("class", "label-text").attr("x", It).attr("y", ot).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "Inter, Helvetica, Arial").attr("font-size", "10px").attr("fill", X).style("pointer-events", "none").text(m);
2759
- if (R && Y.append("circle").attr("cx", It).attr("cy", ot).attr("r", 4).attr("fill", "blue").attr("opacity", 0.8).style("pointer-events", "none").attr("class", "debug-label-center"), Z) {
2760
- const ct = t.edgeIndex - 1, mt = it.append("g").attr("class", "nav-btn-group prev-btn-group");
2761
- mt.append("rect").attr("class", "nav-btn-area prev-btn-area").attr("x", V - z / 2).attr("y", ot - k / 2).attr("width", L).attr("height", k).attr("fill", "transparent").attr("rx", tt).style("cursor", "pointer").style("pointer-events", "all"), mt.append("use").attr("class", "nav-icon prev-icon").attr("href", "#nav-left").attr("x", ht - W / 2).attr("y", ot - W / 2).attr("width", W).attr("height", W).attr("fill", "#888"), mt.on("click", function(dt) {
2762
- dt.stopPropagation();
2763
- const Et = K(ct);
2764
- if (!Et.empty()) {
2758
+ T.append("text").attr("class", "label-text").attr("x", ut).attr("y", tt).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "Inter, Helvetica, Arial").attr("font-size", "10px").attr("fill", X).style("pointer-events", "none").text(C);
2759
+ if (_ && x.append("circle").attr("cx", ut).attr("cy", tt).attr("r", 4).attr("fill", "blue").attr("opacity", 0.8).style("pointer-events", "none").attr("class", "debug-label-center"), ot) {
2760
+ const st = t.edgeIndex - 1, pt = T.append("g").attr("class", "nav-btn-group prev-btn-group");
2761
+ pt.append("rect").attr("class", "nav-btn-area prev-btn-area").attr("x", rt - k / 2).attr("y", tt - O / 2).attr("width", M).attr("height", O).attr("fill", "transparent").attr("rx", j).style("cursor", "pointer").style("pointer-events", "all"), pt.append("use").attr("class", "nav-icon prev-icon").attr("href", "#nav-left").attr("x", lt - H / 2).attr("y", tt - H / 2).attr("width", H).attr("height", H).attr("fill", "#888"), pt.on("click", function(Bt) {
2762
+ Bt.stopPropagation();
2763
+ const wt = J(st);
2764
+ if (!wt.empty()) {
2765
2765
  if (c && l && s && u && d) {
2766
- const bt = Et.node();
2767
- if (bt) {
2768
- const Mt = at(bt).select(".label-text").node();
2769
- let _t, gt;
2770
- if (Mt)
2771
- _t = parseFloat(Mt.getAttribute("x") || "0"), gt = parseFloat(Mt.getAttribute("y") || "0");
2766
+ const xt = wt.node();
2767
+ if (xt) {
2768
+ const vt = at(xt).select(".label-text").node();
2769
+ let Rt, Et;
2770
+ if (vt)
2771
+ Rt = parseFloat(vt.getAttribute("x") || "0"), Et = parseFloat(vt.getAttribute("y") || "0");
2772
2772
  else {
2773
- const kt = bt.getBBox();
2774
- _t = kt.x + kt.width / 2, gt = kt.y + kt.height / 2;
2773
+ const zt = xt.getBBox();
2774
+ Rt = zt.x + zt.width / 2, Et = zt.y + zt.height / 2;
2775
2775
  }
2776
- const lt = s.clientWidth, pt = 1.2 * u / lt, vt = u / 2 - _t * pt, Ot = d / 2 - gt * pt;
2776
+ const ct = s.clientWidth, mt = 1.2 * u / ct, yt = u / 2 - Rt * mt, Tt = d / 2 - Et * mt;
2777
2777
  l.transition().duration(500).call(
2778
2778
  c.transform,
2779
- Pt.translate(vt, Ot).scale(pt)
2779
+ $t.translate(yt, Tt).scale(mt)
2780
2780
  );
2781
2781
  }
2782
2782
  }
2783
- g && g(ct);
2783
+ w && w(st);
2784
2784
  }
2785
2785
  });
2786
2786
  }
2787
- if (S && t.edgeIndex !== void 0) {
2788
- const ct = t.edgeIndex + 1, mt = B ? st : V + z / 2 - L / 2, dt = it.append("g").attr("class", "nav-btn-group next-btn-group");
2789
- dt.append("rect").attr("class", "nav-btn-area next-btn-area").attr("x", V + z / 2 - L - q).attr("y", ot - k / 2).attr("width", L).attr("height", k).attr("fill", "transparent").attr("rx", tt).style("cursor", "pointer").style("pointer-events", "all"), dt.append("use").attr("class", "nav-icon next-icon").attr("href", "#nav-right").attr("x", mt - W / 2).attr("y", ot - W / 2).attr("width", W).attr("height", W).attr("fill", "#888"), dt.on("click", function(Et) {
2790
- Et.stopPropagation();
2791
- const bt = K(ct);
2792
- if (!bt.empty()) {
2787
+ if (Q && t.edgeIndex !== void 0) {
2788
+ const st = t.edgeIndex + 1, pt = B ? dt : rt + k / 2 - M / 2, Bt = T.append("g").attr("class", "nav-btn-group next-btn-group");
2789
+ Bt.append("rect").attr("class", "nav-btn-area next-btn-area").attr("x", rt + k / 2 - M - F).attr("y", tt - O / 2).attr("width", M).attr("height", O).attr("fill", "transparent").attr("rx", j).style("cursor", "pointer").style("pointer-events", "all"), Bt.append("use").attr("class", "nav-icon next-icon").attr("href", "#nav-right").attr("x", pt - H / 2).attr("y", tt - H / 2).attr("width", H).attr("height", H).attr("fill", "#888"), Bt.on("click", function(wt) {
2790
+ wt.stopPropagation();
2791
+ const xt = J(st);
2792
+ if (!xt.empty()) {
2793
2793
  if (c && l && s && u && d) {
2794
- const Mt = bt.node();
2795
- if (Mt) {
2796
- const _t = at(Mt).select(".label-text").node();
2797
- let gt, lt;
2798
- if (_t)
2799
- gt = parseFloat(_t.getAttribute("x") || "0"), lt = parseFloat(_t.getAttribute("y") || "0");
2794
+ const vt = xt.node();
2795
+ if (vt) {
2796
+ const Rt = at(vt).select(".label-text").node();
2797
+ let Et, ct;
2798
+ if (Rt)
2799
+ Et = parseFloat(Rt.getAttribute("x") || "0"), ct = parseFloat(Rt.getAttribute("y") || "0");
2800
2800
  else {
2801
- const ee = Mt.getBBox();
2802
- gt = ee.x + ee.width / 2, lt = ee.y + ee.height / 2;
2801
+ const re = vt.getBBox();
2802
+ Et = re.x + re.width / 2, ct = re.y + re.height / 2;
2803
2803
  }
2804
- const pt = s.clientWidth, vt = 1.2 * u / pt, Ot = u / 2 - gt * vt, kt = d / 2 - lt * vt;
2804
+ const mt = s.clientWidth, yt = 1.2 * u / mt, Tt = u / 2 - Et * yt, zt = d / 2 - ct * yt;
2805
2805
  l.transition().duration(500).call(
2806
2806
  c.transform,
2807
- Pt.translate(Ot, kt).scale(vt)
2807
+ $t.translate(Tt, zt).scale(yt)
2808
2808
  );
2809
2809
  }
2810
2810
  }
2811
- g && g(ct);
2811
+ w && w(st);
2812
2812
  }
2813
2813
  });
2814
2814
  }
2815
- B && rt && g && Y.append("text").attr("class", "close-btn").attr("x", be).attr("y", ot).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "Arial").attr("font-size", "12px").attr("font-weight", "bold").attr("fill", "#888").style("cursor", "pointer").text("✕").on("mouseenter", function() {
2815
+ B && q && w && x.append("text").attr("class", "close-btn").attr("x", bt).attr("y", tt).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "Arial").attr("font-size", "12px").attr("font-weight", "bold").attr("fill", "#888").style("cursor", "pointer").text("✕").on("mouseenter", function() {
2816
2816
  at(this).attr("fill", "#EF4444");
2817
2817
  }).on("mouseleave", function() {
2818
2818
  at(this).attr("fill", "#888");
2819
- }).on("click", function(ct) {
2820
- ct.stopPropagation(), g(null);
2819
+ }).on("click", function(st) {
2820
+ st.stopPropagation(), w(null);
2821
2821
  });
2822
- } else t._ldraw_ && t._ldraw_.forEach((E) => {
2823
- if (E.op === "T" && E.text) {
2824
- const m = E.size || 10, x = m * 0.6, b = E.text.length * x, y = m, C = 6, _ = b + C * 2, L = y + C * 2, q = 4, rt = w.y;
2825
- Y.append("rect").attr("x", w.x - _ / 2).attr("y", rt - L / 2).attr("width", _).attr("height", L).attr("rx", q).attr("ry", q).attr("fill", "white").attr("stroke", "#d0d0d0").attr("stroke-width", 0.5), Y.append("text").attr("x", w.x).attr("y", rt).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", E.face || "Inter, Helvetica, Arial").attr("font-size", `${m}px`).attr("fill", E.color || "#666").text(E.text);
2822
+ } else t._ldraw_ && t._ldraw_.forEach((h) => {
2823
+ if (h.op === "T" && h.text) {
2824
+ const C = h.size || 10, E = C * 0.6, Y = h.text.length * E, g = C, v = 6, L = Y + v * 2, M = g + v * 2, F = 4, q = p.y;
2825
+ x.append("rect").attr("x", p.x - L / 2).attr("y", q - M / 2).attr("width", L).attr("height", M).attr("rx", F).attr("ry", F).attr("fill", "white").attr("stroke", "#d0d0d0").attr("stroke-width", 0.5), x.append("text").attr("x", p.x).attr("y", q).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", h.face || "Inter, Helvetica, Arial").attr("font-size", `${C}px`).attr("fill", h.color || "#666").text(h.text);
2826
2826
  }
2827
2827
  });
2828
- if (R) {
2829
- let E;
2830
- t.depth === 0 ? E = `d:0 dir:${t.baseDirection || "base"} off:${t.baseOffset} id:${t._gvid}` : E = `d:${t.depth} dir:${t.baseDirection || "?"} midY:${Math.round(t.midY)} id:${t._gvid}`, Y.append("text").attr("x", w.x).attr("y", w.y + 15).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "monospace").attr("font-size", "9px").attr("fill", "#999").text(E);
2828
+ if (_) {
2829
+ let h;
2830
+ t.depth === 0 ? h = `d:0 dir:${t.baseDirection || "base"} off:${t.baseOffset} id:${t._gvid}` : h = `d:${t.depth} dir:${t.baseDirection || "?"} midY:${Math.round(t.midY)} id:${t._gvid}`, x.append("text").attr("x", p.x).attr("y", p.y + 15).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "monospace").attr("font-size", "9px").attr("fill", "#999").text(h);
2831
2831
  }
2832
2832
  } else
2833
- t._draw_ && t._draw_.forEach((F) => {
2834
- if (F.op === "b" && F.points) {
2835
- const H = F.points.map(([N, f]) => [N, r - f]), Q = `M${H[0][0]},${H[0][1]} C${H.slice(1).map((N) => `${N[0]},${N[1]}`).join(" ")}`;
2836
- Y.append("path").attr("d", Q).attr("fill", "none").attr("stroke", F.color || "#9AA4B2").attr("stroke-width", 2);
2833
+ t._draw_ && t._draw_.forEach((R) => {
2834
+ if (R.op === "b" && R.points) {
2835
+ const U = R.points.map(([P, f]) => [P, r - f]), W = `M${U[0][0]},${U[0][1]} C${U.slice(1).map((P) => `${P[0]},${P[1]}`).join(" ")}`;
2836
+ x.append("path").attr("d", W).attr("fill", "none").attr("stroke", R.color || "#9AA4B2").attr("stroke-width", 2);
2837
2837
  }
2838
- }), t._hdraw_ && t._hdraw_.forEach((F) => {
2839
- if (F.op === "P" && F.points) {
2840
- const H = F.points.map(([Q, N]) => [Q, r - N]);
2841
- Y.append("polygon").attr("points", H.map((Q) => Q.join(",")).join(" ")).attr("fill", F.color || "#9AA4B2");
2838
+ }), t._hdraw_ && t._hdraw_.forEach((R) => {
2839
+ if (R.op === "P" && R.points) {
2840
+ const U = R.points.map(([W, P]) => [W, r - P]);
2841
+ x.append("polygon").attr("points", U.map((W) => W.join(",")).join(" ")).attr("fill", R.color || "#9AA4B2");
2842
2842
  }
2843
- }), t._ldraw_ && $t(Y, t._ldraw_, r);
2843
+ }), t._ldraw_ && St(x, t._ldraw_, r);
2844
2844
  }
2845
- function Na(t, e, r, n, o = !0, a = Ee, i = !0, c = 14, l = !1, s, u, d, p, g) {
2846
- var P;
2845
+ function Na(t, e, r, n, o = !0, a = be, i = !0, c = 14, l = !1, s, u, d, m, w, _ = !0) {
2846
+ var G;
2847
2847
  t.innerHTML = "";
2848
- const R = ((P = e.bb) == null ? void 0 : P.split(",").map(Number)) || [0, 0, 1e3, 800];
2849
- let [, , B, $] = R;
2850
- const Y = at(t).append("svg").attr("width", "100%").attr("height", "100%").attr("viewBox", `0 0 ${B} ${$}`).style("background", "white");
2851
- Y.append("defs").html(`
2848
+ const B = ((G = e.bb) == null ? void 0 : G.split(",").map(Number)) || [0, 0, 1e3, 800];
2849
+ let [, , V, x] = B;
2850
+ const K = at(t).append("svg").attr("width", "100%").attr("height", "100%").attr("viewBox", `0 0 ${V} ${x}`).style("background", "white");
2851
+ K.append("defs").html(`
2852
2852
  <style>
2853
2853
  @keyframes selected-pulse {
2854
2854
  0%, 100% {
@@ -2920,386 +2920,386 @@ function Na(t, e, r, n, o = !0, a = Ee, i = !0, c = 14, l = !1, s, u, d, p, g) {
2920
2920
  <path d="M22.7076 16.7071L12.7076 26.7071C12.6147 26.8 12.5044 26.8737 12.383 26.924C12.2616 26.9743 12.1315 27.0001 12.0001 27.0001C11.8687 27.0001 11.7386 26.9743 11.6172 26.924C11.4958 26.8737 11.3855 26.8 11.2926 26.7071C11.1997 26.6142 11.126 26.5039 11.0757 26.3825C11.0254 26.2611 10.9995 26.131 10.9995 25.9996C10.9995 25.8682 11.0254 25.7381 11.0757 25.6167C11.126 25.4953 11.1997 25.385 11.2926 25.2921L20.5863 15.9996L11.2926 6.70708C11.1049 6.51944 10.9995 6.26494 10.9995 5.99958C10.9995 5.73422 11.1049 5.47972 11.2926 5.29208C11.4802 5.10444 11.7347 4.99902 12.0001 4.99902C12.2654 4.99902 12.5199 5.10444 12.7076 5.29208L22.7076 15.2921C22.8005 15.385 22.8743 15.4952 22.9246 15.6166C22.975 15.738 23.0009 15.8682 23.0009 15.9996C23.0009 16.131 22.975 16.2611 22.9246 16.3825C22.8743 16.5039 22.8005 16.6142 22.7076 16.7071Z"/>
2921
2921
  </symbol>
2922
2922
  `);
2923
- const J = Y.append("g").attr("id", "graph0");
2924
- l && Y.append("circle").attr("cx", B / 2).attr("cy", $ / 2).attr("r", 8).attr("fill", "red").attr("opacity", 0.9).style("pointer-events", "none").attr("class", "debug-center-marker");
2925
- const A = (e.objects || []).map(
2926
- (h) => new jr({
2927
- _gvid: h._gvid,
2928
- name: h.name,
2929
- _draw_: h._draw_,
2930
- _ldraw_: h._ldraw_,
2931
- bb: h.bb,
2932
- pos: h.pos,
2923
+ const Z = K.append("g").attr("id", "graph0");
2924
+ l && K.append("circle").attr("cx", V / 2).attr("cy", x / 2).attr("r", 8).attr("fill", "red").attr("opacity", 0.9).style("pointer-events", "none").attr("class", "debug-center-marker");
2925
+ const N = (e.objects || []).map(
2926
+ (p) => new jr({
2927
+ _gvid: p._gvid,
2928
+ name: p.name,
2929
+ _draw_: p._draw_,
2930
+ _ldraw_: p._ldraw_,
2931
+ bb: p.bb,
2932
+ pos: p.pos,
2933
2933
  // Apply custom node dimensions if provided (convert points to inches)
2934
- width: d !== void 0 ? String(d / 72) : h.width,
2935
- height: p !== void 0 ? String(p / 72) : h.height,
2936
- label: h.label
2934
+ width: d !== void 0 ? String(d / 72) : p.width,
2935
+ height: m !== void 0 ? String(m / 72) : p.height,
2936
+ label: p.label
2937
2937
  })
2938
- ), O = /* @__PURE__ */ new Map();
2939
- A.forEach((h) => {
2940
- O.set(h._gvid, h);
2938
+ ), $ = /* @__PURE__ */ new Map();
2939
+ N.forEach((p) => {
2940
+ $.set(p._gvid, p);
2941
2941
  });
2942
- const et = (e.edges || []).map((h) => {
2943
- const w = new Ma({
2944
- _gvid: h._gvid,
2945
- name: h.name,
2946
- _draw_: h._draw_,
2947
- _ldraw_: h._ldraw_,
2948
- _hdraw_: h._hdraw_,
2949
- _tdraw_: h._tdraw_,
2950
- head: h.head,
2951
- tail: h.tail,
2952
- label: h.label
2953
- }), E = h.tail !== void 0 ? O.get(h.tail) : void 0, m = h.head !== void 0 ? O.get(h.head) : void 0;
2954
- return E && m && w.setNodes(E, m), w;
2955
- }), { nodeColumnMap: nt, nodeColumns: G, edgeColumns: F } = Ya(
2956
- A,
2957
- et
2942
+ const it = (e.edges || []).map((p) => {
2943
+ const h = new Ma({
2944
+ _gvid: p._gvid,
2945
+ name: p.name,
2946
+ _draw_: p._draw_,
2947
+ _ldraw_: p._ldraw_,
2948
+ _hdraw_: p._hdraw_,
2949
+ _tdraw_: p._tdraw_,
2950
+ head: p.head,
2951
+ tail: p.tail,
2952
+ label: p.label
2953
+ }), C = p.tail !== void 0 ? $.get(p.tail) : void 0, E = p.head !== void 0 ? $.get(p.head) : void 0;
2954
+ return C && E && h.setNodes(C, E), h;
2955
+ }), { nodeColumnMap: A, nodeColumns: R, edgeColumns: U } = Ya(
2956
+ N,
2957
+ it
2958
2958
  );
2959
- console.log("debug:", { nodeColumnMap: nt, nodeColumns: G, edgeColumns: F }), console.log(
2959
+ console.log("debug:", { nodeColumnMap: A, nodeColumns: R, edgeColumns: U }), console.log(
2960
2960
  "debug: edges sorted by midpoint Y:",
2961
2961
  Object.fromEntries(
2962
- Array.from(F.entries()).map(([h, w]) => [
2963
- h,
2964
- w.edges.map((E) => {
2965
- const m = E.getStartPoint(), x = E.getEndPoint(), b = m && x ? (m.y + x.y) / 2 : 0;
2962
+ Array.from(U.entries()).map(([p, h]) => [
2963
+ p,
2964
+ h.edges.map((C) => {
2965
+ const E = C.getStartPoint(), Y = C.getEndPoint(), g = E && Y ? (E.y + Y.y) / 2 : 0;
2966
2966
  return {
2967
- name: E.name,
2968
- edgeIndex: E.edgeIndex,
2969
- direction: E.getDirection(),
2970
- startPoint: E.getStartPoint(),
2971
- endPoint: E.getEndPoint(),
2972
- midpointY: b.toFixed(2)
2967
+ name: C.name,
2968
+ edgeIndex: C.edgeIndex,
2969
+ direction: C.getDirection(),
2970
+ startPoint: C.getStartPoint(),
2971
+ endPoint: C.getEndPoint(),
2972
+ midpointY: g.toFixed(2)
2973
2973
  };
2974
2974
  })
2975
2975
  ])
2976
2976
  )
2977
2977
  );
2978
- const H = Array.from(G.keys()).sort((h, w) => h - w), Q = H.length, N = 80;
2979
- let f;
2980
- if (g !== void 0)
2981
- f = g, B = (Q > 1 ? (Q - 1) * f : 0) + 2 * N;
2978
+ const W = Array.from(R.keys()).sort((p, h) => p - h), P = W.length, f = 80;
2979
+ let b;
2980
+ if (w !== void 0)
2981
+ b = w, V = (P > 1 ? (P - 1) * b : 0) + 2 * f;
2982
2982
  else {
2983
- const h = B - 2 * N;
2984
- f = Q > 1 ? h / (Q - 1) : 0;
2985
- }
2986
- if (H.forEach((h, w) => {
2987
- const E = G.get(h);
2988
- if (!E) return;
2989
- const m = E.nodes;
2990
- if (m.length === 0) return;
2983
+ const p = V - 2 * f;
2984
+ b = P > 1 ? p / (P - 1) : 0;
2985
+ }
2986
+ if (W.forEach((p, h) => {
2987
+ const C = R.get(p);
2988
+ if (!C) return;
2989
+ const E = C.nodes;
2990
+ if (E.length === 0) return;
2991
2991
  console.log(
2992
- `Column ${h} before sort:`,
2993
- m.map((S) => ({
2994
- name: S.name,
2995
- isVirtual: S.virtualNode,
2996
- pos: S.pos
2992
+ `Column ${p} before sort:`,
2993
+ E.map((I) => ({
2994
+ name: I.name,
2995
+ isVirtual: I.virtualNode,
2996
+ pos: I.pos
2997
2997
  }))
2998
2998
  );
2999
- const x = Q > 1 ? N + w * f : B / 2;
3000
- m.sort((S, T) => {
3001
- const z = S.getPosition(), k = T.getPosition();
3002
- return !z || !k ? 0 : k[1] - z[1];
2999
+ const Y = P > 1 ? f + h * b : V / 2;
3000
+ E.sort((I, k) => {
3001
+ const O = I.getPosition(), j = k.getPosition();
3002
+ return !O || !j ? 0 : j[1] - O[1];
3003
3003
  }), console.log(
3004
- `Column ${h} after sort:`,
3005
- m.map((S) => ({
3006
- name: S.name,
3007
- isVirtual: S.virtualNode,
3008
- pos: S.pos
3004
+ `Column ${p} after sort:`,
3005
+ E.map((I) => ({
3006
+ name: I.name,
3007
+ isVirtual: I.virtualNode,
3008
+ pos: I.pos
3009
3009
  }))
3010
3010
  );
3011
- const b = 50, y = m.filter((S) => !S.virtualNode), C = y.length;
3012
- if (C === 0) {
3013
- let S = ($ + m.reduce((T, z) => T + z.getHeightPoints(), 0)) / 2;
3014
- m.forEach((T) => {
3015
- const z = T.getHeightPoints();
3016
- S -= z / 2, T.pos = `${x},${S}`, S -= z / 2;
3011
+ const g = 50, v = E.filter((I) => !I.virtualNode), L = v.length;
3012
+ if (L === 0) {
3013
+ let I = (x + E.reduce((k, O) => k + O.getHeightPoints(), 0)) / 2;
3014
+ E.forEach((k) => {
3015
+ const O = k.getHeightPoints();
3016
+ I -= O / 2, k.pos = `${Y},${I}`, I -= O / 2;
3017
3017
  });
3018
3018
  return;
3019
3019
  }
3020
- let _, L;
3021
- if (C % 2 === 1) {
3022
- const S = Math.floor(C / 2), T = y[S];
3023
- L = m.indexOf(T), _ = $ / 2;
3020
+ let M, F;
3021
+ if (L % 2 === 1) {
3022
+ const I = Math.floor(L / 2), k = v[I];
3023
+ F = E.indexOf(k), M = x / 2;
3024
3024
  } else {
3025
- const S = C / 2 - 1, T = C / 2, z = y[S];
3026
- y[T], L = m.indexOf(z), _ = $ / 2;
3025
+ const I = L / 2 - 1, k = L / 2, O = v[I];
3026
+ v[k], F = E.indexOf(O), M = x / 2;
3027
3027
  }
3028
- const q = m[L], rt = q.getHeightPoints();
3029
- q.pos = `${x},${_}`, console.log(
3028
+ const q = E[F], ot = q.getHeightPoints();
3029
+ q.pos = `${Y},${M}`, console.log(
3030
3030
  `Positioned center ${q.name} (virtual: ${q.virtualNode}) at ${q.pos}`
3031
3031
  );
3032
- let Z = _ + rt / 2;
3033
- for (let S = L - 1; S >= 0; S--) {
3034
- const T = m[S], z = m[S + 1], k = T.getHeightPoints(), tt = T.virtualNode || z.virtualNode ? 0 : b;
3035
- Z += tt + k / 2, T.pos = `${x},${Z}`, console.log(
3036
- `Positioned ${T.name} (virtual: ${T.virtualNode}) at ${T.pos}, spacing: ${tt}`
3037
- ), Z += k / 2;
3032
+ let Q = M + ot / 2;
3033
+ for (let I = F - 1; I >= 0; I--) {
3034
+ const k = E[I], O = E[I + 1], j = k.getHeightPoints(), tt = k.virtualNode || O.virtualNode ? 0 : g;
3035
+ Q += tt + j / 2, k.pos = `${Y},${Q}`, console.log(
3036
+ `Positioned ${k.name} (virtual: ${k.virtualNode}) at ${k.pos}, spacing: ${tt}`
3037
+ ), Q += j / 2;
3038
3038
  }
3039
- Z = _ - rt / 2;
3040
- for (let S = L + 1; S < m.length; S++) {
3041
- const T = m[S], z = m[S - 1], k = T.getHeightPoints(), tt = T.virtualNode || z.virtualNode ? 0 : b;
3042
- Z -= tt + k / 2, T.pos = `${x},${Z}`, console.log(
3043
- `Positioned ${T.name} (virtual: ${T.virtualNode}) at ${T.pos}, spacing: ${tt}`
3044
- ), Z -= k / 2;
3039
+ Q = M - ot / 2;
3040
+ for (let I = F + 1; I < E.length; I++) {
3041
+ const k = E[I], O = E[I - 1], j = k.getHeightPoints(), tt = k.virtualNode || O.virtualNode ? 0 : g;
3042
+ Q -= tt + j / 2, k.pos = `${Y},${Q}`, console.log(
3043
+ `Positioned ${k.name} (virtual: ${k.virtualNode}) at ${k.pos}, spacing: ${tt}`
3044
+ ), Q -= j / 2;
3045
3045
  }
3046
- }), g !== void 0 && Y.attr("viewBox", `0 0 ${B} ${$}`), G.forEach((h) => {
3047
- h.nodes.forEach((w) => {
3048
- const E = w.getPosition();
3049
- if (!E) return;
3050
- const [m, x] = E, b = w.getWidthPoints(), y = w.getHeightPoints(), C = w.virtualNode;
3051
- if (C && !l) return;
3052
- const _ = J.append("g").attr("class", C ? "node virtual-node" : "node").attr("id", w.name);
3053
- let L = null;
3046
+ }), w !== void 0 && K.attr("viewBox", `0 0 ${V} ${x}`), R.forEach((p) => {
3047
+ p.nodes.forEach((h) => {
3048
+ const C = h.getPosition();
3049
+ if (!C) return;
3050
+ const [E, Y] = C, g = h.getWidthPoints(), v = h.getHeightPoints(), L = h.virtualNode;
3051
+ if (L && !l) return;
3052
+ const M = Z.append("g").attr("class", L ? "node virtual-node" : "node").attr("id", h.name);
3053
+ let F = null;
3054
3054
  try {
3055
- w.label && (L = pr(w.label));
3056
- } catch (V) {
3057
- console.warn(`Failed to decode node label for ${w.name}:`, V);
3055
+ h.label && (F = pr(h.label));
3056
+ } catch (J) {
3057
+ console.warn(`Failed to decode node label for ${h.name}:`, J);
3058
3058
  }
3059
- L != null && L.key && _.attr("data-key", L.key);
3060
- const q = l && C, rt = (L == null ? void 0 : L.tags) || [], Z = (L == null ? void 0 : L.label) || "", S = (L == null ? void 0 : L.text) || "", T = (L == null ? void 0 : L.color) || "#334155", z = (L == null ? void 0 : L.background) || "white", k = z !== "white", tt = k ? z : "#D5DFEA";
3061
- if ((rt.length > 0 || Z.length > 0) && !C) {
3062
- const V = y / 2, K = y / 2, W = $ - x - y / 2;
3063
- _.append("rect").attr("x", m - b / 2).attr("y", W).attr("width", b).attr("height", V).attr("rx", 5).attr("ry", 0).attr("fill", k ? z : "#EDF2F7").attr("stroke", tt).attr("stroke-width", 1), k && _.append("line").attr("x1", m - b / 2).attr("y1", W + V).attr("x2", m + b / 2).attr("y2", W + V).attr("stroke", T).attr("stroke-width", 1), _.append("rect").attr("x", m - b / 2).attr("y", W + V).attr("width", b).attr("height", K).attr("rx", 0).attr("ry", 5).attr("fill", z).attr("stroke", tt).attr("stroke-width", 1);
3064
- const it = _.append("rect").attr("x", m - b / 2 - 4).attr("y", W - 4).attr("width", b + 8).attr("height", y + 8).attr("rx", 5).attr("ry", 5).attr("fill", "none").attr("stroke", "#000000").attr("stroke-width", 2).attr("opacity", 0).style("pointer-events", "none");
3065
- _.style("cursor", "pointer").on("mouseenter", function() {
3066
- it.attr("opacity", 1);
3059
+ F != null && F.key && M.attr("data-key", F.key);
3060
+ const q = l && L, ot = (F == null ? void 0 : F.tags) || [], Q = (F == null ? void 0 : F.label) || "", I = (F == null ? void 0 : F.text) || "", k = (F == null ? void 0 : F.color) || "#334155", O = (F == null ? void 0 : F.background) || "white", j = O !== "white", tt = j ? O : "#D5DFEA";
3061
+ if ((ot.length > 0 || Q.length > 0) && !L) {
3062
+ const J = v / 2, H = v / 2, T = x - Y - v / 2;
3063
+ M.append("rect").attr("x", E - g / 2).attr("y", T).attr("width", g).attr("height", J).attr("rx", 5).attr("ry", 0).attr("fill", j ? O : "#EDF2F7").attr("stroke", tt).attr("stroke-width", 1), j && M.append("line").attr("x1", E - g / 2).attr("y1", T + J).attr("x2", E + g / 2).attr("y2", T + J).attr("stroke", k).attr("stroke-width", 1), M.append("rect").attr("x", E - g / 2).attr("y", T + J).attr("width", g).attr("height", H).attr("rx", 0).attr("ry", 5).attr("fill", O).attr("stroke", tt).attr("stroke-width", 1);
3064
+ const lt = M.append("rect").attr("x", E - g / 2 - 4).attr("y", T - 4).attr("width", g + 8).attr("height", v + 8).attr("rx", 5).attr("ry", 5).attr("fill", "none").attr("stroke", "#000000").attr("stroke-width", 2).attr("opacity", 0).style("pointer-events", "none");
3065
+ M.style("cursor", "pointer").on("mouseenter", function() {
3066
+ lt.attr("opacity", 1);
3067
3067
  }).on("mouseleave", function() {
3068
- it.attr("opacity", 0);
3068
+ lt.attr("opacity", 0);
3069
3069
  });
3070
- let ht = m - b / 2 + 8;
3071
- const st = W + V / 2, be = 7.2, It = 6, ct = 18, mt = 4;
3072
- if (rt.forEach((dt) => {
3073
- const bt = dt.length * be + It * 2;
3074
- _.append("rect").attr("x", ht).attr("y", st - ct / 2).attr("width", bt).attr("height", ct).attr("rx", 5).attr("ry", 5).attr("fill", "#FFF8E1").attr("stroke", "#FFD66D").attr("stroke-width", 1), _.append("text").attr("x", ht + It).attr("y", st).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-inter), Inter, Helvetica, Arial").attr("font-size", "12px").attr("font-weight", "500").attr("fill", "var(--text-warning-primary, #CD7004)").text(dt), ht += bt + mt;
3075
- }), Z) {
3076
- const dt = m + b / 2 - 8 - ht, Et = _.append("text").attr("x", ht).attr("y", st).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-inter), Inter, Helvetica, Arial").attr("font-size", "12px").attr("font-weight", "600").attr("fill", T);
3077
- Re(Et, dt, Z);
3070
+ let dt = E - g / 2 + 8;
3071
+ const bt = T + J / 2, ut = 7.2, st = 6, pt = 18, Bt = 4;
3072
+ if (ot.forEach((wt) => {
3073
+ const vt = wt.length * ut + st * 2;
3074
+ M.append("rect").attr("x", dt).attr("y", bt - pt / 2).attr("width", vt).attr("height", pt).attr("rx", 5).attr("ry", 5).attr("fill", "#FFF8E1").attr("stroke", "#FFD66D").attr("stroke-width", 1), M.append("text").attr("x", dt + st).attr("y", bt).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-inter), Inter, Helvetica, Arial").attr("font-size", "12px").attr("font-weight", "500").attr("fill", "var(--text-warning-primary, #CD7004)").text(wt), dt += vt + Bt;
3075
+ }), Q) {
3076
+ const wt = E + g / 2 - 8 - dt, xt = M.append("text").attr("x", dt).attr("y", bt).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-inter), Inter, Helvetica, Arial").attr("font-size", "12px").attr("font-weight", "600").attr("fill", k);
3077
+ Re(xt, wt, Q);
3078
3078
  }
3079
- if (S) {
3080
- const dt = b - 16, Et = _.append("text").attr("x", m - b / 2 + 8).attr("y", W + V + K / 2).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-fira-code), Fira Code, monospace").attr("font-size", "12px").attr("font-weight", "400").attr("fill", T);
3081
- Re(Et, dt, S);
3079
+ if (I) {
3080
+ const wt = g - 16, xt = M.append("text").attr("x", E - g / 2 + 8).attr("y", T + J + H / 2).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-fira-code), Fira Code, monospace").attr("font-size", "12px").attr("font-weight", "400").attr("fill", k);
3081
+ Re(xt, wt, I);
3082
3082
  }
3083
3083
  } else {
3084
- const V = _.append("rect").attr("x", m - b / 2).attr("y", $ - x - y / 2).attr("width", b).attr("height", y).attr("rx", 5).attr("ry", 5).attr("fill", z).attr("stroke", q ? "#EF4444" : "#D5DFEA").attr("stroke-width", q ? 2 : 1);
3085
- if (!C) {
3086
- const K = _.append("rect").attr("x", m - b / 2 - 4).attr("y", $ - x - y / 2 - 4).attr("width", b + 8).attr("height", y + 8).attr("rx", 5).attr("ry", 5).attr("fill", "none").attr("stroke", "#000000").attr("stroke-width", 2).attr("opacity", 0).style("pointer-events", "none");
3087
- V.style("cursor", "pointer").on("mouseenter", function() {
3088
- K.attr("opacity", 1);
3084
+ const J = M.append("rect").attr("x", E - g / 2).attr("y", x - Y - v / 2).attr("width", g).attr("height", v).attr("rx", 5).attr("ry", 5).attr("fill", O).attr("stroke", q ? "#EF4444" : "#D5DFEA").attr("stroke-width", q ? 2 : 1);
3085
+ if (!L) {
3086
+ const H = M.append("rect").attr("x", E - g / 2 - 4).attr("y", x - Y - v / 2 - 4).attr("width", g + 8).attr("height", v + 8).attr("rx", 5).attr("ry", 5).attr("fill", "none").attr("stroke", "#000000").attr("stroke-width", 2).attr("opacity", 0).style("pointer-events", "none");
3087
+ J.style("cursor", "pointer").on("mouseenter", function() {
3088
+ H.attr("opacity", 1);
3089
3089
  }).on("mouseleave", function() {
3090
- K.attr("opacity", 0);
3090
+ H.attr("opacity", 0);
3091
3091
  });
3092
3092
  }
3093
- if (L)
3094
- if (C) {
3095
- const K = Z || S;
3096
- _.append("text").attr("x", m).attr("y", $ - x).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "Inter, Helvetica, Arial").attr("font-size", "10px").attr("fill", "#991B1B").text(
3097
- K.length > 20 ? K.slice(0, 20) + "..." : K
3093
+ if (F)
3094
+ if (L) {
3095
+ const H = Q || I;
3096
+ M.append("text").attr("x", E).attr("y", x - Y).attr("text-anchor", "middle").attr("dominant-baseline", "middle").attr("font-family", "Inter, Helvetica, Arial").attr("font-size", "10px").attr("fill", "#991B1B").text(
3097
+ H.length > 20 ? H.slice(0, 20) + "..." : H
3098
3098
  );
3099
3099
  } else {
3100
- const K = S || Z, W = b - 16, it = _.append("text").attr("x", m - b / 2 + 8).attr("y", $ - x).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-fira-code), Fira Code, monospace").attr("font-size", "12px").attr("font-weight", "400").attr("fill", T);
3101
- Re(it, W, K);
3100
+ const H = I || Q, T = g - 16, lt = M.append("text").attr("x", E - g / 2 + 8).attr("y", x - Y).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", "var(--font-fira-code), Fira Code, monospace").attr("font-size", "12px").attr("font-weight", "400").attr("fill", k);
3101
+ Re(lt, T, H);
3102
3102
  }
3103
3103
  }
3104
- !w.label && w._ldraw_ && w._ldraw_.length > 0 && !C && w._ldraw_.forEach((V) => {
3105
- V.op === "T" && V.text && _.append("text").attr("x", m - b / 2 + 8).attr("y", $ - x).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", V.face || "Inter, Helvetica, Arial").attr("font-size", `${V.size || 11}px`).attr("fill", V.color || "#334155").text(V.text);
3104
+ !h.label && h._ldraw_ && h._ldraw_.length > 0 && !L && h._ldraw_.forEach((J) => {
3105
+ J.op === "T" && J.text && M.append("text").attr("x", E - g / 2 + 8).attr("y", x - Y).attr("text-anchor", "start").attr("dominant-baseline", "middle").attr("font-family", J.face || "Inter, Helvetica, Arial").attr("font-size", `${J.size || 11}px`).attr("fill", J.color || "#334155").text(J.text);
3106
3106
  });
3107
3107
  });
3108
3108
  }), i) {
3109
- Da(G, $), Ba(et, F), console.log(
3109
+ Da(R, x), Ba(it, U), console.log(
3110
3110
  "debug: base edges selected:",
3111
3111
  Object.fromEntries(
3112
- Array.from(F.entries()).map(([y, C]) => {
3113
- var _, L;
3112
+ Array.from(U.entries()).map(([v, L]) => {
3113
+ var M, F;
3114
3114
  return [
3115
- y,
3115
+ v,
3116
3116
  {
3117
- baseEdge: (_ = C.baseEdge) == null ? void 0 : _.name,
3118
- baseEdgeId: (L = C.baseEdge) == null ? void 0 : L.edgeIndex,
3119
- baseEdgeIndex: C.baseEdgeIndex,
3120
- totalEdges: C.edges.length,
3121
- depth0Edges: C.edges.filter((q) => q.depth === 0).length
3117
+ baseEdge: (M = L.baseEdge) == null ? void 0 : M.name,
3118
+ baseEdgeId: (F = L.baseEdge) == null ? void 0 : F.edgeIndex,
3119
+ baseEdgeIndex: L.baseEdgeIndex,
3120
+ totalEdges: L.edges.length,
3121
+ depth0Edges: L.edges.filter((q) => q.depth === 0).length
3122
3122
  }
3123
3123
  ];
3124
3124
  })
3125
3125
  )
3126
3126
  );
3127
- const h = a.loopRadius, w = a.edgeSpacing, E = a.labelHeight;
3128
- F.forEach((y) => {
3129
- const C = y.edges;
3130
- if (C.length === 0) return;
3131
- const _ = y.baseEdge, L = y.baseEdgeIndex;
3132
- if (!_ || L < 0) return;
3133
- const q = _.getStartPoint(), rt = _.getEndPoint();
3134
- if (!q || !rt) return;
3135
- const Z = $ - q.y, S = $ - rt.y;
3136
- _.midY = (Z + S) / 2;
3137
- const T = ae(
3138
- _,
3139
- $,
3127
+ const p = a.loopRadius, h = a.edgeSpacing, C = a.labelHeight;
3128
+ U.forEach((v) => {
3129
+ const L = v.edges;
3130
+ if (L.length === 0) return;
3131
+ const M = v.baseEdge, F = v.baseEdgeIndex;
3132
+ if (!M || F < 0) return;
3133
+ const q = M.getStartPoint(), ot = M.getEndPoint();
3134
+ if (!q || !ot) return;
3135
+ const Q = x - q.y, I = x - ot.y;
3136
+ M.midY = (Q + I) / 2;
3137
+ const k = se(
3138
+ M,
3139
+ x,
3140
3140
  void 0,
3141
3141
  a
3142
3142
  );
3143
- T && (_.midY = T.midY, _.orthogonalPathPoints = T.points), y.aboveY = _.midY, y.belowY = _.midY;
3144
- for (let z = L - 1; z >= 0; z--) {
3145
- const k = C[z];
3146
- if (k.depth !== 0) continue;
3147
- if (k.getDirection() === "self") {
3148
- const W = k.getStartPoint();
3149
- W && (k.midY = $ - W.y - h);
3143
+ k && (M.midY = k.midY, M.orthogonalPathPoints = k.points), v.aboveY = M.midY, v.belowY = M.midY;
3144
+ for (let O = F - 1; O >= 0; O--) {
3145
+ const j = L[O];
3146
+ if (j.depth !== 0) continue;
3147
+ if (j.getDirection() === "self") {
3148
+ const T = j.getStartPoint();
3149
+ T && (j.midY = x - T.y - p);
3150
3150
  continue;
3151
3151
  }
3152
- const ot = k.label ? w + E : w;
3153
- k.midY = y.aboveY - ot, y.aboveY = k.midY, k.baseDirection = "above", k.baseOffset = -(L - z);
3154
- const V = z < C.length - 1 ? C[z + 1] : void 0, K = ae(
3155
- k,
3156
- $,
3157
- V,
3152
+ const rt = j.label ? h + C : h;
3153
+ j.midY = v.aboveY - rt, v.aboveY = j.midY, j.baseDirection = "above", j.baseOffset = -(F - O);
3154
+ const J = O < L.length - 1 ? L[O + 1] : void 0, H = se(
3155
+ j,
3156
+ x,
3157
+ J,
3158
3158
  a
3159
3159
  );
3160
- K && (k.midY = K.midY, k.orthogonalPathPoints = K.points, y.aboveY = k.midY);
3160
+ H && (j.midY = H.midY, j.orthogonalPathPoints = H.points, v.aboveY = j.midY);
3161
3161
  }
3162
- for (let z = L + 1; z < C.length; z++) {
3163
- const k = C[z];
3164
- if (k.depth !== 0) continue;
3165
- if (k.getDirection() === "self") {
3166
- const W = k.getStartPoint();
3167
- W && (k.midY = $ - W.y - h);
3162
+ for (let O = F + 1; O < L.length; O++) {
3163
+ const j = L[O];
3164
+ if (j.depth !== 0) continue;
3165
+ if (j.getDirection() === "self") {
3166
+ const T = j.getStartPoint();
3167
+ T && (j.midY = x - T.y - p);
3168
3168
  continue;
3169
3169
  }
3170
- const ot = k.label ? w + E : w;
3171
- k.midY = y.belowY + ot, y.belowY = k.midY, k.baseDirection = "below", k.baseOffset = z - L;
3172
- const V = z > 0 ? C[z - 1] : void 0, K = ae(
3173
- k,
3174
- $,
3175
- V,
3170
+ const rt = j.label ? h + C : h;
3171
+ j.midY = v.belowY + rt, v.belowY = j.midY, j.baseDirection = "below", j.baseOffset = O - F;
3172
+ const J = O > 0 ? L[O - 1] : void 0, H = se(
3173
+ j,
3174
+ x,
3175
+ J,
3176
3176
  a
3177
3177
  );
3178
- K && (k.midY = K.midY, k.orthogonalPathPoints = K.points, y.belowY = k.midY);
3178
+ H && (j.midY = H.midY, j.orthogonalPathPoints = H.points, v.belowY = j.midY);
3179
3179
  }
3180
3180
  });
3181
- const m = [];
3182
- F.forEach((y) => {
3183
- const C = y.edges;
3184
- C.length === 0 || y.baseEdge || !C.every((L) => L.depth > 0) || C.forEach((L) => {
3185
- if (L.getDirection() !== "self")
3186
- m.push(L);
3181
+ const E = [];
3182
+ U.forEach((v) => {
3183
+ const L = v.edges;
3184
+ L.length === 0 || v.baseEdge || !L.every((F) => F.depth > 0) || L.forEach((F) => {
3185
+ if (F.getDirection() !== "self")
3186
+ E.push(F);
3187
3187
  else {
3188
- const q = L.getStartPoint();
3189
- q && (L.midY = $ - q.y - h);
3188
+ const q = F.getStartPoint();
3189
+ q && (F.midY = x - q.y - p);
3190
3190
  }
3191
3191
  });
3192
- }), m.sort((y, C) => y.depth - C.depth), console.log("Processing deep edges by depth:", {
3193
- totalEdges: m.length,
3194
- depths: [...new Set(m.map((y) => y.depth))].sort((y, C) => y - C)
3192
+ }), E.sort((v, L) => v.depth - L.depth), console.log("Processing deep edges by depth:", {
3193
+ totalEdges: E.length,
3194
+ depths: [...new Set(E.map((v) => v.depth))].sort((v, L) => v - L)
3195
3195
  });
3196
- let x = 1 / 0, b = -1 / 0;
3197
- F.forEach((y) => {
3198
- y.aboveY !== 0 && (x = Math.min(x, y.aboveY)), y.belowY !== 0 && (b = Math.max(b, y.belowY));
3199
- }), G.forEach((y) => {
3200
- y.aboveY !== 0 && (x = Math.min(x, y.aboveY)), y.belowY !== 0 && (b = Math.max(b, y.belowY));
3196
+ let Y = 1 / 0, g = -1 / 0;
3197
+ U.forEach((v) => {
3198
+ v.aboveY !== 0 && (Y = Math.min(Y, v.aboveY)), v.belowY !== 0 && (g = Math.max(g, v.belowY));
3199
+ }), R.forEach((v) => {
3200
+ v.aboveY !== 0 && (Y = Math.min(Y, v.aboveY)), v.belowY !== 0 && (g = Math.max(g, v.belowY));
3201
3201
  }), console.log("Global bounds before deep edges:", {
3202
- globalAboveY: x,
3203
- globalBelowY: b
3204
- }), m.forEach((y) => {
3205
- if (!y.sourceNode || !y.targetNode) return;
3206
- const C = nt.get(y.sourceNode._gvid), _ = nt.get(y.targetNode._gvid);
3207
- if (C === void 0 || _ === void 0) return;
3208
- const L = Math.min(C, _), q = Math.max(C, _), rt = [];
3209
- for (let W = L; W <= q; W++) {
3210
- const it = G.get(W);
3211
- it && rt.push(...it.nodes);
3202
+ globalAboveY: Y,
3203
+ globalBelowY: g
3204
+ }), E.forEach((v) => {
3205
+ if (!v.sourceNode || !v.targetNode) return;
3206
+ const L = A.get(v.sourceNode._gvid), M = A.get(v.targetNode._gvid);
3207
+ if (L === void 0 || M === void 0) return;
3208
+ const F = Math.min(L, M), q = Math.max(L, M), ot = [];
3209
+ for (let T = F; T <= q; T++) {
3210
+ const lt = R.get(T);
3211
+ lt && ot.push(...lt.nodes);
3212
3212
  }
3213
- const Z = rt.map((W) => {
3214
- const it = W.getPosition();
3215
- if (!it) return null;
3216
- const ht = $ - it[1], st = W.height ? parseFloat(W.height) * 72 : 40;
3217
- return { y: ht, height: st, bottomY: ht + st / 2 };
3213
+ const Q = ot.map((T) => {
3214
+ const lt = T.getPosition();
3215
+ if (!lt) return null;
3216
+ const dt = x - lt[1], bt = T.height ? parseFloat(T.height) * 72 : 40;
3217
+ return { y: dt, height: bt, bottomY: dt + bt / 2 };
3218
3218
  }).filter(
3219
- (W) => W !== null
3220
- ).sort((W, it) => W.y - it.y);
3221
- let S;
3222
- if (Z.length === 0)
3223
- S = (x + b) / 2;
3224
- else if (Z.length % 2 === 1)
3225
- S = Z[Math.floor(Z.length / 2)].bottomY;
3219
+ (T) => T !== null
3220
+ ).sort((T, lt) => T.y - lt.y);
3221
+ let I;
3222
+ if (Q.length === 0)
3223
+ I = (Y + g) / 2;
3224
+ else if (Q.length % 2 === 1)
3225
+ I = Q[Math.floor(Q.length / 2)].bottomY;
3226
3226
  else {
3227
- const W = Z.length / 2;
3228
- S = (Z[W - 1].bottomY + Z[W].bottomY) / 2;
3227
+ const T = Q.length / 2;
3228
+ I = (Q[T - 1].bottomY + Q[T].bottomY) / 2;
3229
3229
  }
3230
- const T = y.getStartPoint(), z = y.getEndPoint(), tt = (T && z ? $ - (T.y + z.y) / 2 : S) < S ? "above" : "below";
3231
- y.baseDirection = tt;
3232
- const ot = y.label ? w + E : w;
3233
- let V;
3234
- tt === "above" ? (y.midY = x - ot, V = x, x = y.midY) : (y.midY = b + ot, V = b, b = y.midY), console.log("Placed deep edge:", {
3235
- edgeIndex: y.edgeIndex,
3236
- depth: y.depth,
3230
+ const k = v.getStartPoint(), O = v.getEndPoint(), tt = (k && O ? x - (k.y + O.y) / 2 : I) < I ? "above" : "below";
3231
+ v.baseDirection = tt;
3232
+ const rt = v.label ? h + C : h;
3233
+ let J;
3234
+ tt === "above" ? (v.midY = Y - rt, J = Y, Y = v.midY) : (v.midY = g + rt, J = g, g = v.midY), console.log("Placed deep edge:", {
3235
+ edgeIndex: v.edgeIndex,
3236
+ depth: v.depth,
3237
3237
  direction: tt,
3238
- midY: y.midY,
3239
- centerNodeBottomY: S,
3240
- globalAboveY: x,
3241
- globalBelowY: b
3238
+ midY: v.midY,
3239
+ centerNodeBottomY: I,
3240
+ globalAboveY: Y,
3241
+ globalBelowY: g
3242
3242
  });
3243
- const K = ae(
3244
- y,
3245
- $,
3246
- { midY: V },
3243
+ const H = se(
3244
+ v,
3245
+ x,
3246
+ { midY: J },
3247
3247
  a
3248
3248
  );
3249
- K && (y.midY = K.midY, y.orthogonalPathPoints = K.points, tt === "above" ? x = Math.min(x, K.midY) : b = Math.max(b, K.midY));
3249
+ H && (v.midY = H.midY, v.orthogonalPathPoints = H.points, tt === "above" ? Y = Math.min(Y, H.midY) : g = Math.max(g, H.midY));
3250
3250
  });
3251
3251
  }
3252
- const M = et.map((h) => h.edgeIndex).filter((h) => h !== void 0), v = M.length > 0 ? Math.min(...M) : 0, D = M.length > 0 ? Math.max(...M) : 0, X = We().scaleExtent([0.1, ba(t, B, c)]).on("zoom", (h) => {
3253
- const w = h.transform;
3254
- console.log("zoom event:", { x: w.x, y: w.y, k: w.k, isNaN: isNaN(w.x) || isNaN(w.y) || isNaN(w.k) }), !isNaN(w.x) && !isNaN(w.y) && !isNaN(w.k) && J.attr("transform", w.toString());
3252
+ const y = it.map((p) => p.edgeIndex).filter((p) => p !== void 0), D = y.length > 0 ? Math.min(...y) : 0, X = y.length > 0 ? Math.max(...y) : 0, S = We().scaleExtent([0.1, ba(t, V, c)]).on("zoom", (p) => {
3253
+ const h = p.transform;
3254
+ console.log("zoom event:", { x: h.x, y: h.y, k: h.k, isNaN: isNaN(h.x) || isNaN(h.y) || isNaN(h.k) }), !isNaN(h.x) && !isNaN(h.y) && !isNaN(h.k) && Z.attr("transform", h.toString());
3255
3255
  });
3256
- if (Y.call(X), et.forEach((h) => {
3256
+ if (K.call(S), _ || (K.on("wheel.zoom", null), K.on("dblclick.zoom", null)), it.forEach((p) => {
3257
3257
  if (n != null) {
3258
3258
  if (o) {
3259
- if (h.depth > n) return;
3260
- } else if (h.depth !== n) return;
3259
+ if (p.depth > n) return;
3260
+ } else if (p.depth !== n) return;
3261
3261
  }
3262
3262
  Pa(
3263
- h,
3264
- J,
3265
- $,
3263
+ p,
3264
+ Z,
3265
+ x,
3266
3266
  a,
3267
3267
  i,
3268
- v,
3269
3268
  D,
3270
3269
  X,
3271
- Y,
3270
+ S,
3271
+ K,
3272
3272
  t,
3273
- B,
3274
- $,
3273
+ V,
3274
+ x,
3275
3275
  s,
3276
3276
  u,
3277
3277
  l
3278
3278
  );
3279
3279
  }), l) {
3280
- const h = J.node();
3281
- if (h) {
3282
- const w = h.getBBox(), E = w.x + w.width / 2, m = w.y + w.height / 2;
3283
- J.append("rect").attr("x", w.x).attr("y", w.y).attr("width", w.width).attr("height", w.height).attr("fill", "none").attr("stroke", "yellow").attr("stroke-width", 3).attr("opacity", 0.8).style("pointer-events", "none").attr("class", "debug-root-border"), J.append("circle").attr("cx", E).attr("cy", m).attr("r", 10).attr("fill", "yellow").attr("stroke", "orange").attr("stroke-width", 2).attr("opacity", 0.9).style("pointer-events", "none").attr("class", "debug-geometric-center");
3280
+ const p = Z.node();
3281
+ if (p) {
3282
+ const h = p.getBBox(), C = h.x + h.width / 2, E = h.y + h.height / 2;
3283
+ Z.append("rect").attr("x", h.x).attr("y", h.y).attr("width", h.width).attr("height", h.height).attr("fill", "none").attr("stroke", "yellow").attr("stroke-width", 3).attr("opacity", 0.8).style("pointer-events", "none").attr("class", "debug-root-border"), Z.append("circle").attr("cx", C).attr("cy", E).attr("r", 10).attr("fill", "yellow").attr("stroke", "orange").attr("stroke-width", 2).attr("opacity", 0.9).style("pointer-events", "none").attr("class", "debug-geometric-center");
3284
3284
  }
3285
3285
  }
3286
- const I = J.node();
3287
- if (I) {
3288
- const h = I.getBBox(), w = 0.9 * B / h.width, E = h.x + h.width / 2, m = h.y + h.height / 2, x = B / 2 - E * w, b = $ / 2 - m * w;
3289
- Y.call(
3290
- X.transform,
3291
- Pt.translate(x, b).scale(w)
3286
+ const z = Z.node();
3287
+ if (z) {
3288
+ const p = z.getBBox(), h = 0.9 * V / p.width, C = p.x + p.width / 2, E = p.y + p.height / 2, Y = V / 2 - C * h, g = x / 2 - E * h;
3289
+ K.call(
3290
+ S.transform,
3291
+ $t.translate(Y, g).scale(h)
3292
3292
  );
3293
3293
  }
3294
3294
  return {
3295
- zoomBehavior: X,
3296
- svgElement: Y.node(),
3297
- gElement: J.node(),
3295
+ zoomBehavior: S,
3296
+ svgElement: K.node(),
3297
+ gElement: Z.node(),
3298
3298
  baseFontSize: c,
3299
- viewBoxWidth: B
3299
+ viewBoxWidth: V
3300
3300
  };
3301
3301
  }
3302
- function $t(t, e, r) {
3302
+ function St(t, e, r) {
3303
3303
  let n = "#000000", o = "#000000", a = "#000000";
3304
3304
  e.forEach((i) => {
3305
3305
  switch (i.op) {
@@ -3364,9 +3364,9 @@ function $t(t, e, r) {
3364
3364
  });
3365
3365
  }
3366
3366
  function $a(t, e, r = 14) {
3367
- var g;
3367
+ var w;
3368
3368
  t.innerHTML = "";
3369
- const n = ((g = e.bb) == null ? void 0 : g.split(",").map(Number)) || [0, 0, 1e3, 800], [, , o, a] = n, i = at(t).append("svg").attr("width", "100%").attr("height", "100%").attr("viewBox", `0 0 ${o} ${a}`).style("background", "white");
3369
+ const n = ((w = e.bb) == null ? void 0 : w.split(",").map(Number)) || [0, 0, 1e3, 800], [, , o, a] = n, i = at(t).append("svg").attr("width", "100%").attr("height", "100%").attr("viewBox", `0 0 ${o} ${a}`).style("background", "white");
3370
3370
  i.append("defs").html(`
3371
3371
  <style>
3372
3372
  .node rect, .node ellipse, .node polygon {
@@ -3378,23 +3378,23 @@ function $a(t, e, r = 14) {
3378
3378
  </style>
3379
3379
  `);
3380
3380
  const c = i.append("g").attr("id", "graph0");
3381
- (e.objects || []).forEach((R) => {
3382
- const B = c.append("g").attr("class", "node").attr("id", R.name);
3383
- R._draw_ && $t(B, R._draw_, a), R._ldraw_ && $t(B, R._ldraw_, a);
3384
- }), (e.edges || []).forEach((R) => {
3385
- const B = c.append("g").attr("class", "edge").attr("id", `edge_${R._gvid}`);
3386
- R._draw_ && $t(B, R._draw_, a), R._hdraw_ && $t(B, R._hdraw_, a), R._tdraw_ && $t(B, R._tdraw_, a), R._ldraw_ && $t(B, R._ldraw_, a);
3381
+ (e.objects || []).forEach((_) => {
3382
+ const B = c.append("g").attr("class", "node").attr("id", _.name);
3383
+ _._draw_ && St(B, _._draw_, a), _._ldraw_ && St(B, _._ldraw_, a);
3384
+ }), (e.edges || []).forEach((_) => {
3385
+ const B = c.append("g").attr("class", "edge").attr("id", `edge_${_._gvid}`);
3386
+ _._draw_ && St(B, _._draw_, a), _._hdraw_ && St(B, _._hdraw_, a), _._tdraw_ && St(B, _._tdraw_, a), _._ldraw_ && St(B, _._ldraw_, a);
3387
3387
  });
3388
- const u = We().scaleExtent([0.1, 10]).on("zoom", (R) => {
3389
- c.attr("transform", R.transform.toString());
3388
+ const u = We().scaleExtent([0.1, 10]).on("zoom", (_) => {
3389
+ c.attr("transform", _.transform.toString());
3390
3390
  });
3391
3391
  i.call(u);
3392
- const d = t.clientWidth || 800, p = r * (d / o);
3392
+ const d = t.clientWidth || 800, m = r * (d / o);
3393
3393
  return {
3394
3394
  zoomBehavior: u,
3395
3395
  svgElement: i.node(),
3396
3396
  gElement: c.node(),
3397
- baseFontSize: p,
3397
+ baseFontSize: m,
3398
3398
  viewBoxWidth: o
3399
3399
  };
3400
3400
  }
@@ -3423,15 +3423,15 @@ function Xa(t) {
3423
3423
  let Ie = null;
3424
3424
  Ie = Xa;
3425
3425
  function Sa() {
3426
- const t = ut(null), e = ut(null), [r, n] = He(!1), [o, a] = He(null), i = Me(() => {
3426
+ const t = ft(null), e = ft(null), [r, n] = He(!1), [o, a] = He(null), i = Me(() => {
3427
3427
  let s;
3428
3428
  return Ie && (s = new Ie()), s.onmessage = (u) => {
3429
- const { id: d, success: p, json: g, error: R } = u.data;
3429
+ const { id: d, success: m, json: w, error: _ } = u.data;
3430
3430
  if (e.current && e.current.id === d) {
3431
- if (n(!1), p && g)
3432
- e.current.resolve(g);
3431
+ if (n(!1), m && w)
3432
+ e.current.resolve(w);
3433
3433
  else {
3434
- const B = new Error(R || "Unknown worker error");
3434
+ const B = new Error(_ || "Unknown worker error");
3435
3435
  a(B.message), e.current.reject(B);
3436
3436
  }
3437
3437
  e.current = null;
@@ -3452,23 +3452,23 @@ function Sa() {
3452
3452
  return;
3453
3453
  }
3454
3454
  e.current && e.current.reject(new Error("Request cancelled"));
3455
- const p = Math.random().toString(36).slice(2);
3456
- e.current = { id: p, resolve: u, reject: d }, n(!0), a(null);
3457
- const g = { id: p, dot: s };
3458
- t.current.postMessage(g);
3455
+ const m = Math.random().toString(36).slice(2);
3456
+ e.current = { id: m, resolve: u, reject: d }, n(!0), a(null);
3457
+ const w = { id: m, dot: s };
3458
+ t.current.postMessage(w);
3459
3459
  }), []), l = Me(() => {
3460
3460
  e.current && (console.warn("Graphviz worker: Request cancelled by user"), e.current.reject(new Error("Cancelled by user")), e.current = null, n(!1)), t.current && (t.current.terminate(), t.current = i());
3461
3461
  }, [i]);
3462
3462
  return { layout: c, cancel: l, isLoading: r, error: o };
3463
3463
  }
3464
3464
  function Ua({ onCancel: t }) {
3465
- return /* @__PURE__ */ Bt("div", { className: "absolute inset-0 bg-gray-900/80 flex flex-col items-center justify-center z-40", children: /* @__PURE__ */ fe("div", { className: "flex flex-col items-center gap-4", children: [
3466
- /* @__PURE__ */ Bt("div", { className: "w-12 h-12 border-4 border-blue-500/30 border-t-blue-500 rounded-full animate-spin" }),
3467
- /* @__PURE__ */ fe("div", { className: "text-center", children: [
3468
- /* @__PURE__ */ Bt("p", { className: "text-white font-medium mb-1", children: "Processing layout..." }),
3469
- /* @__PURE__ */ Bt("p", { className: "text-gray-400 text-sm", children: "This may take a while for large graphs" })
3465
+ return /* @__PURE__ */ Nt("div", { className: "absolute inset-0 bg-gray-900/80 flex flex-col items-center justify-center z-40", children: /* @__PURE__ */ he("div", { className: "flex flex-col items-center gap-4", children: [
3466
+ /* @__PURE__ */ Nt("div", { className: "w-12 h-12 border-4 border-blue-500/30 border-t-blue-500 rounded-full animate-spin" }),
3467
+ /* @__PURE__ */ he("div", { className: "text-center", children: [
3468
+ /* @__PURE__ */ Nt("p", { className: "text-white font-medium mb-1", children: "Processing layout..." }),
3469
+ /* @__PURE__ */ Nt("p", { className: "text-gray-400 text-sm", children: "This may take a while for large graphs" })
3470
3470
  ] }),
3471
- /* @__PURE__ */ Bt(
3471
+ /* @__PURE__ */ Nt(
3472
3472
  "button",
3473
3473
  {
3474
3474
  onClick: t,
@@ -3490,108 +3490,110 @@ const Oa = Tr(function({
3490
3490
  className: s = "",
3491
3491
  showLoading: u = !0,
3492
3492
  debug: d = !1,
3493
- selectedEdgeId: p = null,
3494
- onEdgeSelect: g,
3495
- useNativeRendering: R = !1,
3493
+ selectedEdgeId: m = null,
3494
+ onEdgeSelect: w,
3495
+ useNativeRendering: _ = !1,
3496
3496
  nodeWidth: B = 240,
3497
- nodeHeight: $ = 64,
3498
- nodeColumnSpacing: Y = 800
3499
- }, J) {
3500
- const j = ut(null), { layout: A, cancel: O, isLoading: U, error: et } = Sa(), nt = ut(null), G = ut(null), F = ut(null), H = ut(14), Q = ut(1e3), N = ut(!1), f = ut(null), M = ut(null), v = ut(null), D = ut(null), X = ut(g);
3501
- return X.current = g, Vr(J, () => ({
3502
- zoomIn: (I = 10) => {
3503
- var b, y;
3504
- if (!nt.current || !G.current || !F.current) return;
3505
- const P = qt(F.current), h = 1 + I / 100, w = P.k * h, E = at(G.current), m = ((b = j.current) == null ? void 0 : b.clientWidth) || 1, x = ((y = j.current) == null ? void 0 : y.clientHeight) || 1;
3497
+ nodeHeight: V = 64,
3498
+ nodeColumnSpacing: x = 800,
3499
+ clickPassthrough: K = !1,
3500
+ enableWheelZoom: Z = !0
3501
+ }, et) {
3502
+ const N = ft(null), { layout: $, cancel: nt, isLoading: it, error: A } = Sa(), R = ft(null), U = ft(null), W = ft(null), P = ft(14), f = ft(1e3), b = ft(!1), y = ft(null), D = ft(null), X = ft(null), S = ft(null), z = ft(w);
3503
+ return z.current = w, Vr(et, () => ({
3504
+ zoomIn: (G = 10) => {
3505
+ var v, L;
3506
+ if (!R.current || !U.current || !W.current) return;
3507
+ const p = Kt(W.current), h = 1 + G / 100, C = p.k * h, E = at(U.current), Y = ((v = N.current) == null ? void 0 : v.clientWidth) || 1, g = ((L = N.current) == null ? void 0 : L.clientHeight) || 1;
3506
3508
  E.transition().duration(300).call(
3507
- nt.current.scaleTo,
3508
- w,
3509
- [m / 2, x / 2]
3509
+ R.current.scaleTo,
3510
+ C,
3511
+ [Y / 2, g / 2]
3510
3512
  );
3511
3513
  },
3512
- zoomOut: (I = 10) => {
3513
- var b, y;
3514
- if (!nt.current || !G.current || !F.current) return;
3515
- const P = qt(F.current), h = 1 - I / 100, w = Math.max(0.1, P.k * h), E = at(G.current), m = ((b = j.current) == null ? void 0 : b.clientWidth) || 1, x = ((y = j.current) == null ? void 0 : y.clientHeight) || 1;
3514
+ zoomOut: (G = 10) => {
3515
+ var v, L;
3516
+ if (!R.current || !U.current || !W.current) return;
3517
+ const p = Kt(W.current), h = 1 - G / 100, C = Math.max(0.1, p.k * h), E = at(U.current), Y = ((v = N.current) == null ? void 0 : v.clientWidth) || 1, g = ((L = N.current) == null ? void 0 : L.clientHeight) || 1;
3516
3518
  E.transition().duration(300).call(
3517
- nt.current.scaleTo,
3518
- w,
3519
- [m / 2, x / 2]
3519
+ R.current.scaleTo,
3520
+ C,
3521
+ [Y / 2, g / 2]
3520
3522
  );
3521
3523
  },
3522
3524
  toggleZoom: () => {
3523
- var it, ht;
3524
- if (!nt.current || !G.current || !F.current) return;
3525
- const I = at(G.current), P = ((it = j.current) == null ? void 0 : it.clientWidth) || 1;
3526
- (ht = j.current) != null && ht.clientHeight;
3527
- const h = H.current, w = G.current.getAttribute("viewBox");
3528
- if (!w) return;
3529
- const [, , E, m] = w.split(" ").map(Number);
3530
- if (isNaN(E) || isNaN(m))
3525
+ var dt, bt;
3526
+ if (!R.current || !U.current || !W.current) return;
3527
+ const G = at(U.current), p = ((dt = N.current) == null ? void 0 : dt.clientWidth) || 1;
3528
+ (bt = N.current) != null && bt.clientHeight;
3529
+ const h = P.current, C = U.current.getAttribute("viewBox");
3530
+ if (!C) return;
3531
+ const [, , E, Y] = C.split(" ").map(Number);
3532
+ if (isNaN(E) || isNaN(Y))
3531
3533
  return;
3532
- if (!M.current) {
3533
- const st = F.current.getBBox();
3534
- M.current = { x: st.x, y: st.y, width: st.width, height: st.height };
3534
+ if (!D.current) {
3535
+ const ut = W.current.getBBox();
3536
+ D.current = { x: ut.x, y: ut.y, width: ut.width, height: ut.height };
3535
3537
  }
3536
- const x = M.current;
3537
- if (console.log("rootBBox:", x), isNaN(x.x) || isNaN(x.y) || isNaN(x.width) || isNaN(x.height)) {
3538
+ const g = D.current;
3539
+ if (console.log("rootBBox:", g), isNaN(g.x) || isNaN(g.y) || isNaN(g.width) || isNaN(g.height)) {
3538
3540
  console.error("rootBBox contains NaN values, recalculating...");
3539
- const st = F.current.getBBox();
3540
- M.current = { x: st.x, y: st.y, width: st.width, height: st.height };
3541
+ const ut = W.current.getBBox();
3542
+ D.current = { x: ut.x, y: ut.y, width: ut.width, height: ut.height };
3541
3543
  }
3542
- const b = x.x + x.width / 2, y = x.y + x.height / 2, C = P / E, _ = 0.9 * E / x.width, L = h * C * _, rt = 16 / (h * C), Z = h * C * rt, S = Math.min(_, rt), T = Math.max(_, rt), z = qt(G.current), k = h * C * z.k;
3544
+ const v = g.x + g.width / 2, L = g.y + g.height / 2, M = p / E, F = 0.9 * E / g.width, q = h * M * F, Q = 16 / (h * M), I = h * M * Q, k = Math.min(F, Q), O = Math.max(F, Q), j = Kt(U.current), tt = h * M * j.k;
3543
3545
  console.log("toggleZoom debug:", {
3544
- currentState: N.current ? "zoomedIn" : "zoomedOut",
3545
- currentScale: z.k,
3546
- currentFontSize: k,
3547
- overviewScale: _,
3548
- overviewFontSize: L,
3549
- detailScale: rt,
3550
- detailFontSize: Z,
3551
- zoomOutScale: S,
3552
- zoomInScale: T
3546
+ currentState: b.current ? "zoomedIn" : "zoomedOut",
3547
+ currentScale: j.k,
3548
+ currentFontSize: tt,
3549
+ overviewScale: F,
3550
+ overviewFontSize: q,
3551
+ detailScale: Q,
3552
+ detailFontSize: I,
3553
+ zoomOutScale: k,
3554
+ zoomInScale: O
3553
3555
  });
3554
- let tt;
3555
- N.current ? (tt = S, N.current = !1) : (tt = T, f.current = qt(G.current), N.current = !0), console.log("toggleZoom target:", {
3556
- targetScale: tt,
3557
- targetFontSize: h * C * tt,
3558
- newState: N.current ? "zoomedIn" : "zoomedOut"
3556
+ let rt;
3557
+ b.current ? (rt = k, b.current = !1) : (rt = O, y.current = Kt(U.current), b.current = !0), console.log("toggleZoom target:", {
3558
+ targetScale: rt,
3559
+ targetFontSize: h * M * rt,
3560
+ newState: b.current ? "zoomedIn" : "zoomedOut"
3559
3561
  });
3560
- const ot = E / 2 - b * tt, V = m / 2 - y * tt, K = Pt.translate(ot, V).scale(tt);
3561
- console.log("newTransform:", { x: K.x, y: K.y, k: K.k }), at(F.current).transition().duration(500).attr("transform", K.toString()).on("end", () => {
3562
- I.call(nt.current.transform, K);
3562
+ const J = E / 2 - v * rt, H = Y / 2 - L * rt, T = $t.translate(J, H).scale(rt);
3563
+ console.log("newTransform:", { x: T.x, y: T.y, k: T.k }), at(W.current).transition().duration(500).attr("transform", T.toString()).on("end", () => {
3564
+ G.call(R.current.transform, T);
3563
3565
  });
3564
3566
  },
3565
3567
  stopRendering: () => {
3566
- D.current && (clearInterval(D.current), D.current = null), v.current = null, O(), j.current && (j.current.innerHTML = ""), N.current = !1, f.current = null;
3568
+ S.current && (clearInterval(S.current), S.current = null), X.current = null, nt(), N.current && (N.current.innerHTML = ""), b.current = !1, y.current = null;
3567
3569
  }
3568
- }), [O]), Le(() => {
3569
- if (!e || !j.current) return;
3570
- let I = !1;
3571
- return v.current = Date.now(), l && (D.current = setInterval(() => {
3572
- if (v.current) {
3573
- const P = Date.now() - v.current;
3574
- l(P);
3570
+ }), [nt]), Le(() => {
3571
+ if (!e || !N.current) return;
3572
+ let G = !1;
3573
+ return X.current = Date.now(), l && (S.current = setInterval(() => {
3574
+ if (X.current) {
3575
+ const p = Date.now() - X.current;
3576
+ l(p);
3575
3577
  }
3576
- }, 100)), A(e).then((P) => {
3577
- var w;
3578
- if (I) return;
3579
- const h = JSON.parse(P);
3580
- if (j.current) {
3578
+ }, 100)), $(e).then((p) => {
3579
+ var C;
3580
+ if (G) return;
3581
+ const h = JSON.parse(p);
3582
+ if (N.current) {
3581
3583
  let E = n;
3582
3584
  if (h.objects) {
3583
- for (const x of h.objects)
3584
- if (x._ldraw_)
3585
- for (const b of x._ldraw_)
3586
- b.size && b.size > E && (E = b.size);
3585
+ for (const g of h.objects)
3586
+ if (g._ldraw_)
3587
+ for (const v of g._ldraw_)
3588
+ v.size && v.size > E && (E = v.size);
3587
3589
  }
3588
- let m;
3589
- if (R ? m = $a(
3590
- j.current,
3590
+ let Y;
3591
+ if (_ ? Y = $a(
3592
+ N.current,
3591
3593
  h,
3592
3594
  E
3593
- ) : m = Na(
3594
- j.current,
3595
+ ) : Y = Na(
3596
+ N.current,
3595
3597
  h,
3596
3598
  r,
3597
3599
  null,
@@ -3606,67 +3608,86 @@ const Oa = Tr(function({
3606
3608
  d,
3607
3609
  null,
3608
3610
  // selectedEdgeId - handle selection separately via useEffect
3609
- (x) => {
3610
- var b;
3611
- return (b = X.current) == null ? void 0 : b.call(X, x);
3611
+ (g) => {
3612
+ var v;
3613
+ return (v = z.current) == null ? void 0 : v.call(z, g);
3612
3614
  },
3613
3615
  // Use ref for callback
3614
3616
  B,
3615
- $,
3616
- Y
3617
- ), nt.current = m.zoomBehavior, G.current = m.svgElement, F.current = m.gElement, H.current = m.baseFontSize, Q.current = m.viewBoxWidth, F.current) {
3618
- const x = F.current.getBBox();
3619
- M.current = { x: x.x, y: x.y, width: x.width, height: x.height };
3620
- const b = Q.current, y = ((w = j.current) == null ? void 0 : w.clientWidth) || 1, C = H.current, _ = y / b, L = 0.9 * b / x.width, q = 16 / (C * _);
3621
- N.current = L >= q;
3617
+ V,
3618
+ x,
3619
+ Z
3620
+ ), R.current = Y.zoomBehavior, U.current = Y.svgElement, W.current = Y.gElement, P.current = Y.baseFontSize, f.current = Y.viewBoxWidth, K && U.current && U.current.addEventListener("click", (g) => {
3621
+ const v = new MouseEvent("click", {
3622
+ bubbles: !0,
3623
+ cancelable: !0,
3624
+ clientX: g.clientX,
3625
+ clientY: g.clientY,
3626
+ view: window
3627
+ }), M = document.elementsFromPoint(g.clientX, g.clientY).find((F) => {
3628
+ var q;
3629
+ return !((q = U.current) != null && q.contains(F)) && F !== U.current;
3630
+ });
3631
+ M && M.dispatchEvent(v), document.body.dispatchEvent(new MouseEvent("click", {
3632
+ bubbles: !0,
3633
+ cancelable: !0,
3634
+ clientX: g.clientX,
3635
+ clientY: g.clientY,
3636
+ view: window
3637
+ }));
3638
+ }), W.current) {
3639
+ const g = W.current.getBBox();
3640
+ D.current = { x: g.x, y: g.y, width: g.width, height: g.height };
3641
+ const v = f.current, L = ((C = N.current) == null ? void 0 : C.clientWidth) || 1, M = P.current, F = L / v, q = 0.9 * v / g.width, ot = 16 / (M * F);
3642
+ b.current = q >= ot;
3622
3643
  }
3623
- if (f.current = null, D.current && (clearInterval(D.current), D.current = null), v.current = null, c) {
3624
- const x = j.current.querySelector("svg"), b = x == null ? void 0 : x.querySelector("#graph0");
3625
- if (x && b) {
3626
- const y = E, C = x.getAttribute("viewBox");
3627
- let _ = 1e3;
3628
- if (C) {
3629
- const [, , Z] = C.split(" ").map(Number);
3630
- Z && (_ = Z);
3644
+ if (y.current = null, S.current && (clearInterval(S.current), S.current = null), X.current = null, c) {
3645
+ const g = N.current.querySelector("svg"), v = g == null ? void 0 : g.querySelector("#graph0");
3646
+ if (g && v) {
3647
+ const L = E, M = g.getAttribute("viewBox");
3648
+ let F = 1e3;
3649
+ if (M) {
3650
+ const [, , I] = M.split(" ").map(Number);
3651
+ I && (F = I);
3631
3652
  }
3632
- const L = () => {
3633
- var tt;
3634
- const Z = b.getAttribute("transform");
3635
- let S = 1;
3636
- if (Z) {
3637
- const ot = Z.match(/scale\(([^,)]+)/);
3638
- if (ot) {
3639
- const V = parseFloat(ot[1]);
3640
- isNaN(V) || (S = V);
3653
+ const q = () => {
3654
+ var rt;
3655
+ const I = v.getAttribute("transform");
3656
+ let k = 1;
3657
+ if (I) {
3658
+ const J = I.match(/scale\(([^,)]+)/);
3659
+ if (J) {
3660
+ const H = parseFloat(J[1]);
3661
+ isNaN(H) || (k = H);
3641
3662
  } else {
3642
- const V = Z.match(/matrix\(([^,)]+)/);
3643
- if (V) {
3644
- const K = parseFloat(V[1]);
3645
- isNaN(K) || (S = K);
3663
+ const H = I.match(/matrix\(([^,)]+)/);
3664
+ if (H) {
3665
+ const T = parseFloat(H[1]);
3666
+ isNaN(T) || (k = T);
3646
3667
  }
3647
3668
  }
3648
3669
  }
3649
- const z = (((tt = j.current) == null ? void 0 : tt.clientWidth) || 1) / _, k = y * z * S;
3650
- !isNaN(k) && !isNaN(S) && c({ baseFontSize: y, actualFontSize: k, scale: S });
3670
+ const j = (((rt = N.current) == null ? void 0 : rt.clientWidth) || 1) / F, tt = L * j * k;
3671
+ !isNaN(tt) && !isNaN(k) && c({ baseFontSize: L, actualFontSize: tt, scale: k });
3651
3672
  };
3652
- L();
3653
- const q = new MutationObserver(L);
3654
- q.observe(b, {
3673
+ q();
3674
+ const ot = new MutationObserver(q);
3675
+ ot.observe(v, {
3655
3676
  attributes: !0,
3656
3677
  attributeFilter: ["transform"]
3657
3678
  });
3658
- const rt = () => L();
3659
- return window.addEventListener("resize", rt), () => {
3660
- q.disconnect(), window.removeEventListener("resize", rt);
3679
+ const Q = () => q();
3680
+ return window.addEventListener("resize", Q), () => {
3681
+ ot.disconnect(), window.removeEventListener("resize", Q);
3661
3682
  };
3662
3683
  }
3663
3684
  }
3664
3685
  }
3665
- a == null || a({ json: h, svgElement: G.current });
3666
- }).catch((P) => {
3667
- I || (D.current && (clearInterval(D.current), D.current = null), v.current = null, P.message !== "Cancelled by user" && P.message !== "Request cancelled" && (console.error("GraphvizRenderer error:", P), j.current && (j.current.innerHTML = `<div style="padding: 1rem; color: #ef4444"><strong>Error rendering graph:</strong> ${P.message}</div>`), i == null || i(P instanceof Error ? P : new Error(String(P)))));
3686
+ a == null || a({ json: h, svgElement: U.current });
3687
+ }).catch((p) => {
3688
+ G || (S.current && (clearInterval(S.current), S.current = null), X.current = null, p.message !== "Cancelled by user" && p.message !== "Request cancelled" && (console.error("GraphvizRenderer error:", p), N.current && (N.current.innerHTML = `<div style="padding: 1rem; color: #ef4444"><strong>Error rendering graph:</strong> ${p.message}</div>`), i == null || i(p instanceof Error ? p : new Error(String(p)))));
3668
3689
  }), () => {
3669
- I = !0, D.current && (clearInterval(D.current), D.current = null), v.current = null, O();
3690
+ G = !0, S.current && (clearInterval(S.current), S.current = null), X.current = null, nt();
3670
3691
  };
3671
3692
  }, [
3672
3693
  e,
@@ -3674,52 +3695,52 @@ const Oa = Tr(function({
3674
3695
  n,
3675
3696
  l,
3676
3697
  d,
3677
- R,
3698
+ _,
3678
3699
  B,
3679
- $,
3680
- Y
3700
+ V,
3701
+ x
3681
3702
  ]), Le(() => {
3682
- var P;
3683
- if (R || !j.current) return;
3684
- const I = j.current.querySelector("svg");
3685
- if (I && (I.querySelectorAll("g.edge.selected").forEach((h) => {
3686
- h.classList.remove("selected"), h.querySelectorAll(".close-btn, .close-btn-bg").forEach((w) => w.remove());
3687
- }), p != null)) {
3688
- const h = I.querySelector(`g.edge[data-edge-id="${p}"]`);
3703
+ var p;
3704
+ if (_ || !N.current) return;
3705
+ const G = N.current.querySelector("svg");
3706
+ if (G && (G.querySelectorAll("g.edge.selected").forEach((h) => {
3707
+ h.classList.remove("selected"), h.querySelectorAll(".close-btn, .close-btn-bg").forEach((C) => C.remove());
3708
+ }), m != null)) {
3709
+ const h = G.querySelector(`g.edge[data-edge-id="${m}"]`);
3689
3710
  if (h) {
3690
- h.classList.add("selected"), (P = h.parentNode) == null || P.appendChild(h);
3691
- const w = h.querySelector(".label-bg");
3692
- if (w && g) {
3693
- w.getBoundingClientRect();
3711
+ h.classList.add("selected"), (p = h.parentNode) == null || p.appendChild(h);
3712
+ const C = h.querySelector(".label-bg");
3713
+ if (C && w) {
3714
+ C.getBoundingClientRect();
3694
3715
  const E = h.querySelector(".label-text-elem") || h.querySelector(".label-text");
3695
3716
  if (E) {
3696
- const m = E.getAttribute("y"), x = parseFloat(w.getAttribute("x") || "0"), b = parseFloat(w.getAttribute("width") || "0"), y = x + b + 16;
3717
+ const Y = E.getAttribute("y"), g = parseFloat(C.getAttribute("x") || "0"), v = parseFloat(C.getAttribute("width") || "0"), L = g + v + 16;
3697
3718
  if (!h.querySelector(".close-btn")) {
3698
- const C = document.createElementNS("http://www.w3.org/2000/svg", "circle");
3699
- C.setAttribute("class", "close-btn-bg"), C.setAttribute("cx", String(y)), C.setAttribute("cy", m || "0"), C.setAttribute("r", "8"), C.setAttribute("fill", "white"), C.setAttribute("stroke", "#d0d0d0"), C.setAttribute("stroke-width", "1"), C.style.cursor = "pointer";
3700
- const _ = document.createElementNS("http://www.w3.org/2000/svg", "text");
3701
- _.setAttribute("class", "close-btn"), _.setAttribute("x", String(y)), _.setAttribute("y", m || "0"), _.setAttribute("text-anchor", "middle"), _.setAttribute("dominant-baseline", "central"), _.setAttribute("font-family", "Arial"), _.setAttribute("font-size", "12px"), _.setAttribute("font-weight", "bold"), _.setAttribute("fill", "#888"), _.style.cursor = "pointer", _.textContent = "✕";
3702
- const L = (q) => {
3703
- q.stopPropagation(), g(null);
3719
+ const M = document.createElementNS("http://www.w3.org/2000/svg", "circle");
3720
+ M.setAttribute("class", "close-btn-bg"), M.setAttribute("cx", String(L)), M.setAttribute("cy", Y || "0"), M.setAttribute("r", "8"), M.setAttribute("fill", "white"), M.setAttribute("stroke", "#d0d0d0"), M.setAttribute("stroke-width", "1"), M.style.cursor = "pointer";
3721
+ const F = document.createElementNS("http://www.w3.org/2000/svg", "text");
3722
+ F.setAttribute("class", "close-btn"), F.setAttribute("x", String(L)), F.setAttribute("y", Y || "0"), F.setAttribute("text-anchor", "middle"), F.setAttribute("dominant-baseline", "central"), F.setAttribute("font-family", "Arial"), F.setAttribute("font-size", "12px"), F.setAttribute("font-weight", "bold"), F.setAttribute("fill", "#888"), F.style.cursor = "pointer", F.textContent = "✕";
3723
+ const q = (ot) => {
3724
+ ot.stopPropagation(), w(null);
3704
3725
  };
3705
- C.addEventListener("click", L), _.addEventListener("click", L), h.appendChild(C), h.appendChild(_);
3726
+ M.addEventListener("click", q), F.addEventListener("click", q), h.appendChild(M), h.appendChild(F);
3706
3727
  }
3707
3728
  }
3708
3729
  }
3709
3730
  }
3710
3731
  }
3711
- }, [p, g, R]), /* @__PURE__ */ fe("div", { className: `graphviz-renderer ${s}`.trim(), style: { position: "relative", width: "100%", height: "100%" }, children: [
3712
- /* @__PURE__ */ Bt("div", { ref: j, style: { width: "100%", height: "100%" } }),
3713
- U && u && (o ?? /* @__PURE__ */ Bt(Ua, { onCancel: O })),
3714
- et && !U && /* @__PURE__ */ fe("div", { style: { padding: "1rem", color: "#ef4444" }, children: [
3715
- /* @__PURE__ */ Bt("strong", { children: "Error:" }),
3732
+ }, [m, w, _]), /* @__PURE__ */ he("div", { className: `graphviz-renderer ${s}`.trim(), style: { position: "relative", width: "100%", height: "100%" }, children: [
3733
+ /* @__PURE__ */ Nt("div", { ref: N, style: { width: "100%", height: "100%" } }),
3734
+ it && u && (o ?? /* @__PURE__ */ Nt(Ua, { onCancel: nt })),
3735
+ A && !it && /* @__PURE__ */ he("div", { style: { padding: "1rem", color: "#ef4444" }, children: [
3736
+ /* @__PURE__ */ Nt("strong", { children: "Error:" }),
3716
3737
  " ",
3717
- et
3738
+ A
3718
3739
  ] })
3719
3740
  ] });
3720
3741
  });
3721
3742
  export {
3722
- Ee as DEFAULT_LAYOUT_CONFIG,
3743
+ be as DEFAULT_LAYOUT_CONFIG,
3723
3744
  Oa as GraphvizRenderer,
3724
3745
  za as LARGE_GRAPH_THRESHOLD,
3725
3746
  Ua as WorkerLoadingIndicator,