@fallen-8/studio 0.0.36 → 0.0.38

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.
Files changed (47) hide show
  1. package/dist-lib/{Canvas3D-BXYc6PEP.js → Canvas3D-DEWoiNMD.js} +1 -1
  2. package/dist-lib/{F8GraphCanvas-Ckq0NuuE.js → F8GraphCanvas-Cu6dtIgq.js} +981 -965
  3. package/dist-lib/canvas.js +1 -1
  4. package/dist-lib/{cssMode-nGncvC5m.js → cssMode-1gdBAwNQ.js} +1 -1
  5. package/dist-lib/f8-studio.css +1 -1
  6. package/dist-lib/f8-studio.js +2 -2
  7. package/dist-lib/{freemarker2-CP74sa8J.js → freemarker2-DOQZLtnt.js} +1 -1
  8. package/dist-lib/{handlebars-QALLOIn0.js → handlebars-CIXlymxU.js} +1 -1
  9. package/dist-lib/{html-85a-cm74.js → html--Bi9VDgI.js} +1 -1
  10. package/dist-lib/{htmlMode-BgQACh7e.js → htmlMode-BqCrpeeP.js} +1 -1
  11. package/dist-lib/{index-CQF9rZdm.js → index-0ioFtrZM.js} +24510 -23934
  12. package/dist-lib/{javascript-C5gSrEJX.js → javascript-BL3tIzUw.js} +1 -1
  13. package/dist-lib/{jsonMode-CPyHCN9i.js → jsonMode-FxM7KRm5.js} +1 -1
  14. package/dist-lib/{liquid-C-WFafiu.js → liquid-wB7unZht.js} +1 -1
  15. package/dist-lib/{mdx-Cqij6eG9.js → mdx-DmS41r19.js} +1 -1
  16. package/dist-lib/{python-DxKmSiUE.js → python-C24igqMV.js} +1 -1
  17. package/dist-lib/{razor-C_PJXRiv.js → razor-BRvioLVk.js} +1 -1
  18. package/dist-lib/{tsMode-BPfWv0l3.js → tsMode-zMn1qnUE.js} +1 -1
  19. package/dist-lib/types/api/client.d.ts +49 -0
  20. package/dist-lib/types/api/endpoints.d.ts +49 -3
  21. package/dist-lib/types/api/types.d.ts +65 -3
  22. package/dist-lib/types/app/nav.d.ts +2 -7
  23. package/dist-lib/types/app/routes.d.ts +7 -2
  24. package/dist-lib/types/components/ConfigurationSurface.d.ts +23 -2
  25. package/dist-lib/types/components/ErrorBox.d.ts +6 -0
  26. package/dist-lib/types/components/SemanticBlockEditor.d.ts +4 -1
  27. package/dist-lib/types/components/SemanticQueryEditor.d.ts +8 -1
  28. package/dist-lib/types/components/SettingRow.d.ts +14 -0
  29. package/dist-lib/types/components/StoredQueriesPanel.d.ts +16 -11
  30. package/dist-lib/types/components/StoredQueryControls.d.ts +3 -4
  31. package/dist-lib/types/delegate/nl/NlDraftStats.d.ts +13 -0
  32. package/dist-lib/types/delegate/nl/config.d.ts +5 -4
  33. package/dist-lib/types/delegate/nl/generate.d.ts +6 -0
  34. package/dist-lib/types/lib/fieldHelp.d.ts +3 -1
  35. package/dist-lib/types/lib/fileLimits.d.ts +69 -0
  36. package/dist-lib/types/lib/format.d.ts +8 -0
  37. package/dist-lib/types/lib/modelProvenance.d.ts +26 -0
  38. package/dist-lib/types/lib/storedQueries.d.ts +10 -0
  39. package/dist-lib/types/lib/vectorIndexCreate.d.ts +49 -0
  40. package/dist-lib/types/screens/PathScreen.d.ts +3 -0
  41. package/dist-lib/types/screens/TraverseScreen.d.ts +1 -0
  42. package/dist-lib/types/state/instanceStore.d.ts +49 -2
  43. package/dist-lib/types/state/integrations.d.ts +11 -1
  44. package/dist-lib/{typescript-CmUu7z19.js → typescript-BIjKKvsW.js} +1 -1
  45. package/dist-lib/{xml-BID2APnO.js → xml-CT-uMOiT.js} +1 -1
  46. package/dist-lib/{yaml-CpQ-mN6F.js → yaml-Dezcc_VH.js} +1 -1
  47. package/package.json +1 -1
@@ -1,5 +1,5 @@
1
- import { jsxs as va, jsx as We } from "react/jsx-runtime";
2
- import Dt, { createContext as hi, useContext as di, useRef as Be, useEffect as Qe, useImperativeHandle as fi, lazy as ma, useMemo as an, Suspense as ya } from "react";
1
+ import { jsxs as ma, jsx as We } from "react/jsx-runtime";
2
+ import Dt, { createContext as di, useContext as fi, useRef as Be, useEffect as Qe, useImperativeHandle as gi, lazy as ya, useMemo as an, Suspense as ba } from "react";
3
3
  const on = (n) => {
4
4
  let r;
5
5
  const t = /* @__PURE__ */ new Set(), e = (l, c) => {
@@ -10,8 +10,8 @@ const on = (n) => {
10
10
  }
11
11
  }, i = () => r, s = { setState: e, getState: i, getInitialState: () => u, subscribe: (l) => (t.add(l), () => t.delete(l)) }, u = r = n(e, i, s);
12
12
  return s;
13
- }, ba = ((n) => n ? on(n) : on), wa = (n) => n;
14
- function Ea(n, r = wa) {
13
+ }, wa = ((n) => n ? on(n) : on), Ea = (n) => n;
14
+ function _a(n, r = Ea) {
15
15
  const t = Dt.useSyncExternalStore(
16
16
  n.subscribe,
17
17
  Dt.useCallback(() => r(n.getState()), [n, r]),
@@ -19,11 +19,11 @@ function Ea(n, r = wa) {
19
19
  );
20
20
  return Dt.useDebugValue(t), t;
21
21
  }
22
- const _a = (n) => {
23
- const r = ba(n), t = (e) => Ea(r, e);
22
+ const Ta = (n) => {
23
+ const r = wa(n), t = (e) => _a(r, e);
24
24
  return Object.assign(t, r), t;
25
- }, gi = ((n) => _a);
26
- function Ta(n, r) {
25
+ }, pi = ((n) => Ta);
26
+ function Sa(n, r) {
27
27
  let t;
28
28
  try {
29
29
  t = n();
@@ -61,9 +61,9 @@ const _r = (n) => (r) => {
61
61
  }
62
62
  };
63
63
  }
64
- }, Sa = (n, r) => (t, e, i) => {
64
+ }, Ra = (n, r) => (t, e, i) => {
65
65
  let a = {
66
- storage: Ta(() => window.localStorage),
66
+ storage: Sa(() => window.localStorage),
67
67
  partialize: (w) => w,
68
68
  version: 0,
69
69
  merge: (w, k) => ({
@@ -160,7 +160,7 @@ const _r = (n) => (r) => {
160
160
  l.delete(w);
161
161
  })
162
162
  }, a.skipHydration || R(), b || y;
163
- }, Ra = Sa, Tr = {
163
+ }, Aa = Ra, Tr = {
164
164
  renderer: "2d",
165
165
  layout2d: "force",
166
166
  layout3d: "force",
@@ -181,7 +181,7 @@ const _r = (n) => (r) => {
181
181
  // persisted copy winning, so a magnitude written here would be frozen into every existing
182
182
  // workspace's local storage and would then outrank the documented default forever.
183
183
  };
184
- function Aa(n) {
184
+ function ka(n) {
185
185
  const r = n.trim();
186
186
  if (!r) return { ok: !1, error: "empty" };
187
187
  let t;
@@ -211,20 +211,20 @@ const $r = {
211
211
  queryText: "",
212
212
  embeddingName: "default",
213
213
  metric: "Cosine"
214
- }, pi = {
214
+ }, vi = {
215
215
  ...$r,
216
216
  enabled: !1,
217
217
  minScoreEnabled: !1,
218
218
  minScore: "0.7",
219
219
  costBySimilarity: !1
220
220
  };
221
- function ec(n) {
221
+ function ac(n) {
222
222
  return n.enabled && (n.minScoreEnabled || n.costBySimilarity);
223
223
  }
224
- function tc(n) {
224
+ function oc(n) {
225
225
  return n.enabled && n.costBySimilarity;
226
226
  }
227
- function ka(n, r) {
227
+ function Ca(n, r) {
228
228
  const t = {
229
229
  embeddingName: n.embeddingName.trim() || void 0,
230
230
  metric: n.metric
@@ -239,31 +239,33 @@ function ka(n, r) {
239
239
  return { ok: !1, error: "enter query text (or switch to a pasted vector)." };
240
240
  t.queryText = n.queryText;
241
241
  } else {
242
- const e = Aa(n.vectorText);
242
+ const e = ka(n.vectorText);
243
243
  if (!e.ok)
244
244
  return { ok: !1, error: `query vector: ${e.error}.` };
245
245
  t.queryVector = e.vector;
246
246
  }
247
247
  return { ok: !0, spec: t };
248
248
  }
249
- function rc(n) {
249
+ function sc(n) {
250
250
  const r = n.trim();
251
251
  if (!r)
252
252
  return;
253
253
  const t = Number(r);
254
254
  return Number.isFinite(t) ? t : void 0;
255
255
  }
256
- function nc(n) {
256
+ function uc(n) {
257
257
  const r = n.metric === "L2" ? "≤" : "≥", t = [`${n.metric} over '${n.embeddingName}' (d=${n.dimension})`];
258
258
  n.minScore != null && t.push(`pre-filter ${r} ${n.minScore}`);
259
259
  for (const e of n.patternThresholds ?? [])
260
260
  t.push(`step ${e.pattern} ${r} ${e.minScore}`);
261
- return n.queryText && t.push(`from text "${n.queryText}"`), t.push("bound at creation — recalculate reuses the stored vector"), t.join(" · ");
261
+ return n.queryText && t.push(`from text "${n.queryText}"`), n.embeddingBackend && t.push(
262
+ n.embeddingIdentity ? `via ${n.embeddingBackend} · ${n.embeddingIdentity}` : `via ${n.embeddingBackend}`
263
+ ), t.push("bound at creation — recalculate reuses the stored vector"), t.join(" · ");
262
264
  }
263
- function ic(n, r) {
265
+ function lc(n, r) {
264
266
  if (!n.enabled)
265
267
  return { ok: !0, spec: void 0 };
266
- const t = ka(n, { providerEnabled: r.providerEnabled });
268
+ const t = Ca(n, { providerEnabled: r.providerEnabled });
267
269
  if (!t.ok)
268
270
  return t;
269
271
  const e = t.spec;
@@ -298,13 +300,13 @@ const Sr = [
298
300
  labels: [],
299
301
  keys: []
300
302
  };
301
- function ac(n, r) {
303
+ function cc(n, r) {
302
304
  return n.kind === "resync" ? !0 : !(!r.kinds.includes(n.kind) || n.element !== void 0 && !r.elements.includes(n.element) || r.labels.length > 0 && (n.label === void 0 || !r.labels.includes(n.label)) || r.keys.length > 0 && (n.key === void 0 || !r.keys.includes(n.key)));
303
305
  }
304
- function oc(n) {
306
+ function hc(n) {
305
307
  return n.kinds.length > 0 && n.elements.length > 0;
306
308
  }
307
- function sc(n) {
309
+ function dc(n) {
308
310
  return {
309
311
  kinds: n.kinds.length === Sr.length ? void 0 : Sr.filter((r) => n.kinds.includes(r)),
310
312
  elements: n.elements.length === Rr.length ? void 0 : Rr.filter((r) => n.elements.includes(r)),
@@ -316,10 +318,10 @@ function He(n, r) {
316
318
  const t = r === void 0 ? n : `${n}/${r}`;
317
319
  return t.endsWith("/default") ? t.slice(0, -8) : t;
318
320
  }
319
- const Ca = 100;
320
- let xa = 0;
321
- function Da() {
322
- return gi()((n) => ({
321
+ const xa = 100;
322
+ let Da = 0;
323
+ function La() {
324
+ return pi()((n) => ({
323
325
  entries: [],
324
326
  unread: 0,
325
327
  resyncSinceOpen: !1,
@@ -327,9 +329,9 @@ function Da() {
327
329
  lastEventId: null,
328
330
  record: (r, t) => n((e) => ({
329
331
  entries: [
330
- { key: ++xa, event: r, receivedAt: Date.now() },
332
+ { key: ++Da, event: r, receivedAt: Date.now() },
331
333
  ...e.entries
332
- ].slice(0, Ca),
334
+ ].slice(0, xa),
333
335
  unread: !e.panelOpen && r.kind !== "resync" && t ? e.unread + 1 : e.unread,
334
336
  resyncSinceOpen: !e.panelOpen && r.kind === "resync" ? !0 : e.resyncSinceOpen
335
337
  })),
@@ -339,16 +341,16 @@ function Da() {
339
341
  }));
340
342
  }
341
343
  const xe = /* @__PURE__ */ new Map();
342
- function uc(n, r) {
344
+ function fc(n, r) {
343
345
  const t = He(n, r);
344
346
  let e = xe.get(t);
345
- return e || (e = Da(), xe.set(t, e)), e;
347
+ return e || (e = La(), xe.set(t, e)), e;
346
348
  }
347
- function La(n, r) {
349
+ function Ga(n, r) {
348
350
  const t = He(n, r);
349
351
  xe.get(t)?.getState().clear(), xe.delete(t);
350
352
  }
351
- function Ga(n) {
353
+ function Ia(n) {
352
354
  for (const [r, t] of [...xe.entries()])
353
355
  (r === n || r.startsWith(`${n}/`)) && (t.getState().clear(), xe.delete(r));
354
356
  }
@@ -358,7 +360,7 @@ function Pa(n, r, t) {
358
360
  const a = xe.get(e);
359
361
  xe.get(i)?.getState().clear(), xe.delete(e), xe.delete(i), a && xe.set(i, a);
360
362
  }
361
- const Ia = {
363
+ const Fa = {
362
364
  ink: "--color-ink",
363
365
  panel: "--color-panel",
364
366
  panel2: "--color-panel-2",
@@ -373,17 +375,17 @@ const Ia = {
373
375
  fontMono: "--font-mono"
374
376
  };
375
377
  let _t = {}, wt = 0;
376
- function lc() {
378
+ function gc() {
377
379
  return _t;
378
380
  }
379
- function cc(n) {
381
+ function pc(n) {
380
382
  if (wt > 0 && n !== _t)
381
383
  throw new Error(
382
384
  "F8 Studio is already mounted. Two simultaneous Studio embeds are not supported (they share one instance registry and one set of persisted keys); unmount the first, or run the second in its own realm (iframe/worker)."
383
385
  );
384
386
  _t = n;
385
387
  }
386
- function hc() {
388
+ function vc() {
387
389
  if (wt > 0)
388
390
  throw new Error(
389
391
  "F8 Studio is already mounted. Two simultaneous Studio embeds are not supported (they share one instance registry and one set of persisted keys); unmount the first, or run the second in its own realm (iframe/worker)."
@@ -394,31 +396,31 @@ function hc() {
394
396
  n || (n = !0, wt -= 1);
395
397
  };
396
398
  }
397
- function dc() {
399
+ function mc() {
398
400
  wt === 0 && (_t = {});
399
401
  }
400
- function Fa(n) {
402
+ function Oa(n) {
401
403
  return `${_t.storageNamespace ?? ""}${n}`;
402
404
  }
403
- function Oa(n) {
405
+ function za(n) {
404
406
  const r = {};
405
407
  if (!n) return r;
406
408
  for (const [t, e] of Object.entries(n))
407
- e && (r[Ia[t]] = e);
409
+ e && (r[Fa[t]] = e);
408
410
  return r;
409
411
  }
410
- const za = hi({});
411
- function fc() {
412
- return di(za);
412
+ const Na = di({});
413
+ function yc() {
414
+ return fi(Na);
413
415
  }
414
- const Na = hi(void 0);
415
- function gc() {
416
- return di(Na);
416
+ const Ua = di(void 0);
417
+ function bc() {
418
+ return fi(Ua);
417
419
  }
418
- function Xe(n) {
419
- return Fa(`f8.workspace.${n}`);
420
+ function Ke(n) {
421
+ return Oa(`f8.workspace.${n}`);
420
422
  }
421
- function vi(n) {
423
+ function mi(n) {
422
424
  return n.label ?? n.edgePropertyId ?? null;
423
425
  }
424
426
  const un = 200;
@@ -430,7 +432,7 @@ function ln(n) {
430
432
  }
431
433
  return r;
432
434
  }
433
- function Ua(n, r, t) {
435
+ function $a(n, r, t) {
434
436
  const e = { ...t?.nodes ?? {} }, i = { ...t?.edges ?? {} };
435
437
  for (const a of n)
436
438
  e[a.id] = {
@@ -449,7 +451,7 @@ function Ua(n, r, t) {
449
451
  };
450
452
  return { nodes: e, edges: i };
451
453
  }
452
- const qt = {
454
+ const Ma = ["path", "subgraph", "stored"], cn = "path", Ba = (n) => typeof n == "string" && Ma.includes(n), wc = (n) => n === "SubGraph" ? "subgraph" : "path", Kt = {
453
455
  from: "",
454
456
  to: "",
455
457
  algorithm: "BLS",
@@ -463,14 +465,15 @@ const qt = {
463
465
  edgeCost: "",
464
466
  filterSource: "inline",
465
467
  storedQuery: "",
466
- semantic: { ...pi }
467
- }, Xt = {
468
+ semantic: { ...vi }
469
+ }, Wa = ["property", "index", "semantic"], Mt = {
468
470
  mode: "property",
469
471
  propertyScope: "key",
470
472
  propertyId: "",
471
473
  searchTerm: "",
472
474
  searchLabel: "",
473
475
  indexId: "",
476
+ semanticIndexId: "",
474
477
  form: "equality",
475
478
  operator: "Equals",
476
479
  resultType: "Both",
@@ -486,9 +489,13 @@ const qt = {
486
489
  vectorK: "10",
487
490
  vectorKind: "any",
488
491
  vectorLabel: "",
489
- vectorSource: "vector",
490
492
  vectorSearchText: ""
491
- }, Lt = {
493
+ };
494
+ function Ha(n) {
495
+ const { vectorSource: r, ...t } = n ?? {}, e = { ...Mt, ...t };
496
+ return Wa.includes(e.mode) || (e.mode = Mt.mode), r === "text" && e.mode === "index" && e.form === "vector" ? { ...e, mode: "semantic", semanticIndexId: e.semanticIndexId || e.indexId } : e;
497
+ }
498
+ const Lt = {
492
499
  name: "",
493
500
  fromSubGraph: "",
494
501
  vertexFilterMode: "everything",
@@ -499,7 +506,7 @@ const qt = {
499
506
  filterSource: "inline",
500
507
  storedQuery: "",
501
508
  semanticQuery: { ...$r }
502
- }, Kt = {
509
+ }, Xt = {
503
510
  idInput: "",
504
511
  lookupKind: "graphelement",
505
512
  maxElements: 1e3,
@@ -518,7 +525,7 @@ const qt = {
518
525
  showWriteBack: !1,
519
526
  writeBack: !1,
520
527
  writeBackKey: ""
521
- }, cn = {
528
+ }, hn = {
522
529
  tab: "style",
523
530
  findTerm: "",
524
531
  findLabel: "",
@@ -526,9 +533,9 @@ const qt = {
526
533
  connectMaxDepth: 3,
527
534
  connectScope: "all"
528
535
  };
529
- function $a(n) {
530
- return gi()(
531
- Ra(
536
+ function ja(n) {
537
+ return pi()(
538
+ Aa(
532
539
  (r) => ({
533
540
  canvasNodes: {},
534
541
  canvasEdges: {},
@@ -536,18 +543,19 @@ function $a(n) {
536
543
  pathOverlay: null,
537
544
  wholeGraphTruncation: null,
538
545
  resultSets: [],
539
- pathDraft: { ...qt },
540
- queryDraft: { ...Xt },
546
+ pathDraft: { ...Kt },
547
+ queryDraft: { ...Mt },
541
548
  subgraphDraft: { ...Lt },
542
- browserDraft: { ...Kt },
549
+ browserDraft: { ...Xt },
543
550
  analyticsDraft: { ...Yt },
544
- canvasToolsDraft: { ...cn },
551
+ canvasToolsDraft: { ...hn },
552
+ traverseTab: cn,
545
553
  scanPrefill: null,
546
554
  feedFilter: { ...sn },
547
555
  inspectPrefill: null,
548
556
  integrationWatch: null,
549
557
  mergeIntoCanvas: (t, e) => r((i) => {
550
- const a = Ua(t, e, {
558
+ const a = $a(t, e, {
551
559
  nodes: i.canvasNodes,
552
560
  edges: i.canvasEdges
553
561
  });
@@ -589,23 +597,24 @@ function $a(n) {
589
597
  })),
590
598
  removeResultSet: (t) => r((e) => ({ resultSets: e.resultSets.filter((i) => i.id !== t) })),
591
599
  setPathDraft: (t) => r((e) => ({ pathDraft: { ...e.pathDraft, ...t } })),
592
- resetPathDraft: () => r({ pathDraft: { ...qt } }),
600
+ resetPathDraft: () => r({ pathDraft: { ...Kt } }),
593
601
  setQueryDraft: (t) => r((e) => ({ queryDraft: { ...e.queryDraft, ...t } })),
594
- resetQueryDraft: () => r({ queryDraft: { ...Xt } }),
602
+ resetQueryDraft: () => r({ queryDraft: { ...Mt } }),
595
603
  setSubgraphDraft: (t) => r((e) => ({ subgraphDraft: { ...e.subgraphDraft, ...t } })),
596
604
  resetSubgraphDraft: () => r({ subgraphDraft: { ...Lt } }),
597
605
  setBrowserDraft: (t) => r((e) => ({ browserDraft: { ...e.browserDraft, ...t } })),
598
- resetBrowserDraft: () => r({ browserDraft: { ...Kt } }),
606
+ resetBrowserDraft: () => r({ browserDraft: { ...Xt } }),
599
607
  setAnalyticsDraft: (t) => r((e) => ({ analyticsDraft: { ...e.analyticsDraft, ...t } })),
600
608
  resetAnalyticsDraft: () => r({ analyticsDraft: { ...Yt } }),
601
609
  setCanvasToolsDraft: (t) => r((e) => ({ canvasToolsDraft: { ...e.canvasToolsDraft, ...t } })),
610
+ setTraverseTab: (t) => r({ traverseTab: t }),
602
611
  setScanPrefill: (t) => r({ scanPrefill: t }),
603
612
  setFeedFilter: (t) => r((e) => ({ feedFilter: { ...e.feedFilter, ...t } })),
604
613
  setInspectPrefill: (t) => r({ inspectPrefill: t }),
605
614
  setIntegrationWatch: (t) => r({ integrationWatch: t })
606
615
  }),
607
616
  {
608
- name: Xe(n),
617
+ name: Ke(n),
609
618
  // One-shot navigation intents are session state: persisted, a never-consumed
610
619
  // one would fire a surprise lookup on a later session's first visit.
611
620
  partialize: ({ scanPrefill: r, inspectPrefill: t, ...e }) => e,
@@ -617,13 +626,13 @@ function $a(n) {
617
626
  ...t,
618
627
  ...e,
619
628
  pathDraft: {
620
- ...qt,
629
+ ...Kt,
621
630
  ...e.pathDraft ?? {},
622
631
  // Nested draft added after some state was persisted: deep-default it too, so
623
632
  // an older pathDraft picks up every semantic field instead of a partial.
624
- semantic: { ...pi, ...e.pathDraft?.semantic ?? {} }
633
+ semantic: { ...vi, ...e.pathDraft?.semantic ?? {} }
625
634
  },
626
- queryDraft: { ...Xt, ...e.queryDraft ?? {} },
635
+ queryDraft: Ha(e.queryDraft),
627
636
  // A subgraph draft persisted before the slot-mode restructure (feature
628
637
  // subgraph-semantic-thresholds) carried a block-local `semantic` object and no
629
638
  // slot modes; it is RESET rather than migrated - a draft is a session
@@ -636,9 +645,12 @@ function $a(n) {
636
645
  ...e.subgraphDraft?.semanticQuery ?? {}
637
646
  }
638
647
  },
639
- browserDraft: { ...Kt, ...e.browserDraft ?? {} },
648
+ browserDraft: { ...Xt, ...e.browserDraft ?? {} },
640
649
  analyticsDraft: { ...Yt, ...e.analyticsDraft ?? {} },
641
- canvasToolsDraft: { ...cn, ...e.canvasToolsDraft ?? {} },
650
+ canvasToolsDraft: { ...hn, ...e.canvasToolsDraft ?? {} },
651
+ // Normalized, not trusted: a tab id this build does not know (hand-edited storage,
652
+ // a renamed tab) would leave the Traverse screen with every panel hidden.
653
+ traverseTab: Ba(e.traverseTab) ? e.traverseTab : cn,
642
654
  styleConfig: { ...Tr, ...e.styleConfig ?? {} },
643
655
  feedFilter: { ...sn, ...e.feedFilter ?? {} },
644
656
  // One-shots never rehydrate (see partialize); this also drops values
@@ -656,34 +668,34 @@ function $a(n) {
656
668
  );
657
669
  }
658
670
  const je = /* @__PURE__ */ new Map();
659
- function pc(n, r) {
671
+ function Ec(n, r) {
660
672
  const t = He(n, r);
661
673
  let e = je.get(t);
662
- return e || (e = $a(t), je.set(t, e)), e;
674
+ return e || (e = ja(t), je.set(t, e)), e;
663
675
  }
664
- function vc(n, r) {
676
+ function _c(n, r) {
665
677
  const t = He(n, r);
666
- je.delete(t), localStorage.removeItem(Xe(t)), La(n, r);
678
+ je.delete(t), localStorage.removeItem(Ke(t)), Ga(n, r);
667
679
  }
668
- function mc(n) {
680
+ function Tc(n) {
669
681
  for (const r of [...je.keys()])
670
682
  (r === n || r.startsWith(`${n}/`)) && je.delete(r);
671
683
  for (let r = localStorage.length - 1; r >= 0; r--) {
672
684
  const t = localStorage.key(r);
673
- (t === Xe(n) || t?.startsWith(Xe(`${n}/`))) && localStorage.removeItem(t);
685
+ (t === Ke(n) || t?.startsWith(Ke(`${n}/`))) && localStorage.removeItem(t);
674
686
  }
675
- Ga(n);
687
+ Ia(n);
676
688
  }
677
- function yc(n, r, t) {
689
+ function Sc(n, r, t) {
678
690
  const e = He(n, r), i = He(n, t);
679
691
  if (e === i) return;
680
- const a = localStorage.getItem(Xe(e));
681
- a !== null && (localStorage.setItem(Xe(i), a), localStorage.removeItem(Xe(e))), je.delete(e), je.delete(i), Pa(n, r, t);
692
+ const a = localStorage.getItem(Ke(e));
693
+ a !== null && (localStorage.setItem(Ke(i), a), localStorage.removeItem(Ke(e))), je.delete(e), je.delete(i), Pa(n, r, t);
682
694
  }
683
- function bc() {
695
+ function Rc() {
684
696
  je.clear();
685
697
  }
686
- const hn = [
698
+ const dn = [
687
699
  "#4cc38a",
688
700
  // green
689
701
  "#58a6ff",
@@ -705,27 +717,27 @@ const hn = [
705
717
  "#79c0ff"
706
718
  // light blue
707
719
  ], Tt = "#55647a";
708
- function Mt(n) {
720
+ function Bt(n) {
709
721
  if (!n) return Tt;
710
722
  let r = 0;
711
723
  for (let t = 0; t < n.length; t++)
712
724
  r = r * 31 + n.charCodeAt(t) | 0;
713
- return hn[Math.abs(r) % hn.length];
725
+ return dn[Math.abs(r) % dn.length];
714
726
  }
715
- function mi(n) {
716
- return n == null || n === "" ? Tt : Mt(String(n));
727
+ function yi(n) {
728
+ return n == null || n === "" ? Tt : Bt(String(n));
717
729
  }
718
- const wc = "#39c5cf", Ec = "#f778ba";
719
- function Ma(n) {
730
+ const Ac = "#39c5cf", kc = "#f778ba";
731
+ function Va(n) {
720
732
  const r = Math.min(1, Math.max(0, n)), t = [57, 197, 207], e = [247, 120, 186];
721
733
  return `#${t.map((a, o) => Math.round(a + (e[o] - a) * r)).map((a) => a.toString(16).padStart(2, "0")).join("")}`;
722
734
  }
723
- const Ba = 5e3, Wa = {
735
+ const qa = 5e3, Ka = {
724
736
  nodeIds: /* @__PURE__ */ new Set(),
725
737
  edgeIds: /* @__PURE__ */ new Set(),
726
738
  active: !1,
727
739
  dim: !1
728
- }, Mr = 5, Ha = [3, 14], ja = 1, Va = [0.5, 5], qa = 11, Xa = 9, Ka = 8, Ya = 3, Za = "#4cc38a", Qa = "#2a3240", Ja = "#1a2029", eo = "#2c3543";
740
+ }, Mr = 5, Xa = [3, 14], Ya = 1, Za = [0.5, 5], Qa = 11, Ja = 9, eo = 8, to = 3, ro = "#4cc38a", no = "#2a3240", io = "#1a2029", ao = "#2c3543";
729
741
  function tt(n, r) {
730
742
  return (n.props ?? {})[r];
731
743
  }
@@ -737,7 +749,7 @@ function St(n) {
737
749
  }
738
750
  return null;
739
751
  }
740
- function to(n) {
752
+ function oo(n) {
741
753
  if (n == null || typeof n == "boolean") return null;
742
754
  const r = String(n).trim();
743
755
  return r ? /^(https?:\/\/|data:)/i.test(r) ? { kind: "url", value: r } : { kind: "emoji", value: [...r].slice(0, 8).join("") } : null;
@@ -756,7 +768,7 @@ function Ar(n, r, t) {
756
768
  }
757
769
  return { kind: "categorical", property: t };
758
770
  }
759
- function dn(n, r, t) {
771
+ function fn(n, r, t) {
760
772
  if (n.kind === "label") return t;
761
773
  const e = tt(r, n.property);
762
774
  if (e === void 0 || e === "") return Tt;
@@ -764,11 +776,11 @@ function dn(n, r, t) {
764
776
  const i = St(e);
765
777
  if (i === null) return Tt;
766
778
  const a = n.max - n.min;
767
- return Ma(a === 0 ? 0.5 : (i - n.min) / a);
779
+ return Va(a === 0 ? 0.5 : (i - n.min) / a);
768
780
  }
769
- return mi(e);
781
+ return yi(e);
770
782
  }
771
- function fn(n, r, t) {
783
+ function gn(n, r, t) {
772
784
  const e = n.filter((u) => u !== null);
773
785
  if (e.length === 0) return () => t;
774
786
  const i = Math.min(...e), a = Math.max(...e), [o, s] = r;
@@ -784,32 +796,32 @@ function Rt(n) {
784
796
  function Gt(n, r) {
785
797
  return Rt(n) ? n : r;
786
798
  }
787
- function gn(n, r) {
799
+ function pn(n, r) {
788
800
  if (!n) return r;
789
801
  const [t, e] = n;
790
802
  return Rt(t) && Rt(e) ? n : r;
791
803
  }
792
- function ro(n, r) {
804
+ function so(n, r) {
793
805
  const [t, e] = r;
794
806
  return Math.min(Math.max(n, Math.min(t, e)), Math.max(t, e));
795
807
  }
796
- function pn(n, r, t) {
797
- return Rt(n) ? r : ro(r, t);
808
+ function vn(n, r, t) {
809
+ return Rt(n) ? r : so(r, t);
798
810
  }
799
- function no(n) {
800
- const r = Gt(n.nodeSize, Mr), t = gn(n.nodeSizeRange, Ha), e = Gt(n.edgeWidth, ja), i = gn(n.edgeWidthRange, Va);
811
+ function uo(n) {
812
+ const r = Gt(n.nodeSize, Mr), t = pn(n.nodeSizeRange, Xa), e = Gt(n.edgeWidth, Ya), i = pn(n.edgeWidthRange, Za);
801
813
  return {
802
814
  nodeSize: r,
803
815
  nodeSizeRange: t,
804
- nodeSizeFallback: pn(n.nodeSize, r, t),
816
+ nodeSizeFallback: vn(n.nodeSize, r, t),
805
817
  edgeWidth: e,
806
818
  edgeWidthRange: i,
807
- edgeWidthFallback: pn(n.edgeWidth, e, i),
808
- labelSize: Gt(n.labelSize, qa),
809
- edgeLabelSize: Gt(n.edgeLabelSize, Xa)
819
+ edgeWidthFallback: vn(n.edgeWidth, e, i),
820
+ labelSize: Gt(n.labelSize, Qa),
821
+ edgeLabelSize: Gt(n.edgeLabelSize, Ja)
810
822
  };
811
823
  }
812
- function io(n) {
824
+ function lo(n) {
813
825
  const r = /* @__PURE__ */ new Map(), t = (e) => {
814
826
  let i = r.get(e);
815
827
  return i || (i = { in: 0, out: 0 }, r.set(e, i)), i;
@@ -818,8 +830,8 @@ function io(n) {
818
830
  t(e.source).out++, t(e.target).in++;
819
831
  return r;
820
832
  }
821
- function ao(n, r, t, e) {
822
- const i = Object.values(n), a = Object.values(r), o = no(e), s = Ar(i, e.nodeColorMode, e.nodeColorProperty), u = Ar(a, e.edgeColorMode, e.edgeColorProperty), l = e.nodeSizeMode === "in-degree" || e.nodeSizeMode === "out-degree" || e.nodeSizeMode === "degree" ? io(a) : null, c = (w) => {
833
+ function co(n, r, t, e) {
834
+ const i = Object.values(n), a = Object.values(r), o = uo(e), s = Ar(i, e.nodeColorMode, e.nodeColorProperty), u = Ar(a, e.edgeColorMode, e.edgeColorProperty), l = e.nodeSizeMode === "in-degree" || e.nodeSizeMode === "out-degree" || e.nodeSizeMode === "degree" ? lo(a) : null, c = (w) => {
823
835
  switch (e.nodeSizeMode) {
824
836
  case "property":
825
837
  return e.nodeSizeProperty ? St(tt(w, e.nodeSizeProperty)) : null;
@@ -834,12 +846,12 @@ function ao(n, r, t, e) {
834
846
  default:
835
847
  return null;
836
848
  }
837
- }, h = e.nodeSizeMode === "fixed" ? () => o.nodeSize : fn(i.map(c), o.nodeSizeRange, o.nodeSizeFallback), v = (w) => e.edgeWidthMode === "property" && e.edgeWidthProperty ? St(tt(w, e.edgeWidthProperty)) : null, y = e.edgeWidthMode === "fixed" ? () => o.edgeWidth : fn(a.map(v), o.edgeWidthRange, o.edgeWidthFallback), b = {};
849
+ }, h = e.nodeSizeMode === "fixed" ? () => o.nodeSize : gn(i.map(c), o.nodeSizeRange, o.nodeSizeFallback), v = (w) => e.edgeWidthMode === "property" && e.edgeWidthProperty ? St(tt(w, e.edgeWidthProperty)) : null, y = e.edgeWidthMode === "fixed" ? () => o.edgeWidth : gn(a.map(v), o.edgeWidthRange, o.edgeWidthFallback), b = {};
838
850
  for (const w of i) {
839
- const k = t.nodeIds.has(w.id), E = t.active && t.dim && !k, m = h(c(w)), p = e.nodeImageProperty ? to(tt(w, e.nodeImageProperty)) : null;
851
+ const k = t.nodeIds.has(w.id), E = t.active && t.dim && !k, m = h(c(w)), p = e.nodeImageProperty ? oo(tt(w, e.nodeImageProperty)) : null;
840
852
  b[w.id] = {
841
- color: E ? Qa : dn(s, w, Mt(w.label)),
842
- size: k ? Math.max(m, Ka) : m,
853
+ color: E ? no : fn(s, w, Bt(w.label)),
854
+ size: k ? Math.max(m, eo) : m,
843
855
  // A dimmed image would still pop against the dim palette — suppress it (FR-9).
844
856
  image: E ? null : p,
845
857
  zIndex: k ? 2 : 1,
@@ -848,18 +860,18 @@ function ao(n, r, t, e) {
848
860
  }
849
861
  const R = {};
850
862
  for (const w of a) {
851
- const k = t.edgeIds.has(w.id), E = t.active && t.dim && !k, m = y(v(w)), p = vi(w), C = p ? Mt(p) : eo;
863
+ const k = t.edgeIds.has(w.id), E = t.active && t.dim && !k, m = y(v(w)), p = mi(w), C = p ? Bt(p) : ao;
852
864
  R[w.id] = {
853
- color: k ? Za : E ? Ja : dn(u, w, C),
854
- width: k ? Math.max(m, Ya) : m,
865
+ color: k ? ro : E ? io : fn(u, w, C),
866
+ width: k ? Math.max(m, to) : m,
855
867
  zIndex: k ? 2 : 0,
856
868
  dimmed: E
857
869
  };
858
870
  }
859
871
  return { nodes: b, edges: R, magnitudes: o };
860
872
  }
861
- const oo = 12;
862
- function _c(n, r) {
873
+ const ho = 12;
874
+ function Cc(n, r) {
863
875
  const t = Object.values(n), e = Ar(t, r.nodeColorMode, r.nodeColorProperty);
864
876
  if (e.kind === "gradient")
865
877
  return { kind: "gradient", title: e.property, min: e.min, max: e.max };
@@ -868,20 +880,20 @@ function _c(n, r) {
868
880
  let s, u;
869
881
  if (e.kind === "categorical") {
870
882
  const c = tt(o, e.property);
871
- s = c === void 0 || c === "" ? "(missing)" : String(c), u = c === void 0 || c === "" ? Tt : mi(c);
883
+ s = c === void 0 || c === "" ? "(missing)" : String(c), u = c === void 0 || c === "" ? Tt : yi(c);
872
884
  } else
873
- s = o.label ?? "(unlabeled)", u = Mt(o.label);
885
+ s = o.label ?? "(unlabeled)", u = Bt(o.label);
874
886
  const l = i.get(s);
875
887
  l ? l.count++ : i.set(s, { color: u, count: 1 });
876
888
  }
877
- const a = [...i.entries()].map(([o, { color: s, count: u }]) => ({ key: o, color: s, count: u })).sort((o, s) => s.count - o.count).slice(0, oo);
889
+ const a = [...i.entries()].map(([o, { color: s, count: u }]) => ({ key: o, color: s, count: u })).sort((o, s) => s.count - o.count).slice(0, ho);
878
890
  return {
879
891
  kind: "categorical",
880
892
  title: e.kind === "categorical" ? e.property : "labels",
881
893
  entries: a
882
894
  };
883
895
  }
884
- function Tc(n) {
896
+ function xc(n) {
885
897
  const r = /* @__PURE__ */ new Set();
886
898
  for (const t of n)
887
899
  for (const e of Object.keys(t.props ?? {})) r.add(e);
@@ -890,10 +902,10 @@ function Tc(n) {
890
902
  function Br(n) {
891
903
  return n && n.__esModule && Object.prototype.hasOwnProperty.call(n, "default") ? n.default : n;
892
904
  }
893
- var Pt = { exports: {} }, vn;
894
- function so() {
895
- if (vn) return Pt.exports;
896
- vn = 1;
905
+ var It = { exports: {} }, mn;
906
+ function fo() {
907
+ if (mn) return It.exports;
908
+ mn = 1;
897
909
  var n = typeof Reflect == "object" ? Reflect : null, r = n && typeof n.apply == "function" ? n.apply : function(C, L, g) {
898
910
  return Function.prototype.apply.call(C, L, g);
899
911
  }, t;
@@ -911,7 +923,7 @@ function so() {
911
923
  function a() {
912
924
  a.init.call(this);
913
925
  }
914
- Pt.exports = a, Pt.exports.once = k, a.EventEmitter = a, a.prototype._events = void 0, a.prototype._eventsCount = 0, a.prototype._maxListeners = void 0;
926
+ It.exports = a, It.exports.once = k, a.EventEmitter = a, a.prototype._events = void 0, a.prototype._eventsCount = 0, a.prototype._maxListeners = void 0;
915
927
  var o = 10;
916
928
  function s(p) {
917
929
  if (typeof p != "function")
@@ -953,13 +965,13 @@ function so() {
953
965
  var O = new Error("Unhandled error." + (D ? " (" + D.message + ")" : ""));
954
966
  throw O.context = D, O;
955
967
  }
956
- var I = S[C];
957
- if (I === void 0)
968
+ var P = S[C];
969
+ if (P === void 0)
958
970
  return !1;
959
- if (typeof I == "function")
960
- r(I, this, L);
971
+ if (typeof P == "function")
972
+ r(P, this, L);
961
973
  else
962
- for (var _ = I.length, W = b(I, _), g = 0; g < _; ++g)
974
+ for (var _ = P.length, W = b(P, _), g = 0; g < _; ++g)
963
975
  r(W[g], this, L);
964
976
  return !0;
965
977
  };
@@ -1100,17 +1112,17 @@ function so() {
1100
1112
  else
1101
1113
  throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof p);
1102
1114
  }
1103
- return Pt.exports;
1115
+ return It.exports;
1104
1116
  }
1105
- var Wr = so();
1106
- function uo() {
1117
+ var Wr = fo();
1118
+ function go() {
1107
1119
  const n = arguments[0];
1108
1120
  for (let r = 1, t = arguments.length; r < t; r++)
1109
1121
  if (arguments[r])
1110
1122
  for (const e in arguments[r]) n[e] = arguments[r][e];
1111
1123
  return n;
1112
1124
  }
1113
- let ue = uo;
1125
+ let ue = go;
1114
1126
  typeof Object.assign == "function" && (ue = Object.assign);
1115
1127
  function _e(n, r, t, e) {
1116
1128
  const i = n._nodes.get(r);
@@ -1120,7 +1132,7 @@ function _e(n, r, t, e) {
1120
1132
  function he(n) {
1121
1133
  return typeof n == "object" && n !== null;
1122
1134
  }
1123
- function yi(n) {
1135
+ function bi(n) {
1124
1136
  let r;
1125
1137
  for (r in n) return !1;
1126
1138
  return !0;
@@ -1140,10 +1152,10 @@ function Ae(n, r, t) {
1140
1152
  };
1141
1153
  typeof t == "function" ? e.get = t : (e.value = t, e.writable = !1), Object.defineProperty(n, r, e);
1142
1154
  }
1143
- function mn(n) {
1155
+ function yn(n) {
1144
1156
  return !(!he(n) || n.attributes && !Array.isArray(n.attributes));
1145
1157
  }
1146
- function lo() {
1158
+ function po() {
1147
1159
  let n = Math.floor(Math.random() * 256) & 255;
1148
1160
  return () => n++;
1149
1161
  }
@@ -1204,22 +1216,22 @@ class Q extends Hr {
1204
1216
  super(r), this.name = "UsageGraphError", typeof Error.captureStackTrace == "function" && Error.captureStackTrace(this, Q.prototype.constructor);
1205
1217
  }
1206
1218
  }
1207
- function bi(n, r) {
1219
+ function wi(n, r) {
1208
1220
  this.key = n, this.attributes = r, this.clear();
1209
1221
  }
1210
- bi.prototype.clear = function() {
1222
+ wi.prototype.clear = function() {
1211
1223
  this.inDegree = 0, this.outDegree = 0, this.undirectedDegree = 0, this.undirectedLoops = 0, this.directedLoops = 0, this.in = {}, this.out = {}, this.undirected = {};
1212
1224
  };
1213
- function wi(n, r) {
1225
+ function Ei(n, r) {
1214
1226
  this.key = n, this.attributes = r, this.clear();
1215
1227
  }
1216
- wi.prototype.clear = function() {
1228
+ Ei.prototype.clear = function() {
1217
1229
  this.inDegree = 0, this.outDegree = 0, this.directedLoops = 0, this.in = {}, this.out = {};
1218
1230
  };
1219
- function Ei(n, r) {
1231
+ function _i(n, r) {
1220
1232
  this.key = n, this.attributes = r, this.clear();
1221
1233
  }
1222
- Ei.prototype.clear = function() {
1234
+ _i.prototype.clear = function() {
1223
1235
  this.undirectedDegree = 0, this.undirectedLoops = 0, this.undirected = {};
1224
1236
  };
1225
1237
  function ut(n, r, t, e, i) {
@@ -1252,16 +1264,16 @@ ut.prototype.detachMulti = function() {
1252
1264
  let t = "out", e = "in";
1253
1265
  this.undirected && (t = e = "undirected"), this.previous === void 0 ? this.next === void 0 ? (delete this.source[t][r], delete this.target[e][n]) : (this.next.previous = void 0, this.source[t][r] = this.next, this.target[e][n] = this.next) : (this.previous.next = this.next, this.next !== void 0 && (this.next.previous = this.previous));
1254
1266
  };
1255
- const _i = 0, Ti = 1, co = 2, Si = 3;
1267
+ const Ti = 0, Si = 1, vo = 2, Ri = 3;
1256
1268
  function Ne(n, r, t, e, i, a, o) {
1257
1269
  let s, u, l, c;
1258
- if (e = "" + e, t === _i) {
1270
+ if (e = "" + e, t === Ti) {
1259
1271
  if (s = n._nodes.get(e), !s)
1260
1272
  throw new M(
1261
1273
  `Graph.${r}: could not find the "${e}" node in the graph.`
1262
1274
  );
1263
1275
  l = i, c = a;
1264
- } else if (t === Si) {
1276
+ } else if (t === Ri) {
1265
1277
  if (i = "" + i, u = n._edges.get(i), !u)
1266
1278
  throw new M(
1267
1279
  `Graph.${r}: could not find the "${i}" edge in the graph.`
@@ -1281,11 +1293,11 @@ function Ne(n, r, t, e, i, a, o) {
1281
1293
  throw new M(
1282
1294
  `Graph.${r}: could not find the "${e}" edge in the graph.`
1283
1295
  );
1284
- t === Ti ? s = u.source : s = u.target, l = i, c = a;
1296
+ t === Si ? s = u.source : s = u.target, l = i, c = a;
1285
1297
  }
1286
1298
  return [s, l, c];
1287
1299
  }
1288
- function ho(n, r, t) {
1300
+ function mo(n, r, t) {
1289
1301
  n.prototype[r] = function(e, i, a) {
1290
1302
  const [o, s] = Ne(
1291
1303
  this,
@@ -1298,7 +1310,7 @@ function ho(n, r, t) {
1298
1310
  return o.attributes[s];
1299
1311
  };
1300
1312
  }
1301
- function fo(n, r, t) {
1313
+ function yo(n, r, t) {
1302
1314
  n.prototype[r] = function(e, i) {
1303
1315
  const [a] = Ne(
1304
1316
  this,
@@ -1310,7 +1322,7 @@ function fo(n, r, t) {
1310
1322
  return a.attributes;
1311
1323
  };
1312
1324
  }
1313
- function go(n, r, t) {
1325
+ function bo(n, r, t) {
1314
1326
  n.prototype[r] = function(e, i, a) {
1315
1327
  const [o, s] = Ne(
1316
1328
  this,
@@ -1323,7 +1335,7 @@ function go(n, r, t) {
1323
1335
  return o.attributes.hasOwnProperty(s);
1324
1336
  };
1325
1337
  }
1326
- function po(n, r, t) {
1338
+ function wo(n, r, t) {
1327
1339
  n.prototype[r] = function(e, i, a, o) {
1328
1340
  const [s, u, l] = Ne(
1329
1341
  this,
@@ -1342,7 +1354,7 @@ function po(n, r, t) {
1342
1354
  }), this;
1343
1355
  };
1344
1356
  }
1345
- function vo(n, r, t) {
1357
+ function Eo(n, r, t) {
1346
1358
  n.prototype[r] = function(e, i, a, o) {
1347
1359
  const [s, u, l] = Ne(
1348
1360
  this,
@@ -1366,7 +1378,7 @@ function vo(n, r, t) {
1366
1378
  }), this;
1367
1379
  };
1368
1380
  }
1369
- function mo(n, r, t) {
1381
+ function _o(n, r, t) {
1370
1382
  n.prototype[r] = function(e, i, a) {
1371
1383
  const [o, s] = Ne(
1372
1384
  this,
@@ -1384,7 +1396,7 @@ function mo(n, r, t) {
1384
1396
  }), this;
1385
1397
  };
1386
1398
  }
1387
- function yo(n, r, t) {
1399
+ function To(n, r, t) {
1388
1400
  n.prototype[r] = function(e, i, a) {
1389
1401
  const [o, s] = Ne(
1390
1402
  this,
@@ -1405,7 +1417,7 @@ function yo(n, r, t) {
1405
1417
  }), this;
1406
1418
  };
1407
1419
  }
1408
- function bo(n, r, t) {
1420
+ function So(n, r, t) {
1409
1421
  n.prototype[r] = function(e, i, a) {
1410
1422
  const [o, s] = Ne(
1411
1423
  this,
@@ -1427,7 +1439,7 @@ function bo(n, r, t) {
1427
1439
  }), this;
1428
1440
  };
1429
1441
  }
1430
- function wo(n, r, t) {
1442
+ function Ro(n, r, t) {
1431
1443
  n.prototype[r] = function(e, i, a) {
1432
1444
  const [o, s] = Ne(
1433
1445
  this,
@@ -1448,50 +1460,50 @@ function wo(n, r, t) {
1448
1460
  }), this;
1449
1461
  };
1450
1462
  }
1451
- const Eo = [
1463
+ const Ao = [
1452
1464
  {
1453
1465
  name: (n) => `get${n}Attribute`,
1454
- attacher: ho
1466
+ attacher: mo
1455
1467
  },
1456
1468
  {
1457
1469
  name: (n) => `get${n}Attributes`,
1458
- attacher: fo
1470
+ attacher: yo
1459
1471
  },
1460
1472
  {
1461
1473
  name: (n) => `has${n}Attribute`,
1462
- attacher: go
1474
+ attacher: bo
1463
1475
  },
1464
1476
  {
1465
1477
  name: (n) => `set${n}Attribute`,
1466
- attacher: po
1478
+ attacher: wo
1467
1479
  },
1468
1480
  {
1469
1481
  name: (n) => `update${n}Attribute`,
1470
- attacher: vo
1482
+ attacher: Eo
1471
1483
  },
1472
1484
  {
1473
1485
  name: (n) => `remove${n}Attribute`,
1474
- attacher: mo
1486
+ attacher: _o
1475
1487
  },
1476
1488
  {
1477
1489
  name: (n) => `replace${n}Attributes`,
1478
- attacher: yo
1490
+ attacher: To
1479
1491
  },
1480
1492
  {
1481
1493
  name: (n) => `merge${n}Attributes`,
1482
- attacher: bo
1494
+ attacher: So
1483
1495
  },
1484
1496
  {
1485
1497
  name: (n) => `update${n}Attributes`,
1486
- attacher: wo
1498
+ attacher: Ro
1487
1499
  }
1488
1500
  ];
1489
- function _o(n) {
1490
- Eo.forEach(function({ name: r, attacher: t }) {
1491
- t(n, r("Node"), _i), t(n, r("Source"), Ti), t(n, r("Target"), co), t(n, r("Opposite"), Si);
1501
+ function ko(n) {
1502
+ Ao.forEach(function({ name: r, attacher: t }) {
1503
+ t(n, r("Node"), Ti), t(n, r("Source"), Si), t(n, r("Target"), vo), t(n, r("Opposite"), Ri);
1492
1504
  });
1493
1505
  }
1494
- function To(n, r, t) {
1506
+ function Co(n, r, t) {
1495
1507
  n.prototype[r] = function(e, i) {
1496
1508
  let a;
1497
1509
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1521,7 +1533,7 @@ function To(n, r, t) {
1521
1533
  return a.attributes[i];
1522
1534
  };
1523
1535
  }
1524
- function So(n, r, t) {
1536
+ function xo(n, r, t) {
1525
1537
  n.prototype[r] = function(e) {
1526
1538
  let i;
1527
1539
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1551,7 +1563,7 @@ function So(n, r, t) {
1551
1563
  return i.attributes;
1552
1564
  };
1553
1565
  }
1554
- function Ro(n, r, t) {
1566
+ function Do(n, r, t) {
1555
1567
  n.prototype[r] = function(e, i) {
1556
1568
  let a;
1557
1569
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1581,7 +1593,7 @@ function Ro(n, r, t) {
1581
1593
  return a.attributes.hasOwnProperty(i);
1582
1594
  };
1583
1595
  }
1584
- function Ao(n, r, t) {
1596
+ function Lo(n, r, t) {
1585
1597
  n.prototype[r] = function(e, i, a) {
1586
1598
  let o;
1587
1599
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1616,7 +1628,7 @@ function Ao(n, r, t) {
1616
1628
  }), this;
1617
1629
  };
1618
1630
  }
1619
- function ko(n, r, t) {
1631
+ function Go(n, r, t) {
1620
1632
  n.prototype[r] = function(e, i, a) {
1621
1633
  let o;
1622
1634
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1655,7 +1667,7 @@ function ko(n, r, t) {
1655
1667
  }), this;
1656
1668
  };
1657
1669
  }
1658
- function Co(n, r, t) {
1670
+ function Io(n, r, t) {
1659
1671
  n.prototype[r] = function(e, i) {
1660
1672
  let a;
1661
1673
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1690,7 +1702,7 @@ function Co(n, r, t) {
1690
1702
  }), this;
1691
1703
  };
1692
1704
  }
1693
- function xo(n, r, t) {
1705
+ function Po(n, r, t) {
1694
1706
  n.prototype[r] = function(e, i) {
1695
1707
  let a;
1696
1708
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1728,7 +1740,7 @@ function xo(n, r, t) {
1728
1740
  }), this;
1729
1741
  };
1730
1742
  }
1731
- function Do(n, r, t) {
1743
+ function Fo(n, r, t) {
1732
1744
  n.prototype[r] = function(e, i) {
1733
1745
  let a;
1734
1746
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1767,7 +1779,7 @@ function Do(n, r, t) {
1767
1779
  }), this;
1768
1780
  };
1769
1781
  }
1770
- function Lo(n, r, t) {
1782
+ function Oo(n, r, t) {
1771
1783
  n.prototype[r] = function(e, i) {
1772
1784
  let a;
1773
1785
  if (this.type !== "mixed" && t !== "mixed" && t !== this.type)
@@ -1805,50 +1817,50 @@ function Lo(n, r, t) {
1805
1817
  }), this;
1806
1818
  };
1807
1819
  }
1808
- const Go = [
1820
+ const zo = [
1809
1821
  {
1810
1822
  name: (n) => `get${n}Attribute`,
1811
- attacher: To
1823
+ attacher: Co
1812
1824
  },
1813
1825
  {
1814
1826
  name: (n) => `get${n}Attributes`,
1815
- attacher: So
1827
+ attacher: xo
1816
1828
  },
1817
1829
  {
1818
1830
  name: (n) => `has${n}Attribute`,
1819
- attacher: Ro
1831
+ attacher: Do
1820
1832
  },
1821
1833
  {
1822
1834
  name: (n) => `set${n}Attribute`,
1823
- attacher: Ao
1835
+ attacher: Lo
1824
1836
  },
1825
1837
  {
1826
1838
  name: (n) => `update${n}Attribute`,
1827
- attacher: ko
1839
+ attacher: Go
1828
1840
  },
1829
1841
  {
1830
1842
  name: (n) => `remove${n}Attribute`,
1831
- attacher: Co
1843
+ attacher: Io
1832
1844
  },
1833
1845
  {
1834
1846
  name: (n) => `replace${n}Attributes`,
1835
- attacher: xo
1847
+ attacher: Po
1836
1848
  },
1837
1849
  {
1838
1850
  name: (n) => `merge${n}Attributes`,
1839
- attacher: Do
1851
+ attacher: Fo
1840
1852
  },
1841
1853
  {
1842
1854
  name: (n) => `update${n}Attributes`,
1843
- attacher: Lo
1855
+ attacher: Oo
1844
1856
  }
1845
1857
  ];
1846
- function Po(n) {
1847
- Go.forEach(function({ name: r, attacher: t }) {
1858
+ function No(n) {
1859
+ zo.forEach(function({ name: r, attacher: t }) {
1848
1860
  t(n, r("Edge"), "mixed"), t(n, r("DirectedEdge"), "directed"), t(n, r("UndirectedEdge"), "undirected");
1849
1861
  });
1850
1862
  }
1851
- const Io = [
1863
+ const Uo = [
1852
1864
  {
1853
1865
  name: "edges",
1854
1866
  type: "mixed"
@@ -1882,7 +1894,7 @@ const Io = [
1882
1894
  type: "undirected"
1883
1895
  }
1884
1896
  ];
1885
- function Fo(n, r, t, e) {
1897
+ function $o(n, r, t, e) {
1886
1898
  let i = !1;
1887
1899
  for (const a in r) {
1888
1900
  if (a === e) continue;
@@ -1898,7 +1910,7 @@ function Fo(n, r, t, e) {
1898
1910
  ), n && i) return o.key;
1899
1911
  }
1900
1912
  }
1901
- function Oo(n, r, t, e) {
1913
+ function Mo(n, r, t, e) {
1902
1914
  let i, a, o, s = !1;
1903
1915
  for (const u in r)
1904
1916
  if (u !== e) {
@@ -1953,7 +1965,7 @@ function Zt(n, r) {
1953
1965
  }
1954
1966
  };
1955
1967
  }
1956
- function zo(n, r, t, e) {
1968
+ function Bo(n, r, t, e) {
1957
1969
  const i = r[t];
1958
1970
  if (!i) return;
1959
1971
  const a = i.source, o = i.target;
@@ -1968,7 +1980,7 @@ function zo(n, r, t, e) {
1968
1980
  ) && n)
1969
1981
  return i.key;
1970
1982
  }
1971
- function No(n, r, t, e) {
1983
+ function Wo(n, r, t, e) {
1972
1984
  let i = r[t];
1973
1985
  if (!i) return;
1974
1986
  let a = !1;
@@ -2030,7 +2042,7 @@ function Qt(n, r) {
2030
2042
  }
2031
2043
  };
2032
2044
  }
2033
- function Uo(n, r) {
2045
+ function Ho(n, r) {
2034
2046
  if (n.size === 0) return [];
2035
2047
  if (r === "mixed" || r === n.type)
2036
2048
  return Array.from(n._edges.keys());
@@ -2040,7 +2052,7 @@ function Uo(n, r) {
2040
2052
  u = s.value, u.undirected === i && (e[o++] = u.key);
2041
2053
  return e;
2042
2054
  }
2043
- function Ri(n, r, t, e) {
2055
+ function Ai(n, r, t, e) {
2044
2056
  if (r.size === 0) return;
2045
2057
  const i = t !== "mixed" && t !== r.type, a = t === "undirected";
2046
2058
  let o, s, u = !1;
@@ -2059,7 +2071,7 @@ function Ri(n, r, t, e) {
2059
2071
  ), n && u) return c;
2060
2072
  }
2061
2073
  }
2062
- function $o(n, r) {
2074
+ function jo(n, r) {
2063
2075
  if (n.size === 0) return st();
2064
2076
  const t = r !== "mixed" && r !== n.type, e = r === "undirected", i = n._edges.values();
2065
2077
  return {
@@ -2086,7 +2098,7 @@ function $o(n, r) {
2086
2098
  };
2087
2099
  }
2088
2100
  function jr(n, r, t, e, i, a) {
2089
- const o = r ? Oo : Fo;
2101
+ const o = r ? Mo : $o;
2090
2102
  let s;
2091
2103
  if (t !== "undirected" && (e !== "out" && (s = o(n, i.in, a), n && s) || e !== "in" && (s = o(
2092
2104
  n,
@@ -2096,13 +2108,13 @@ function jr(n, r, t, e, i, a) {
2096
2108
  ), n && s)) || t !== "directed" && (s = o(n, i.undirected, a), n && s))
2097
2109
  return s;
2098
2110
  }
2099
- function Mo(n, r, t, e) {
2111
+ function Vo(n, r, t, e) {
2100
2112
  const i = [];
2101
2113
  return jr(!1, n, r, t, e, function(a) {
2102
2114
  i.push(a);
2103
2115
  }), i;
2104
2116
  }
2105
- function Bo(n, r, t) {
2117
+ function qo(n, r, t) {
2106
2118
  let e = st();
2107
2119
  return n !== "undirected" && (r !== "out" && typeof t.in < "u" && (e = ze(e, Zt(t.in))), r !== "in" && typeof t.out < "u" && (e = ze(
2108
2120
  e,
@@ -2110,12 +2122,12 @@ function Bo(n, r, t) {
2110
2122
  ))), n !== "directed" && typeof t.undirected < "u" && (e = ze(e, Zt(t.undirected))), e;
2111
2123
  }
2112
2124
  function Vr(n, r, t, e, i, a, o) {
2113
- const s = t ? No : zo;
2125
+ const s = t ? Wo : Bo;
2114
2126
  let u;
2115
2127
  if (r !== "undirected" && (typeof i.in < "u" && e !== "out" && (u = s(n, i.in, a, o), n && u) || typeof i.out < "u" && e !== "in" && (e || i.key !== a) && (u = s(n, i.out, a, o), n && u)) || r !== "directed" && typeof i.undirected < "u" && (u = s(n, i.undirected, a, o), n && u))
2116
2128
  return u;
2117
2129
  }
2118
- function Wo(n, r, t, e, i) {
2130
+ function Ko(n, r, t, e, i) {
2119
2131
  const a = [];
2120
2132
  return Vr(
2121
2133
  !1,
@@ -2129,19 +2141,19 @@ function Wo(n, r, t, e, i) {
2129
2141
  }
2130
2142
  ), a;
2131
2143
  }
2132
- function Ho(n, r, t, e) {
2144
+ function Xo(n, r, t, e) {
2133
2145
  let i = st();
2134
2146
  return n !== "undirected" && (typeof t.in < "u" && r !== "out" && e in t.in && (i = ze(i, Qt(t.in, e))), typeof t.out < "u" && r !== "in" && e in t.out && (r || t.key !== e) && (i = ze(i, Qt(t.out, e)))), n !== "directed" && typeof t.undirected < "u" && e in t.undirected && (i = ze(
2135
2147
  i,
2136
2148
  Qt(t.undirected, e)
2137
2149
  )), i;
2138
2150
  }
2139
- function jo(n, r) {
2151
+ function Yo(n, r) {
2140
2152
  const { name: t, type: e, direction: i } = r;
2141
2153
  n.prototype[t] = function(a, o) {
2142
2154
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type)
2143
2155
  return [];
2144
- if (!arguments.length) return Uo(this, e);
2156
+ if (!arguments.length) return Ho(this, e);
2145
2157
  if (arguments.length === 1) {
2146
2158
  a = "" + a;
2147
2159
  const s = this._nodes.get(a);
@@ -2149,7 +2161,7 @@ function jo(n, r) {
2149
2161
  throw new M(
2150
2162
  `Graph.${t}: could not find the "${a}" node in the graph.`
2151
2163
  );
2152
- return Mo(
2164
+ return Vo(
2153
2165
  this.multi,
2154
2166
  e === "mixed" ? this.type : e,
2155
2167
  i,
@@ -2167,7 +2179,7 @@ function jo(n, r) {
2167
2179
  throw new M(
2168
2180
  `Graph.${t}: could not find the "${o}" target node in the graph.`
2169
2181
  );
2170
- return Wo(
2182
+ return Ko(
2171
2183
  e,
2172
2184
  this.multi,
2173
2185
  i,
@@ -2180,12 +2192,12 @@ function jo(n, r) {
2180
2192
  );
2181
2193
  };
2182
2194
  }
2183
- function Vo(n, r) {
2195
+ function Zo(n, r) {
2184
2196
  const { name: t, type: e, direction: i } = r, a = "forEach" + t[0].toUpperCase() + t.slice(1, -1);
2185
2197
  n.prototype[a] = function(l, c, h) {
2186
2198
  if (!(e !== "mixed" && this.type !== "mixed" && e !== this.type)) {
2187
2199
  if (arguments.length === 1)
2188
- return h = l, Ri(!1, this, e, h);
2200
+ return h = l, Ai(!1, this, e, h);
2189
2201
  if (arguments.length === 2) {
2190
2202
  l = "" + l, h = c;
2191
2203
  const v = this._nodes.get(l);
@@ -2271,13 +2283,13 @@ function Vo(n, r) {
2271
2283
  }), this[a].apply(this, l), v;
2272
2284
  };
2273
2285
  }
2274
- function qo(n, r) {
2286
+ function Qo(n, r) {
2275
2287
  const { name: t, type: e, direction: i } = r, a = "find" + t[0].toUpperCase() + t.slice(1, -1);
2276
2288
  n.prototype[a] = function(u, l, c) {
2277
2289
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type)
2278
2290
  return !1;
2279
2291
  if (arguments.length === 1)
2280
- return c = u, Ri(!0, this, e, c);
2292
+ return c = u, Ai(!0, this, e, c);
2281
2293
  if (arguments.length === 2) {
2282
2294
  u = "" + u, c = l;
2283
2295
  const h = this._nodes.get(u);
@@ -2330,12 +2342,12 @@ function qo(n, r) {
2330
2342
  return u.push((h, v, y, b, R, w, k) => !l(h, v, y, b, R, w, k)), !this[a].apply(this, u);
2331
2343
  };
2332
2344
  }
2333
- function Xo(n, r) {
2345
+ function Jo(n, r) {
2334
2346
  const { name: t, type: e, direction: i } = r, a = t.slice(0, -1) + "Entries";
2335
2347
  n.prototype[a] = function(o, s) {
2336
2348
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type)
2337
2349
  return st();
2338
- if (!arguments.length) return $o(this, e);
2350
+ if (!arguments.length) return jo(this, e);
2339
2351
  if (arguments.length === 1) {
2340
2352
  o = "" + o;
2341
2353
  const u = this._nodes.get(o);
@@ -2343,7 +2355,7 @@ function Xo(n, r) {
2343
2355
  throw new M(
2344
2356
  `Graph.${a}: could not find the "${o}" node in the graph.`
2345
2357
  );
2346
- return Bo(e, i, u);
2358
+ return qo(e, i, u);
2347
2359
  }
2348
2360
  if (arguments.length === 2) {
2349
2361
  o = "" + o, s = "" + s;
@@ -2356,19 +2368,19 @@ function Xo(n, r) {
2356
2368
  throw new M(
2357
2369
  `Graph.${a}: could not find the "${s}" target node in the graph.`
2358
2370
  );
2359
- return Ho(e, i, u, s);
2371
+ return Xo(e, i, u, s);
2360
2372
  }
2361
2373
  throw new H(
2362
2374
  `Graph.${a}: too many arguments (expecting 0, 1 or 2 and got ${arguments.length}).`
2363
2375
  );
2364
2376
  };
2365
2377
  }
2366
- function Ko(n) {
2367
- Io.forEach((r) => {
2368
- jo(n, r), Vo(n, r), qo(n, r), Xo(n, r);
2378
+ function es(n) {
2379
+ Uo.forEach((r) => {
2380
+ Yo(n, r), Zo(n, r), Qo(n, r), Jo(n, r);
2369
2381
  });
2370
2382
  }
2371
- const Yo = [
2383
+ const ts = [
2372
2384
  {
2373
2385
  name: "neighbors",
2374
2386
  type: "mixed"
@@ -2402,13 +2414,13 @@ const Yo = [
2402
2414
  type: "undirected"
2403
2415
  }
2404
2416
  ];
2405
- function Wt() {
2417
+ function Ht() {
2406
2418
  this.A = null, this.B = null;
2407
2419
  }
2408
- Wt.prototype.wrap = function(n) {
2420
+ Ht.prototype.wrap = function(n) {
2409
2421
  this.A === null ? this.A = n : this.B === null && (this.B = n);
2410
2422
  };
2411
- Wt.prototype.has = function(n) {
2423
+ Ht.prototype.has = function(n) {
2412
2424
  return this.A !== null && n in this.A || this.B !== null && n in this.B;
2413
2425
  };
2414
2426
  function ht(n, r, t, e, i) {
@@ -2438,7 +2450,7 @@ function qr(n, r, t, e, i) {
2438
2450
  i
2439
2451
  );
2440
2452
  }
2441
- const a = new Wt();
2453
+ const a = new Ht();
2442
2454
  let o;
2443
2455
  if (r !== "undirected") {
2444
2456
  if (t !== "out") {
@@ -2471,7 +2483,7 @@ function qr(n, r, t, e, i) {
2471
2483
  ), n && o))
2472
2484
  return o;
2473
2485
  }
2474
- function Zo(n, r, t) {
2486
+ function rs(n, r, t) {
2475
2487
  if (n !== "mixed") {
2476
2488
  if (n === "undirected") return Object.keys(t.undirected);
2477
2489
  if (typeof r == "string") return Object.keys(t[r]);
@@ -2506,7 +2518,7 @@ function dt(n, r, t) {
2506
2518
  }
2507
2519
  };
2508
2520
  }
2509
- function Qo(n, r, t) {
2521
+ function ns(n, r, t) {
2510
2522
  if (n !== "mixed") {
2511
2523
  if (n === "undirected")
2512
2524
  return dt(null, t, t.undirected);
@@ -2514,7 +2526,7 @@ function Qo(n, r, t) {
2514
2526
  return dt(null, t, t[r]);
2515
2527
  }
2516
2528
  let e = st();
2517
- const i = new Wt();
2529
+ const i = new Ht();
2518
2530
  return n !== "undirected" && (r !== "out" && (e = ze(
2519
2531
  e,
2520
2532
  dt(i, t, t.in)
@@ -2526,7 +2538,7 @@ function Qo(n, r, t) {
2526
2538
  dt(i, t, t.undirected)
2527
2539
  )), e;
2528
2540
  }
2529
- function Jo(n, r) {
2541
+ function is(n, r) {
2530
2542
  const { name: t, type: e, direction: i } = r;
2531
2543
  n.prototype[t] = function(a) {
2532
2544
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type)
@@ -2537,14 +2549,14 @@ function Jo(n, r) {
2537
2549
  throw new M(
2538
2550
  `Graph.${t}: could not find the "${a}" node in the graph.`
2539
2551
  );
2540
- return Zo(
2552
+ return rs(
2541
2553
  e === "mixed" ? this.type : e,
2542
2554
  i,
2543
2555
  o
2544
2556
  );
2545
2557
  };
2546
2558
  }
2547
- function es(n, r) {
2559
+ function as(n, r) {
2548
2560
  const { name: t, type: e, direction: i } = r, a = "forEach" + t[0].toUpperCase() + t.slice(1, -1);
2549
2561
  n.prototype[a] = function(l, c) {
2550
2562
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type) return;
@@ -2588,7 +2600,7 @@ function es(n, r) {
2588
2600
  }), v;
2589
2601
  };
2590
2602
  }
2591
- function ts(n, r) {
2603
+ function os(n, r) {
2592
2604
  const { name: t, type: e, direction: i } = r, a = t[0].toUpperCase() + t.slice(1, -1), o = "find" + a;
2593
2605
  n.prototype[o] = function(l, c) {
2594
2606
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type) return;
@@ -2615,7 +2627,7 @@ function ts(n, r) {
2615
2627
  return !this[o](l, (v, y) => !c(v, y));
2616
2628
  };
2617
2629
  }
2618
- function rs(n, r) {
2630
+ function ss(n, r) {
2619
2631
  const { name: t, type: e, direction: i } = r, a = t.slice(0, -1) + "Entries";
2620
2632
  n.prototype[a] = function(o) {
2621
2633
  if (e !== "mixed" && this.type !== "mixed" && e !== this.type)
@@ -2626,19 +2638,19 @@ function rs(n, r) {
2626
2638
  throw new M(
2627
2639
  `Graph.${a}: could not find the "${o}" node in the graph.`
2628
2640
  );
2629
- return Qo(
2641
+ return ns(
2630
2642
  e === "mixed" ? this.type : e,
2631
2643
  i,
2632
2644
  s
2633
2645
  );
2634
2646
  };
2635
2647
  }
2636
- function ns(n) {
2637
- Yo.forEach((r) => {
2638
- Jo(n, r), es(n, r), ts(n, r), rs(n, r);
2648
+ function us(n) {
2649
+ ts.forEach((r) => {
2650
+ is(n, r), as(n, r), os(n, r), ss(n, r);
2639
2651
  });
2640
2652
  }
2641
- function It(n, r, t, e, i) {
2653
+ function Pt(n, r, t, e, i) {
2642
2654
  const a = e._nodes.values(), o = e.type;
2643
2655
  let s, u, l, c, h, v;
2644
2656
  for (; s = a.next(), s.done !== !0; ) {
@@ -2689,19 +2701,19 @@ function It(n, r, t, e, i) {
2689
2701
  );
2690
2702
  }
2691
2703
  }
2692
- function is(n, r) {
2704
+ function ls(n, r) {
2693
2705
  const t = { key: n };
2694
- return yi(r.attributes) || (t.attributes = ue({}, r.attributes)), t;
2706
+ return bi(r.attributes) || (t.attributes = ue({}, r.attributes)), t;
2695
2707
  }
2696
- function as(n, r, t) {
2708
+ function cs(n, r, t) {
2697
2709
  const e = {
2698
2710
  key: r,
2699
2711
  source: t.source.key,
2700
2712
  target: t.target.key
2701
2713
  };
2702
- return yi(t.attributes) || (e.attributes = ue({}, t.attributes)), n === "mixed" && t.undirected && (e.undirected = !0), e;
2714
+ return bi(t.attributes) || (e.attributes = ue({}, t.attributes)), n === "mixed" && t.undirected && (e.undirected = !0), e;
2703
2715
  }
2704
- function os(n) {
2716
+ function hs(n) {
2705
2717
  if (!he(n))
2706
2718
  throw new H(
2707
2719
  'Graph.import: invalid serialized node. A serialized node should be a plain object with at least a "key" property.'
@@ -2715,7 +2727,7 @@ function os(n) {
2715
2727
  "Graph.import: invalid attributes. Attributes should be a plain object, null or omitted."
2716
2728
  );
2717
2729
  }
2718
- function ss(n) {
2730
+ function ds(n) {
2719
2731
  if (!he(n))
2720
2732
  throw new H(
2721
2733
  'Graph.import: invalid serialized edge. A serialized edge should be a plain object with at least a "source" & "target" property.'
@@ -2737,12 +2749,12 @@ function ss(n) {
2737
2749
  "Graph.import: invalid undirectedness information. Undirected should be boolean or omitted."
2738
2750
  );
2739
2751
  }
2740
- const us = lo(), ls = /* @__PURE__ */ new Set(["directed", "undirected", "mixed"]), yn = /* @__PURE__ */ new Set([
2752
+ const fs = po(), gs = /* @__PURE__ */ new Set(["directed", "undirected", "mixed"]), bn = /* @__PURE__ */ new Set([
2741
2753
  "domain",
2742
2754
  "_events",
2743
2755
  "_eventsCount",
2744
2756
  "_maxListeners"
2745
- ]), cs = [
2757
+ ]), ps = [
2746
2758
  {
2747
2759
  name: (n) => `${n}Edge`,
2748
2760
  generateKey: !0
@@ -2768,12 +2780,12 @@ const us = lo(), ls = /* @__PURE__ */ new Set(["directed", "undirected", "mixed"
2768
2780
  name: (n) => `${n}UndirectedEdgeWithKey`,
2769
2781
  type: "undirected"
2770
2782
  }
2771
- ], hs = {
2783
+ ], vs = {
2772
2784
  allowSelfLoops: !0,
2773
2785
  multi: !1,
2774
2786
  type: "mixed"
2775
2787
  };
2776
- function ds(n, r, t) {
2788
+ function ms(n, r, t) {
2777
2789
  if (t && !he(t))
2778
2790
  throw new H(
2779
2791
  `Graph.addNode: invalid attributes. Expecting an object but got "${t}"`
@@ -2788,14 +2800,14 @@ function ds(n, r, t) {
2788
2800
  attributes: t
2789
2801
  }), e;
2790
2802
  }
2791
- function bn(n, r, t) {
2803
+ function wn(n, r, t) {
2792
2804
  const e = new n.NodeDataClass(r, t);
2793
2805
  return n._nodes.set(r, e), n.emit("nodeAdded", {
2794
2806
  key: r,
2795
2807
  attributes: t
2796
2808
  }), e;
2797
2809
  }
2798
- function Ai(n, r, t, e, i, a, o, s) {
2810
+ function ki(n, r, t, e, i, a, o, s) {
2799
2811
  if (!e && n.type === "undirected")
2800
2812
  throw new Q(
2801
2813
  `Graph.${r}: you cannot add a directed edge to an undirected graph. Use the #.addEdge or #.addUndirectedEdge instead.`
@@ -2849,7 +2861,7 @@ function Ai(n, r, t, e, i, a, o, s) {
2849
2861
  const v = a === o;
2850
2862
  return e ? (u.undirectedDegree++, l.undirectedDegree++, v && (u.undirectedLoops++, n._undirectedSelfLoopCount++)) : (u.outDegree++, l.inDegree++, v && (u.directedLoops++, n._directedSelfLoopCount++)), n.multi ? h.attachMulti() : h.attach(), e ? n._undirectedSize++ : n._directedSize++, c.key = i, n.emit("edgeAdded", c), i;
2851
2863
  }
2852
- function fs(n, r, t, e, i, a, o, s, u) {
2864
+ function ys(n, r, t, e, i, a, o, s, u) {
2853
2865
  if (!e && n.type === "undirected")
2854
2866
  throw new Q(
2855
2867
  `Graph.${r}: you cannot merge/update a directed edge to an undirected graph. Use the #.mergeEdge/#.updateEdge or #.addUndirectedEdge instead.`
@@ -2917,7 +2929,7 @@ function fs(n, r, t, e, i, a, o, s, u) {
2917
2929
  `Graph.${r}: the "${i}" edge already exists in the graph.`
2918
2930
  );
2919
2931
  let R = !1, w = !1;
2920
- c || (c = bn(n, a, {}), R = !0, a === o && (h = c, w = !0)), h || (h = bn(n, o, {}), w = !0), v = new ut(e, i, c, h, s), n._edges.set(i, v);
2932
+ c || (c = wn(n, a, {}), R = !0, a === o && (h = c, w = !0)), h || (h = wn(n, o, {}), w = !0), v = new ut(e, i, c, h, s), n._edges.set(i, v);
2921
2933
  const k = a === o;
2922
2934
  return e ? (c.undirectedDegree++, h.undirectedDegree++, k && (c.undirectedLoops++, n._undirectedSelfLoopCount++)) : (c.outDegree++, h.inDegree++, k && (c.directedLoops++, n._directedSelfLoopCount++)), n.multi ? v.attachMulti() : v.attach(), e ? n._undirectedSize++ : n._directedSize++, b.key = i, n.emit("edgeAdded", b), [i, !0, R, w];
2923
2935
  }
@@ -2934,11 +2946,11 @@ function Je(n, r) {
2934
2946
  }
2935
2947
  class ae extends Wr.EventEmitter {
2936
2948
  constructor(r) {
2937
- if (super(), r = ue({}, hs, r), typeof r.multi != "boolean")
2949
+ if (super(), r = ue({}, vs, r), typeof r.multi != "boolean")
2938
2950
  throw new H(
2939
2951
  `Graph.constructor: invalid 'multi' option. Expecting a boolean but got "${r.multi}".`
2940
2952
  );
2941
- if (!ls.has(r.type))
2953
+ if (!gs.has(r.type))
2942
2954
  throw new H(
2943
2955
  `Graph.constructor: invalid 'type' option. Should be one of "mixed", "directed" or "undirected" but got "${r.type}".`
2944
2956
  );
@@ -2946,9 +2958,9 @@ class ae extends Wr.EventEmitter {
2946
2958
  throw new H(
2947
2959
  `Graph.constructor: invalid 'allowSelfLoops' option. Expecting a boolean but got "${r.allowSelfLoops}".`
2948
2960
  );
2949
- const t = r.type === "mixed" ? bi : r.type === "directed" ? wi : Ei;
2961
+ const t = r.type === "mixed" ? wi : r.type === "directed" ? Ei : _i;
2950
2962
  Ee(this, "NodeDataClass", t);
2951
- const e = "geid_" + us() + "_";
2963
+ const e = "geid_" + fs() + "_";
2952
2964
  let i = 0;
2953
2965
  const a = () => {
2954
2966
  let o;
@@ -2957,7 +2969,7 @@ class ae extends Wr.EventEmitter {
2957
2969
  while (this._edges.has(o));
2958
2970
  return o;
2959
2971
  };
2960
- Ee(this, "_attributes", {}), Ee(this, "_nodes", /* @__PURE__ */ new Map()), Ee(this, "_edges", /* @__PURE__ */ new Map()), Ee(this, "_directedSize", 0), Ee(this, "_undirectedSize", 0), Ee(this, "_directedSelfLoopCount", 0), Ee(this, "_undirectedSelfLoopCount", 0), Ee(this, "_edgeKeyGenerator", a), Ee(this, "_options", r), yn.forEach((o) => Ee(this, o, this[o])), Ae(this, "order", () => this._nodes.size), Ae(this, "size", () => this._edges.size), Ae(this, "directedSize", () => this._directedSize), Ae(this, "undirectedSize", () => this._undirectedSize), Ae(
2972
+ Ee(this, "_attributes", {}), Ee(this, "_nodes", /* @__PURE__ */ new Map()), Ee(this, "_edges", /* @__PURE__ */ new Map()), Ee(this, "_directedSize", 0), Ee(this, "_undirectedSize", 0), Ee(this, "_directedSelfLoopCount", 0), Ee(this, "_undirectedSelfLoopCount", 0), Ee(this, "_edgeKeyGenerator", a), Ee(this, "_options", r), bn.forEach((o) => Ee(this, o, this[o])), Ae(this, "order", () => this._nodes.size), Ae(this, "size", () => this._edges.size), Ae(this, "directedSize", () => this._directedSize), Ae(this, "undirectedSize", () => this._undirectedSize), Ae(
2961
2973
  this,
2962
2974
  "selfLoopCount",
2963
2975
  () => this._directedSelfLoopCount + this._undirectedSelfLoopCount
@@ -3686,7 +3698,7 @@ class ae extends Wr.EventEmitter {
3686
3698
  * @throws {Error} - Will throw if the given attributes are not an object.
3687
3699
  */
3688
3700
  addNode(r, t) {
3689
- return ds(this, r, t).key;
3701
+ return ms(this, r, t).key;
3690
3702
  }
3691
3703
  /**
3692
3704
  * Method used to merge a node into the graph.
@@ -4029,7 +4041,7 @@ class ae extends Wr.EventEmitter {
4029
4041
  throw new H(
4030
4042
  "Graph.updateEachNodeAttributes: expecting an updater function."
4031
4043
  );
4032
- if (t && !mn(t))
4044
+ if (t && !yn(t))
4033
4045
  throw new H(
4034
4046
  "Graph.updateEachNodeAttributes: invalid hints. Expecting an object having the following shape: {attributes?: [string]}"
4035
4047
  );
@@ -4052,7 +4064,7 @@ class ae extends Wr.EventEmitter {
4052
4064
  throw new H(
4053
4065
  "Graph.updateEachEdgeAttributes: expecting an updater function."
4054
4066
  );
4055
- if (t && !mn(t))
4067
+ if (t && !yn(t))
4056
4068
  throw new H(
4057
4069
  "Graph.updateEachEdgeAttributes: invalid hints. Expecting an object having the following shape: {attributes?: [string]}"
4058
4070
  );
@@ -4086,14 +4098,14 @@ class ae extends Wr.EventEmitter {
4086
4098
  throw new H(
4087
4099
  "Graph.forEachAdjacencyEntry: expecting a callback."
4088
4100
  );
4089
- It(!1, !1, !1, this, r);
4101
+ Pt(!1, !1, !1, this, r);
4090
4102
  }
4091
4103
  forEachAdjacencyEntryWithOrphans(r) {
4092
4104
  if (typeof r != "function")
4093
4105
  throw new H(
4094
4106
  "Graph.forEachAdjacencyEntryWithOrphans: expecting a callback."
4095
4107
  );
4096
- It(!1, !1, !0, this, r);
4108
+ Pt(!1, !1, !0, this, r);
4097
4109
  }
4098
4110
  /**
4099
4111
  * Method iterating over the graph's assymetric adjacency using the given callback.
@@ -4105,14 +4117,14 @@ class ae extends Wr.EventEmitter {
4105
4117
  throw new H(
4106
4118
  "Graph.forEachAssymetricAdjacencyEntry: expecting a callback."
4107
4119
  );
4108
- It(!1, !0, !1, this, r);
4120
+ Pt(!1, !0, !1, this, r);
4109
4121
  }
4110
4122
  forEachAssymetricAdjacencyEntryWithOrphans(r) {
4111
4123
  if (typeof r != "function")
4112
4124
  throw new H(
4113
4125
  "Graph.forEachAssymetricAdjacencyEntryWithOrphans: expecting a callback."
4114
4126
  );
4115
- It(!1, !0, !0, this, r);
4127
+ Pt(!1, !0, !0, this, r);
4116
4128
  }
4117
4129
  /**
4118
4130
  * Method returning the list of the graph's nodes.
@@ -4276,11 +4288,11 @@ class ae extends Wr.EventEmitter {
4276
4288
  const r = new Array(this._nodes.size);
4277
4289
  let t = 0;
4278
4290
  this._nodes.forEach((i, a) => {
4279
- r[t++] = is(a, i);
4291
+ r[t++] = ls(a, i);
4280
4292
  });
4281
4293
  const e = new Array(this._edges.size);
4282
4294
  return t = 0, this._edges.forEach((i, a) => {
4283
- e[t++] = as(this.type, a, i);
4295
+ e[t++] = cs(this.type, a, i);
4284
4296
  }), {
4285
4297
  options: {
4286
4298
  type: this.type,
@@ -4324,7 +4336,7 @@ class ae extends Wr.EventEmitter {
4324
4336
  "Graph.import: invalid nodes. Expecting an array."
4325
4337
  );
4326
4338
  for (e = 0, i = a.length; e < i; e++) {
4327
- o = a[e], os(o);
4339
+ o = a[e], hs(o);
4328
4340
  const { key: u, attributes: l } = o;
4329
4341
  t ? this.mergeNode(u, l) : this.addNode(u, l);
4330
4342
  }
@@ -4336,7 +4348,7 @@ class ae extends Wr.EventEmitter {
4336
4348
  "Graph.import: invalid edges. Expecting an array."
4337
4349
  );
4338
4350
  for (e = 0, i = a.length; e < i; e++) {
4339
- s = a[e], ss(s);
4351
+ s = a[e], ds(s);
4340
4352
  const {
4341
4353
  source: l,
4342
4354
  target: c,
@@ -4400,7 +4412,7 @@ class ae extends Wr.EventEmitter {
4400
4412
  const t = this.emptyCopy(r), e = this._edges.values();
4401
4413
  let i, a;
4402
4414
  for (; i = e.next(), i.done !== !0; )
4403
- a = i.value, Ai(
4415
+ a = i.value, ki(
4404
4416
  t,
4405
4417
  "copy",
4406
4418
  !1,
@@ -4450,14 +4462,14 @@ class ae extends Wr.EventEmitter {
4450
4462
  });
4451
4463
  const i = {};
4452
4464
  for (const a in this)
4453
- this.hasOwnProperty(a) && !yn.has(a) && typeof this[a] != "function" && typeof a != "symbol" && (i[a] = this[a]);
4465
+ this.hasOwnProperty(a) && !bn.has(a) && typeof this[a] != "function" && typeof a != "symbol" && (i[a] = this[a]);
4454
4466
  return i.attributes = this._attributes, i.nodes = r, i.edges = t, Ee(i, "constructor", this.constructor), i;
4455
4467
  }
4456
4468
  }
4457
4469
  typeof Symbol < "u" && (ae.prototype[/* @__PURE__ */ Symbol.for("nodejs.util.inspect.custom")] = ae.prototype.inspect);
4458
- cs.forEach((n) => {
4470
+ ps.forEach((n) => {
4459
4471
  ["add", "merge", "update"].forEach((r) => {
4460
- const t = n.name(r), e = r === "add" ? Ai : fs;
4472
+ const t = n.name(r), e = r === "add" ? ki : ys;
4461
4473
  n.generateKey ? ae.prototype[t] = function(i, a, o) {
4462
4474
  return e(
4463
4475
  this,
@@ -4485,11 +4497,11 @@ cs.forEach((n) => {
4485
4497
  };
4486
4498
  });
4487
4499
  });
4488
- _o(ae);
4489
- Po(ae);
4490
- Ko(ae);
4491
- ns(ae);
4492
- class ki extends ae {
4500
+ ko(ae);
4501
+ No(ae);
4502
+ es(ae);
4503
+ us(ae);
4504
+ class Ci extends ae {
4493
4505
  constructor(r) {
4494
4506
  const t = ue({ type: "directed" }, r);
4495
4507
  if ("multi" in t && t.multi !== !1)
@@ -4503,7 +4515,7 @@ class ki extends ae {
4503
4515
  super(t);
4504
4516
  }
4505
4517
  }
4506
- class Ci extends ae {
4518
+ class xi extends ae {
4507
4519
  constructor(r) {
4508
4520
  const t = ue({ type: "undirected" }, r);
4509
4521
  if ("multi" in t && t.multi !== !1)
@@ -4517,7 +4529,7 @@ class Ci extends ae {
4517
4529
  super(t);
4518
4530
  }
4519
4531
  }
4520
- class xi extends ae {
4532
+ class Di extends ae {
4521
4533
  constructor(r) {
4522
4534
  const t = ue({ multi: !0 }, r);
4523
4535
  if ("multi" in t && t.multi !== !0)
@@ -4527,7 +4539,7 @@ class xi extends ae {
4527
4539
  super(t);
4528
4540
  }
4529
4541
  }
4530
- class Di extends ae {
4542
+ class Li extends ae {
4531
4543
  constructor(r) {
4532
4544
  const t = ue({ type: "directed", multi: !0 }, r);
4533
4545
  if ("multi" in t && t.multi !== !0)
@@ -4541,7 +4553,7 @@ class Di extends ae {
4541
4553
  super(t);
4542
4554
  }
4543
4555
  }
4544
- class Li extends ae {
4556
+ class Gi extends ae {
4545
4557
  constructor(r) {
4546
4558
  const t = ue({ type: "undirected", multi: !0 }, r);
4547
4559
  if ("multi" in t && t.multi !== !0)
@@ -4562,21 +4574,21 @@ function lt(n) {
4562
4574
  };
4563
4575
  }
4564
4576
  lt(ae);
4565
- lt(ki);
4566
4577
  lt(Ci);
4567
4578
  lt(xi);
4568
4579
  lt(Di);
4569
4580
  lt(Li);
4581
+ lt(Gi);
4570
4582
  ae.Graph = ae;
4571
- ae.DirectedGraph = ki;
4572
- ae.UndirectedGraph = Ci;
4573
- ae.MultiGraph = xi;
4574
- ae.MultiDirectedGraph = Di;
4575
- ae.MultiUndirectedGraph = Li;
4583
+ ae.DirectedGraph = Ci;
4584
+ ae.UndirectedGraph = xi;
4585
+ ae.MultiGraph = Di;
4586
+ ae.MultiDirectedGraph = Li;
4587
+ ae.MultiUndirectedGraph = Gi;
4576
4588
  ae.InvalidArgumentsGraphError = H;
4577
4589
  ae.NotFoundGraphError = M;
4578
4590
  ae.UsageGraphError = Q;
4579
- function gs(n, r) {
4591
+ function bs(n, r) {
4580
4592
  if (typeof n != "object" || !n) return n;
4581
4593
  var t = n[Symbol.toPrimitive];
4582
4594
  if (t !== void 0) {
@@ -4587,20 +4599,20 @@ function gs(n, r) {
4587
4599
  return String(n);
4588
4600
  }
4589
4601
  function Et(n) {
4590
- var r = gs(n, "string");
4602
+ var r = bs(n, "string");
4591
4603
  return typeof r == "symbol" ? r : r + "";
4592
4604
  }
4593
4605
  function ge(n, r) {
4594
4606
  if (!(n instanceof r)) throw new TypeError("Cannot call a class as a function");
4595
4607
  }
4596
- function wn(n, r) {
4608
+ function En(n, r) {
4597
4609
  for (var t = 0; t < r.length; t++) {
4598
4610
  var e = r[t];
4599
4611
  e.enumerable = e.enumerable || !1, e.configurable = !0, "value" in e && (e.writable = !0), Object.defineProperty(n, Et(e.key), e);
4600
4612
  }
4601
4613
  }
4602
4614
  function pe(n, r, t) {
4603
- return r && wn(n.prototype, r), t && wn(n, t), Object.defineProperty(n, "prototype", {
4615
+ return r && En(n.prototype, r), t && En(n, t), Object.defineProperty(n, "prototype", {
4604
4616
  writable: !1
4605
4617
  }), n;
4606
4618
  }
@@ -4609,27 +4621,27 @@ function nt(n) {
4609
4621
  return r.__proto__ || Object.getPrototypeOf(r);
4610
4622
  }, nt(n);
4611
4623
  }
4612
- function Gi() {
4624
+ function Ii() {
4613
4625
  try {
4614
4626
  var n = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
4615
4627
  }));
4616
4628
  } catch {
4617
4629
  }
4618
- return (Gi = function() {
4630
+ return (Ii = function() {
4619
4631
  return !!n;
4620
4632
  })();
4621
4633
  }
4622
- function ps(n) {
4634
+ function ws(n) {
4623
4635
  if (n === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
4624
4636
  return n;
4625
4637
  }
4626
- function vs(n, r) {
4638
+ function Es(n, r) {
4627
4639
  if (r && (typeof r == "object" || typeof r == "function")) return r;
4628
4640
  if (r !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
4629
- return ps(n);
4641
+ return ws(n);
4630
4642
  }
4631
4643
  function Te(n, r, t) {
4632
- return r = nt(r), vs(n, Gi() ? Reflect.construct(r, t || [], nt(n).constructor) : r.apply(n, t));
4644
+ return r = nt(r), Es(n, Ii() ? Reflect.construct(r, t || [], nt(n).constructor) : r.apply(n, t));
4633
4645
  }
4634
4646
  function kr(n, r) {
4635
4647
  return kr = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, e) {
@@ -4648,10 +4660,10 @@ function Se(n, r) {
4648
4660
  writable: !1
4649
4661
  }), r && kr(n, r);
4650
4662
  }
4651
- function ms(n) {
4663
+ function _s(n) {
4652
4664
  if (Array.isArray(n)) return n;
4653
4665
  }
4654
- function ys(n, r) {
4666
+ function Ts(n, r) {
4655
4667
  var t = n == null ? null : typeof Symbol < "u" && n[Symbol.iterator] || n["@@iterator"];
4656
4668
  if (t != null) {
4657
4669
  var e, i, a, o, s = [], u = !0, l = !1;
@@ -4684,12 +4696,12 @@ function Pi(n, r) {
4684
4696
  return t === "Object" && n.constructor && (t = n.constructor.name), t === "Map" || t === "Set" ? Array.from(n) : t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? Cr(n, r) : void 0;
4685
4697
  }
4686
4698
  }
4687
- function bs() {
4699
+ function Ss() {
4688
4700
  throw new TypeError(`Invalid attempt to destructure non-iterable instance.
4689
4701
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
4690
4702
  }
4691
4703
  function it(n, r) {
4692
- return ms(n) || ys(n, r) || Pi(n, r) || bs();
4704
+ return _s(n) || Ts(n, r) || Pi(n, r) || Ss();
4693
4705
  }
4694
4706
  var Jt = {
4695
4707
  black: "#000000",
@@ -4840,13 +4852,13 @@ var Jt = {
4840
4852
  snow: "#FFFAFA",
4841
4853
  lightyellow: "#FFFFE0",
4842
4854
  ivory: "#FFFFF0"
4843
- }, Ii = new Int8Array(4), er = new Int32Array(Ii.buffer, 0, 1), ws = new Float32Array(Ii.buffer, 0, 1), Es = /^\s*rgba?\s*\(/, _s = /^\s*rgba?\s*\(\s*([0-9]*)\s*,\s*([0-9]*)\s*,\s*([0-9]*)(?:\s*,\s*(.*)?)?\)\s*$/;
4844
- function Ts(n) {
4855
+ }, Fi = new Int8Array(4), er = new Int32Array(Fi.buffer, 0, 1), Rs = new Float32Array(Fi.buffer, 0, 1), As = /^\s*rgba?\s*\(/, ks = /^\s*rgba?\s*\(\s*([0-9]*)\s*,\s*([0-9]*)\s*,\s*([0-9]*)(?:\s*,\s*(.*)?)?\)\s*$/;
4856
+ function Cs(n) {
4845
4857
  var r = 0, t = 0, e = 0, i = 1;
4846
4858
  if (n[0] === "#")
4847
4859
  n.length === 4 ? (r = parseInt(n.charAt(1) + n.charAt(1), 16), t = parseInt(n.charAt(2) + n.charAt(2), 16), e = parseInt(n.charAt(3) + n.charAt(3), 16)) : (r = parseInt(n.charAt(1) + n.charAt(2), 16), t = parseInt(n.charAt(3) + n.charAt(4), 16), e = parseInt(n.charAt(5) + n.charAt(6), 16)), n.length === 9 && (i = parseInt(n.charAt(7) + n.charAt(8), 16) / 255);
4848
- else if (Es.test(n)) {
4849
- var a = n.match(_s);
4860
+ else if (As.test(n)) {
4861
+ var a = n.match(ks);
4850
4862
  a && (r = +a[1], t = +a[2], e = +a[3], a[4] && (i = +a[4]));
4851
4863
  }
4852
4864
  return {
@@ -4859,26 +4871,26 @@ function Ts(n) {
4859
4871
  var rt = {};
4860
4872
  for (var Ft in Jt)
4861
4873
  rt[Ft] = Ye(Jt[Ft]), rt[Jt[Ft]] = rt[Ft];
4862
- function Fi(n, r, t, e, i) {
4863
- return er[0] = e << 24 | t << 16 | r << 8 | n, er[0] = er[0] & 4278190079, ws[0];
4874
+ function Oi(n, r, t, e, i) {
4875
+ return er[0] = e << 24 | t << 16 | r << 8 | n, er[0] = er[0] & 4278190079, Rs[0];
4864
4876
  }
4865
4877
  function Ye(n) {
4866
4878
  if (n = n.toLowerCase(), typeof rt[n] < "u") return rt[n];
4867
- var r = Ts(n), t = r.r, e = r.g, i = r.b, a = r.a;
4879
+ var r = Cs(n), t = r.r, e = r.g, i = r.b, a = r.a;
4868
4880
  a = a * 255 | 0;
4869
- var o = Fi(t, e, i, a);
4881
+ var o = Oi(t, e, i, a);
4870
4882
  return rt[n] = o, o;
4871
4883
  }
4872
4884
  var tr = {};
4873
- function Oi(n) {
4885
+ function zi(n) {
4874
4886
  if (typeof tr[n] < "u") return tr[n];
4875
- var r = (n & 16711680) >>> 16, t = (n & 65280) >>> 8, e = n & 255, i = 255, a = Fi(r, t, e, i);
4887
+ var r = (n & 16711680) >>> 16, t = (n & 65280) >>> 8, e = n & 255, i = 255, a = Oi(r, t, e, i);
4876
4888
  return tr[n] = a, a;
4877
4889
  }
4878
- function En(n, r, t, e) {
4890
+ function _n(n, r, t, e) {
4879
4891
  return t + (r << 8) + (n << 16);
4880
4892
  }
4881
- function _n(n, r, t, e, i, a) {
4893
+ function Tn(n, r, t, e, i, a) {
4882
4894
  var o = Math.floor(t / a * i), s = Math.floor(n.drawingBufferHeight / a - e / a * i), u = new Uint8Array(4);
4883
4895
  n.bindFramebuffer(n.FRAMEBUFFER, r), n.readPixels(o, s, 1, 1, n.RGBA, n.UNSIGNED_BYTE, u);
4884
4896
  var l = it(u, 4), c = l[0], h = l[1], v = l[2], y = l[3];
@@ -4892,7 +4904,7 @@ function N(n, r, t) {
4892
4904
  writable: !0
4893
4905
  }) : n[r] = t, n;
4894
4906
  }
4895
- function Tn(n, r) {
4907
+ function Sn(n, r) {
4896
4908
  var t = Object.keys(n);
4897
4909
  if (Object.getOwnPropertySymbols) {
4898
4910
  var e = Object.getOwnPropertySymbols(n);
@@ -4905,43 +4917,43 @@ function Tn(n, r) {
4905
4917
  function j(n) {
4906
4918
  for (var r = 1; r < arguments.length; r++) {
4907
4919
  var t = arguments[r] != null ? arguments[r] : {};
4908
- r % 2 ? Tn(Object(t), !0).forEach(function(e) {
4920
+ r % 2 ? Sn(Object(t), !0).forEach(function(e) {
4909
4921
  N(n, e, t[e]);
4910
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Tn(Object(t)).forEach(function(e) {
4922
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Sn(Object(t)).forEach(function(e) {
4911
4923
  Object.defineProperty(n, e, Object.getOwnPropertyDescriptor(t, e));
4912
4924
  });
4913
4925
  }
4914
4926
  return n;
4915
4927
  }
4916
- function Ss(n, r) {
4928
+ function xs(n, r) {
4917
4929
  for (; !{}.hasOwnProperty.call(n, r) && (n = nt(n)) !== null; ) ;
4918
4930
  return n;
4919
4931
  }
4920
4932
  function xr() {
4921
4933
  return xr = typeof Reflect < "u" && Reflect.get ? Reflect.get.bind() : function(n, r, t) {
4922
- var e = Ss(n, r);
4934
+ var e = xs(n, r);
4923
4935
  if (e) {
4924
4936
  var i = Object.getOwnPropertyDescriptor(e, r);
4925
4937
  return i.get ? i.get.call(arguments.length < 3 ? n : t) : i.value;
4926
4938
  }
4927
4939
  }, xr.apply(null, arguments);
4928
4940
  }
4929
- function zi(n, r, t, e) {
4941
+ function Ni(n, r, t, e) {
4930
4942
  var i = xr(nt(n.prototype), r, t);
4931
4943
  return typeof i == "function" ? function(a) {
4932
4944
  return i.apply(t, a);
4933
4945
  } : i;
4934
4946
  }
4935
- function Rs(n) {
4947
+ function Ds(n) {
4936
4948
  return n.normalized ? 1 : n.size;
4937
4949
  }
4938
4950
  function rr(n) {
4939
4951
  var r = 0;
4940
4952
  return n.forEach(function(t) {
4941
- return r += Rs(t);
4953
+ return r += Ds(t);
4942
4954
  }), r;
4943
4955
  }
4944
- function Ni(n, r, t) {
4956
+ function Ui(n, r, t) {
4945
4957
  var e = n === "VERTEX" ? r.VERTEX_SHADER : r.FRAGMENT_SHADER, i = r.createShader(e);
4946
4958
  if (i === null)
4947
4959
  throw new Error("loadShader: error while creating the shader");
@@ -4955,13 +4967,13 @@ function Ni(n, r, t) {
4955
4967
  }
4956
4968
  return i;
4957
4969
  }
4958
- function As(n, r) {
4959
- return Ni("VERTEX", n, r);
4970
+ function Ls(n, r) {
4971
+ return Ui("VERTEX", n, r);
4960
4972
  }
4961
- function ks(n, r) {
4962
- return Ni("FRAGMENT", n, r);
4973
+ function Gs(n, r) {
4974
+ return Ui("FRAGMENT", n, r);
4963
4975
  }
4964
- function Cs(n, r) {
4976
+ function Is(n, r) {
4965
4977
  var t = n.createProgram();
4966
4978
  if (t === null)
4967
4979
  throw new Error("loadProgram: error while creating the program.");
@@ -4975,16 +4987,16 @@ function Cs(n, r) {
4975
4987
  }
4976
4988
  return t;
4977
4989
  }
4978
- function Sn(n) {
4990
+ function Rn(n) {
4979
4991
  var r = n.gl, t = n.buffer, e = n.program, i = n.vertexShader, a = n.fragmentShader;
4980
4992
  r.deleteShader(i), r.deleteShader(a), r.deleteProgram(e), r.deleteBuffer(t);
4981
4993
  }
4982
- var Rn = `#define PICKING_MODE
4983
- `, xs = N(N(N(N(N(N(N(N({}, WebGL2RenderingContext.BOOL, 1), WebGL2RenderingContext.BYTE, 1), WebGL2RenderingContext.UNSIGNED_BYTE, 1), WebGL2RenderingContext.SHORT, 2), WebGL2RenderingContext.UNSIGNED_SHORT, 2), WebGL2RenderingContext.INT, 4), WebGL2RenderingContext.UNSIGNED_INT, 4), WebGL2RenderingContext.FLOAT, 4), Ui = /* @__PURE__ */ (function() {
4994
+ var An = `#define PICKING_MODE
4995
+ `, Ps = N(N(N(N(N(N(N(N({}, WebGL2RenderingContext.BOOL, 1), WebGL2RenderingContext.BYTE, 1), WebGL2RenderingContext.UNSIGNED_BYTE, 1), WebGL2RenderingContext.SHORT, 2), WebGL2RenderingContext.UNSIGNED_SHORT, 2), WebGL2RenderingContext.INT, 4), WebGL2RenderingContext.UNSIGNED_INT, 4), WebGL2RenderingContext.FLOAT, 4), $i = /* @__PURE__ */ (function() {
4984
4996
  function n(r, t, e) {
4985
4997
  ge(this, n), N(this, "array", new Float32Array()), N(this, "constantArray", new Float32Array()), N(this, "capacity", 0), N(this, "verticesCount", 0);
4986
4998
  var i = this.getDefinition();
4987
- if (this.VERTICES = i.VERTICES, this.VERTEX_SHADER_SOURCE = i.VERTEX_SHADER_SOURCE, this.FRAGMENT_SHADER_SOURCE = i.FRAGMENT_SHADER_SOURCE, this.UNIFORMS = i.UNIFORMS, this.ATTRIBUTES = i.ATTRIBUTES, this.METHOD = i.METHOD, this.CONSTANT_ATTRIBUTES = "CONSTANT_ATTRIBUTES" in i ? i.CONSTANT_ATTRIBUTES : [], this.CONSTANT_DATA = "CONSTANT_DATA" in i ? i.CONSTANT_DATA : [], this.isInstanced = "CONSTANT_ATTRIBUTES" in i, this.ATTRIBUTES_ITEMS_COUNT = rr(this.ATTRIBUTES), this.STRIDE = this.VERTICES * this.ATTRIBUTES_ITEMS_COUNT, this.renderer = e, this.normalProgram = this.getProgramInfo("normal", r, i.VERTEX_SHADER_SOURCE, i.FRAGMENT_SHADER_SOURCE, null), this.pickProgram = t ? this.getProgramInfo("pick", r, Rn + i.VERTEX_SHADER_SOURCE, Rn + i.FRAGMENT_SHADER_SOURCE, t) : null, this.isInstanced) {
4999
+ if (this.VERTICES = i.VERTICES, this.VERTEX_SHADER_SOURCE = i.VERTEX_SHADER_SOURCE, this.FRAGMENT_SHADER_SOURCE = i.FRAGMENT_SHADER_SOURCE, this.UNIFORMS = i.UNIFORMS, this.ATTRIBUTES = i.ATTRIBUTES, this.METHOD = i.METHOD, this.CONSTANT_ATTRIBUTES = "CONSTANT_ATTRIBUTES" in i ? i.CONSTANT_ATTRIBUTES : [], this.CONSTANT_DATA = "CONSTANT_DATA" in i ? i.CONSTANT_DATA : [], this.isInstanced = "CONSTANT_ATTRIBUTES" in i, this.ATTRIBUTES_ITEMS_COUNT = rr(this.ATTRIBUTES), this.STRIDE = this.VERTICES * this.ATTRIBUTES_ITEMS_COUNT, this.renderer = e, this.normalProgram = this.getProgramInfo("normal", r, i.VERTEX_SHADER_SOURCE, i.FRAGMENT_SHADER_SOURCE, null), this.pickProgram = t ? this.getProgramInfo("pick", r, An + i.VERTEX_SHADER_SOURCE, An + i.FRAGMENT_SHADER_SOURCE, t) : null, this.isInstanced) {
4988
5000
  var a = rr(this.CONSTANT_ATTRIBUTES);
4989
5001
  if (this.CONSTANT_DATA.length !== this.VERTICES) throw new Error("Program: error while getting constant data (expected ".concat(this.VERTICES, " items, received ").concat(this.CONSTANT_DATA.length, " instead)"));
4990
5002
  this.constantArray = new Float32Array(this.CONSTANT_DATA.length * a);
@@ -4999,14 +5011,14 @@ var Rn = `#define PICKING_MODE
4999
5011
  return pe(n, [{
5000
5012
  key: "kill",
5001
5013
  value: function() {
5002
- Sn(this.normalProgram), this.pickProgram && (Sn(this.pickProgram), this.pickProgram = null);
5014
+ Rn(this.normalProgram), this.pickProgram && (Rn(this.pickProgram), this.pickProgram = null);
5003
5015
  }
5004
5016
  }, {
5005
5017
  key: "getProgramInfo",
5006
5018
  value: function(t, e, i, a, o) {
5007
5019
  var s = this.getDefinition(), u = e.createBuffer();
5008
5020
  if (u === null) throw new Error("Program: error while creating the WebGL buffer.");
5009
- var l = As(e, i), c = ks(e, a), h = Cs(e, [l, c]), v = {};
5021
+ var l = Ls(e, i), c = Gs(e, a), h = Is(e, [l, c]), v = {};
5010
5022
  s.UNIFORMS.forEach(function(R) {
5011
5023
  var w = e.getUniformLocation(h, R);
5012
5024
  w && (v[R] = w);
@@ -5061,7 +5073,7 @@ var Rn = `#define PICKING_MODE
5061
5073
  }, {
5062
5074
  key: "bindAttribute",
5063
5075
  value: function(t, e, i, a) {
5064
- var o = xs[t.type];
5076
+ var o = Ps[t.type];
5065
5077
  if (typeof o != "number") throw new Error('Program.bind: yet unsupported attribute type "'.concat(t.type, '"'));
5066
5078
  var s = e.attributeLocations[t.name], u = e.gl;
5067
5079
  if (s !== -1) {
@@ -5126,14 +5138,14 @@ var Rn = `#define PICKING_MODE
5126
5138
  }
5127
5139
  }
5128
5140
  }]);
5129
- })(), $i = /* @__PURE__ */ (function(n) {
5141
+ })(), Mi = /* @__PURE__ */ (function(n) {
5130
5142
  function r() {
5131
5143
  return ge(this, r), Te(this, r, arguments);
5132
5144
  }
5133
5145
  return Se(r, n), pe(r, [{
5134
5146
  key: "kill",
5135
5147
  value: function() {
5136
- zi(r, "kill", this)([]);
5148
+ Ni(r, "kill", this)([]);
5137
5149
  }
5138
5150
  }, {
5139
5151
  key: "process",
@@ -5144,10 +5156,10 @@ var Rn = `#define PICKING_MODE
5144
5156
  this.array[o] = 0;
5145
5157
  return;
5146
5158
  }
5147
- return this.processVisibleItem(Oi(e), o, a);
5159
+ return this.processVisibleItem(zi(e), o, a);
5148
5160
  }
5149
5161
  }]);
5150
- })(Ui), Ht = /* @__PURE__ */ (function(n) {
5162
+ })($i), jt = /* @__PURE__ */ (function(n) {
5151
5163
  function r() {
5152
5164
  var t;
5153
5165
  ge(this, r);
@@ -5158,7 +5170,7 @@ var Rn = `#define PICKING_MODE
5158
5170
  return Se(r, n), pe(r, [{
5159
5171
  key: "kill",
5160
5172
  value: function() {
5161
- zi(r, "kill", this)([]);
5173
+ Ni(r, "kill", this)([]);
5162
5174
  }
5163
5175
  }, {
5164
5176
  key: "process",
@@ -5169,11 +5181,11 @@ var Rn = `#define PICKING_MODE
5169
5181
  this.array[u] = 0;
5170
5182
  return;
5171
5183
  }
5172
- return this.processVisibleItem(Oi(e), u, a, o, s);
5184
+ return this.processVisibleItem(zi(e), u, a, o, s);
5173
5185
  }
5174
5186
  }]);
5175
- })(Ui);
5176
- function Ds(n, r) {
5187
+ })($i);
5188
+ function Fs(n, r) {
5177
5189
  return /* @__PURE__ */ (function() {
5178
5190
  function t(e, i, a) {
5179
5191
  ge(this, t), N(this, "drawLabel", r), this.programs = n.map(function(o) {
@@ -5211,7 +5223,7 @@ function Ds(n, r) {
5211
5223
  }]);
5212
5224
  })();
5213
5225
  }
5214
- function Ls(n, r, t, e, i) {
5226
+ function Os(n, r, t, e, i) {
5215
5227
  var a = i.edgeLabelSize, o = i.edgeLabelFont, s = i.edgeLabelWeight, u = i.edgeLabelColor.attribute ? r[i.edgeLabelColor.attribute] || i.edgeLabelColor.color || "#000" : i.edgeLabelColor.color, l = r.label;
5216
5228
  if (l) {
5217
5229
  n.fillStyle = u, n.font = "".concat(s, " ").concat(a, "px ").concat(o);
@@ -5230,13 +5242,13 @@ function Ls(n, r, t, e, i) {
5230
5242
  }
5231
5243
  }
5232
5244
  }
5233
- function Mi(n, r, t) {
5245
+ function Bi(n, r, t) {
5234
5246
  if (r.label) {
5235
5247
  var e = t.labelSize, i = t.labelFont, a = t.labelWeight, o = t.labelColor.attribute ? r[t.labelColor.attribute] || t.labelColor.color || "#000" : t.labelColor.color;
5236
5248
  n.fillStyle = o, n.font = "".concat(a, " ").concat(e, "px ").concat(i), n.fillText(r.label, r.x + r.size + 3, r.y + e / 3);
5237
5249
  }
5238
5250
  }
5239
- function Gs(n, r, t) {
5251
+ function zs(n, r, t) {
5240
5252
  var e = t.labelSize, i = t.labelFont, a = t.labelWeight;
5241
5253
  n.font = "".concat(a, " ").concat(e, "px ").concat(i), n.fillStyle = "#FFF", n.shadowOffsetX = 0, n.shadowOffsetY = 0, n.shadowBlur = 8, n.shadowColor = "#000";
5242
5254
  var o = 2;
@@ -5245,9 +5257,9 @@ function Gs(n, r, t) {
5245
5257
  n.beginPath(), n.moveTo(r.x + v, r.y + l / 2), n.lineTo(r.x + c + u, r.y + l / 2), n.lineTo(r.x + c + u, r.y - l / 2), n.lineTo(r.x + v, r.y - l / 2), n.arc(r.x, r.y, c, h, -h), n.closePath(), n.fill();
5246
5258
  } else
5247
5259
  n.beginPath(), n.arc(r.x, r.y, r.size + o, 0, Math.PI * 2), n.closePath(), n.fill();
5248
- n.shadowOffsetX = 0, n.shadowOffsetY = 0, n.shadowBlur = 0, Mi(n, r, t);
5260
+ n.shadowOffsetX = 0, n.shadowOffsetY = 0, n.shadowBlur = 0, Bi(n, r, t);
5249
5261
  }
5250
- var Ps = (
5262
+ var Ns = (
5251
5263
  /*glsl*/
5252
5264
  `
5253
5265
  precision highp float;
@@ -5282,7 +5294,7 @@ void main(void) {
5282
5294
  #endif
5283
5295
  }
5284
5296
  `
5285
- ), Is = Ps, Fs = (
5297
+ ), Us = Ns, $s = (
5286
5298
  /*glsl*/
5287
5299
  `
5288
5300
  attribute vec4 a_id;
@@ -5326,7 +5338,7 @@ void main() {
5326
5338
  v_color.a *= bias;
5327
5339
  }
5328
5340
  `
5329
- ), Os = Fs, Bi = WebGLRenderingContext, An = Bi.UNSIGNED_BYTE, nr = Bi.FLOAT, zs = ["u_sizeRatio", "u_correctionRatio", "u_matrix"], At = /* @__PURE__ */ (function(n) {
5341
+ ), Ms = $s, Wi = WebGLRenderingContext, kn = Wi.UNSIGNED_BYTE, nr = Wi.FLOAT, Bs = ["u_sizeRatio", "u_correctionRatio", "u_matrix"], At = /* @__PURE__ */ (function(n) {
5330
5342
  function r() {
5331
5343
  return ge(this, r), Te(this, r, arguments);
5332
5344
  }
@@ -5335,10 +5347,10 @@ void main() {
5335
5347
  value: function() {
5336
5348
  return {
5337
5349
  VERTICES: 3,
5338
- VERTEX_SHADER_SOURCE: Os,
5339
- FRAGMENT_SHADER_SOURCE: Is,
5350
+ VERTEX_SHADER_SOURCE: Ms,
5351
+ FRAGMENT_SHADER_SOURCE: Us,
5340
5352
  METHOD: WebGLRenderingContext.TRIANGLES,
5341
- UNIFORMS: zs,
5353
+ UNIFORMS: Bs,
5342
5354
  ATTRIBUTES: [{
5343
5355
  name: "a_position",
5344
5356
  size: 2,
@@ -5350,12 +5362,12 @@ void main() {
5350
5362
  }, {
5351
5363
  name: "a_color",
5352
5364
  size: 4,
5353
- type: An,
5365
+ type: kn,
5354
5366
  normalized: !0
5355
5367
  }, {
5356
5368
  name: "a_id",
5357
5369
  size: 4,
5358
- type: An,
5370
+ type: kn,
5359
5371
  normalized: !0
5360
5372
  }],
5361
5373
  CONSTANT_ATTRIBUTES: [{
@@ -5379,11 +5391,11 @@ void main() {
5379
5391
  a.uniform1f(u, e.correctionRatio), a.uniform1f(s, e.sizeRatio), a.uniformMatrix3fv(l, !1, e.matrix);
5380
5392
  }
5381
5393
  }]);
5382
- })($i);
5394
+ })(Mi);
5383
5395
  N(At, "ANGLE_1", 0);
5384
5396
  N(At, "ANGLE_2", 2 * Math.PI / 3);
5385
5397
  N(At, "ANGLE_3", 4 * Math.PI / 3);
5386
- var Ns = (
5398
+ var Ws = (
5387
5399
  /*glsl*/
5388
5400
  `
5389
5401
  precision mediump float;
@@ -5394,7 +5406,7 @@ void main(void) {
5394
5406
  gl_FragColor = v_color;
5395
5407
  }
5396
5408
  `
5397
- ), Us = Ns, $s = (
5409
+ ), Hs = Ws, js = (
5398
5410
  /*glsl*/
5399
5411
  `
5400
5412
  attribute vec2 a_position;
@@ -5463,13 +5475,13 @@ void main() {
5463
5475
  v_color.a *= bias;
5464
5476
  }
5465
5477
  `
5466
- ), Ms = $s, Wi = WebGLRenderingContext, kn = Wi.UNSIGNED_BYTE, Ot = Wi.FLOAT, Bs = ["u_matrix", "u_sizeRatio", "u_correctionRatio", "u_minEdgeThickness", "u_lengthToThicknessRatio", "u_widenessToThicknessRatio"], jt = {
5478
+ ), Vs = js, Hi = WebGLRenderingContext, Cn = Hi.UNSIGNED_BYTE, Ot = Hi.FLOAT, qs = ["u_matrix", "u_sizeRatio", "u_correctionRatio", "u_minEdgeThickness", "u_lengthToThicknessRatio", "u_widenessToThicknessRatio"], Vt = {
5467
5479
  extremity: "target",
5468
5480
  lengthToThicknessRatio: 2.5,
5469
5481
  widenessToThicknessRatio: 2
5470
5482
  };
5471
- function Hi(n) {
5472
- var r = j(j({}, jt), {});
5483
+ function ji(n) {
5484
+ var r = j(j({}, Vt), {});
5473
5485
  return /* @__PURE__ */ (function(t) {
5474
5486
  function e() {
5475
5487
  return ge(this, e), Te(this, e, arguments);
@@ -5479,10 +5491,10 @@ function Hi(n) {
5479
5491
  value: function() {
5480
5492
  return {
5481
5493
  VERTICES: 3,
5482
- VERTEX_SHADER_SOURCE: Ms,
5483
- FRAGMENT_SHADER_SOURCE: Us,
5494
+ VERTEX_SHADER_SOURCE: Vs,
5495
+ FRAGMENT_SHADER_SOURCE: Hs,
5484
5496
  METHOD: WebGLRenderingContext.TRIANGLES,
5485
- UNIFORMS: Bs,
5497
+ UNIFORMS: qs,
5486
5498
  ATTRIBUTES: [{
5487
5499
  name: "a_position",
5488
5500
  size: 2,
@@ -5498,12 +5510,12 @@ function Hi(n) {
5498
5510
  }, {
5499
5511
  name: "a_color",
5500
5512
  size: 4,
5501
- type: kn,
5513
+ type: Cn,
5502
5514
  normalized: !0
5503
5515
  }, {
5504
5516
  name: "a_id",
5505
5517
  size: 4,
5506
- type: kn,
5518
+ type: Cn,
5507
5519
  normalized: !0
5508
5520
  }],
5509
5521
  CONSTANT_ATTRIBUTES: [{
@@ -5533,10 +5545,10 @@ function Hi(n) {
5533
5545
  s.uniformMatrix3fv(l, !1, a.matrix), s.uniform1f(c, a.sizeRatio), s.uniform1f(h, a.correctionRatio), s.uniform1f(v, a.minEdgeThickness), s.uniform1f(y, r.lengthToThicknessRatio), s.uniform1f(b, r.widenessToThicknessRatio);
5534
5546
  }
5535
5547
  }]);
5536
- })(Ht);
5548
+ })(jt);
5537
5549
  }
5538
- Hi();
5539
- var Ws = (
5550
+ ji();
5551
+ var Ks = (
5540
5552
  /*glsl*/
5541
5553
  `
5542
5554
  precision mediump float;
@@ -5565,7 +5577,7 @@ void main(void) {
5565
5577
  #endif
5566
5578
  }
5567
5579
  `
5568
- ), ji = Ws, Hs = (
5580
+ ), Vi = Ks, Xs = (
5569
5581
  /*glsl*/
5570
5582
  `
5571
5583
  attribute vec4 a_id;
@@ -5636,11 +5648,11 @@ void main() {
5636
5648
  v_color.a *= bias;
5637
5649
  }
5638
5650
  `
5639
- ), js = Hs, Vi = WebGLRenderingContext, Cn = Vi.UNSIGNED_BYTE, qe = Vi.FLOAT, Vs = ["u_matrix", "u_zoomRatio", "u_sizeRatio", "u_correctionRatio", "u_pixelRatio", "u_feather", "u_minEdgeThickness", "u_lengthToThicknessRatio"], qs = {
5640
- lengthToThicknessRatio: jt.lengthToThicknessRatio
5651
+ ), Ys = Xs, qi = WebGLRenderingContext, xn = qi.UNSIGNED_BYTE, qe = qi.FLOAT, Zs = ["u_matrix", "u_zoomRatio", "u_sizeRatio", "u_correctionRatio", "u_pixelRatio", "u_feather", "u_minEdgeThickness", "u_lengthToThicknessRatio"], Qs = {
5652
+ lengthToThicknessRatio: Vt.lengthToThicknessRatio
5641
5653
  };
5642
- function qi(n) {
5643
- var r = j(j({}, qs), {});
5654
+ function Ki(n) {
5655
+ var r = j(j({}, Qs), {});
5644
5656
  return /* @__PURE__ */ (function(t) {
5645
5657
  function e() {
5646
5658
  return ge(this, e), Te(this, e, arguments);
@@ -5650,10 +5662,10 @@ function qi(n) {
5650
5662
  value: function() {
5651
5663
  return {
5652
5664
  VERTICES: 6,
5653
- VERTEX_SHADER_SOURCE: js,
5654
- FRAGMENT_SHADER_SOURCE: ji,
5665
+ VERTEX_SHADER_SOURCE: Ys,
5666
+ FRAGMENT_SHADER_SOURCE: Vi,
5655
5667
  METHOD: WebGLRenderingContext.TRIANGLES,
5656
- UNIFORMS: Vs,
5668
+ UNIFORMS: Zs,
5657
5669
  ATTRIBUTES: [{
5658
5670
  name: "a_positionStart",
5659
5671
  size: 2,
@@ -5669,12 +5681,12 @@ function qi(n) {
5669
5681
  }, {
5670
5682
  name: "a_color",
5671
5683
  size: 4,
5672
- type: Cn,
5684
+ type: xn,
5673
5685
  normalized: !0
5674
5686
  }, {
5675
5687
  name: "a_id",
5676
5688
  size: 4,
5677
- type: Cn,
5689
+ type: xn,
5678
5690
  normalized: !0
5679
5691
  }, {
5680
5692
  name: "a_radius",
@@ -5718,13 +5730,13 @@ function qi(n) {
5718
5730
  s.uniformMatrix3fv(l, !1, a.matrix), s.uniform1f(c, a.zoomRatio), s.uniform1f(b, a.sizeRatio), s.uniform1f(y, a.correctionRatio), s.uniform1f(v, a.pixelRatio), s.uniform1f(h, a.antiAliasingFeather), s.uniform1f(R, a.minEdgeThickness), s.uniform1f(w, r.lengthToThicknessRatio);
5719
5731
  }
5720
5732
  }]);
5721
- })(Ht);
5733
+ })(jt);
5722
5734
  }
5723
- qi();
5724
- function Xs(n) {
5725
- return Ds([qi(), Hi()]);
5735
+ Ki();
5736
+ function Js(n) {
5737
+ return Fs([Ki(), ji()]);
5726
5738
  }
5727
- var Ks = Xs(), Xi = Ks, Ys = (
5739
+ var eu = Js(), Xi = eu, tu = (
5728
5740
  /*glsl*/
5729
5741
  `
5730
5742
  attribute vec4 a_id;
@@ -5792,7 +5804,7 @@ void main() {
5792
5804
  v_color.a *= bias;
5793
5805
  }
5794
5806
  `
5795
- ), Zs = Ys, Ki = WebGLRenderingContext, xn = Ki.UNSIGNED_BYTE, ft = Ki.FLOAT, Qs = ["u_matrix", "u_zoomRatio", "u_sizeRatio", "u_correctionRatio", "u_pixelRatio", "u_feather", "u_minEdgeThickness"], Yi = /* @__PURE__ */ (function(n) {
5807
+ ), ru = tu, Yi = WebGLRenderingContext, Dn = Yi.UNSIGNED_BYTE, ft = Yi.FLOAT, nu = ["u_matrix", "u_zoomRatio", "u_sizeRatio", "u_correctionRatio", "u_pixelRatio", "u_feather", "u_minEdgeThickness"], Zi = /* @__PURE__ */ (function(n) {
5796
5808
  function r() {
5797
5809
  return ge(this, r), Te(this, r, arguments);
5798
5810
  }
@@ -5801,10 +5813,10 @@ void main() {
5801
5813
  value: function() {
5802
5814
  return {
5803
5815
  VERTICES: 6,
5804
- VERTEX_SHADER_SOURCE: Zs,
5805
- FRAGMENT_SHADER_SOURCE: ji,
5816
+ VERTEX_SHADER_SOURCE: ru,
5817
+ FRAGMENT_SHADER_SOURCE: Vi,
5806
5818
  METHOD: WebGLRenderingContext.TRIANGLES,
5807
- UNIFORMS: Qs,
5819
+ UNIFORMS: nu,
5808
5820
  ATTRIBUTES: [{
5809
5821
  name: "a_positionStart",
5810
5822
  size: 2,
@@ -5820,12 +5832,12 @@ void main() {
5820
5832
  }, {
5821
5833
  name: "a_color",
5822
5834
  size: 4,
5823
- type: xn,
5835
+ type: Dn,
5824
5836
  normalized: !0
5825
5837
  }, {
5826
5838
  name: "a_id",
5827
5839
  size: 4,
5828
- type: xn,
5840
+ type: Dn,
5829
5841
  normalized: !0
5830
5842
  }],
5831
5843
  CONSTANT_ATTRIBUTES: [
@@ -5860,43 +5872,43 @@ void main() {
5860
5872
  a.uniformMatrix3fv(s, !1, e.matrix), a.uniform1f(u, e.zoomRatio), a.uniform1f(v, e.sizeRatio), a.uniform1f(h, e.correctionRatio), a.uniform1f(c, e.pixelRatio), a.uniform1f(l, e.antiAliasingFeather), a.uniform1f(y, e.minEdgeThickness);
5861
5873
  }
5862
5874
  }]);
5863
- })(Ht), Xr = /* @__PURE__ */ (function(n) {
5875
+ })(jt), Kr = /* @__PURE__ */ (function(n) {
5864
5876
  function r() {
5865
5877
  var t;
5866
5878
  return ge(this, r), t = Te(this, r), t.rawEmitter = t, t;
5867
5879
  }
5868
5880
  return Se(r, n), pe(r);
5869
- })(Wr.EventEmitter), ir, Dn;
5881
+ })(Wr.EventEmitter), ir, Ln;
5870
5882
  function Ze() {
5871
- return Dn || (Dn = 1, ir = function(r) {
5883
+ return Ln || (Ln = 1, ir = function(r) {
5872
5884
  return r !== null && typeof r == "object" && typeof r.addUndirectedEdgeWithKey == "function" && typeof r.dropNode == "function" && typeof r.multi == "boolean";
5873
5885
  }), ir;
5874
5886
  }
5875
- var Js = Ze();
5876
- const eu = /* @__PURE__ */ Br(Js);
5877
- var tu = function(r) {
5887
+ var iu = Ze();
5888
+ const au = /* @__PURE__ */ Br(iu);
5889
+ var ou = function(r) {
5878
5890
  return r;
5879
- }, ru = function(r) {
5891
+ }, su = function(r) {
5880
5892
  return r * r;
5881
- }, nu = function(r) {
5893
+ }, uu = function(r) {
5882
5894
  return r * (2 - r);
5883
- }, iu = function(r) {
5895
+ }, lu = function(r) {
5884
5896
  return (r *= 2) < 1 ? 0.5 * r * r : -0.5 * (--r * (r - 2) - 1);
5885
- }, au = function(r) {
5897
+ }, cu = function(r) {
5886
5898
  return r * r * r;
5887
- }, ou = function(r) {
5899
+ }, hu = function(r) {
5888
5900
  return --r * r * r + 1;
5889
- }, su = function(r) {
5901
+ }, du = function(r) {
5890
5902
  return (r *= 2) < 1 ? 0.5 * r * r * r : 0.5 * ((r -= 2) * r * r + 2);
5891
- }, uu = {
5892
- linear: tu,
5893
- quadraticIn: ru,
5894
- quadraticOut: nu,
5895
- quadraticInOut: iu,
5896
- cubicIn: au,
5897
- cubicOut: ou,
5898
- cubicInOut: su
5899
- }, lu = {
5903
+ }, fu = {
5904
+ linear: ou,
5905
+ quadraticIn: su,
5906
+ quadraticOut: uu,
5907
+ quadraticInOut: lu,
5908
+ cubicIn: cu,
5909
+ cubicOut: hu,
5910
+ cubicInOut: du
5911
+ }, gu = {
5900
5912
  easing: "quadraticInOut",
5901
5913
  duration: 150
5902
5914
  };
@@ -5906,11 +5918,11 @@ function ke() {
5906
5918
  function zt(n, r, t) {
5907
5919
  return n[0] = r, n[4] = typeof t == "number" ? t : r, n;
5908
5920
  }
5909
- function Ln(n, r) {
5921
+ function Gn(n, r) {
5910
5922
  var t = Math.sin(r), e = Math.cos(r);
5911
5923
  return n[0] = e, n[1] = t, n[3] = -t, n[4] = e, n;
5912
5924
  }
5913
- function Gn(n, r, t) {
5925
+ function In(n, r, t) {
5914
5926
  return n[6] = r, n[7] = t, n;
5915
5927
  }
5916
5928
  function $e(n, r) {
@@ -5924,22 +5936,22 @@ function Dr(n, r) {
5924
5936
  y: l * i + c * o + u * t
5925
5937
  };
5926
5938
  }
5927
- function cu(n, r) {
5939
+ function pu(n, r) {
5928
5940
  var t = n.height / n.width, e = r.height / r.width;
5929
5941
  return t < 1 && e > 1 || t > 1 && e < 1 ? 1 : Math.min(Math.max(e, 1 / e), Math.max(1 / t, t));
5930
5942
  }
5931
5943
  function gt(n, r, t, e, i) {
5932
- var a = n.angle, o = n.ratio, s = n.x, u = n.y, l = r.width, c = r.height, h = ke(), v = Math.min(l, c) - 2 * e, y = cu(r, t);
5933
- return i ? ($e(h, Gn(ke(), s, u)), $e(h, zt(ke(), o)), $e(h, Ln(ke(), a)), $e(h, zt(ke(), l / v / 2 / y, c / v / 2 / y))) : ($e(h, zt(ke(), 2 * (v / l) * y, 2 * (v / c) * y)), $e(h, Ln(ke(), -a)), $e(h, zt(ke(), 1 / o)), $e(h, Gn(ke(), -s, -u))), h;
5944
+ var a = n.angle, o = n.ratio, s = n.x, u = n.y, l = r.width, c = r.height, h = ke(), v = Math.min(l, c) - 2 * e, y = pu(r, t);
5945
+ return i ? ($e(h, In(ke(), s, u)), $e(h, zt(ke(), o)), $e(h, Gn(ke(), a)), $e(h, zt(ke(), l / v / 2 / y, c / v / 2 / y))) : ($e(h, zt(ke(), 2 * (v / l) * y, 2 * (v / c) * y)), $e(h, Gn(ke(), -a)), $e(h, zt(ke(), 1 / o)), $e(h, In(ke(), -s, -u))), h;
5934
5946
  }
5935
- function hu(n, r, t) {
5947
+ function vu(n, r, t) {
5936
5948
  var e = Dr(n, {
5937
5949
  x: Math.cos(r.angle),
5938
5950
  y: Math.sin(r.angle)
5939
5951
  }, 0), i = e.x, a = e.y;
5940
5952
  return 1 / Math.sqrt(Math.pow(i, 2) + Math.pow(a, 2)) / t.width;
5941
5953
  }
5942
- function du(n) {
5954
+ function mu(n) {
5943
5955
  if (!n.order) return {
5944
5956
  x: [0, 1],
5945
5957
  y: [0, 1]
@@ -5953,14 +5965,14 @@ function du(n) {
5953
5965
  y: [e, i]
5954
5966
  };
5955
5967
  }
5956
- function fu(n) {
5957
- if (!eu(n)) throw new Error("Sigma: invalid graph instance.");
5968
+ function yu(n) {
5969
+ if (!au(n)) throw new Error("Sigma: invalid graph instance.");
5958
5970
  n.forEachNode(function(r, t) {
5959
5971
  if (!Number.isFinite(t.x) || !Number.isFinite(t.y))
5960
5972
  throw new Error("Sigma: Coordinates of node ".concat(r, " are invalid. A node must have a numeric 'x' and 'y' attribute."));
5961
5973
  });
5962
5974
  }
5963
- function gu(n, r, t) {
5975
+ function bu(n, r, t) {
5964
5976
  var e = document.createElement(n);
5965
5977
  if (r)
5966
5978
  for (var i in r)
@@ -5973,13 +5985,13 @@ function gu(n, r, t) {
5973
5985
  function Pn() {
5974
5986
  return typeof window.devicePixelRatio < "u" ? window.devicePixelRatio : 1;
5975
5987
  }
5976
- function In(n, r, t) {
5988
+ function Fn(n, r, t) {
5977
5989
  return t.sort(function(e, i) {
5978
5990
  var a = r(e) || 0, o = r(i) || 0;
5979
5991
  return a < o ? -1 : a > o ? 1 : 0;
5980
5992
  });
5981
5993
  }
5982
- function Fn(n) {
5994
+ function On(n) {
5983
5995
  var r = it(n.x, 2), t = r[0], e = r[1], i = it(n.y, 2), a = i[0], o = i[1], s = Math.max(e - t, o - a), u = (e + t) / 2, l = (o + a) / 2;
5984
5996
  (s === 0 || Math.abs(s) === 1 / 0 || isNaN(s)) && (s = 1), isNaN(u) && (u = 0), isNaN(l) && (l = 0);
5985
5997
  var c = function(v) {
@@ -6005,7 +6017,7 @@ function Lr(n) {
6005
6017
  return r && typeof Symbol == "function" && r.constructor === Symbol && r !== Symbol.prototype ? "symbol" : typeof r;
6006
6018
  }, Lr(n);
6007
6019
  }
6008
- function On(n, r) {
6020
+ function zn(n, r) {
6009
6021
  var t = r.size;
6010
6022
  if (t !== 0) {
6011
6023
  var e = n.length;
@@ -6024,7 +6036,7 @@ function ar(n) {
6024
6036
  }
6025
6037
  return n;
6026
6038
  }
6027
- var Kr = {
6039
+ var Xr = {
6028
6040
  // Performance
6029
6041
  hideEdgesOnMove: !1,
6030
6042
  hideLabelsOnMove: !1,
@@ -6049,9 +6061,9 @@ var Kr = {
6049
6061
  attribute: "color"
6050
6062
  },
6051
6063
  stagePadding: 30,
6052
- defaultDrawEdgeLabel: Ls,
6053
- defaultDrawNodeLabel: Mi,
6054
- defaultDrawNodeHover: Gs,
6064
+ defaultDrawEdgeLabel: Os,
6065
+ defaultDrawNodeLabel: Bi,
6066
+ defaultDrawNodeHover: zs,
6055
6067
  minEdgeThickness: 1.7,
6056
6068
  antiAliasingFeather: 1,
6057
6069
  // Mouse and touch settings
@@ -6091,11 +6103,11 @@ var Kr = {
6091
6103
  nodeProgramClasses: {},
6092
6104
  nodeHoverProgramClasses: {},
6093
6105
  edgeProgramClasses: {}
6094
- }, pu = {
6106
+ }, wu = {
6095
6107
  circle: At
6096
- }, vu = {
6108
+ }, Eu = {
6097
6109
  arrow: Xi,
6098
- line: Yi
6110
+ line: Zi
6099
6111
  };
6100
6112
  function or(n) {
6101
6113
  if (typeof n.labelDensity != "number" || n.labelDensity < 0)
@@ -6104,11 +6116,11 @@ function or(n) {
6104
6116
  if (typeof r == "number" && typeof t == "number" && t < r)
6105
6117
  throw new Error("Settings: invalid camera ratio boundaries. Expecting `maxCameraRatio` to be greater than `minCameraRatio`.");
6106
6118
  }
6107
- function mu(n) {
6108
- var r = ar({}, Kr, n);
6109
- return r.nodeProgramClasses = ar({}, pu, r.nodeProgramClasses), r.edgeProgramClasses = ar({}, vu, r.edgeProgramClasses), r;
6119
+ function _u(n) {
6120
+ var r = ar({}, Xr, n);
6121
+ return r.nodeProgramClasses = ar({}, wu, r.nodeProgramClasses), r.edgeProgramClasses = ar({}, Eu, r.edgeProgramClasses), r;
6110
6122
  }
6111
- var Nt = 1.5, zn = /* @__PURE__ */ (function(n) {
6123
+ var Nt = 1.5, Nn = /* @__PURE__ */ (function(n) {
6112
6124
  function r() {
6113
6125
  var t;
6114
6126
  return ge(this, r), t = Te(this, r), N(t, "x", 0.5), N(t, "y", 0.5), N(t, "angle", 0), N(t, "ratio", 1), N(t, "minRatio", null), N(t, "maxRatio", null), N(t, "enabledZooming", !0), N(t, "enabledPanning", !0), N(t, "enabledRotation", !0), N(t, "clean", null), N(t, "nextFrame", null), N(t, "previousState", null), N(t, "enabled", !0), t.previousState = t.getState(), t;
@@ -6222,7 +6234,7 @@ var Nt = 1.5, zn = /* @__PURE__ */ (function(n) {
6222
6234
  return i.animate(e, a, y);
6223
6235
  });
6224
6236
  if (this.enabled) {
6225
- var s = j(j({}, lu), a), u = this.validateState(e), l = typeof s.easing == "function" ? s.easing : uu[s.easing], c = Date.now(), h = this.getState(), v = function() {
6237
+ var s = j(j({}, gu), a), u = this.validateState(e), l = typeof s.easing == "function" ? s.easing : fu[s.easing], c = Date.now(), h = this.getState(), v = function() {
6226
6238
  var b = (Date.now() - c) / s.duration;
6227
6239
  if (b >= 1) {
6228
6240
  i.nextFrame = null, i.setState(u), i.animationCallback && (i.animationCallback.call(null), i.animationCallback = void 0);
@@ -6290,7 +6302,7 @@ var Nt = 1.5, zn = /* @__PURE__ */ (function(n) {
6290
6302
  return i.setState(e);
6291
6303
  }
6292
6304
  }]);
6293
- })(Xr);
6305
+ })(Kr);
6294
6306
  function De(n, r) {
6295
6307
  var t = r.getBoundingClientRect();
6296
6308
  return {
@@ -6318,14 +6330,14 @@ function pt(n) {
6318
6330
  });
6319
6331
  return r;
6320
6332
  }
6321
- function yu(n, r) {
6333
+ function Tu(n, r) {
6322
6334
  return j(j({}, Fe(n, r)), {}, {
6323
- delta: Zi(n)
6335
+ delta: Qi(n)
6324
6336
  });
6325
6337
  }
6326
- var bu = 2;
6338
+ var Su = 2;
6327
6339
  function Ut(n) {
6328
- for (var r = [], t = 0, e = Math.min(n.length, bu); t < e; t++) r.push(n[t]);
6340
+ for (var r = [], t = 0, e = Math.min(n.length, Su); t < e; t++) r.push(n[t]);
6329
6341
  return r;
6330
6342
  }
6331
6343
  function vt(n, r, t) {
@@ -6344,23 +6356,23 @@ function vt(n, r, t) {
6344
6356
  };
6345
6357
  return e;
6346
6358
  }
6347
- function Zi(n) {
6359
+ function Qi(n) {
6348
6360
  if (typeof n.deltaY < "u") return n.deltaY * -3 / 360;
6349
6361
  if (typeof n.detail < "u") return n.detail / -9;
6350
6362
  throw new Error("Captor: could not extract delta from event.");
6351
6363
  }
6352
- var Qi = /* @__PURE__ */ (function(n) {
6364
+ var Ji = /* @__PURE__ */ (function(n) {
6353
6365
  function r(t, e) {
6354
6366
  var i;
6355
6367
  return ge(this, r), i = Te(this, r), i.container = t, i.renderer = e, i;
6356
6368
  }
6357
6369
  return Se(r, n), pe(r);
6358
- })(Xr), wu = ["doubleClickTimeout", "doubleClickZoomingDuration", "doubleClickZoomingRatio", "dragTimeout", "draggedEventsTolerance", "inertiaDuration", "inertiaRatio", "zoomDuration", "zoomingRatio"], Eu = wu.reduce(function(n, r) {
6359
- return j(j({}, n), {}, N({}, r, Kr[r]));
6360
- }, {}), _u = /* @__PURE__ */ (function(n) {
6370
+ })(Kr), Ru = ["doubleClickTimeout", "doubleClickZoomingDuration", "doubleClickZoomingRatio", "dragTimeout", "draggedEventsTolerance", "inertiaDuration", "inertiaRatio", "zoomDuration", "zoomingRatio"], Au = Ru.reduce(function(n, r) {
6371
+ return j(j({}, n), {}, N({}, r, Xr[r]));
6372
+ }, {}), ku = /* @__PURE__ */ (function(n) {
6361
6373
  function r(t, e) {
6362
6374
  var i;
6363
- return ge(this, r), i = Te(this, r, [t, e]), N(i, "enabled", !0), N(i, "draggedEvents", 0), N(i, "downStartTime", null), N(i, "lastMouseX", null), N(i, "lastMouseY", null), N(i, "isMouseDown", !1), N(i, "isMoving", !1), N(i, "movingTimeout", null), N(i, "startCameraState", null), N(i, "clicks", 0), N(i, "doubleClickTimeout", null), N(i, "currentWheelDirection", 0), N(i, "settings", Eu), i.handleClick = i.handleClick.bind(i), i.handleRightClick = i.handleRightClick.bind(i), i.handleDown = i.handleDown.bind(i), i.handleUp = i.handleUp.bind(i), i.handleMove = i.handleMove.bind(i), i.handleWheel = i.handleWheel.bind(i), i.handleLeave = i.handleLeave.bind(i), i.handleEnter = i.handleEnter.bind(i), t.addEventListener("click", i.handleClick, {
6375
+ return ge(this, r), i = Te(this, r, [t, e]), N(i, "enabled", !0), N(i, "draggedEvents", 0), N(i, "downStartTime", null), N(i, "lastMouseX", null), N(i, "lastMouseY", null), N(i, "isMouseDown", !1), N(i, "isMoving", !1), N(i, "movingTimeout", null), N(i, "startCameraState", null), N(i, "clicks", 0), N(i, "doubleClickTimeout", null), N(i, "currentWheelDirection", 0), N(i, "settings", Au), i.handleClick = i.handleClick.bind(i), i.handleRightClick = i.handleRightClick.bind(i), i.handleDown = i.handleDown.bind(i), i.handleUp = i.handleUp.bind(i), i.handleMove = i.handleMove.bind(i), i.handleWheel = i.handleWheel.bind(i), i.handleLeave = i.handleLeave.bind(i), i.handleEnter = i.handleEnter.bind(i), t.addEventListener("click", i.handleClick, {
6364
6376
  capture: !1
6365
6377
  }), t.addEventListener("contextmenu", i.handleRightClick, {
6366
6378
  capture: !1
@@ -6493,9 +6505,9 @@ var Qi = /* @__PURE__ */ (function(n) {
6493
6505
  value: function(e) {
6494
6506
  var i = this, a = this.renderer.getCamera();
6495
6507
  if (!(!this.enabled || !a.enabledZooming)) {
6496
- var o = Zi(e);
6508
+ var o = Qi(e);
6497
6509
  if (o) {
6498
- var s = yu(e, this.container);
6510
+ var s = Tu(e, this.container);
6499
6511
  if (this.emit("wheel", s), s.sigmaDefaultPrevented) {
6500
6512
  e.preventDefault(), e.stopPropagation();
6501
6513
  return;
@@ -6516,12 +6528,12 @@ var Qi = /* @__PURE__ */ (function(n) {
6516
6528
  this.settings = e;
6517
6529
  }
6518
6530
  }]);
6519
- })(Qi), Tu = ["dragTimeout", "inertiaDuration", "inertiaRatio", "doubleClickTimeout", "doubleClickZoomingRatio", "doubleClickZoomingDuration", "tapMoveTolerance"], Su = Tu.reduce(function(n, r) {
6520
- return j(j({}, n), {}, N({}, r, Kr[r]));
6521
- }, {}), Ru = /* @__PURE__ */ (function(n) {
6531
+ })(Ji), Cu = ["dragTimeout", "inertiaDuration", "inertiaRatio", "doubleClickTimeout", "doubleClickZoomingRatio", "doubleClickZoomingDuration", "tapMoveTolerance"], xu = Cu.reduce(function(n, r) {
6532
+ return j(j({}, n), {}, N({}, r, Xr[r]));
6533
+ }, {}), Du = /* @__PURE__ */ (function(n) {
6522
6534
  function r(t, e) {
6523
6535
  var i;
6524
- return ge(this, r), i = Te(this, r, [t, e]), N(i, "enabled", !0), N(i, "isMoving", !1), N(i, "hasMoved", !1), N(i, "touchMode", 0), N(i, "startTouchesPositions", []), N(i, "lastTouches", []), N(i, "lastTap", null), N(i, "settings", Su), i.handleStart = i.handleStart.bind(i), i.handleLeave = i.handleLeave.bind(i), i.handleMove = i.handleMove.bind(i), t.addEventListener("touchstart", i.handleStart, {
6536
+ return ge(this, r), i = Te(this, r, [t, e]), N(i, "enabled", !0), N(i, "isMoving", !1), N(i, "hasMoved", !1), N(i, "touchMode", 0), N(i, "startTouchesPositions", []), N(i, "lastTouches", []), N(i, "lastTap", null), N(i, "settings", xu), i.handleStart = i.handleStart.bind(i), i.handleLeave = i.handleLeave.bind(i), i.handleMove = i.handleMove.bind(i), t.addEventListener("touchstart", i.handleStart, {
6525
6537
  capture: !1
6526
6538
  }), t.addEventListener("touchcancel", i.handleLeave, {
6527
6539
  capture: !1
@@ -6622,14 +6634,14 @@ var Qi = /* @__PURE__ */ (function(n) {
6622
6634
  var i = this;
6623
6635
  if (!(!this.enabled || !this.startTouchesPositions.length)) {
6624
6636
  e.preventDefault();
6625
- var a = Ut(e.touches), o = a.map(function(P) {
6626
- return De(P, i.container);
6637
+ var a = Ut(e.touches), o = a.map(function(I) {
6638
+ return De(I, i.container);
6627
6639
  }), s = this.lastTouches;
6628
6640
  this.lastTouches = a, this.lastTouchesPositions = o;
6629
6641
  var u = vt(e, s, this.container);
6630
- if (this.emit("touchmove", u), !u.sigmaDefaultPrevented && (this.hasMoved || (this.hasMoved = o.some(function(P, A) {
6642
+ if (this.emit("touchmove", u), !u.sigmaDefaultPrevented && (this.hasMoved || (this.hasMoved = o.some(function(I, A) {
6631
6643
  var z = i.startTouchesPositions[A];
6632
- return z && (P.x !== z.x || P.y !== z.y);
6644
+ return z && (I.x !== z.x || I.y !== z.y);
6633
6645
  })), !!this.hasMoved)) {
6634
6646
  this.isMoving = !0, this.movingTimeout && clearTimeout(this.movingTimeout), this.movingTimeout = window.setTimeout(function() {
6635
6647
  i.isMoving = !1;
@@ -6652,9 +6664,9 @@ var Qi = /* @__PURE__ */ (function(n) {
6652
6664
  ratio: 1
6653
6665
  }, m = o[0], p = m.x, C = m.y, L = o[1], g = L.x, x = L.y, S = Math.atan2(x - C, g - p) - this.startTouchesAngle, D = Math.hypot(x - C, g - p) / this.startTouchesDistance, O = l.getBoundedRatio(c.ratio / D);
6654
6666
  E.ratio = O, E.angle = c.angle + S;
6655
- var I = this.getDimensions(), _ = this.renderer.viewportToFramedGraph((this.startTouchesPositions || [])[0], {
6667
+ var P = this.getDimensions(), _ = this.renderer.viewportToFramedGraph((this.startTouchesPositions || [])[0], {
6656
6668
  cameraState: c
6657
- }), W = Math.min(I.width, I.height) - 2 * h, X = W / I.width, T = W / I.height, f = O / W, d = p - W / 2 / X, U = C - W / 2 / T, $ = [d * Math.cos(-E.angle) - U * Math.sin(-E.angle), U * Math.cos(-E.angle) + d * Math.sin(-E.angle)];
6669
+ }), W = Math.min(P.width, P.height) - 2 * h, K = W / P.width, T = W / P.height, f = O / W, d = p - W / 2 / K, U = C - W / 2 / T, $ = [d * Math.cos(-E.angle) - U * Math.sin(-E.angle), U * Math.cos(-E.angle) + d * Math.sin(-E.angle)];
6658
6670
  d = $[0], U = $[1], E.x = _.x - d * f, E.y = _.y + U * f, l.setState(E);
6659
6671
  break;
6660
6672
  }
@@ -6668,21 +6680,21 @@ var Qi = /* @__PURE__ */ (function(n) {
6668
6680
  this.settings = e;
6669
6681
  }
6670
6682
  }]);
6671
- })(Qi);
6672
- function Au(n) {
6683
+ })(Ji);
6684
+ function Lu(n) {
6673
6685
  if (Array.isArray(n)) return Cr(n);
6674
6686
  }
6675
- function ku(n) {
6687
+ function Gu(n) {
6676
6688
  if (typeof Symbol < "u" && n[Symbol.iterator] != null || n["@@iterator"] != null) return Array.from(n);
6677
6689
  }
6678
- function Cu() {
6690
+ function Iu() {
6679
6691
  throw new TypeError(`Invalid attempt to spread non-iterable instance.
6680
6692
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
6681
6693
  }
6682
- function Nn(n) {
6683
- return Au(n) || ku(n) || Pi(n) || Cu();
6694
+ function Un(n) {
6695
+ return Lu(n) || Gu(n) || Pi(n) || Iu();
6684
6696
  }
6685
- function xu(n, r) {
6697
+ function Pu(n, r) {
6686
6698
  if (n == null) return {};
6687
6699
  var t = {};
6688
6700
  for (var e in n) if ({}.hasOwnProperty.call(n, e)) {
@@ -6693,14 +6705,14 @@ function xu(n, r) {
6693
6705
  }
6694
6706
  function sr(n, r) {
6695
6707
  if (n == null) return {};
6696
- var t, e, i = xu(n, r);
6708
+ var t, e, i = Pu(n, r);
6697
6709
  if (Object.getOwnPropertySymbols) {
6698
6710
  var a = Object.getOwnPropertySymbols(n);
6699
6711
  for (e = 0; e < a.length; e++) t = a[e], r.indexOf(t) === -1 && {}.propertyIsEnumerable.call(n, t) && (i[t] = n[t]);
6700
6712
  }
6701
6713
  return i;
6702
6714
  }
6703
- var Un = /* @__PURE__ */ (function() {
6715
+ var $n = /* @__PURE__ */ (function() {
6704
6716
  function n(r, t) {
6705
6717
  ge(this, n), this.key = r, this.size = t;
6706
6718
  }
@@ -6710,7 +6722,7 @@ var Un = /* @__PURE__ */ (function() {
6710
6722
  return t.size > e.size ? -1 : t.size < e.size || t.key > e.key ? 1 : -1;
6711
6723
  }
6712
6724
  }]);
6713
- })(), $n = /* @__PURE__ */ (function() {
6725
+ })(), Mn = /* @__PURE__ */ (function() {
6714
6726
  function n() {
6715
6727
  ge(this, n), N(this, "width", 0), N(this, "height", 0), N(this, "cellSize", 0), N(this, "columns", 0), N(this, "rows", 0), N(this, "cells", {});
6716
6728
  }
@@ -6728,7 +6740,7 @@ var Un = /* @__PURE__ */ (function() {
6728
6740
  }, {
6729
6741
  key: "add",
6730
6742
  value: function(t, e, i) {
6731
- var a = new Un(t, e), o = this.getIndex(i), s = this.cells[o];
6743
+ var a = new $n(t, e), o = this.getIndex(i), s = this.cells[o];
6732
6744
  s || (s = [], this.cells[o] = s), s.push(a);
6733
6745
  }
6734
6746
  }, {
@@ -6736,7 +6748,7 @@ var Un = /* @__PURE__ */ (function() {
6736
6748
  value: function() {
6737
6749
  for (var t in this.cells) {
6738
6750
  var e = this.cells[t];
6739
- e.sort(Un.compare);
6751
+ e.sort($n.compare);
6740
6752
  }
6741
6753
  }
6742
6754
  }, {
@@ -6750,30 +6762,30 @@ var Un = /* @__PURE__ */ (function() {
6750
6762
  }
6751
6763
  }]);
6752
6764
  })();
6753
- function Du(n) {
6765
+ function Fu(n) {
6754
6766
  var r = n.graph, t = n.hoveredNode, e = n.highlightedNodes, i = n.displayedNodeLabels, a = [];
6755
6767
  return r.forEachEdge(function(o, s, u, l) {
6756
6768
  (u === t || l === t || e.has(u) || e.has(l) || i.has(u) && i.has(l)) && a.push(o);
6757
6769
  }), a;
6758
6770
  }
6759
- var Mn = 150, Bn = 50, Oe = Object.prototype.hasOwnProperty;
6760
- function Lu(n, r, t) {
6771
+ var Bn = 150, Wn = 50, Oe = Object.prototype.hasOwnProperty;
6772
+ function Ou(n, r, t) {
6761
6773
  if (!Oe.call(t, "x") || !Oe.call(t, "y")) throw new Error('Sigma: could not find a valid position (x, y) for node "'.concat(r, '". All your nodes must have a number "x" and "y". Maybe your forgot to apply a layout or your "nodeReducer" is not returning the correct data?'));
6762
6774
  return t.color || (t.color = n.defaultNodeColor), !t.label && t.label !== "" && (t.label = null), t.label !== void 0 && t.label !== null ? t.label = "" + t.label : t.label = null, t.size || (t.size = 2), Oe.call(t, "hidden") || (t.hidden = !1), Oe.call(t, "highlighted") || (t.highlighted = !1), Oe.call(t, "forceLabel") || (t.forceLabel = !1), (!t.type || t.type === "") && (t.type = n.defaultNodeType), t.zIndex || (t.zIndex = 0), t;
6763
6775
  }
6764
- function Gu(n, r, t) {
6776
+ function zu(n, r, t) {
6765
6777
  return t.color || (t.color = n.defaultEdgeColor), t.label || (t.label = ""), t.size || (t.size = 0.5), Oe.call(t, "hidden") || (t.hidden = !1), Oe.call(t, "forceLabel") || (t.forceLabel = !1), (!t.type || t.type === "") && (t.type = n.defaultEdgeType), t.zIndex || (t.zIndex = 0), t;
6766
6778
  }
6767
- var Pu = /* @__PURE__ */ (function(n) {
6779
+ var Nu = /* @__PURE__ */ (function(n) {
6768
6780
  function r(t, e) {
6769
6781
  var i, a = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
6770
- if (ge(this, r), i = Te(this, r), N(i, "elements", {}), N(i, "canvasContexts", {}), N(i, "webGLContexts", {}), N(i, "pickingLayers", /* @__PURE__ */ new Set()), N(i, "textures", {}), N(i, "frameBuffers", {}), N(i, "activeListeners", {}), N(i, "labelGrid", new $n()), N(i, "nodeDataCache", {}), N(i, "edgeDataCache", {}), N(i, "nodeProgramIndex", {}), N(i, "edgeProgramIndex", {}), N(i, "nodesWithForcedLabels", /* @__PURE__ */ new Set()), N(i, "edgesWithForcedLabels", /* @__PURE__ */ new Set()), N(i, "nodeExtent", {
6782
+ if (ge(this, r), i = Te(this, r), N(i, "elements", {}), N(i, "canvasContexts", {}), N(i, "webGLContexts", {}), N(i, "pickingLayers", /* @__PURE__ */ new Set()), N(i, "textures", {}), N(i, "frameBuffers", {}), N(i, "activeListeners", {}), N(i, "labelGrid", new Mn()), N(i, "nodeDataCache", {}), N(i, "edgeDataCache", {}), N(i, "nodeProgramIndex", {}), N(i, "edgeProgramIndex", {}), N(i, "nodesWithForcedLabels", /* @__PURE__ */ new Set()), N(i, "edgesWithForcedLabels", /* @__PURE__ */ new Set()), N(i, "nodeExtent", {
6771
6783
  x: [0, 1],
6772
6784
  y: [0, 1]
6773
- }), N(i, "nodeZExtent", [1 / 0, -1 / 0]), N(i, "edgeZExtent", [1 / 0, -1 / 0]), N(i, "matrix", ke()), N(i, "invMatrix", ke()), N(i, "correctionRatio", 1), N(i, "customBBox", null), N(i, "normalizationFunction", Fn({
6785
+ }), N(i, "nodeZExtent", [1 / 0, -1 / 0]), N(i, "edgeZExtent", [1 / 0, -1 / 0]), N(i, "matrix", ke()), N(i, "invMatrix", ke()), N(i, "correctionRatio", 1), N(i, "customBBox", null), N(i, "normalizationFunction", On({
6774
6786
  x: [0, 1],
6775
6787
  y: [0, 1]
6776
- })), N(i, "graphToViewportRatio", 1), N(i, "itemIDsIndex", {}), N(i, "nodeIndices", {}), N(i, "edgeIndices", {}), N(i, "width", 0), N(i, "height", 0), N(i, "pixelRatio", Pn()), N(i, "pickingDownSizingRatio", 2 * i.pixelRatio), N(i, "displayedNodeLabels", /* @__PURE__ */ new Set()), N(i, "displayedEdgeLabels", /* @__PURE__ */ new Set()), N(i, "highlightedNodes", /* @__PURE__ */ new Set()), N(i, "hoveredNode", null), N(i, "hoveredEdge", null), N(i, "renderFrame", null), N(i, "renderHighlightedNodesFrame", null), N(i, "needToProcess", !1), N(i, "checkEdgesEventsFrame", null), N(i, "nodePrograms", {}), N(i, "nodeHoverPrograms", {}), N(i, "edgePrograms", {}), i.settings = mu(a), or(i.settings), fu(t), !(e instanceof HTMLElement)) throw new Error("Sigma: container should be an html element.");
6788
+ })), N(i, "graphToViewportRatio", 1), N(i, "itemIDsIndex", {}), N(i, "nodeIndices", {}), N(i, "edgeIndices", {}), N(i, "width", 0), N(i, "height", 0), N(i, "pixelRatio", Pn()), N(i, "pickingDownSizingRatio", 2 * i.pixelRatio), N(i, "displayedNodeLabels", /* @__PURE__ */ new Set()), N(i, "displayedEdgeLabels", /* @__PURE__ */ new Set()), N(i, "highlightedNodes", /* @__PURE__ */ new Set()), N(i, "hoveredNode", null), N(i, "hoveredEdge", null), N(i, "renderFrame", null), N(i, "renderHighlightedNodesFrame", null), N(i, "needToProcess", !1), N(i, "checkEdgesEventsFrame", null), N(i, "nodePrograms", {}), N(i, "nodeHoverPrograms", {}), N(i, "edgePrograms", {}), i.settings = _u(a), or(i.settings), yu(t), !(e instanceof HTMLElement)) throw new Error("Sigma: container should be an html element.");
6777
6789
  i.graph = t, i.container = e, i.createWebGLContext("edges", {
6778
6790
  picking: a.enableEdgeEvents
6779
6791
  }), i.createCanvasContext("edgeLabels"), i.createWebGLContext("nodes", {
@@ -6788,7 +6800,7 @@ var Pu = /* @__PURE__ */ (function(n) {
6788
6800
  i.registerNodeProgram(o, i.settings.nodeProgramClasses[o], i.settings.nodeHoverProgramClasses[o]);
6789
6801
  for (var s in i.settings.edgeProgramClasses)
6790
6802
  i.registerEdgeProgram(s, i.settings.edgeProgramClasses[s]);
6791
- return i.camera = new zn(), i.bindCameraHandlers(), i.mouseCaptor = new _u(i.elements.mouse, i), i.mouseCaptor.setSettings(i.settings), i.touchCaptor = new Ru(i.elements.mouse, i), i.touchCaptor.setSettings(i.settings), i.bindEventHandlers(), i.bindGraphHandlers(), i.handleSettingsUpdate(), i.refresh(), i;
6803
+ return i.camera = new Nn(), i.bindCameraHandlers(), i.mouseCaptor = new ku(i.elements.mouse, i), i.mouseCaptor.setSettings(i.settings), i.touchCaptor = new Du(i.elements.mouse, i), i.touchCaptor.setSettings(i.settings), i.bindEventHandlers(), i.bindGraphHandlers(), i.handleSettingsUpdate(), i.refresh(), i;
6792
6804
  }
6793
6805
  return Se(r, n), pe(r, [{
6794
6806
  key: "registerNodeProgram",
@@ -6883,7 +6895,7 @@ var Pu = /* @__PURE__ */ (function(n) {
6883
6895
  }, {
6884
6896
  key: "getNodeAtPosition",
6885
6897
  value: function(e) {
6886
- var i = e.x, a = e.y, o = _n(this.webGLContexts.nodes, this.frameBuffers.nodes, i, a, this.pixelRatio, this.pickingDownSizingRatio), s = En.apply(void 0, Nn(o)), u = this.itemIDsIndex[s];
6898
+ var i = e.x, a = e.y, o = Tn(this.webGLContexts.nodes, this.frameBuffers.nodes, i, a, this.pixelRatio, this.pickingDownSizingRatio), s = _n.apply(void 0, Un(o)), u = this.itemIDsIndex[s];
6887
6899
  return u && u.type === "node" ? u.id : null;
6888
6900
  }
6889
6901
  /**
@@ -7090,7 +7102,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7090
7102
  }, {
7091
7103
  key: "getEdgeAtPoint",
7092
7104
  value: function(e, i) {
7093
- var a = _n(this.webGLContexts.edges, this.frameBuffers.edges, e, i, this.pixelRatio, this.pickingDownSizingRatio), o = En.apply(void 0, Nn(a)), s = this.itemIDsIndex[o];
7105
+ var a = Tn(this.webGLContexts.edges, this.frameBuffers.edges, e, i, this.pixelRatio, this.pickingDownSizingRatio), o = _n.apply(void 0, Un(a)), s = this.itemIDsIndex[o];
7094
7106
  return s && s.type === "edge" ? s.id : null;
7095
7107
  }
7096
7108
  /**
@@ -7108,15 +7120,15 @@ var Pu = /* @__PURE__ */ (function(n) {
7108
7120
  var e = this;
7109
7121
  this.emit("beforeProcess");
7110
7122
  var i = this.graph, a = this.settings, o = this.getDimensions();
7111
- if (this.nodeExtent = du(this.graph), !this.settings.autoRescale) {
7123
+ if (this.nodeExtent = mu(this.graph), !this.settings.autoRescale) {
7112
7124
  var s = o.width, u = o.height, l = this.nodeExtent, c = l.x, h = l.y;
7113
7125
  this.nodeExtent = {
7114
7126
  x: [(c[0] + c[1]) / 2 - s / 2, (c[0] + c[1]) / 2 + s / 2],
7115
7127
  y: [(h[0] + h[1]) / 2 - u / 2, (h[0] + h[1]) / 2 + u / 2]
7116
7128
  };
7117
7129
  }
7118
- this.normalizationFunction = Fn(this.customBBox || this.nodeExtent);
7119
- var v = new zn(), y = gt(v.getState(), o, this.getGraphDimensions(), this.getStagePadding());
7130
+ this.normalizationFunction = On(this.customBBox || this.nodeExtent);
7131
+ var v = new Nn(), y = gt(v.getState(), o, this.getGraphDimensions(), this.getStagePadding());
7120
7132
  this.labelGrid.resizeAndClear(o, a.labelGridCellSize);
7121
7133
  for (var b = {}, R = {}, w = {}, k = {}, E = 1, m = i.nodes(), p = 0, C = m.length; p < C; p++) {
7122
7134
  var L = m[p], g = this.nodeDataCache[L], x = i.getNodeAttributes(L);
@@ -7130,32 +7142,32 @@ var Pu = /* @__PURE__ */ (function(n) {
7130
7142
  throw new Error('Sigma: could not find a suitable program for node type "'.concat(S, '"!'));
7131
7143
  this.nodePrograms[S].reallocate(b[S] || 0), b[S] = 0;
7132
7144
  }
7133
- this.settings.zIndex && this.nodeZExtent[0] !== this.nodeZExtent[1] && (m = In(this.nodeZExtent, function(te) {
7145
+ this.settings.zIndex && this.nodeZExtent[0] !== this.nodeZExtent[1] && (m = Fn(this.nodeZExtent, function(te) {
7134
7146
  return e.nodeDataCache[te].zIndex;
7135
7147
  }, m));
7136
7148
  for (var D = 0, O = m.length; D < O; D++) {
7137
- var I = m[D];
7138
- R[I] = E, k[R[I]] = {
7149
+ var P = m[D];
7150
+ R[P] = E, k[R[P]] = {
7139
7151
  type: "node",
7140
- id: I
7152
+ id: P
7141
7153
  }, E++;
7142
- var _ = this.nodeDataCache[I];
7143
- this.addNodeToProgram(I, R[I], b[_.type]++);
7154
+ var _ = this.nodeDataCache[P];
7155
+ this.addNodeToProgram(P, R[P], b[_.type]++);
7144
7156
  }
7145
- for (var W = {}, X = i.edges(), T = 0, f = X.length; T < f; T++) {
7146
- var d = X[T], U = this.edgeDataCache[d];
7157
+ for (var W = {}, K = i.edges(), T = 0, f = K.length; T < f; T++) {
7158
+ var d = K[T], U = this.edgeDataCache[d];
7147
7159
  W[U.type] = (W[U.type] || 0) + 1;
7148
7160
  }
7149
- this.settings.zIndex && this.edgeZExtent[0] !== this.edgeZExtent[1] && (X = In(this.edgeZExtent, function(te) {
7161
+ this.settings.zIndex && this.edgeZExtent[0] !== this.edgeZExtent[1] && (K = Fn(this.edgeZExtent, function(te) {
7150
7162
  return e.edgeDataCache[te].zIndex;
7151
- }, X));
7163
+ }, K));
7152
7164
  for (var $ in this.edgePrograms) {
7153
7165
  if (!Oe.call(this.edgePrograms, $))
7154
7166
  throw new Error('Sigma: could not find a suitable program for edge type "'.concat($, '"!'));
7155
7167
  this.edgePrograms[$].reallocate(W[$] || 0), W[$] = 0;
7156
7168
  }
7157
- for (var P = 0, A = X.length; P < A; P++) {
7158
- var z = X[P];
7169
+ for (var I = 0, A = K.length; I < A; I++) {
7170
+ var z = K[I];
7159
7171
  w[z] = E, k[w[z]] = {
7160
7172
  type: "edge",
7161
7173
  id: z
@@ -7216,12 +7228,12 @@ var Pu = /* @__PURE__ */ (function(n) {
7216
7228
  cameraState: e
7217
7229
  })], k = 1 / 0, E = -1 / 0, m = 1 / 0, p = -1 / 0;
7218
7230
  w.forEach(function(W) {
7219
- var X = W.x, T = W.y;
7220
- k = Math.min(k, X), E = Math.max(E, X), m = Math.min(m, T), p = Math.max(p, T);
7231
+ var K = W.x, T = W.y;
7232
+ k = Math.min(k, K), E = Math.max(E, K), m = Math.min(m, T), p = Math.max(p, T);
7221
7233
  });
7222
7234
  var C = E - k, L = p - m, g = this.getDimensions(), x = g.width, S = g.height, D = 0, O = 0;
7223
7235
  if (C >= x ? E < x - o ? D = E - (x - o) : k > o && (D = k - o) : E > x + o ? D = E - (x + o) : k < -o && (D = k + o), L >= S ? p < S - o ? O = p - (S - o) : m > o && (O = m - o) : p > S + o ? O = p - (S + o) : m < -o && (O = m + o), D || O) {
7224
- var I = this.viewportToFramedGraph({
7236
+ var P = this.viewportToFramedGraph({
7225
7237
  x: 0,
7226
7238
  y: 0
7227
7239
  }, {
@@ -7232,7 +7244,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7232
7244
  }, {
7233
7245
  cameraState: e
7234
7246
  });
7235
- D = _.x - I.x, O = _.y - I.y, u.x += D, u.y += O;
7247
+ D = _.x - P.x, O = _.y - P.y, u.x += D, u.y += O;
7236
7248
  }
7237
7249
  return u;
7238
7250
  }
@@ -7246,12 +7258,12 @@ var Pu = /* @__PURE__ */ (function(n) {
7246
7258
  value: function() {
7247
7259
  if (!this.settings.renderLabels) return this;
7248
7260
  var e = this.camera.getState(), i = this.labelGrid.getLabelsToDisplay(e.ratio, this.settings.labelDensity);
7249
- On(i, this.nodesWithForcedLabels), this.displayedNodeLabels = /* @__PURE__ */ new Set();
7261
+ zn(i, this.nodesWithForcedLabels), this.displayedNodeLabels = /* @__PURE__ */ new Set();
7250
7262
  for (var a = this.canvasContexts.labels, o = 0, s = i.length; o < s; o++) {
7251
7263
  var u = i[o], l = this.nodeDataCache[u];
7252
7264
  if (!this.displayedNodeLabels.has(u) && !l.hidden) {
7253
7265
  var c = this.framedGraphToViewport(l), h = c.x, v = c.y, y = this.scaleSize(l.size);
7254
- if (!(!l.forceLabel && y < this.settings.labelRenderedSizeThreshold) && !(h < -Mn || h > this.width + Mn || v < -Bn || v > this.height + Bn)) {
7266
+ if (!(!l.forceLabel && y < this.settings.labelRenderedSizeThreshold) && !(h < -Bn || h > this.width + Bn || v < -Wn || v > this.height + Wn)) {
7255
7267
  this.displayedNodeLabels.add(u);
7256
7268
  var b = this.settings.defaultDrawNodeLabel, R = this.nodePrograms[l.type], w = R?.drawLabel || b;
7257
7269
  w(a, j(j({
@@ -7278,13 +7290,13 @@ var Pu = /* @__PURE__ */ (function(n) {
7278
7290
  if (!this.settings.renderEdgeLabels) return this;
7279
7291
  var e = this.canvasContexts.edgeLabels;
7280
7292
  e.clearRect(0, 0, this.width, this.height);
7281
- var i = Du({
7293
+ var i = Fu({
7282
7294
  graph: this.graph,
7283
7295
  hoveredNode: this.hoveredNode,
7284
7296
  displayedNodeLabels: this.displayedNodeLabels,
7285
7297
  highlightedNodes: this.highlightedNodes
7286
7298
  });
7287
- On(i, this.edgesWithForcedLabels);
7299
+ zn(i, this.edgesWithForcedLabels);
7288
7300
  for (var a = /* @__PURE__ */ new Set(), o = 0, s = i.length; o < s; o++) {
7289
7301
  var u = i[o], l = this.graph.extremities(u), c = this.nodeDataCache[l[0]], h = this.nodeDataCache[l[1]], v = this.edgeDataCache[u];
7290
7302
  if (!a.has(u) && !(v.hidden || c.hidden || h.hidden)) {
@@ -7377,7 +7389,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7377
7389
  return e.resetWebGLTexture(w);
7378
7390
  }), !this.graph.order) return i();
7379
7391
  var a = this.mouseCaptor, o = this.camera.isAnimated() || a.isMoving || a.draggedEvents || a.currentWheelDirection, s = this.camera.getState(), u = this.getDimensions(), l = this.getGraphDimensions(), c = this.getStagePadding();
7380
- this.matrix = gt(s, u, l, c), this.invMatrix = gt(s, u, l, c, !0), this.correctionRatio = hu(this.matrix, s, u), this.graphToViewportRatio = this.getGraphToViewportRatio();
7392
+ this.matrix = gt(s, u, l, c), this.invMatrix = gt(s, u, l, c, !0), this.correctionRatio = vu(this.matrix, s, u), this.graphToViewportRatio = this.getGraphToViewportRatio();
7381
7393
  var h = this.getRenderParams();
7382
7394
  for (var v in this.nodePrograms) {
7383
7395
  var y = this.nodePrograms[v];
@@ -7400,7 +7412,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7400
7412
  value: function(e) {
7401
7413
  var i = Object.assign({}, this.graph.getNodeAttributes(e));
7402
7414
  this.settings.nodeReducer && (i = this.settings.nodeReducer(e, i));
7403
- var a = Lu(this.settings, e, i);
7415
+ var a = Ou(this.settings, e, i);
7404
7416
  this.nodeDataCache[e] = a, this.nodesWithForcedLabels.delete(e), a.forceLabel && !a.hidden && this.nodesWithForcedLabels.add(e), this.highlightedNodes.delete(e), a.highlighted && !a.hidden && this.highlightedNodes.add(e), this.settings.zIndex && (a.zIndex < this.nodeZExtent[0] && (this.nodeZExtent[0] = a.zIndex), a.zIndex > this.nodeZExtent[1] && (this.nodeZExtent[1] = a.zIndex));
7405
7417
  }
7406
7418
  /**
@@ -7435,7 +7447,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7435
7447
  value: function(e) {
7436
7448
  var i = Object.assign({}, this.graph.getEdgeAttributes(e));
7437
7449
  this.settings.edgeReducer && (i = this.settings.edgeReducer(e, i));
7438
- var a = Gu(this.settings, e, i);
7450
+ var a = zu(this.settings, e, i);
7439
7451
  this.edgeDataCache[e] = a, this.edgesWithForcedLabels.delete(e), a.forceLabel && !a.hidden && this.edgesWithForcedLabels.add(e), this.settings.zIndex && (a.zIndex < this.edgeZExtent[0] && (this.edgeZExtent[0] = a.zIndex), a.zIndex > this.edgeZExtent[1] && (this.edgeZExtent[1] = a.zIndex));
7440
7452
  }
7441
7453
  /**
@@ -7465,7 +7477,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7465
7477
  }, {
7466
7478
  key: "clearNodeIndices",
7467
7479
  value: function() {
7468
- this.labelGrid = new $n(), this.nodeExtent = {
7480
+ this.labelGrid = new Mn(), this.nodeExtent = {
7469
7481
  x: [0, 1],
7470
7482
  y: [0, 1]
7471
7483
  }, this.nodeDataCache = {}, this.edgeProgramIndex = {}, this.nodesWithForcedLabels = /* @__PURE__ */ new Set(), this.nodeZExtent = [1 / 0, -1 / 0], this.highlightedNodes = /* @__PURE__ */ new Set();
@@ -7595,7 +7607,7 @@ var Pu = /* @__PURE__ */ (function(n) {
7595
7607
  value: function(e, i) {
7596
7608
  var a = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
7597
7609
  if (this.elements[e]) throw new Error('Sigma: a layer named "'.concat(e, '" already exists'));
7598
- var o = gu(i, {
7610
+ var o = bu(i, {
7599
7611
  position: "absolute"
7600
7612
  }, {
7601
7613
  class: "sigma-".concat(e)
@@ -8210,36 +8222,36 @@ var Pu = /* @__PURE__ */ (function(n) {
8210
8222
  return e;
8211
8223
  }
8212
8224
  }]);
8213
- })(Xr), Iu = Pu;
8225
+ })(Kr), Uu = Nu;
8214
8226
  function Gr(n, r) {
8215
8227
  (r == null || r > n.length) && (r = n.length);
8216
8228
  for (var t = 0, e = Array(r); t < r; t++) e[t] = n[t];
8217
8229
  return e;
8218
8230
  }
8219
- function Fu(n) {
8231
+ function $u(n) {
8220
8232
  if (Array.isArray(n)) return Gr(n);
8221
8233
  }
8222
- function Ou(n) {
8234
+ function Mu(n) {
8223
8235
  if (typeof Symbol < "u" && n[Symbol.iterator] != null || n["@@iterator"] != null) return Array.from(n);
8224
8236
  }
8225
- function zu(n, r) {
8237
+ function Bu(n, r) {
8226
8238
  if (n) {
8227
8239
  if (typeof n == "string") return Gr(n, r);
8228
8240
  var t = {}.toString.call(n).slice(8, -1);
8229
8241
  return t === "Object" && n.constructor && (t = n.constructor.name), t === "Map" || t === "Set" ? Array.from(n) : t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? Gr(n, r) : void 0;
8230
8242
  }
8231
8243
  }
8232
- function Nu() {
8244
+ function Wu() {
8233
8245
  throw new TypeError(`Invalid attempt to spread non-iterable instance.
8234
8246
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
8235
8247
  }
8236
8248
  function Yr(n) {
8237
- return Fu(n) || Ou(n) || zu(n) || Nu();
8249
+ return $u(n) || Mu(n) || Bu(n) || Wu();
8238
8250
  }
8239
8251
  function Zr(n, r) {
8240
8252
  if (!(n instanceof r)) throw new TypeError("Cannot call a class as a function");
8241
8253
  }
8242
- function Uu(n, r) {
8254
+ function Hu(n, r) {
8243
8255
  if (typeof n != "object" || !n) return n;
8244
8256
  var t = n[Symbol.toPrimitive];
8245
8257
  if (t !== void 0) {
@@ -8249,18 +8261,18 @@ function Uu(n, r) {
8249
8261
  }
8250
8262
  return (r === "string" ? String : Number)(n);
8251
8263
  }
8252
- function Ji(n) {
8253
- var r = Uu(n, "string");
8264
+ function ea(n) {
8265
+ var r = Hu(n, "string");
8254
8266
  return typeof r == "symbol" ? r : r + "";
8255
8267
  }
8256
- function $u(n, r) {
8268
+ function ju(n, r) {
8257
8269
  for (var t = 0; t < r.length; t++) {
8258
8270
  var e = r[t];
8259
- e.enumerable = e.enumerable || !1, e.configurable = !0, "value" in e && (e.writable = !0), Object.defineProperty(n, Ji(e.key), e);
8271
+ e.enumerable = e.enumerable || !1, e.configurable = !0, "value" in e && (e.writable = !0), Object.defineProperty(n, ea(e.key), e);
8260
8272
  }
8261
8273
  }
8262
8274
  function Qr(n, r, t) {
8263
- return r && $u(n.prototype, r), Object.defineProperty(n, "prototype", {
8275
+ return r && ju(n.prototype, r), Object.defineProperty(n, "prototype", {
8264
8276
  writable: !1
8265
8277
  }), n;
8266
8278
  }
@@ -8269,13 +8281,13 @@ function at(n) {
8269
8281
  return r.__proto__ || Object.getPrototypeOf(r);
8270
8282
  }, at(n);
8271
8283
  }
8272
- function ea() {
8284
+ function ta() {
8273
8285
  try {
8274
8286
  var n = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
8275
8287
  }));
8276
8288
  } catch {
8277
8289
  }
8278
- return (ea = function() {
8290
+ return (ta = function() {
8279
8291
  return !!n;
8280
8292
  })();
8281
8293
  }
@@ -8283,39 +8295,39 @@ function Ce(n) {
8283
8295
  if (n === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
8284
8296
  return n;
8285
8297
  }
8286
- function Mu(n, r) {
8298
+ function Vu(n, r) {
8287
8299
  if (r && (typeof r == "object" || typeof r == "function")) return r;
8288
8300
  if (r !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
8289
8301
  return Ce(n);
8290
8302
  }
8291
- function ta(n, r, t) {
8292
- return r = at(r), Mu(n, ea() ? Reflect.construct(r, t || [], at(n).constructor) : r.apply(n, t));
8303
+ function ra(n, r, t) {
8304
+ return r = at(r), Vu(n, ta() ? Reflect.construct(r, t || [], at(n).constructor) : r.apply(n, t));
8293
8305
  }
8294
- function Bu(n, r) {
8306
+ function qu(n, r) {
8295
8307
  for (; !{}.hasOwnProperty.call(n, r) && (n = at(n)) !== null; ) ;
8296
8308
  return n;
8297
8309
  }
8298
- function Pr() {
8299
- return Pr = typeof Reflect < "u" && Reflect.get ? Reflect.get.bind() : function(n, r, t) {
8300
- var e = Bu(n, r);
8310
+ function Ir() {
8311
+ return Ir = typeof Reflect < "u" && Reflect.get ? Reflect.get.bind() : function(n, r, t) {
8312
+ var e = qu(n, r);
8301
8313
  if (e) {
8302
8314
  var i = Object.getOwnPropertyDescriptor(e, r);
8303
8315
  return i.get ? i.get.call(arguments.length < 3 ? n : t) : i.value;
8304
8316
  }
8305
- }, Pr.apply(null, arguments);
8317
+ }, Ir.apply(null, arguments);
8306
8318
  }
8307
- function Wn(n, r, t, e) {
8308
- var i = Pr(at(n.prototype), r, t);
8319
+ function Hn(n, r, t, e) {
8320
+ var i = Ir(at(n.prototype), r, t);
8309
8321
  return typeof i == "function" ? function(a) {
8310
8322
  return i.apply(t, a);
8311
8323
  } : i;
8312
8324
  }
8313
- function Ir(n, r) {
8314
- return Ir = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, e) {
8325
+ function Pr(n, r) {
8326
+ return Pr = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, e) {
8315
8327
  return t.__proto__ = e, t;
8316
- }, Ir(n, r);
8328
+ }, Pr(n, r);
8317
8329
  }
8318
- function ra(n, r) {
8330
+ function na(n, r) {
8319
8331
  if (typeof r != "function" && r !== null) throw new TypeError("Super expression must either be null or a function");
8320
8332
  n.prototype = Object.create(r && r.prototype, {
8321
8333
  constructor: {
@@ -8325,17 +8337,17 @@ function ra(n, r) {
8325
8337
  }
8326
8338
  }), Object.defineProperty(n, "prototype", {
8327
8339
  writable: !1
8328
- }), r && Ir(n, r);
8340
+ }), r && Pr(n, r);
8329
8341
  }
8330
8342
  function fe(n, r, t) {
8331
- return (r = Ji(r)) in n ? Object.defineProperty(n, r, {
8343
+ return (r = ea(r)) in n ? Object.defineProperty(n, r, {
8332
8344
  value: t,
8333
8345
  enumerable: !0,
8334
8346
  configurable: !0,
8335
8347
  writable: !0
8336
8348
  }) : n[r] = t, n;
8337
8349
  }
8338
- function Wu(n, r) {
8350
+ function Ku(n, r) {
8339
8351
  if (n == null) return {};
8340
8352
  var t = {};
8341
8353
  for (var e in n) if ({}.hasOwnProperty.call(n, e)) {
@@ -8344,16 +8356,16 @@ function Wu(n, r) {
8344
8356
  }
8345
8357
  return t;
8346
8358
  }
8347
- function Hu(n, r) {
8359
+ function Xu(n, r) {
8348
8360
  if (n == null) return {};
8349
- var t, e, i = Wu(n, r);
8361
+ var t, e, i = Ku(n, r);
8350
8362
  if (Object.getOwnPropertySymbols) {
8351
8363
  var a = Object.getOwnPropertySymbols(n);
8352
8364
  for (e = 0; e < a.length; e++) t = a[e], r.includes(t) || {}.propertyIsEnumerable.call(n, t) && (i[t] = n[t]);
8353
8365
  }
8354
8366
  return i;
8355
8367
  }
8356
- function Hn(n, r) {
8368
+ function jn(n, r) {
8357
8369
  var t = Object.keys(n);
8358
8370
  if (Object.getOwnPropertySymbols) {
8359
8371
  var e = Object.getOwnPropertySymbols(n);
@@ -8366,15 +8378,15 @@ function Hn(n, r) {
8366
8378
  function me(n) {
8367
8379
  for (var r = 1; r < arguments.length; r++) {
8368
8380
  var t = arguments[r] != null ? arguments[r] : {};
8369
- r % 2 ? Hn(Object(t), !0).forEach(function(e) {
8381
+ r % 2 ? jn(Object(t), !0).forEach(function(e) {
8370
8382
  fe(n, e, t[e]);
8371
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Hn(Object(t)).forEach(function(e) {
8383
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : jn(Object(t)).forEach(function(e) {
8372
8384
  Object.defineProperty(n, e, Object.getOwnPropertyDescriptor(t, e));
8373
8385
  });
8374
8386
  }
8375
8387
  return n;
8376
8388
  }
8377
- function ju(n) {
8389
+ function Yu(n) {
8378
8390
  var r = n.texturesCount, t = (
8379
8391
  /*glsl*/
8380
8392
  `
@@ -8481,7 +8493,7 @@ void main(void) {
8481
8493
  );
8482
8494
  return t;
8483
8495
  }
8484
- var Vu = (
8496
+ var Zu = (
8485
8497
  /*glsl*/
8486
8498
  `
8487
8499
  attribute vec4 a_id;
@@ -8533,9 +8545,9 @@ void main() {
8533
8545
  v_color.a *= bias;
8534
8546
  }
8535
8547
  `
8536
- ), qu = Vu;
8537
- function Ke() {
8538
- Ke = function() {
8548
+ ), Qu = Zu;
8549
+ function Xe() {
8550
+ Xe = function() {
8539
8551
  return r;
8540
8552
  };
8541
8553
  var n, r = {}, t = Object.prototype, e = t.hasOwnProperty, i = Object.defineProperty || function(T, f, d) {
@@ -8557,10 +8569,10 @@ function Ke() {
8557
8569
  };
8558
8570
  }
8559
8571
  function c(T, f, d, U) {
8560
- var $ = f && f.prototype instanceof k ? f : k, P = Object.create($.prototype), A = new W(U || []);
8561
- return i(P, "_invoke", {
8572
+ var $ = f && f.prototype instanceof k ? f : k, I = Object.create($.prototype), A = new W(U || []);
8573
+ return i(I, "_invoke", {
8562
8574
  value: D(T, d, A)
8563
- }), P;
8575
+ }), I;
8564
8576
  }
8565
8577
  function h(T, f, d) {
8566
8578
  try {
@@ -8587,7 +8599,7 @@ function Ke() {
8587
8599
  l(p, o, function() {
8588
8600
  return this;
8589
8601
  });
8590
- var C = Object.getPrototypeOf, L = C && C(C(X([])));
8602
+ var C = Object.getPrototypeOf, L = C && C(C(K([])));
8591
8603
  L && L !== t && e.call(L, o) && (p = L);
8592
8604
  var g = m.prototype = k.prototype = Object.create(p);
8593
8605
  function x(T) {
@@ -8598,8 +8610,8 @@ function Ke() {
8598
8610
  });
8599
8611
  }
8600
8612
  function S(T, f) {
8601
- function d($, P, A, z) {
8602
- var Z = h(T[$], T, P);
8613
+ function d($, I, A, z) {
8614
+ var Z = h(T[$], T, I);
8603
8615
  if (Z.type !== "throw") {
8604
8616
  var te = Z.arg, oe = te.value;
8605
8617
  return oe && typeof oe == "object" && e.call(oe, "__await") ? f.resolve(oe.__await).then(function(ne) {
@@ -8616,10 +8628,10 @@ function Ke() {
8616
8628
  }
8617
8629
  var U;
8618
8630
  i(this, "_invoke", {
8619
- value: function($, P) {
8631
+ value: function($, I) {
8620
8632
  function A() {
8621
8633
  return new f(function(z, Z) {
8622
- d($, P, z, Z);
8634
+ d($, I, z, Z);
8623
8635
  });
8624
8636
  }
8625
8637
  return U = U ? U.then(A, A) : A();
@@ -8628,16 +8640,16 @@ function Ke() {
8628
8640
  }
8629
8641
  function D(T, f, d) {
8630
8642
  var U = v;
8631
- return function($, P) {
8643
+ return function($, I) {
8632
8644
  if (U === b) throw Error("Generator is already running");
8633
8645
  if (U === R) {
8634
- if ($ === "throw") throw P;
8646
+ if ($ === "throw") throw I;
8635
8647
  return {
8636
8648
  value: n,
8637
8649
  done: !0
8638
8650
  };
8639
8651
  }
8640
- for (d.method = $, d.arg = P; ; ) {
8652
+ for (d.method = $, d.arg = I; ; ) {
8641
8653
  var A = d.delegate;
8642
8654
  if (A) {
8643
8655
  var z = O(A, d);
@@ -8669,10 +8681,10 @@ function Ke() {
8669
8681
  if (U === n) return f.delegate = null, d === "throw" && T.iterator.return && (f.method = "return", f.arg = n, O(T, f), f.method === "throw") || d !== "return" && (f.method = "throw", f.arg = new TypeError("The iterator does not provide a '" + d + "' method")), w;
8670
8682
  var $ = h(U, T.iterator, f.arg);
8671
8683
  if ($.type === "throw") return f.method = "throw", f.arg = $.arg, f.delegate = null, w;
8672
- var P = $.arg;
8673
- return P ? P.done ? (f[T.resultName] = P.value, f.next = T.nextLoc, f.method !== "return" && (f.method = "next", f.arg = n), f.delegate = null, w) : P : (f.method = "throw", f.arg = new TypeError("iterator result is not an object"), f.delegate = null, w);
8684
+ var I = $.arg;
8685
+ return I ? I.done ? (f[T.resultName] = I.value, f.next = T.nextLoc, f.method !== "return" && (f.method = "next", f.arg = n), f.delegate = null, w) : I : (f.method = "throw", f.arg = new TypeError("iterator result is not an object"), f.delegate = null, w);
8674
8686
  }
8675
- function I(T) {
8687
+ function P(T) {
8676
8688
  var f = {
8677
8689
  tryLoc: T[0]
8678
8690
  };
@@ -8685,9 +8697,9 @@ function Ke() {
8685
8697
  function W(T) {
8686
8698
  this.tryEntries = [{
8687
8699
  tryLoc: "root"
8688
- }], T.forEach(I, this), this.reset(!0);
8700
+ }], T.forEach(P, this), this.reset(!0);
8689
8701
  }
8690
- function X(T) {
8702
+ function K(T) {
8691
8703
  if (T || T === "") {
8692
8704
  var f = T[o];
8693
8705
  if (f) return f.call(T);
@@ -8721,9 +8733,9 @@ function Ke() {
8721
8733
  return this;
8722
8734
  }), r.AsyncIterator = S, r.async = function(T, f, d, U, $) {
8723
8735
  $ === void 0 && ($ = Promise);
8724
- var P = new S(c(T, f, d, U), $);
8725
- return r.isGeneratorFunction(f) ? P : P.next().then(function(A) {
8726
- return A.done ? A.value : P.next();
8736
+ var I = new S(c(T, f, d, U), $);
8737
+ return r.isGeneratorFunction(f) ? I : I.next().then(function(A) {
8738
+ return A.done ? A.value : I.next();
8727
8739
  });
8728
8740
  }, x(g), l(g, u, "Generator"), l(g, o, function() {
8729
8741
  return this;
@@ -8734,12 +8746,12 @@ function Ke() {
8734
8746
  for (var U in f) d.push(U);
8735
8747
  return d.reverse(), function $() {
8736
8748
  for (; d.length; ) {
8737
- var P = d.pop();
8738
- if (P in f) return $.value = P, $.done = !1, $;
8749
+ var I = d.pop();
8750
+ if (I in f) return $.value = I, $.done = !1, $;
8739
8751
  }
8740
8752
  return $.done = !0, $;
8741
8753
  };
8742
- }, r.values = X, W.prototype = {
8754
+ }, r.values = K, W.prototype = {
8743
8755
  constructor: W,
8744
8756
  reset: function(T) {
8745
8757
  if (this.prev = 0, this.next = 0, this.sent = this._sent = n, this.done = !1, this.delegate = null, this.method = "next", this.arg = n, this.tryEntries.forEach(_), !T) for (var f in this) f.charAt(0) === "t" && e.call(this, f) && !isNaN(+f.slice(1)) && (this[f] = n);
@@ -8754,10 +8766,10 @@ function Ke() {
8754
8766
  if (this.done) throw T;
8755
8767
  var f = this;
8756
8768
  function d(Z, te) {
8757
- return P.type = "throw", P.arg = T, f.next = Z, te && (f.method = "next", f.arg = n), !!te;
8769
+ return I.type = "throw", I.arg = T, f.next = Z, te && (f.method = "next", f.arg = n), !!te;
8758
8770
  }
8759
8771
  for (var U = this.tryEntries.length - 1; U >= 0; --U) {
8760
- var $ = this.tryEntries[U], P = $.completion;
8772
+ var $ = this.tryEntries[U], I = $.completion;
8761
8773
  if ($.tryLoc === "root") return d("end");
8762
8774
  if ($.tryLoc <= this.prev) {
8763
8775
  var A = e.call($, "catchLoc"), z = e.call($, "finallyLoc");
@@ -8782,8 +8794,8 @@ function Ke() {
8782
8794
  }
8783
8795
  }
8784
8796
  $ && (T === "break" || T === "continue") && $.tryLoc <= f && f <= $.finallyLoc && ($ = null);
8785
- var P = $ ? $.completion : {};
8786
- return P.type = T, P.arg = f, $ ? (this.method = "next", this.next = $.finallyLoc, w) : this.complete(P);
8797
+ var I = $ ? $.completion : {};
8798
+ return I.type = T, I.arg = f, $ ? (this.method = "next", this.next = $.finallyLoc, w) : this.complete(I);
8787
8799
  },
8788
8800
  complete: function(T, f) {
8789
8801
  if (T.type === "throw") throw T.arg;
@@ -8811,14 +8823,14 @@ function Ke() {
8811
8823
  },
8812
8824
  delegateYield: function(T, f, d) {
8813
8825
  return this.delegate = {
8814
- iterator: X(T),
8826
+ iterator: K(T),
8815
8827
  resultName: f,
8816
8828
  nextLoc: d
8817
8829
  }, this.method === "next" && (this.arg = n), w;
8818
8830
  }
8819
8831
  }, r;
8820
8832
  }
8821
- function jn(n, r, t, e, i, a, o) {
8833
+ function Vn(n, r, t, e, i, a, o) {
8822
8834
  try {
8823
8835
  var s = n[a](o), u = s.value;
8824
8836
  } catch (l) {
@@ -8832,10 +8844,10 @@ function Jr(n) {
8832
8844
  return new Promise(function(e, i) {
8833
8845
  var a = n.apply(r, t);
8834
8846
  function o(u) {
8835
- jn(a, e, i, o, s, "next", u);
8847
+ Vn(a, e, i, o, s, "next", u);
8836
8848
  }
8837
8849
  function s(u) {
8838
- jn(a, e, i, o, s, "throw", u);
8850
+ Vn(a, e, i, o, s, "throw", u);
8839
8851
  }
8840
8852
  o(void 0);
8841
8853
  });
@@ -8851,7 +8863,7 @@ var en = {
8851
8863
  maxTextureSize: 4096,
8852
8864
  debounceTimeout: 500,
8853
8865
  crossOrigin: "anonymous"
8854
- }, Xu = 1;
8866
+ }, Ju = 1;
8855
8867
  function Fr(n) {
8856
8868
  var r = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, t = r.crossOrigin;
8857
8869
  return new Promise(function(e, i) {
@@ -8867,13 +8879,13 @@ function Fr(n) {
8867
8879
  }), t && a.setAttribute("crossOrigin", t), a.src = n;
8868
8880
  });
8869
8881
  }
8870
- function Ku(n) {
8882
+ function el(n) {
8871
8883
  return Or.apply(this, arguments);
8872
8884
  }
8873
8885
  function Or() {
8874
- return Or = Jr(/* @__PURE__ */ Ke().mark(function n(r) {
8886
+ return Or = Jr(/* @__PURE__ */ Xe().mark(function n(r) {
8875
8887
  var t, e, i, a, o, s, u, l, c, h, v, y, b, R = arguments;
8876
- return Ke().wrap(function(k) {
8888
+ return Xe().wrap(function(k) {
8877
8889
  for (; ; ) switch (k.prev = k.next) {
8878
8890
  case 0:
8879
8891
  if (t = R.length > 1 && R[1] !== void 0 ? R[1] : {}, e = t.size, i = t.crossOrigin, i !== "use-credentials") {
@@ -8911,20 +8923,20 @@ function Or() {
8911
8923
  }, n);
8912
8924
  })), Or.apply(this, arguments);
8913
8925
  }
8914
- function Yu(n) {
8926
+ function tl(n) {
8915
8927
  return zr.apply(this, arguments);
8916
8928
  }
8917
8929
  function zr() {
8918
- return zr = Jr(/* @__PURE__ */ Ke().mark(function n(r) {
8930
+ return zr = Jr(/* @__PURE__ */ Xe().mark(function n(r) {
8919
8931
  var t, e, i, a, o, s, u = arguments;
8920
- return Ke().wrap(function(c) {
8932
+ return Xe().wrap(function(c) {
8921
8933
  for (; ; ) switch (c.prev = c.next) {
8922
8934
  case 0:
8923
8935
  if (e = u.length > 1 && u[1] !== void 0 ? u[1] : {}, i = e.size, a = e.crossOrigin, o = ((t = r.split(/[#?]/)[0].split(".").pop()) === null || t === void 0 ? void 0 : t.trim().toLowerCase()) === "svg", !(o && i)) {
8924
8936
  c.next = 16;
8925
8937
  break;
8926
8938
  }
8927
- return c.prev = 3, c.next = 6, Ku(r, {
8939
+ return c.prev = 3, c.next = 6, el(r, {
8928
8940
  size: i,
8929
8941
  crossOrigin: a
8930
8942
  });
@@ -8955,7 +8967,7 @@ function zr() {
8955
8967
  }, n, null, [[3, 9]]);
8956
8968
  })), zr.apply(this, arguments);
8957
8969
  }
8958
- function Zu(n, r, t) {
8970
+ function rl(n, r, t) {
8959
8971
  var e = t.objectFit, i = t.size, a = t.correctCentering, o = e === "contain" ? Math.max(n.width, n.height) : Math.min(n.width, n.height), s = i.mode === "auto" ? o : i.mode === "force" ? i.value : Math.min(i.value, o), u = (n.width - o) / 2, l = (n.height - o) / 2;
8960
8972
  if (a) {
8961
8973
  var c = r.getCorrectionOffset(n, o);
@@ -8968,9 +8980,9 @@ function Zu(n, r, t) {
8968
8980
  destinationSize: s
8969
8981
  };
8970
8982
  }
8971
- function Qu(n, r, t) {
8983
+ function nl(n, r, t) {
8972
8984
  for (var e = r.canvas, i = e.width, a = e.height, o = [], s = t.x, u = t.y, l = t.rowHeight, c = t.maxRowWidth, h = {}, v = 0, y = n.length; v < y; v++) {
8973
- var b = n[v], R = b.key, w = b.image, k = b.sourceSize, E = b.sourceX, m = b.sourceY, p = b.destinationSize, C = p + Xu;
8985
+ var b = n[v], R = b.key, w = b.image, k = b.sourceSize, E = b.sourceX, m = b.sourceY, p = b.destinationSize, C = p + Ju;
8974
8986
  u + C > a || s + C > i && u + C + l > a || (s + C > i && (c = Math.max(c, s), s = 0, u += l, l = C), o.push({
8975
8987
  key: R,
8976
8988
  image: w,
@@ -8988,8 +9000,8 @@ function Qu(n, r, t) {
8988
9000
  }
8989
9001
  c = Math.max(c, s);
8990
9002
  for (var L = c, g = u + l, x = 0, S = o.length; x < S; x++) {
8991
- var D = o[x], O = D.image, I = D.sourceSize, _ = D.sourceX, W = D.sourceY, X = D.destinationSize, T = D.destinationX, f = D.destinationY;
8992
- r.drawImage(O, _, W, I, I, T, f, X, X);
9003
+ var D = o[x], O = D.image, P = D.sourceSize, _ = D.sourceX, W = D.sourceY, K = D.destinationSize, T = D.destinationX, f = D.destinationY;
9004
+ r.drawImage(O, _, W, P, P, T, f, K, K);
8993
9005
  }
8994
9006
  return {
8995
9007
  atlas: h,
@@ -9002,7 +9014,7 @@ function Qu(n, r, t) {
9002
9014
  }
9003
9015
  };
9004
9016
  }
9005
- function Ju(n, r, t) {
9017
+ function il(n, r, t) {
9006
9018
  var e = n.atlas, i = n.textures, a = n.cursor, o = {
9007
9019
  atlas: me({}, e),
9008
9020
  textures: Yr(i.slice(0, -1)),
@@ -9018,7 +9030,7 @@ function Ju(n, r, t) {
9018
9030
  }
9019
9031
  }
9020
9032
  for (var v = function() {
9021
- var b = Qu(s, t, o.cursor), R = b.atlas, w = b.texture, k = b.cursor;
9033
+ var b = nl(s, t, o.cursor), R = b.atlas, w = b.texture, k = b.cursor;
9022
9034
  o.cursor = k;
9023
9035
  var E = [];
9024
9036
  s.forEach(function(m) {
@@ -9035,7 +9047,7 @@ function Ju(n, r, t) {
9035
9047
  v();
9036
9048
  return o;
9037
9049
  }
9038
- var el = /* @__PURE__ */ (function() {
9050
+ var al = /* @__PURE__ */ (function() {
9039
9051
  function n() {
9040
9052
  Zr(this, n), this.canvas = document.createElement("canvas"), this.context = this.canvas.getContext("2d", {
9041
9053
  willReadFrequently: !0
@@ -9060,12 +9072,12 @@ var el = /* @__PURE__ */ (function() {
9060
9072
  }
9061
9073
  }]), n;
9062
9074
  })(), $t = /* @__PURE__ */ (function(n) {
9063
- ra(r, n);
9075
+ na(r, n);
9064
9076
  function r() {
9065
9077
  var t, e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
9066
- return Zr(this, r), t = ta(this, r), fe(Ce(t), "canvas", document.createElement("canvas")), fe(Ce(t), "ctx", t.canvas.getContext("2d", {
9078
+ return Zr(this, r), t = ra(this, r), fe(Ce(t), "canvas", document.createElement("canvas")), fe(Ce(t), "ctx", t.canvas.getContext("2d", {
9067
9079
  willReadFrequently: !0
9068
- })), fe(Ce(t), "corrector", new el()), fe(Ce(t), "imageStates", {}), fe(Ce(t), "textures", [t.ctx.getImageData(0, 0, 1, 1)]), fe(Ce(t), "lastTextureCursor", {
9080
+ })), fe(Ce(t), "corrector", new al()), fe(Ce(t), "imageStates", {}), fe(Ce(t), "textures", [t.ctx.getImageData(0, 0, 1, 1)]), fe(Ce(t), "lastTextureCursor", {
9069
9081
  x: 0,
9070
9082
  y: 0,
9071
9083
  rowHeight: 0,
@@ -9083,7 +9095,7 @@ var el = /* @__PURE__ */ (function() {
9083
9095
  }, {
9084
9096
  key: "generateTextures",
9085
9097
  value: function() {
9086
- var e = Ju({
9098
+ var e = il({
9087
9099
  atlas: this.atlas,
9088
9100
  textures: this.textures,
9089
9101
  cursor: this.lastTextureCursor
@@ -9097,9 +9109,9 @@ var el = /* @__PURE__ */ (function() {
9097
9109
  }, {
9098
9110
  key: "registerImage",
9099
9111
  value: (function() {
9100
- var t = Jr(/* @__PURE__ */ Ke().mark(function i(a) {
9112
+ var t = Jr(/* @__PURE__ */ Xe().mark(function i(a) {
9101
9113
  var o, s;
9102
- return Ke().wrap(function(l) {
9114
+ return Xe().wrap(function(l) {
9103
9115
  for (; ; ) switch (l.prev = l.next) {
9104
9116
  case 0:
9105
9117
  if (!this.imageStates[a]) {
@@ -9110,7 +9122,7 @@ var el = /* @__PURE__ */ (function() {
9110
9122
  case 2:
9111
9123
  return this.imageStates[a] = {
9112
9124
  status: "loading"
9113
- }, l.prev = 3, o = this.options.size, l.next = 7, Yu(a, {
9125
+ }, l.prev = 3, o = this.options.size, l.next = 7, tl(a, {
9114
9126
  size: o.mode === "force" ? o.value : void 0,
9115
9127
  crossOrigin: this.options.crossOrigin || void 0
9116
9128
  });
@@ -9118,7 +9130,7 @@ var el = /* @__PURE__ */ (function() {
9118
9130
  s = l.sent, this.imageStates[a] = me({
9119
9131
  status: "ready",
9120
9132
  image: s
9121
- }, Zu(s, this.corrector, this.options)), this.scheduleGenerateTexture(), l.next = 15;
9133
+ }, rl(s, this.corrector, this.options)), this.scheduleGenerateTexture(), l.next = 15;
9122
9134
  break;
9123
9135
  case 12:
9124
9136
  l.prev = 12, l.t0 = l.catch(3), this.imageStates[a] = {
@@ -9148,7 +9160,7 @@ var el = /* @__PURE__ */ (function() {
9148
9160
  }]), r;
9149
9161
  })(Wr.EventEmitter);
9150
9162
  fe($t, "NEW_TEXTURE_EVENT", "newTexture");
9151
- var tl = ["drawHover", "drawLabel", "drawingMode", "keepWithinCircle", "padding", "colorAttribute", "imageAttribute"], na = WebGLRenderingContext, Vn = na.UNSIGNED_BYTE, mt = na.FLOAT, rl = me(me({}, en), {}, {
9163
+ var ol = ["drawHover", "drawLabel", "drawingMode", "keepWithinCircle", "padding", "colorAttribute", "imageAttribute"], ia = WebGLRenderingContext, qn = ia.UNSIGNED_BYTE, mt = ia.FLOAT, sl = me(me({}, en), {}, {
9152
9164
  drawingMode: "background",
9153
9165
  keepWithinCircle: !0,
9154
9166
  drawLabel: void 0,
@@ -9156,18 +9168,18 @@ var tl = ["drawHover", "drawLabel", "drawingMode", "keepWithinCircle", "padding"
9156
9168
  padding: 0,
9157
9169
  colorAttribute: "color",
9158
9170
  imageAttribute: "image"
9159
- }), nl = ["u_sizeRatio", "u_correctionRatio", "u_cameraAngle", "u_percentagePadding", "u_matrix", "u_colorizeImages", "u_keepWithinCircle", "u_atlas"];
9171
+ }), ul = ["u_sizeRatio", "u_correctionRatio", "u_cameraAngle", "u_percentagePadding", "u_matrix", "u_colorizeImages", "u_keepWithinCircle", "u_atlas"];
9160
9172
  function tn(n) {
9161
9173
  var r, t = document.createElement("canvas").getContext("webgl"), e = Math.min(t.getParameter(t.MAX_TEXTURE_SIZE), en.maxTextureSize);
9162
9174
  t.canvas.remove();
9163
- var i = me(me(me({}, rl), {
9175
+ var i = me(me(me({}, sl), {
9164
9176
  maxTextureSize: e
9165
- }), n || {}), a = i.drawHover, o = i.drawLabel, s = i.drawingMode, u = i.keepWithinCircle, l = i.padding, c = i.colorAttribute, h = i.imageAttribute, v = Hu(i, tl), y = new $t(v);
9177
+ }), n || {}), a = i.drawHover, o = i.drawLabel, s = i.drawingMode, u = i.keepWithinCircle, l = i.padding, c = i.colorAttribute, h = i.imageAttribute, v = Xu(i, ol), y = new $t(v);
9166
9178
  return r = /* @__PURE__ */ (function(b) {
9167
- ra(R, b);
9179
+ na(R, b);
9168
9180
  function R(w, k, E) {
9169
9181
  var m;
9170
- return Zr(this, R), m = ta(this, R, [w, k, E]), fe(Ce(m), "drawLabel", o), fe(Ce(m), "drawHover", a), fe(Ce(m), "textureManagerCallback", null), m.textureManagerCallback = function(p) {
9182
+ return Zr(this, R), m = ra(this, R, [w, k, E]), fe(Ce(m), "drawLabel", o), fe(Ce(m), "drawHover", a), fe(Ce(m), "textureManagerCallback", null), m.textureManagerCallback = function(p) {
9171
9183
  var C = p.atlas, L = p.textures, g = L.length !== m.textures.length;
9172
9184
  m.atlas = C, m.textureImages = L, g && m.upgradeShaders(), m.bindTextures(), m.latestRenderParams && m.render(m.latestRenderParams), m.renderer && m.renderer.refresh && m.renderer.refresh();
9173
9185
  }, y.on($t.NEW_TEXTURE_EVENT, m.textureManagerCallback), m.atlas = y.getAtlas(), m.textureImages = y.getTextures(), m.textures = m.textureImages.map(function() {
@@ -9179,12 +9191,12 @@ function tn(n) {
9179
9191
  value: function() {
9180
9192
  return {
9181
9193
  VERTICES: 3,
9182
- VERTEX_SHADER_SOURCE: qu,
9183
- FRAGMENT_SHADER_SOURCE: ju({
9194
+ VERTEX_SHADER_SOURCE: Qu,
9195
+ FRAGMENT_SHADER_SOURCE: Yu({
9184
9196
  texturesCount: y.getTextures().length
9185
9197
  }),
9186
9198
  METHOD: WebGLRenderingContext.TRIANGLES,
9187
- UNIFORMS: nl,
9199
+ UNIFORMS: ul,
9188
9200
  ATTRIBUTES: [{
9189
9201
  name: "a_position",
9190
9202
  size: 2,
@@ -9196,12 +9208,12 @@ function tn(n) {
9196
9208
  }, {
9197
9209
  name: "a_color",
9198
9210
  size: 4,
9199
- type: Vn,
9211
+ type: qn,
9200
9212
  normalized: !0
9201
9213
  }, {
9202
9214
  name: "a_id",
9203
9215
  size: 4,
9204
- type: Vn,
9216
+ type: qn,
9205
9217
  normalized: !0
9206
9218
  }, {
9207
9219
  name: "a_texture",
@@ -9233,7 +9245,7 @@ function tn(n) {
9233
9245
  if (E)
9234
9246
  for (var m = 0; m < this.textures.length; m++)
9235
9247
  E.deleteTexture(this.textures[m]);
9236
- this.textureManagerCallback && (y.off($t.NEW_TEXTURE_EVENT, this.textureManagerCallback), this.textureManagerCallback = null), Wn(R, "kill", this)([]);
9248
+ this.textureManagerCallback && (y.off($t.NEW_TEXTURE_EVENT, this.textureManagerCallback), this.textureManagerCallback = null), Hn(R, "kill", this)([]);
9237
9249
  }
9238
9250
  }, {
9239
9251
  key: "bindTextures",
@@ -9252,7 +9264,7 @@ function tn(n) {
9252
9264
  if (!E.isPicking)
9253
9265
  for (var m = E.gl, p = 0; p < this.textureImages.length; p++)
9254
9266
  m.activeTexture(m.TEXTURE0 + p), m.bindTexture(m.TEXTURE_2D, this.textures[p]);
9255
- Wn(R, "renderProgram", this)([k, E]);
9267
+ Hn(R, "renderProgram", this)([k, E]);
9256
9268
  }
9257
9269
  }, {
9258
9270
  key: "processVisibleItem",
@@ -9267,13 +9279,13 @@ function tn(n) {
9267
9279
  }, {
9268
9280
  key: "setUniforms",
9269
9281
  value: function(k, E) {
9270
- var m = E.gl, p = E.uniformLocations, C = p.u_sizeRatio, L = p.u_correctionRatio, g = p.u_matrix, x = p.u_atlas, S = p.u_colorizeImages, D = p.u_keepWithinCircle, O = p.u_cameraAngle, I = p.u_percentagePadding;
9271
- this.latestRenderParams = k, m.uniform1f(L, k.correctionRatio), m.uniform1f(C, u ? k.sizeRatio : k.sizeRatio / Math.SQRT2), m.uniform1f(O, k.cameraAngle), m.uniform1f(I, l), m.uniformMatrix3fv(g, !1, k.matrix), m.uniform1iv(x, Yr(new Array(this.textureImages.length)).map(function(_, W) {
9282
+ var m = E.gl, p = E.uniformLocations, C = p.u_sizeRatio, L = p.u_correctionRatio, g = p.u_matrix, x = p.u_atlas, S = p.u_colorizeImages, D = p.u_keepWithinCircle, O = p.u_cameraAngle, P = p.u_percentagePadding;
9283
+ this.latestRenderParams = k, m.uniform1f(L, k.correctionRatio), m.uniform1f(C, u ? k.sizeRatio : k.sizeRatio / Math.SQRT2), m.uniform1f(O, k.cameraAngle), m.uniform1f(P, l), m.uniformMatrix3fv(g, !1, k.matrix), m.uniform1iv(x, Yr(new Array(this.textureImages.length)).map(function(_, W) {
9272
9284
  return W;
9273
9285
  })), m.uniform1i(S, s === "color" ? 1 : 0), m.uniform1i(D, u ? 1 : 0);
9274
9286
  }
9275
9287
  }]), R;
9276
- })($i), fe(r, "ANGLE_1", 0), fe(r, "ANGLE_2", 2 * Math.PI / 3), fe(r, "ANGLE_3", 4 * Math.PI / 3), fe(r, "textureManager", y), r;
9288
+ })(Mi), fe(r, "ANGLE_1", 0), fe(r, "ANGLE_2", 2 * Math.PI / 3), fe(r, "ANGLE_3", 4 * Math.PI / 3), fe(r, "textureManager", y), r;
9277
9289
  }
9278
9290
  tn();
9279
9291
  tn({
@@ -9285,7 +9297,7 @@ tn({
9285
9297
  drawingMode: "color",
9286
9298
  correctCentering: !0
9287
9299
  });
9288
- function il(n, r) {
9300
+ function ll(n, r) {
9289
9301
  if (typeof n != "object" || !n) return n;
9290
9302
  var t = n[Symbol.toPrimitive];
9291
9303
  if (t !== void 0) {
@@ -9295,19 +9307,19 @@ function il(n, r) {
9295
9307
  }
9296
9308
  return (r === "string" ? String : Number)(n);
9297
9309
  }
9298
- function ia(n) {
9299
- var r = il(n, "string");
9310
+ function aa(n) {
9311
+ var r = ll(n, "string");
9300
9312
  return typeof r == "symbol" ? r : r + "";
9301
9313
  }
9302
- function aa(n, r, t) {
9303
- return (r = ia(r)) in n ? Object.defineProperty(n, r, {
9314
+ function oa(n, r, t) {
9315
+ return (r = aa(r)) in n ? Object.defineProperty(n, r, {
9304
9316
  value: t,
9305
9317
  enumerable: !0,
9306
9318
  configurable: !0,
9307
9319
  writable: !0
9308
9320
  }) : n[r] = t, n;
9309
9321
  }
9310
- function qn(n, r) {
9322
+ function Kn(n, r) {
9311
9323
  var t = Object.keys(n);
9312
9324
  if (Object.getOwnPropertySymbols) {
9313
9325
  var e = Object.getOwnPropertySymbols(n);
@@ -9320,61 +9332,61 @@ function qn(n, r) {
9320
9332
  function ot(n) {
9321
9333
  for (var r = 1; r < arguments.length; r++) {
9322
9334
  var t = arguments[r] != null ? arguments[r] : {};
9323
- r % 2 ? qn(Object(t), !0).forEach(function(e) {
9324
- aa(n, e, t[e]);
9325
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : qn(Object(t)).forEach(function(e) {
9335
+ r % 2 ? Kn(Object(t), !0).forEach(function(e) {
9336
+ oa(n, e, t[e]);
9337
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(n, Object.getOwnPropertyDescriptors(t)) : Kn(Object(t)).forEach(function(e) {
9326
9338
  Object.defineProperty(n, e, Object.getOwnPropertyDescriptor(t, e));
9327
9339
  });
9328
9340
  }
9329
9341
  return n;
9330
9342
  }
9331
- function al(n, r) {
9343
+ function cl(n, r) {
9332
9344
  if (!(n instanceof r)) throw new TypeError("Cannot call a class as a function");
9333
9345
  }
9334
- function ol(n, r) {
9346
+ function hl(n, r) {
9335
9347
  for (var t = 0; t < r.length; t++) {
9336
9348
  var e = r[t];
9337
- e.enumerable = e.enumerable || !1, e.configurable = !0, "value" in e && (e.writable = !0), Object.defineProperty(n, ia(e.key), e);
9349
+ e.enumerable = e.enumerable || !1, e.configurable = !0, "value" in e && (e.writable = !0), Object.defineProperty(n, aa(e.key), e);
9338
9350
  }
9339
9351
  }
9340
- function sl(n, r, t) {
9341
- return r && ol(n.prototype, r), Object.defineProperty(n, "prototype", {
9352
+ function dl(n, r, t) {
9353
+ return r && hl(n.prototype, r), Object.defineProperty(n, "prototype", {
9342
9354
  writable: !1
9343
9355
  }), n;
9344
9356
  }
9345
- function Bt(n) {
9346
- return Bt = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(r) {
9357
+ function Wt(n) {
9358
+ return Wt = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function(r) {
9347
9359
  return r.__proto__ || Object.getPrototypeOf(r);
9348
- }, Bt(n);
9360
+ }, Wt(n);
9349
9361
  }
9350
- function oa() {
9362
+ function sa() {
9351
9363
  try {
9352
9364
  var n = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function() {
9353
9365
  }));
9354
9366
  } catch {
9355
9367
  }
9356
- return (oa = function() {
9368
+ return (sa = function() {
9357
9369
  return !!n;
9358
9370
  })();
9359
9371
  }
9360
- function sa(n) {
9372
+ function ua(n) {
9361
9373
  if (n === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
9362
9374
  return n;
9363
9375
  }
9364
- function ul(n, r) {
9376
+ function fl(n, r) {
9365
9377
  if (r && (typeof r == "object" || typeof r == "function")) return r;
9366
9378
  if (r !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
9367
- return sa(n);
9379
+ return ua(n);
9368
9380
  }
9369
- function ll(n, r, t) {
9370
- return r = Bt(r), ul(n, oa() ? Reflect.construct(r, t || [], Bt(n).constructor) : r.apply(n, t));
9381
+ function gl(n, r, t) {
9382
+ return r = Wt(r), fl(n, sa() ? Reflect.construct(r, t || [], Wt(n).constructor) : r.apply(n, t));
9371
9383
  }
9372
9384
  function Nr(n, r) {
9373
9385
  return Nr = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, e) {
9374
9386
  return t.__proto__ = e, t;
9375
9387
  }, Nr(n, r);
9376
9388
  }
9377
- function cl(n, r) {
9389
+ function pl(n, r) {
9378
9390
  if (typeof r != "function" && r !== null) throw new TypeError("Super expression must either be null or a function");
9379
9391
  n.prototype = Object.create(r && r.prototype, {
9380
9392
  constructor: {
@@ -9391,66 +9403,66 @@ function Ur(n, r) {
9391
9403
  for (var t = 0, e = Array(r); t < r; t++) e[t] = n[t];
9392
9404
  return e;
9393
9405
  }
9394
- function hl(n) {
9406
+ function vl(n) {
9395
9407
  if (Array.isArray(n)) return Ur(n);
9396
9408
  }
9397
- function dl(n) {
9409
+ function ml(n) {
9398
9410
  if (typeof Symbol < "u" && n[Symbol.iterator] != null || n["@@iterator"] != null) return Array.from(n);
9399
9411
  }
9400
- function fl(n, r) {
9412
+ function yl(n, r) {
9401
9413
  if (n) {
9402
9414
  if (typeof n == "string") return Ur(n, r);
9403
9415
  var t = {}.toString.call(n).slice(8, -1);
9404
9416
  return t === "Object" && n.constructor && (t = n.constructor.name), t === "Map" || t === "Set" ? Array.from(n) : t === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? Ur(n, r) : void 0;
9405
9417
  }
9406
9418
  }
9407
- function gl() {
9419
+ function bl() {
9408
9420
  throw new TypeError(`Invalid attempt to spread non-iterable instance.
9409
9421
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
9410
9422
  }
9411
9423
  function ur(n) {
9412
- return hl(n) || dl(n) || fl(n) || gl();
9424
+ return vl(n) || ml(n) || yl(n) || bl();
9413
9425
  }
9414
- function ua(n, r, t, e) {
9426
+ function la(n, r, t, e) {
9415
9427
  var i = Math.pow(1 - n, 2) * r.x + 2 * (1 - n) * n * t.x + Math.pow(n, 2) * e.x, a = Math.pow(1 - n, 2) * r.y + 2 * (1 - n) * n * t.y + Math.pow(n, 2) * e.y;
9416
9428
  return {
9417
9429
  x: i,
9418
9430
  y: a
9419
9431
  };
9420
9432
  }
9421
- function pl(n, r, t) {
9433
+ function wl(n, r, t) {
9422
9434
  for (var e = 20, i = 0, a = n, o = 0; o < e; o++) {
9423
- var s = ua((o + 1) / e, n, r, t);
9435
+ var s = la((o + 1) / e, n, r, t);
9424
9436
  i += Math.sqrt(Math.pow(a.x - s.x, 2) + Math.pow(a.y - s.y, 2)), a = s;
9425
9437
  }
9426
9438
  return i;
9427
9439
  }
9428
- function vl(n) {
9440
+ function El(n) {
9429
9441
  var r = n.curvatureAttribute, t = n.defaultCurvature, e = n.keepLabelUpright, i = e === void 0 ? !0 : e;
9430
9442
  return function(a, o, s, u, l) {
9431
9443
  var c = l.edgeLabelSize, h = o[r] || t, v = l.edgeLabelFont, y = l.edgeLabelWeight, b = l.edgeLabelColor.attribute ? o[l.edgeLabelColor.attribute] || l.edgeLabelColor.color || "#000" : l.edgeLabelColor.color, R = o.label;
9432
9444
  if (R) {
9433
9445
  a.fillStyle = b, a.font = "".concat(y, " ").concat(c, "px ").concat(v);
9434
- var w = !i || s.x < u.x, k = w ? s.x : u.x, E = w ? s.y : u.y, m = w ? u.x : s.x, p = w ? u.y : s.y, C = (k + m) / 2, L = (E + p) / 2, g = m - k, x = p - E, S = Math.sqrt(Math.pow(g, 2) + Math.pow(x, 2)), D = w ? 1 : -1, O = C + x * h * D, I = L - g * h * D, _ = o.size * 0.7 + 5, W = {
9435
- x: I - E,
9446
+ var w = !i || s.x < u.x, k = w ? s.x : u.x, E = w ? s.y : u.y, m = w ? u.x : s.x, p = w ? u.y : s.y, C = (k + m) / 2, L = (E + p) / 2, g = m - k, x = p - E, S = Math.sqrt(Math.pow(g, 2) + Math.pow(x, 2)), D = w ? 1 : -1, O = C + x * h * D, P = L - g * h * D, _ = o.size * 0.7 + 5, W = {
9447
+ x: P - E,
9436
9448
  y: -(O - k)
9437
- }, X = Math.sqrt(Math.pow(W.x, 2) + Math.pow(W.y, 2)), T = {
9438
- x: p - I,
9449
+ }, K = Math.sqrt(Math.pow(W.x, 2) + Math.pow(W.y, 2)), T = {
9450
+ x: p - P,
9439
9451
  y: -(m - O)
9440
9452
  }, f = Math.sqrt(Math.pow(T.x, 2) + Math.pow(T.y, 2));
9441
- k += _ * W.x / X, E += _ * W.y / X, m += _ * T.x / f, p += _ * T.y / f, O += _ * x / S, I -= _ * g / S;
9453
+ k += _ * W.x / K, E += _ * W.y / K, m += _ * T.x / f, p += _ * T.y / f, O += _ * x / S, P -= _ * g / S;
9442
9454
  var d = {
9443
9455
  x: O,
9444
- y: I
9456
+ y: P
9445
9457
  }, U = {
9446
9458
  x: k,
9447
9459
  y: E
9448
9460
  }, $ = {
9449
9461
  x: m,
9450
9462
  y: p
9451
- }, P = pl(U, d, $);
9452
- if (!(P < s.size + u.size)) {
9453
- var A = a.measureText(R).width, z = P - s.size - u.size;
9463
+ }, I = wl(U, d, $);
9464
+ if (!(I < s.size + u.size)) {
9465
+ var A = a.measureText(R).width, z = I - s.size - u.size;
9454
9466
  if (A > z) {
9455
9467
  var Z = "…";
9456
9468
  for (R = R + Z, A = a.measureText(R).width; A > z && R.length > 1; )
@@ -9461,15 +9473,15 @@ function vl(n) {
9461
9473
  var V = R[oe];
9462
9474
  te[V] || (te[V] = a.measureText(V).width * (1 + h * 0.35));
9463
9475
  }
9464
- for (var se = 0.5 - A / P / 2, ee = 0, re = R.length; ee < re; ee++) {
9465
- var J = R[ee], le = ua(se, U, d, $), q = 2 * (1 - se) * (O - k) + 2 * se * (m - O), B = 2 * (1 - se) * (I - E) + 2 * se * (p - I), G = Math.atan2(B, q);
9466
- a.save(), a.translate(le.x, le.y), a.rotate(G), a.fillText(J, 0, 0), a.restore(), se += te[J] / P;
9476
+ for (var se = 0.5 - A / I / 2, ee = 0, re = R.length; ee < re; ee++) {
9477
+ var J = R[ee], le = la(se, U, d, $), q = 2 * (1 - se) * (O - k) + 2 * se * (m - O), B = 2 * (1 - se) * (P - E) + 2 * se * (p - P), G = Math.atan2(B, q);
9478
+ a.save(), a.translate(le.x, le.y), a.rotate(G), a.fillText(J, 0, 0), a.restore(), se += te[J] / I;
9467
9479
  }
9468
9480
  }
9469
9481
  }
9470
9482
  };
9471
9483
  }
9472
- function ml(n) {
9484
+ function _l(n) {
9473
9485
  var r = n.arrowHead, t = r?.extremity === "target" || r?.extremity === "both", e = r?.extremity === "source" || r?.extremity === "both", i = (
9474
9486
  /*glsl*/
9475
9487
  `
@@ -9551,7 +9563,7 @@ void main(void) {
9551
9563
  );
9552
9564
  return i;
9553
9565
  }
9554
- function yl(n) {
9566
+ function Tl(n) {
9555
9567
  var r = n.arrowHead, t = r?.extremity === "target" || r?.extremity === "both", e = r?.extremity === "source" || r?.extremity === "both", i = (
9556
9568
  /*glsl*/
9557
9569
  `
@@ -9668,22 +9680,22 @@ void main() {
9668
9680
  );
9669
9681
  return i;
9670
9682
  }
9671
- var rn = 0.25, bl = {
9683
+ var rn = 0.25, Sl = {
9672
9684
  arrowHead: null,
9673
9685
  curvatureAttribute: "curvature",
9674
9686
  defaultCurvature: rn
9675
- }, wl = {
9687
+ }, Rl = {
9676
9688
  edgeIndexAttribute: "parallelIndex",
9677
9689
  edgeMinIndexAttribute: "parallelMinIndex",
9678
9690
  edgeMaxIndexAttribute: "parallelMaxIndex"
9679
9691
  };
9680
- function El(n, r) {
9681
- var t = ot(ot({}, wl), {}), e = {}, i = {}, a = {}, o = 0;
9692
+ function Al(n, r) {
9693
+ var t = ot(ot({}, Rl), {}), e = {}, i = {}, a = {}, o = 0;
9682
9694
  n.forEachNode(function(L) {
9683
9695
  e[L] = ++o + "";
9684
9696
  }), n.forEachEdge(function(L, g, x, S) {
9685
- var D = e[x], O = e[S], I = [D, O].join("-");
9686
- i[L] = I, a[I] = [D, O].sort().join("-");
9697
+ var D = e[x], O = e[S], P = [D, O].join("-");
9698
+ i[L] = P, a[P] = [D, O].sort().join("-");
9687
9699
  });
9688
9700
  var s = {}, u = {};
9689
9701
  n.forEachEdge(function(L) {
@@ -9710,25 +9722,25 @@ function El(n, r) {
9710
9722
  }
9711
9723
  }
9712
9724
  }
9713
- var la = WebGLRenderingContext, Xn = la.UNSIGNED_BYTE, Me = la.FLOAT;
9725
+ var ca = WebGLRenderingContext, Xn = ca.UNSIGNED_BYTE, Me = ca.FLOAT;
9714
9726
  function nn(n) {
9715
- var r = ot(ot({}, bl), n || {}), t = r, e = t.arrowHead, i = t.curvatureAttribute, a = t.drawLabel, o = e?.extremity === "target" || e?.extremity === "both", s = e?.extremity === "source" || e?.extremity === "both", u = ["u_matrix", "u_sizeRatio", "u_dimensions", "u_pixelRatio", "u_feather", "u_minEdgeThickness"].concat(ur(e ? ["u_lengthToThicknessRatio", "u_widenessToThicknessRatio"] : []));
9727
+ var r = ot(ot({}, Sl), n || {}), t = r, e = t.arrowHead, i = t.curvatureAttribute, a = t.drawLabel, o = e?.extremity === "target" || e?.extremity === "both", s = e?.extremity === "source" || e?.extremity === "both", u = ["u_matrix", "u_sizeRatio", "u_dimensions", "u_pixelRatio", "u_feather", "u_minEdgeThickness"].concat(ur(e ? ["u_lengthToThicknessRatio", "u_widenessToThicknessRatio"] : []));
9716
9728
  return /* @__PURE__ */ (function(l) {
9717
- cl(c, l);
9729
+ pl(c, l);
9718
9730
  function c() {
9719
9731
  var h;
9720
- al(this, c);
9732
+ cl(this, c);
9721
9733
  for (var v = arguments.length, y = new Array(v), b = 0; b < v; b++)
9722
9734
  y[b] = arguments[b];
9723
- return h = ll(this, c, [].concat(y)), aa(sa(h), "drawLabel", a || vl(r)), h;
9735
+ return h = gl(this, c, [].concat(y)), oa(ua(h), "drawLabel", a || El(r)), h;
9724
9736
  }
9725
- return sl(c, [{
9737
+ return dl(c, [{
9726
9738
  key: "getDefinition",
9727
9739
  value: function() {
9728
9740
  return {
9729
9741
  VERTICES: 6,
9730
- VERTEX_SHADER_SOURCE: yl(r),
9731
- FRAGMENT_SHADER_SOURCE: ml(r),
9742
+ VERTEX_SHADER_SOURCE: Tl(r),
9743
+ FRAGMENT_SHADER_SOURCE: _l(r),
9732
9744
  METHOD: WebGLRenderingContext.TRIANGLES,
9733
9745
  UNIFORMS: u,
9734
9746
  ATTRIBUTES: [{
@@ -9799,20 +9811,20 @@ function nn(n) {
9799
9811
  }
9800
9812
  }
9801
9813
  }]), c;
9802
- })(Ht);
9814
+ })(jt);
9803
9815
  }
9804
- var _l = nn(), Tl = nn({
9805
- arrowHead: jt
9816
+ var kl = nn(), Cl = nn({
9817
+ arrowHead: Vt
9806
9818
  });
9807
9819
  nn({
9808
- arrowHead: ot(ot({}, jt), {}, {
9820
+ arrowHead: ot(ot({}, Vt), {}, {
9809
9821
  extremity: "both"
9810
9822
  })
9811
9823
  });
9812
- var et = {}, lr, Kn;
9813
- function Vt() {
9814
- if (Kn) return lr;
9815
- Kn = 1;
9824
+ var et = {}, lr, Yn;
9825
+ function qt() {
9826
+ if (Yn) return lr;
9827
+ Yn = 1;
9816
9828
  function n(t) {
9817
9829
  return !t || typeof t != "object" || typeof t == "function" || Array.isArray(t) || t instanceof Set || t instanceof Map || t instanceof RegExp || t instanceof Date;
9818
9830
  }
@@ -9831,10 +9843,10 @@ function Vt() {
9831
9843
  }
9832
9844
  return lr = r, lr;
9833
9845
  }
9834
- var cr, Yn;
9835
- function Sl() {
9836
- if (Yn) return cr;
9837
- Yn = 1;
9846
+ var cr, Zn;
9847
+ function xl() {
9848
+ if (Zn) return cr;
9849
+ Zn = 1;
9838
9850
  function n(t) {
9839
9851
  return function(e, i) {
9840
9852
  return e + Math.floor(t() * (i - e + 1));
@@ -9843,11 +9855,11 @@ function Sl() {
9843
9855
  var r = n(Math.random);
9844
9856
  return r.createRandom = n, cr = r, cr;
9845
9857
  }
9846
- var hr, Zn;
9847
- function Rl() {
9848
- if (Zn) return hr;
9849
- Zn = 1;
9850
- var n = Sl().createRandom;
9858
+ var hr, Qn;
9859
+ function Dl() {
9860
+ if (Qn) return hr;
9861
+ Qn = 1;
9862
+ var n = xl().createRandom;
9851
9863
  function r(e) {
9852
9864
  var i = n(e);
9853
9865
  return function(a) {
@@ -9860,11 +9872,11 @@ function Rl() {
9860
9872
  var t = r(Math.random);
9861
9873
  return t.createShuffleInPlace = r, hr = t, hr;
9862
9874
  }
9863
- var dr, Qn;
9864
- function Al() {
9865
- if (Qn) return dr;
9866
- Qn = 1;
9867
- var n = Vt(), r = Ze(), t = Rl(), e = {
9875
+ var dr, Jn;
9876
+ function Ll() {
9877
+ if (Jn) return dr;
9878
+ Jn = 1;
9879
+ var n = qt(), r = Ze(), t = Dl(), e = {
9868
9880
  attributes: {
9869
9881
  x: "x",
9870
9882
  y: "y"
@@ -9920,16 +9932,16 @@ function Al() {
9920
9932
  return new i(null, g.x, g.y, g.r);
9921
9933
  }
9922
9934
  function c(g, x) {
9923
- var S = g.x, D = g.y, O = g.r, I = x.x, _ = x.y, W = x.r, X = I - S, T = _ - D, f = W - O, d = Math.sqrt(X * X + T * T);
9935
+ var S = g.x, D = g.y, O = g.r, P = x.x, _ = x.y, W = x.r, K = P - S, T = _ - D, f = W - O, d = Math.sqrt(K * K + T * T);
9924
9936
  return new i(
9925
9937
  null,
9926
- (S + I + X / d * f) / 2,
9938
+ (S + P + K / d * f) / 2,
9927
9939
  (D + _ + T / d * f) / 2,
9928
9940
  (d + O + W) / 2
9929
9941
  );
9930
9942
  }
9931
9943
  function h(g, x, S) {
9932
- var D = g.x, O = g.y, I = g.r, _ = x.x, W = x.y, X = x.r, T = S.x, f = S.y, d = S.r, U = D - _, $ = D - T, P = O - W, A = O - f, z = X - I, Z = d - I, te = D * D + O * O - I * I, oe = te - _ * _ - W * W + X * X, ne = te - T * T - f * f + d * d, V = $ * P - U * A, se = (P * ne - A * oe) / (V * 2) - D, ee = (A * z - P * Z) / V, re = ($ * oe - U * ne) / (V * 2) - O, J = (U * Z - $ * z) / V, le = ee * ee + J * J - 1, q = 2 * (I + se * ee + re * J), B = se * se + re * re - I * I, G = -(le ? (q + Math.sqrt(q * q - 4 * le * B)) / (2 * le) : B / q);
9944
+ var D = g.x, O = g.y, P = g.r, _ = x.x, W = x.y, K = x.r, T = S.x, f = S.y, d = S.r, U = D - _, $ = D - T, I = O - W, A = O - f, z = K - P, Z = d - P, te = D * D + O * O - P * P, oe = te - _ * _ - W * W + K * K, ne = te - T * T - f * f + d * d, V = $ * I - U * A, se = (I * ne - A * oe) / (V * 2) - D, ee = (A * z - I * Z) / V, re = ($ * oe - U * ne) / (V * 2) - O, J = (U * Z - $ * z) / V, le = ee * ee + J * J - 1, q = 2 * (P + se * ee + re * J), B = se * se + re * re - P * P, G = -(le ? (q + Math.sqrt(q * q - 4 * le * B)) / (2 * le) : B / q);
9933
9945
  return new i(null, D + se + ee * G, O + re + J * G, G);
9934
9946
  }
9935
9947
  function v(g) {
@@ -9959,18 +9971,18 @@ function Al() {
9959
9971
  throw new Error("graphology-layout/circlepack: extendBasis failure !");
9960
9972
  }
9961
9973
  function b(g) {
9962
- var x = g.wrappedCircle, S = g.next.wrappedCircle, D = x.r + S.r, O = (x.x * S.r + S.x * x.r) / D, I = (x.y * S.r + S.y * x.r) / D;
9963
- return O * O + I * I;
9974
+ var x = g.wrappedCircle, S = g.next.wrappedCircle, D = x.r + S.r, O = (x.x * S.r + S.x * x.r) / D, P = (x.y * S.r + S.y * x.r) / D;
9975
+ return O * O + P * P;
9964
9976
  }
9965
9977
  function R(g, x) {
9966
- var S = 0, D = g.slice(), O = g.length, I = [], _, W;
9978
+ var S = 0, D = g.slice(), O = g.length, P = [], _, W;
9967
9979
  for (x(D); S < O; )
9968
- _ = D[S], W && s(W, _) ? ++S : (I = y(I, _), W = v(I), S = 0);
9980
+ _ = D[S], W && s(W, _) ? ++S : (P = y(P, _), W = v(P), S = 0);
9969
9981
  return W;
9970
9982
  }
9971
9983
  function w(g, x, S) {
9972
- var D = g.x - x.x, O, I, _ = g.y - x.y, W, X, T = D * D + _ * _;
9973
- T ? (I = x.r + S.r, I *= I, X = g.r + S.r, X *= X, I > X ? (O = (T + X - I) / (2 * T), W = Math.sqrt(Math.max(0, X / T - O * O)), S.x = g.x - O * D - W * _, S.y = g.y - O * _ + W * D) : (O = (T + I - X) / (2 * T), W = Math.sqrt(Math.max(0, I / T - O * O)), S.x = x.x + O * D - W * _, S.y = x.y + O * _ + W * D)) : (S.x = x.x + S.r, S.y = x.y);
9984
+ var D = g.x - x.x, O, P, _ = g.y - x.y, W, K, T = D * D + _ * _;
9985
+ T ? (P = x.r + S.r, P *= P, K = g.r + S.r, K *= K, P > K ? (O = (T + K - P) / (2 * T), W = Math.sqrt(Math.max(0, K / T - O * O)), S.x = g.x - O * D - W * _, S.y = g.y - O * _ + W * D) : (O = (T + P - K) / (2 * T), W = Math.sqrt(Math.max(0, P / T - O * O)), S.x = x.x + O * D - W * _, S.y = x.y + O * _ + W * D)) : (S.x = x.x + S.r, S.y = x.y);
9974
9986
  }
9975
9987
  function k(g, x) {
9976
9988
  var S = g.r + x.r - 1e-6, D = x.x - g.x, O = x.y - g.y;
@@ -9979,37 +9991,37 @@ function Al() {
9979
9991
  function E(g, x) {
9980
9992
  var S = g.length;
9981
9993
  if (S === 0) return 0;
9982
- var D, O, I, _, W, X, T, f, d, U;
9994
+ var D, O, P, _, W, K, T, f, d, U;
9983
9995
  if (D = g[0], D.x = 0, D.y = 0, S <= 1) return D.r;
9984
9996
  if (O = g[1], D.x = -O.r, O.x = D.r, O.y = 0, S <= 2) return D.r + O.r;
9985
- I = g[2], w(O, D, I), D = new i(null, null, null, null, D), O = new i(null, null, null, null, O), I = new i(null, null, null, null, I), D.next = I.previous = O, O.next = D.previous = I, I.next = O.previous = D;
9986
- e: for (X = 3; X < S; ++X) {
9987
- I = g[X], w(D.wrappedCircle, O.wrappedCircle, I), I = new i(null, null, null, null, I), T = O.next, f = D.previous, d = O.wrappedCircle.r, U = D.wrappedCircle.r;
9997
+ P = g[2], w(O, D, P), D = new i(null, null, null, null, D), O = new i(null, null, null, null, O), P = new i(null, null, null, null, P), D.next = P.previous = O, O.next = D.previous = P, P.next = O.previous = D;
9998
+ e: for (K = 3; K < S; ++K) {
9999
+ P = g[K], w(D.wrappedCircle, O.wrappedCircle, P), P = new i(null, null, null, null, P), T = O.next, f = D.previous, d = O.wrappedCircle.r, U = D.wrappedCircle.r;
9988
10000
  do
9989
10001
  if (d <= U) {
9990
- if (k(T.wrappedCircle, I.wrappedCircle)) {
9991
- O = T, D.next = O, O.previous = D, --X;
10002
+ if (k(T.wrappedCircle, P.wrappedCircle)) {
10003
+ O = T, D.next = O, O.previous = D, --K;
9992
10004
  continue e;
9993
10005
  }
9994
10006
  d += T.wrappedCircle.r, T = T.next;
9995
10007
  } else {
9996
- if (k(f.wrappedCircle, I.wrappedCircle)) {
9997
- D = f, D.next = O, O.previous = D, --X;
10008
+ if (k(f.wrappedCircle, P.wrappedCircle)) {
10009
+ D = f, D.next = O, O.previous = D, --K;
9998
10010
  continue e;
9999
10011
  }
10000
10012
  U += f.wrappedCircle.r, f = f.previous;
10001
10013
  }
10002
10014
  while (T !== f.next);
10003
- for (I.previous = D, I.next = O, D.next = O.previous = O = I, _ = b(D); (I = I.next) !== O; )
10004
- (W = b(I)) < _ && (D = I, _ = W);
10015
+ for (P.previous = D, P.next = O, D.next = O.previous = O = P, _ = b(D); (P = P.next) !== O; )
10016
+ (W = b(P)) < _ && (D = P, _ = W);
10005
10017
  O = D.next;
10006
10018
  }
10007
- D = [O.wrappedCircle], I = O;
10008
- for (var $ = 1e4; (I = I.next) !== O && --$ !== 0; )
10009
- D.push(I.wrappedCircle);
10010
- for (I = R(D, x), X = 0; X < S; ++X)
10011
- D = g[X], D.x -= I.x, D.y -= I.y;
10012
- return I.r;
10019
+ D = [O.wrappedCircle], P = O;
10020
+ for (var $ = 1e4; (P = P.next) !== O && --$ !== 0; )
10021
+ D.push(P.wrappedCircle);
10022
+ for (P = R(D, x), K = 0; K < S; ++K)
10023
+ D = g[K], D.x -= P.x, D.y -= P.y;
10024
+ return P.r;
10013
10025
  }
10014
10026
  function m(g, x) {
10015
10027
  var S = 0;
@@ -10035,17 +10047,17 @@ function Al() {
10035
10047
  "graphology-layout/circlepack: the given graph is not a valid graphology instance."
10036
10048
  );
10037
10049
  S = n(S, e);
10038
- var D = {}, O = {}, I = x.nodes(), _ = S.center, W = S.hierarchyAttributes, X = t.createShuffleInPlace(S.rng), T = S.scale, f = new i();
10050
+ var D = {}, O = {}, P = x.nodes(), _ = S.center, W = S.hierarchyAttributes, K = t.createShuffleInPlace(S.rng), T = S.scale, f = new i();
10039
10051
  x.forEachNode(function(z, Z) {
10040
10052
  var te = Z.size ? Z.size : 1, oe = new i(z, null, null, te), ne = f;
10041
10053
  W.forEach(function(V) {
10042
10054
  var se = Z[V];
10043
10055
  ne = ne.getChild(se);
10044
10056
  }), ne.addChild(z, oe);
10045
- }), p(f, X), a(x, f, D);
10046
- var d = I.length, U, $, P;
10047
- for (P = 0; P < d; P++) {
10048
- var A = I[P];
10057
+ }), p(f, K), a(x, f, D);
10058
+ var d = P.length, U, $, I;
10059
+ for (I = 0; I < d; I++) {
10060
+ var A = P[I];
10049
10061
  U = _ + T * D[A].x, $ = _ + T * D[A].y, O[A] = {
10050
10062
  x: U,
10051
10063
  y: $
@@ -10056,11 +10068,11 @@ function Al() {
10056
10068
  var L = C.bind(null, !1);
10057
10069
  return L.assign = C.bind(null, !0), dr = L, dr;
10058
10070
  }
10059
- var fr, Jn;
10060
- function kl() {
10061
- if (Jn) return fr;
10062
- Jn = 1;
10063
- var n = Vt(), r = Ze(), t = {
10071
+ var fr, ei;
10072
+ function Gl() {
10073
+ if (ei) return fr;
10074
+ ei = 1;
10075
+ var n = qt(), r = Ze(), t = {
10064
10076
  dimensions: ["x", "y"],
10065
10077
  center: 0.5,
10066
10078
  scale: 1
@@ -10097,11 +10109,11 @@ function kl() {
10097
10109
  var i = e.bind(null, !1);
10098
10110
  return i.assign = e.bind(null, !0), fr = i, fr;
10099
10111
  }
10100
- var gr, ei;
10101
- function Cl() {
10102
- if (ei) return gr;
10103
- ei = 1;
10104
- var n = Vt(), r = Ze(), t = {
10112
+ var gr, ti;
10113
+ function Il() {
10114
+ if (ti) return gr;
10115
+ ti = 1;
10116
+ var n = qt(), r = Ze(), t = {
10105
10117
  dimensions: ["x", "y"],
10106
10118
  center: 0.5,
10107
10119
  rng: Math.random,
@@ -10140,11 +10152,11 @@ function Cl() {
10140
10152
  var i = e.bind(null, !1);
10141
10153
  return i.assign = e.bind(null, !0), gr = i, gr;
10142
10154
  }
10143
- var pr, ti;
10144
- function xl() {
10145
- if (ti) return pr;
10146
- ti = 1;
10147
- var n = Vt(), r = Ze(), t = Math.PI / 180, e = {
10155
+ var pr, ri;
10156
+ function Pl() {
10157
+ if (ri) return pr;
10158
+ ri = 1;
10159
+ var n = qt(), r = Ze(), t = Math.PI / 180, e = {
10148
10160
  dimensions: ["x", "y"],
10149
10161
  centeredOnZero: !1,
10150
10162
  degrees: !1
@@ -10192,42 +10204,42 @@ function xl() {
10192
10204
  var a = i.bind(null, !1);
10193
10205
  return a.assign = i.bind(null, !0), pr = a, pr;
10194
10206
  }
10195
- var ri;
10196
- function Dl() {
10197
- return ri || (ri = 1, et.circlepack = Al(), et.circular = kl(), et.random = Cl(), et.rotation = xl()), et;
10207
+ var ni;
10208
+ function Fl() {
10209
+ return ni || (ni = 1, et.circlepack = Ll(), et.circular = Gl(), et.random = Il(), et.rotation = Pl()), et;
10198
10210
  }
10199
- var vr = Dl(), mr, ni;
10200
- function Ll() {
10201
- return ni || (ni = 1, mr = function() {
10211
+ var vr = Fl(), mr, ii;
10212
+ function Ol() {
10213
+ return ii || (ii = 1, mr = function() {
10202
10214
  var r, t, e = {};
10203
10215
  (function() {
10204
- var a = 0, o = 1, s = 2, u = 3, l = 4, c = 5, h = 6, v = 7, y = 8, b = 9, R = 0, w = 1, k = 2, E = 0, m = 1, p = 2, C = 3, L = 4, g = 5, x = 6, S = 7, D = 8, O = 3, I = 10, _ = 3, W = 9, X = 10;
10216
+ var a = 0, o = 1, s = 2, u = 3, l = 4, c = 5, h = 6, v = 7, y = 8, b = 9, R = 0, w = 1, k = 2, E = 0, m = 1, p = 2, C = 3, L = 4, g = 5, x = 6, S = 7, D = 8, O = 3, P = 10, _ = 3, W = 9, K = 10;
10205
10217
  e.exports = function(f, d, U) {
10206
- var $, P, A, z, Z, te, oe, ne, V, se, ee = d.length, re = U.length, J = f.adjustSizes, le = f.barnesHutTheta * f.barnesHutTheta, q, B, G, ie, de, Y, K, F = [];
10207
- for (A = 0; A < ee; A += I)
10218
+ var $, I, A, z, Z, te, oe, ne, V, se, ee = d.length, re = U.length, J = f.adjustSizes, le = f.barnesHutTheta * f.barnesHutTheta, q, B, G, ie, de, Y, X, F = [];
10219
+ for (A = 0; A < ee; A += P)
10208
10220
  d[A + l] = d[A + s], d[A + c] = d[A + u], d[A + s] = 0, d[A + u] = 0;
10209
10221
  if (f.outboundAttractionDistribution) {
10210
- for (q = 0, A = 0; A < ee; A += I)
10222
+ for (q = 0, A = 0; A < ee; A += P)
10211
10223
  q += d[A + h];
10212
- q /= ee / I;
10224
+ q /= ee / P;
10213
10225
  }
10214
10226
  if (f.barnesHutOptimize) {
10215
10227
  var ve = 1 / 0, Le = -1 / 0, ye = 1 / 0, Re = -1 / 0, ce, be, Ue;
10216
- for (A = 0; A < ee; A += I)
10228
+ for (A = 0; A < ee; A += P)
10217
10229
  ve = Math.min(ve, d[A + a]), Le = Math.max(Le, d[A + a]), ye = Math.min(ye, d[A + o]), Re = Math.max(Re, d[A + o]);
10218
10230
  var we = Le - ve, Ge = Re - ye;
10219
- for (we > Ge ? (ye -= (we - Ge) / 2, Re = ye + we) : (ve -= (Ge - we) / 2, Le = ve + Ge), F[0 + E] = -1, F[0 + m] = (ve + Le) / 2, F[0 + p] = (ye + Re) / 2, F[0 + C] = Math.max(Le - ve, Re - ye), F[0 + L] = -1, F[0 + g] = -1, F[0 + x] = 0, F[0 + S] = 0, F[0 + D] = 0, $ = 1, A = 0; A < ee; A += I)
10220
- for (P = 0, Ue = O; ; )
10221
- if (F[P + g] >= 0) {
10222
- d[A + a] < F[P + m] ? d[A + o] < F[P + p] ? ce = F[P + g] : ce = F[P + g] + W : d[A + o] < F[P + p] ? ce = F[P + g] + W * 2 : ce = F[P + g] + W * 3, F[P + S] = (F[P + S] * F[P + x] + d[A + a] * d[A + h]) / (F[P + x] + d[A + h]), F[P + D] = (F[P + D] * F[P + x] + d[A + o] * d[A + h]) / (F[P + x] + d[A + h]), F[P + x] += d[A + h], P = ce;
10231
+ for (we > Ge ? (ye -= (we - Ge) / 2, Re = ye + we) : (ve -= (Ge - we) / 2, Le = ve + Ge), F[0 + E] = -1, F[0 + m] = (ve + Le) / 2, F[0 + p] = (ye + Re) / 2, F[0 + C] = Math.max(Le - ve, Re - ye), F[0 + L] = -1, F[0 + g] = -1, F[0 + x] = 0, F[0 + S] = 0, F[0 + D] = 0, $ = 1, A = 0; A < ee; A += P)
10232
+ for (I = 0, Ue = O; ; )
10233
+ if (F[I + g] >= 0) {
10234
+ d[A + a] < F[I + m] ? d[A + o] < F[I + p] ? ce = F[I + g] : ce = F[I + g] + W : d[A + o] < F[I + p] ? ce = F[I + g] + W * 2 : ce = F[I + g] + W * 3, F[I + S] = (F[I + S] * F[I + x] + d[A + a] * d[A + h]) / (F[I + x] + d[A + h]), F[I + D] = (F[I + D] * F[I + x] + d[A + o] * d[A + h]) / (F[I + x] + d[A + h]), F[I + x] += d[A + h], I = ce;
10223
10235
  continue;
10224
- } else if (F[P + E] < 0) {
10225
- F[P + E] = A;
10236
+ } else if (F[I + E] < 0) {
10237
+ F[I + E] = A;
10226
10238
  break;
10227
10239
  } else {
10228
- if (F[P + g] = $ * W, ne = F[P + C] / 2, V = F[P + g], F[V + E] = -1, F[V + m] = F[P + m] - ne, F[V + p] = F[P + p] - ne, F[V + C] = ne, F[V + L] = V + W, F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, V += W, F[V + E] = -1, F[V + m] = F[P + m] - ne, F[V + p] = F[P + p] + ne, F[V + C] = ne, F[V + L] = V + W, F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, V += W, F[V + E] = -1, F[V + m] = F[P + m] + ne, F[V + p] = F[P + p] - ne, F[V + C] = ne, F[V + L] = V + W, F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, V += W, F[V + E] = -1, F[V + m] = F[P + m] + ne, F[V + p] = F[P + p] + ne, F[V + C] = ne, F[V + L] = F[P + L], F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, $ += 4, d[F[P + E] + a] < F[P + m] ? d[F[P + E] + o] < F[P + p] ? ce = F[P + g] : ce = F[P + g] + W : d[F[P + E] + o] < F[P + p] ? ce = F[P + g] + W * 2 : ce = F[P + g] + W * 3, F[P + x] = d[F[P + E] + h], F[P + S] = d[F[P + E] + a], F[P + D] = d[F[P + E] + o], F[ce + E] = F[P + E], F[P + E] = -1, d[A + a] < F[P + m] ? d[A + o] < F[P + p] ? be = F[P + g] : be = F[P + g] + W : d[A + o] < F[P + p] ? be = F[P + g] + W * 2 : be = F[P + g] + W * 3, ce === be)
10240
+ if (F[I + g] = $ * W, ne = F[I + C] / 2, V = F[I + g], F[V + E] = -1, F[V + m] = F[I + m] - ne, F[V + p] = F[I + p] - ne, F[V + C] = ne, F[V + L] = V + W, F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, V += W, F[V + E] = -1, F[V + m] = F[I + m] - ne, F[V + p] = F[I + p] + ne, F[V + C] = ne, F[V + L] = V + W, F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, V += W, F[V + E] = -1, F[V + m] = F[I + m] + ne, F[V + p] = F[I + p] - ne, F[V + C] = ne, F[V + L] = V + W, F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, V += W, F[V + E] = -1, F[V + m] = F[I + m] + ne, F[V + p] = F[I + p] + ne, F[V + C] = ne, F[V + L] = F[I + L], F[V + g] = -1, F[V + x] = 0, F[V + S] = 0, F[V + D] = 0, $ += 4, d[F[I + E] + a] < F[I + m] ? d[F[I + E] + o] < F[I + p] ? ce = F[I + g] : ce = F[I + g] + W : d[F[I + E] + o] < F[I + p] ? ce = F[I + g] + W * 2 : ce = F[I + g] + W * 3, F[I + x] = d[F[I + E] + h], F[I + S] = d[F[I + E] + a], F[I + D] = d[F[I + E] + o], F[ce + E] = F[I + E], F[I + E] = -1, d[A + a] < F[I + m] ? d[A + o] < F[I + p] ? be = F[I + g] : be = F[I + g] + W : d[A + o] < F[I + p] ? be = F[I + g] + W * 2 : be = F[I + g] + W * 3, ce === be)
10229
10241
  if (Ue--) {
10230
- P = ce;
10242
+ I = ce;
10231
10243
  continue;
10232
10244
  } else {
10233
10245
  Ue = O;
@@ -10238,46 +10250,46 @@ function Ll() {
10238
10250
  }
10239
10251
  }
10240
10252
  if (f.barnesHutOptimize)
10241
- for (B = f.scalingRatio, A = 0; A < ee; A += I)
10242
- for (P = 0; ; )
10243
- if (F[P + g] >= 0)
10253
+ for (B = f.scalingRatio, A = 0; A < ee; A += P)
10254
+ for (I = 0; ; )
10255
+ if (F[I + g] >= 0)
10244
10256
  if (Y = Math.pow(
10245
- d[A + a] - F[P + S],
10257
+ d[A + a] - F[I + S],
10246
10258
  2
10247
10259
  ) + Math.pow(
10248
- d[A + o] - F[P + D],
10260
+ d[A + o] - F[I + D],
10249
10261
  2
10250
- ), se = F[P + C], 4 * se * se / Y < le) {
10251
- if (G = d[A + a] - F[P + S], ie = d[A + o] - F[P + D], J === !0 ? Y > 0 ? (K = B * d[A + h] * F[P + x] / Y, d[A + s] += G * K, d[A + u] += ie * K) : Y < 0 && (K = -B * d[A + h] * F[P + x] / Math.sqrt(Y), d[A + s] += G * K, d[A + u] += ie * K) : Y > 0 && (K = B * d[A + h] * F[P + x] / Y, d[A + s] += G * K, d[A + u] += ie * K), P = F[P + L], P < 0) break;
10262
+ ), se = F[I + C], 4 * se * se / Y < le) {
10263
+ if (G = d[A + a] - F[I + S], ie = d[A + o] - F[I + D], J === !0 ? Y > 0 ? (X = B * d[A + h] * F[I + x] / Y, d[A + s] += G * X, d[A + u] += ie * X) : Y < 0 && (X = -B * d[A + h] * F[I + x] / Math.sqrt(Y), d[A + s] += G * X, d[A + u] += ie * X) : Y > 0 && (X = B * d[A + h] * F[I + x] / Y, d[A + s] += G * X, d[A + u] += ie * X), I = F[I + L], I < 0) break;
10252
10264
  continue;
10253
10265
  } else {
10254
- P = F[P + g];
10266
+ I = F[I + g];
10255
10267
  continue;
10256
10268
  }
10257
10269
  else {
10258
- if (te = F[P + E], te >= 0 && te !== A && (G = d[A + a] - d[te + a], ie = d[A + o] - d[te + o], Y = G * G + ie * ie, J === !0 ? Y > 0 ? (K = B * d[A + h] * d[te + h] / Y, d[A + s] += G * K, d[A + u] += ie * K) : Y < 0 && (K = -B * d[A + h] * d[te + h] / Math.sqrt(Y), d[A + s] += G * K, d[A + u] += ie * K) : Y > 0 && (K = B * d[A + h] * d[te + h] / Y, d[A + s] += G * K, d[A + u] += ie * K)), P = F[P + L], P < 0) break;
10270
+ if (te = F[I + E], te >= 0 && te !== A && (G = d[A + a] - d[te + a], ie = d[A + o] - d[te + o], Y = G * G + ie * ie, J === !0 ? Y > 0 ? (X = B * d[A + h] * d[te + h] / Y, d[A + s] += G * X, d[A + u] += ie * X) : Y < 0 && (X = -B * d[A + h] * d[te + h] / Math.sqrt(Y), d[A + s] += G * X, d[A + u] += ie * X) : Y > 0 && (X = B * d[A + h] * d[te + h] / Y, d[A + s] += G * X, d[A + u] += ie * X)), I = F[I + L], I < 0) break;
10259
10271
  continue;
10260
10272
  }
10261
10273
  else
10262
- for (B = f.scalingRatio, z = 0; z < ee; z += I)
10263
- for (Z = 0; Z < z; Z += I)
10264
- G = d[z + a] - d[Z + a], ie = d[z + o] - d[Z + o], J === !0 ? (Y = Math.sqrt(G * G + ie * ie) - d[z + y] - d[Z + y], Y > 0 ? (K = B * d[z + h] * d[Z + h] / Y / Y, d[z + s] += G * K, d[z + u] += ie * K, d[Z + s] -= G * K, d[Z + u] -= ie * K) : Y < 0 && (K = 100 * B * d[z + h] * d[Z + h], d[z + s] += G * K, d[z + u] += ie * K, d[Z + s] -= G * K, d[Z + u] -= ie * K)) : (Y = Math.sqrt(G * G + ie * ie), Y > 0 && (K = B * d[z + h] * d[Z + h] / Y / Y, d[z + s] += G * K, d[z + u] += ie * K, d[Z + s] -= G * K, d[Z + u] -= ie * K));
10265
- for (V = f.gravity / f.scalingRatio, B = f.scalingRatio, A = 0; A < ee; A += I)
10266
- K = 0, G = d[A + a], ie = d[A + o], Y = Math.sqrt(Math.pow(G, 2) + Math.pow(ie, 2)), f.strongGravityMode ? Y > 0 && (K = B * d[A + h] * V) : Y > 0 && (K = B * d[A + h] * V / Y), d[A + s] -= G * K, d[A + u] -= ie * K;
10274
+ for (B = f.scalingRatio, z = 0; z < ee; z += P)
10275
+ for (Z = 0; Z < z; Z += P)
10276
+ G = d[z + a] - d[Z + a], ie = d[z + o] - d[Z + o], J === !0 ? (Y = Math.sqrt(G * G + ie * ie) - d[z + y] - d[Z + y], Y > 0 ? (X = B * d[z + h] * d[Z + h] / Y / Y, d[z + s] += G * X, d[z + u] += ie * X, d[Z + s] -= G * X, d[Z + u] -= ie * X) : Y < 0 && (X = 100 * B * d[z + h] * d[Z + h], d[z + s] += G * X, d[z + u] += ie * X, d[Z + s] -= G * X, d[Z + u] -= ie * X)) : (Y = Math.sqrt(G * G + ie * ie), Y > 0 && (X = B * d[z + h] * d[Z + h] / Y / Y, d[z + s] += G * X, d[z + u] += ie * X, d[Z + s] -= G * X, d[Z + u] -= ie * X));
10277
+ for (V = f.gravity / f.scalingRatio, B = f.scalingRatio, A = 0; A < ee; A += P)
10278
+ X = 0, G = d[A + a], ie = d[A + o], Y = Math.sqrt(Math.pow(G, 2) + Math.pow(ie, 2)), f.strongGravityMode ? Y > 0 && (X = B * d[A + h] * V) : Y > 0 && (X = B * d[A + h] * V / Y), d[A + s] -= G * X, d[A + u] -= ie * X;
10267
10279
  for (B = 1 * (f.outboundAttractionDistribution ? q : 1), oe = 0; oe < re; oe += _)
10268
- z = U[oe + R], Z = U[oe + w], ne = U[oe + k], de = Math.pow(ne, f.edgeWeightInfluence), G = d[z + a] - d[Z + a], ie = d[z + o] - d[Z + o], J === !0 ? (Y = Math.sqrt(G * G + ie * ie) - d[z + y] - d[Z + y], f.linLogMode ? f.outboundAttractionDistribution ? Y > 0 && (K = -B * de * Math.log(1 + Y) / Y / d[z + h]) : Y > 0 && (K = -B * de * Math.log(1 + Y) / Y) : f.outboundAttractionDistribution ? Y > 0 && (K = -B * de / d[z + h]) : Y > 0 && (K = -B * de)) : (Y = Math.sqrt(Math.pow(G, 2) + Math.pow(ie, 2)), f.linLogMode ? f.outboundAttractionDistribution ? Y > 0 && (K = -B * de * Math.log(1 + Y) / Y / d[z + h]) : Y > 0 && (K = -B * de * Math.log(1 + Y) / Y) : f.outboundAttractionDistribution ? (Y = 1, K = -B * de / d[z + h]) : (Y = 1, K = -B * de)), Y > 0 && (d[z + s] += G * K, d[z + u] += ie * K, d[Z + s] -= G * K, d[Z + u] -= ie * K);
10269
- var Pe, ct, kt, Ve, Ct, xt;
10280
+ z = U[oe + R], Z = U[oe + w], ne = U[oe + k], de = Math.pow(ne, f.edgeWeightInfluence), G = d[z + a] - d[Z + a], ie = d[z + o] - d[Z + o], J === !0 ? (Y = Math.sqrt(G * G + ie * ie) - d[z + y] - d[Z + y], f.linLogMode ? f.outboundAttractionDistribution ? Y > 0 && (X = -B * de * Math.log(1 + Y) / Y / d[z + h]) : Y > 0 && (X = -B * de * Math.log(1 + Y) / Y) : f.outboundAttractionDistribution ? Y > 0 && (X = -B * de / d[z + h]) : Y > 0 && (X = -B * de)) : (Y = Math.sqrt(Math.pow(G, 2) + Math.pow(ie, 2)), f.linLogMode ? f.outboundAttractionDistribution ? Y > 0 && (X = -B * de * Math.log(1 + Y) / Y / d[z + h]) : Y > 0 && (X = -B * de * Math.log(1 + Y) / Y) : f.outboundAttractionDistribution ? (Y = 1, X = -B * de / d[z + h]) : (Y = 1, X = -B * de)), Y > 0 && (d[z + s] += G * X, d[z + u] += ie * X, d[Z + s] -= G * X, d[Z + u] -= ie * X);
10281
+ var Ie, ct, kt, Ve, Ct, xt;
10270
10282
  if (J === !0)
10271
- for (A = 0; A < ee; A += I)
10272
- d[A + b] !== 1 && (Pe = Math.sqrt(
10283
+ for (A = 0; A < ee; A += P)
10284
+ d[A + b] !== 1 && (Ie = Math.sqrt(
10273
10285
  Math.pow(d[A + s], 2) + Math.pow(d[A + u], 2)
10274
- ), Pe > X && (d[A + s] = d[A + s] * X / Pe, d[A + u] = d[A + u] * X / Pe), ct = d[A + h] * Math.sqrt(
10286
+ ), Ie > K && (d[A + s] = d[A + s] * K / Ie, d[A + u] = d[A + u] * K / Ie), ct = d[A + h] * Math.sqrt(
10275
10287
  (d[A + l] - d[A + s]) * (d[A + l] - d[A + s]) + (d[A + c] - d[A + u]) * (d[A + c] - d[A + u])
10276
10288
  ), kt = Math.sqrt(
10277
10289
  (d[A + l] + d[A + s]) * (d[A + l] + d[A + s]) + (d[A + c] + d[A + u]) * (d[A + c] + d[A + u])
10278
10290
  ) / 2, Ve = 0.1 * Math.log(1 + kt) / (1 + Math.sqrt(ct)), Ct = d[A + a] + d[A + s] * (Ve / f.slowDown), d[A + a] = Ct, xt = d[A + o] + d[A + u] * (Ve / f.slowDown), d[A + o] = xt);
10279
10291
  else
10280
- for (A = 0; A < ee; A += I)
10292
+ for (A = 0; A < ee; A += P)
10281
10293
  d[A + b] !== 1 && (ct = d[A + h] * Math.sqrt(
10282
10294
  (d[A + l] - d[A + s]) * (d[A + l] - d[A + s]) + (d[A + c] - d[A + u]) * (d[A + c] - d[A + u])
10283
10295
  ), kt = Math.sqrt(
@@ -10303,10 +10315,10 @@ function Ll() {
10303
10315
  });
10304
10316
  }), mr;
10305
10317
  }
10306
- var yt = {}, ii;
10307
- function ca() {
10308
- if (ii) return yt;
10309
- ii = 1;
10318
+ var yt = {}, ai;
10319
+ function ha() {
10320
+ if (ai) return yt;
10321
+ ai = 1;
10310
10322
  function n(e) {
10311
10323
  return typeof e != "number" || isNaN(e) ? 1 : e;
10312
10324
  }
@@ -10379,25 +10391,25 @@ function ca() {
10379
10391
  return t(e, n);
10380
10392
  }, yt;
10381
10393
  }
10382
- var Ie = {}, ai;
10383
- function ha() {
10384
- if (ai) return Ie;
10385
- ai = 1;
10394
+ var Pe = {}, oi;
10395
+ function da() {
10396
+ if (oi) return Pe;
10397
+ oi = 1;
10386
10398
  var n = 10, r = 3;
10387
- return Ie.assign = function(t) {
10399
+ return Pe.assign = function(t) {
10388
10400
  t = t || {};
10389
10401
  var e = Array.prototype.slice.call(arguments).slice(1), i, a, o;
10390
10402
  for (i = 0, o = e.length; i < o; i++)
10391
10403
  if (e[i])
10392
10404
  for (a in e[i]) t[a] = e[i][a];
10393
10405
  return t;
10394
- }, Ie.validateSettings = function(t) {
10406
+ }, Pe.validateSettings = function(t) {
10395
10407
  return "linLogMode" in t && typeof t.linLogMode != "boolean" ? { message: "the `linLogMode` setting should be a boolean." } : "outboundAttractionDistribution" in t && typeof t.outboundAttractionDistribution != "boolean" ? {
10396
10408
  message: "the `outboundAttractionDistribution` setting should be a boolean."
10397
10409
  } : "adjustSizes" in t && typeof t.adjustSizes != "boolean" ? { message: "the `adjustSizes` setting should be a boolean." } : "edgeWeightInfluence" in t && typeof t.edgeWeightInfluence != "number" ? {
10398
10410
  message: "the `edgeWeightInfluence` setting should be a number."
10399
10411
  } : "scalingRatio" in t && !(typeof t.scalingRatio == "number" && t.scalingRatio >= 0) ? { message: "the `scalingRatio` setting should be a number >= 0." } : "strongGravityMode" in t && typeof t.strongGravityMode != "boolean" ? { message: "the `strongGravityMode` setting should be a boolean." } : "gravity" in t && !(typeof t.gravity == "number" && t.gravity >= 0) ? { message: "the `gravity` setting should be a number >= 0." } : "slowDown" in t && !(typeof t.slowDown == "number" || t.slowDown >= 0) ? { message: "the `slowDown` setting should be a number >= 0." } : "barnesHutOptimize" in t && typeof t.barnesHutOptimize != "boolean" ? { message: "the `barnesHutOptimize` setting should be a boolean." } : "barnesHutTheta" in t && !(typeof t.barnesHutTheta == "number" && t.barnesHutTheta >= 0) ? { message: "the `barnesHutTheta` setting should be a number >= 0." } : null;
10400
- }, Ie.graphToByteArrays = function(t, e) {
10412
+ }, Pe.graphToByteArrays = function(t, e) {
10401
10413
  var i = t.order, a = t.size, o = {}, s, u = new Float32Array(i * n), l = new Float32Array(a * r);
10402
10414
  return s = 0, t.forEachNode(function(c, h) {
10403
10415
  o[c] = s, u[s] = h.x, u[s + 1] = h.y, u[s + 2] = 0, u[s + 3] = 0, u[s + 4] = 0, u[s + 5] = 0, u[s + 6] = 1, u[s + 7] = 1, u[s + 8] = h.size || 1, u[s + 9] = h.fixed ? 1 : 0, s += n;
@@ -10408,17 +10420,17 @@ function ha() {
10408
10420
  nodes: u,
10409
10421
  edges: l
10410
10422
  };
10411
- }, Ie.assignLayoutChanges = function(t, e, i) {
10423
+ }, Pe.assignLayoutChanges = function(t, e, i) {
10412
10424
  var a = 0;
10413
10425
  t.updateEachNodeAttributes(function(o, s) {
10414
10426
  return s.x = e[a], s.y = e[a + 1], a += n, i ? i(o, s) : s;
10415
10427
  });
10416
- }, Ie.readGraphPositions = function(t, e) {
10428
+ }, Pe.readGraphPositions = function(t, e) {
10417
10429
  var i = 0;
10418
10430
  t.forEachNode(function(a, o) {
10419
10431
  e[i] = o.x, e[i + 1] = o.y, i += n;
10420
10432
  });
10421
- }, Ie.collectLayoutChanges = function(t, e, i) {
10433
+ }, Pe.collectLayoutChanges = function(t, e, i) {
10422
10434
  for (var a = t.nodes(), o = {}, s = 0, u = 0, l = e.length; s < l; s += n) {
10423
10435
  if (i) {
10424
10436
  var c = Object.assign({}, t.getNodeAttributes(a[u]));
@@ -10434,16 +10446,16 @@ function ha() {
10434
10446
  u++;
10435
10447
  }
10436
10448
  return o;
10437
- }, Ie.createWorker = function(e) {
10449
+ }, Pe.createWorker = function(e) {
10438
10450
  var i = window.URL || window.webkitURL, a = e.toString(), o = i.createObjectURL(
10439
10451
  new Blob(["(" + a + ").call(this);"], { type: "text/javascript" })
10440
10452
  ), s = new Worker(o);
10441
10453
  return i.revokeObjectURL(o), s;
10442
- }, Ie;
10454
+ }, Pe;
10443
10455
  }
10444
- var yr, oi;
10445
- function da() {
10446
- return oi || (oi = 1, yr = {
10456
+ var yr, si;
10457
+ function fa() {
10458
+ return si || (si = 1, yr = {
10447
10459
  linLogMode: !1,
10448
10460
  outboundAttractionDistribution: !1,
10449
10461
  adjustSizes: !1,
@@ -10456,11 +10468,11 @@ function da() {
10456
10468
  barnesHutTheta: 0.5
10457
10469
  }), yr;
10458
10470
  }
10459
- var br, si;
10460
- function Gl() {
10461
- if (si) return br;
10462
- si = 1;
10463
- var n = Ll(), r = Ze(), t = ca().createEdgeWeightGetter, e = ha(), i = da();
10471
+ var br, ui;
10472
+ function zl() {
10473
+ if (ui) return br;
10474
+ ui = 1;
10475
+ var n = Ol(), r = Ze(), t = ha().createEdgeWeightGetter, e = da(), i = fa();
10464
10476
  function a(o, s) {
10465
10477
  if (s = s || {}, !r(o))
10466
10478
  throw new Error(
@@ -10509,28 +10521,28 @@ function Gl() {
10509
10521
  this.running = !1, this.killed = !0, this.matrices = null, this.worker.terminate(), this.graph.removeListener("nodeAdded", this.handleGraphUpdate), this.graph.removeListener("edgeAdded", this.handleGraphUpdate), this.graph.removeListener("nodeDropped", this.handleGraphUpdate), this.graph.removeListener("edgeDropped", this.handleGraphUpdate);
10510
10522
  }, br = a, br;
10511
10523
  }
10512
- var Pl = Gl();
10513
- const Il = /* @__PURE__ */ Br(Pl);
10514
- var wr, ui;
10515
- function Fl() {
10516
- if (ui) return wr;
10517
- ui = 1;
10524
+ var Nl = zl();
10525
+ const Ul = /* @__PURE__ */ Br(Nl);
10526
+ var wr, li;
10527
+ function $l() {
10528
+ if (li) return wr;
10529
+ li = 1;
10518
10530
  var n = 0, r = 1, t = 2, e = 3, i = 4, a = 5, o = 6, s = 7, u = 8, l = 9, c = 0, h = 1, v = 2, y = 0, b = 1, R = 2, w = 3, k = 4, E = 5, m = 6, p = 7, C = 8, L = 3, g = 10, x = 3, S = 9, D = 10;
10519
- return wr = function(I, _, W) {
10520
- var X, T, f, d, U, $, P, A, z, Z, te = _.length, oe = W.length, ne = I.adjustSizes, V = I.barnesHutTheta * I.barnesHutTheta, se, ee, re, J, le, q, B, G = [];
10531
+ return wr = function(P, _, W) {
10532
+ var K, T, f, d, U, $, I, A, z, Z, te = _.length, oe = W.length, ne = P.adjustSizes, V = P.barnesHutTheta * P.barnesHutTheta, se, ee, re, J, le, q, B, G = [];
10521
10533
  for (f = 0; f < te; f += g)
10522
10534
  _[f + i] = _[f + t], _[f + a] = _[f + e], _[f + t] = 0, _[f + e] = 0;
10523
- if (I.outboundAttractionDistribution) {
10535
+ if (P.outboundAttractionDistribution) {
10524
10536
  for (se = 0, f = 0; f < te; f += g)
10525
10537
  se += _[f + o];
10526
10538
  se /= te / g;
10527
10539
  }
10528
- if (I.barnesHutOptimize) {
10529
- var ie = 1 / 0, de = -1 / 0, Y = 1 / 0, K = -1 / 0, F, ve, Le;
10540
+ if (P.barnesHutOptimize) {
10541
+ var ie = 1 / 0, de = -1 / 0, Y = 1 / 0, X = -1 / 0, F, ve, Le;
10530
10542
  for (f = 0; f < te; f += g)
10531
- ie = Math.min(ie, _[f + n]), de = Math.max(de, _[f + n]), Y = Math.min(Y, _[f + r]), K = Math.max(K, _[f + r]);
10532
- var ye = de - ie, Re = K - Y;
10533
- for (ye > Re ? (Y -= (ye - Re) / 2, K = Y + ye) : (ie -= (Re - ye) / 2, de = ie + Re), G[0 + y] = -1, G[0 + b] = (ie + de) / 2, G[0 + R] = (Y + K) / 2, G[0 + w] = Math.max(de - ie, K - Y), G[0 + k] = -1, G[0 + E] = -1, G[0 + m] = 0, G[0 + p] = 0, G[0 + C] = 0, X = 1, f = 0; f < te; f += g)
10543
+ ie = Math.min(ie, _[f + n]), de = Math.max(de, _[f + n]), Y = Math.min(Y, _[f + r]), X = Math.max(X, _[f + r]);
10544
+ var ye = de - ie, Re = X - Y;
10545
+ for (ye > Re ? (Y -= (ye - Re) / 2, X = Y + ye) : (ie -= (Re - ye) / 2, de = ie + Re), G[0 + y] = -1, G[0 + b] = (ie + de) / 2, G[0 + R] = (Y + X) / 2, G[0 + w] = Math.max(de - ie, X - Y), G[0 + k] = -1, G[0 + E] = -1, G[0 + m] = 0, G[0 + p] = 0, G[0 + C] = 0, K = 1, f = 0; f < te; f += g)
10534
10546
  for (T = 0, Le = L; ; )
10535
10547
  if (G[T + E] >= 0) {
10536
10548
  _[f + n] < G[T + b] ? _[f + r] < G[T + R] ? F = G[T + E] : F = G[T + E] + S : _[f + r] < G[T + R] ? F = G[T + E] + S * 2 : F = G[T + E] + S * 3, G[T + p] = (G[T + p] * G[T + m] + _[f + n] * _[f + o]) / (G[T + m] + _[f + o]), G[T + C] = (G[T + C] * G[T + m] + _[f + r] * _[f + o]) / (G[T + m] + _[f + o]), G[T + m] += _[f + o], T = F;
@@ -10539,7 +10551,7 @@ function Fl() {
10539
10551
  G[T + y] = f;
10540
10552
  break;
10541
10553
  } else {
10542
- if (G[T + E] = X * S, A = G[T + w] / 2, z = G[T + E], G[z + y] = -1, G[z + b] = G[T + b] - A, G[z + R] = G[T + R] - A, G[z + w] = A, G[z + k] = z + S, G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, z += S, G[z + y] = -1, G[z + b] = G[T + b] - A, G[z + R] = G[T + R] + A, G[z + w] = A, G[z + k] = z + S, G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, z += S, G[z + y] = -1, G[z + b] = G[T + b] + A, G[z + R] = G[T + R] - A, G[z + w] = A, G[z + k] = z + S, G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, z += S, G[z + y] = -1, G[z + b] = G[T + b] + A, G[z + R] = G[T + R] + A, G[z + w] = A, G[z + k] = G[T + k], G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, X += 4, _[G[T + y] + n] < G[T + b] ? _[G[T + y] + r] < G[T + R] ? F = G[T + E] : F = G[T + E] + S : _[G[T + y] + r] < G[T + R] ? F = G[T + E] + S * 2 : F = G[T + E] + S * 3, G[T + m] = _[G[T + y] + o], G[T + p] = _[G[T + y] + n], G[T + C] = _[G[T + y] + r], G[F + y] = G[T + y], G[T + y] = -1, _[f + n] < G[T + b] ? _[f + r] < G[T + R] ? ve = G[T + E] : ve = G[T + E] + S : _[f + r] < G[T + R] ? ve = G[T + E] + S * 2 : ve = G[T + E] + S * 3, F === ve)
10554
+ if (G[T + E] = K * S, A = G[T + w] / 2, z = G[T + E], G[z + y] = -1, G[z + b] = G[T + b] - A, G[z + R] = G[T + R] - A, G[z + w] = A, G[z + k] = z + S, G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, z += S, G[z + y] = -1, G[z + b] = G[T + b] - A, G[z + R] = G[T + R] + A, G[z + w] = A, G[z + k] = z + S, G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, z += S, G[z + y] = -1, G[z + b] = G[T + b] + A, G[z + R] = G[T + R] - A, G[z + w] = A, G[z + k] = z + S, G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, z += S, G[z + y] = -1, G[z + b] = G[T + b] + A, G[z + R] = G[T + R] + A, G[z + w] = A, G[z + k] = G[T + k], G[z + E] = -1, G[z + m] = 0, G[z + p] = 0, G[z + C] = 0, K += 4, _[G[T + y] + n] < G[T + b] ? _[G[T + y] + r] < G[T + R] ? F = G[T + E] : F = G[T + E] + S : _[G[T + y] + r] < G[T + R] ? F = G[T + E] + S * 2 : F = G[T + E] + S * 3, G[T + m] = _[G[T + y] + o], G[T + p] = _[G[T + y] + n], G[T + C] = _[G[T + y] + r], G[F + y] = G[T + y], G[T + y] = -1, _[f + n] < G[T + b] ? _[f + r] < G[T + R] ? ve = G[T + E] : ve = G[T + E] + S : _[f + r] < G[T + R] ? ve = G[T + E] + S * 2 : ve = G[T + E] + S * 3, F === ve)
10543
10555
  if (Le--) {
10544
10556
  T = F;
10545
10557
  continue;
@@ -10551,8 +10563,8 @@ function Fl() {
10551
10563
  break;
10552
10564
  }
10553
10565
  }
10554
- if (I.barnesHutOptimize)
10555
- for (ee = I.scalingRatio, f = 0; f < te; f += g)
10566
+ if (P.barnesHutOptimize)
10567
+ for (ee = P.scalingRatio, f = 0; f < te; f += g)
10556
10568
  for (T = 0; ; )
10557
10569
  if (G[T + E] >= 0)
10558
10570
  if (q = Math.pow(
@@ -10573,14 +10585,14 @@ function Fl() {
10573
10585
  continue;
10574
10586
  }
10575
10587
  else
10576
- for (ee = I.scalingRatio, d = 0; d < te; d += g)
10588
+ for (ee = P.scalingRatio, d = 0; d < te; d += g)
10577
10589
  for (U = 0; U < d; U += g)
10578
10590
  re = _[d + n] - _[U + n], J = _[d + r] - _[U + r], ne === !0 ? (q = Math.sqrt(re * re + J * J) - _[d + u] - _[U + u], q > 0 ? (B = ee * _[d + o] * _[U + o] / q / q, _[d + t] += re * B, _[d + e] += J * B, _[U + t] -= re * B, _[U + e] -= J * B) : q < 0 && (B = 100 * ee * _[d + o] * _[U + o], _[d + t] += re * B, _[d + e] += J * B, _[U + t] -= re * B, _[U + e] -= J * B)) : (q = Math.sqrt(re * re + J * J), q > 0 && (B = ee * _[d + o] * _[U + o] / q / q, _[d + t] += re * B, _[d + e] += J * B, _[U + t] -= re * B, _[U + e] -= J * B));
10579
- for (z = I.gravity / I.scalingRatio, ee = I.scalingRatio, f = 0; f < te; f += g)
10580
- B = 0, re = _[f + n], J = _[f + r], q = Math.sqrt(Math.pow(re, 2) + Math.pow(J, 2)), I.strongGravityMode ? q > 0 && (B = ee * _[f + o] * z) : q > 0 && (B = ee * _[f + o] * z / q), _[f + t] -= re * B, _[f + e] -= J * B;
10581
- for (ee = 1 * (I.outboundAttractionDistribution ? se : 1), P = 0; P < oe; P += x)
10582
- d = W[P + c], U = W[P + h], A = W[P + v], le = Math.pow(A, I.edgeWeightInfluence), re = _[d + n] - _[U + n], J = _[d + r] - _[U + r], ne === !0 ? (q = Math.sqrt(re * re + J * J) - _[d + u] - _[U + u], I.linLogMode ? I.outboundAttractionDistribution ? q > 0 && (B = -ee * le * Math.log(1 + q) / q / _[d + o]) : q > 0 && (B = -ee * le * Math.log(1 + q) / q) : I.outboundAttractionDistribution ? q > 0 && (B = -ee * le / _[d + o]) : q > 0 && (B = -ee * le)) : (q = Math.sqrt(Math.pow(re, 2) + Math.pow(J, 2)), I.linLogMode ? I.outboundAttractionDistribution ? q > 0 && (B = -ee * le * Math.log(1 + q) / q / _[d + o]) : q > 0 && (B = -ee * le * Math.log(1 + q) / q) : I.outboundAttractionDistribution ? (q = 1, B = -ee * le / _[d + o]) : (q = 1, B = -ee * le)), q > 0 && (_[d + t] += re * B, _[d + e] += J * B, _[U + t] -= re * B, _[U + e] -= J * B);
10583
- var ce, be, Ue, we, Ge, Pe;
10591
+ for (z = P.gravity / P.scalingRatio, ee = P.scalingRatio, f = 0; f < te; f += g)
10592
+ B = 0, re = _[f + n], J = _[f + r], q = Math.sqrt(Math.pow(re, 2) + Math.pow(J, 2)), P.strongGravityMode ? q > 0 && (B = ee * _[f + o] * z) : q > 0 && (B = ee * _[f + o] * z / q), _[f + t] -= re * B, _[f + e] -= J * B;
10593
+ for (ee = 1 * (P.outboundAttractionDistribution ? se : 1), I = 0; I < oe; I += x)
10594
+ d = W[I + c], U = W[I + h], A = W[I + v], le = Math.pow(A, P.edgeWeightInfluence), re = _[d + n] - _[U + n], J = _[d + r] - _[U + r], ne === !0 ? (q = Math.sqrt(re * re + J * J) - _[d + u] - _[U + u], P.linLogMode ? P.outboundAttractionDistribution ? q > 0 && (B = -ee * le * Math.log(1 + q) / q / _[d + o]) : q > 0 && (B = -ee * le * Math.log(1 + q) / q) : P.outboundAttractionDistribution ? q > 0 && (B = -ee * le / _[d + o]) : q > 0 && (B = -ee * le)) : (q = Math.sqrt(Math.pow(re, 2) + Math.pow(J, 2)), P.linLogMode ? P.outboundAttractionDistribution ? q > 0 && (B = -ee * le * Math.log(1 + q) / q / _[d + o]) : q > 0 && (B = -ee * le * Math.log(1 + q) / q) : P.outboundAttractionDistribution ? (q = 1, B = -ee * le / _[d + o]) : (q = 1, B = -ee * le)), q > 0 && (_[d + t] += re * B, _[d + e] += J * B, _[U + t] -= re * B, _[U + e] -= J * B);
10595
+ var ce, be, Ue, we, Ge, Ie;
10584
10596
  if (ne === !0)
10585
10597
  for (f = 0; f < te; f += g)
10586
10598
  _[f + l] !== 1 && (ce = Math.sqrt(
@@ -10589,7 +10601,7 @@ function Fl() {
10589
10601
  (_[f + i] - _[f + t]) * (_[f + i] - _[f + t]) + (_[f + a] - _[f + e]) * (_[f + a] - _[f + e])
10590
10602
  ), Ue = Math.sqrt(
10591
10603
  (_[f + i] + _[f + t]) * (_[f + i] + _[f + t]) + (_[f + a] + _[f + e]) * (_[f + a] + _[f + e])
10592
- ) / 2, we = 0.1 * Math.log(1 + Ue) / (1 + Math.sqrt(be)), Ge = _[f + n] + _[f + t] * (we / I.slowDown), _[f + n] = Ge, Pe = _[f + r] + _[f + e] * (we / I.slowDown), _[f + r] = Pe);
10604
+ ) / 2, we = 0.1 * Math.log(1 + Ue) / (1 + Math.sqrt(be)), Ge = _[f + n] + _[f + t] * (we / P.slowDown), _[f + n] = Ge, Ie = _[f + r] + _[f + e] * (we / P.slowDown), _[f + r] = Ie);
10593
10605
  else
10594
10606
  for (f = 0; f < te; f += g)
10595
10607
  _[f + l] !== 1 && (be = _[f + o] * Math.sqrt(
@@ -10601,15 +10613,15 @@ function Fl() {
10601
10613
  Math.sqrt(
10602
10614
  we * (Math.pow(_[f + t], 2) + Math.pow(_[f + e], 2)) / (1 + Math.sqrt(be))
10603
10615
  )
10604
- ), Ge = _[f + n] + _[f + t] * (we / I.slowDown), _[f + n] = Ge, Pe = _[f + r] + _[f + e] * (we / I.slowDown), _[f + r] = Pe);
10616
+ ), Ge = _[f + n] + _[f + t] * (we / P.slowDown), _[f + n] = Ge, Ie = _[f + r] + _[f + e] * (we / P.slowDown), _[f + r] = Ie);
10605
10617
  return {};
10606
10618
  }, wr;
10607
10619
  }
10608
- var Er, li;
10609
- function Ol() {
10610
- if (li) return Er;
10611
- li = 1;
10612
- var n = Ze(), r = ca().createEdgeWeightGetter, t = Fl(), e = ha(), i = da();
10620
+ var Er, ci;
10621
+ function Ml() {
10622
+ if (ci) return Er;
10623
+ ci = 1;
10624
+ var n = Ze(), r = ha().createEdgeWeightGetter, t = $l(), e = da(), i = fa();
10613
10625
  function a(u, l, c) {
10614
10626
  if (!n(l))
10615
10627
  throw new Error(
@@ -10654,9 +10666,9 @@ function Ol() {
10654
10666
  var s = a.bind(null, !1);
10655
10667
  return s.assign = a.bind(null, !0), s.inferSettings = o, Er = s, Er;
10656
10668
  }
10657
- var zl = Ol();
10658
- const Nl = /* @__PURE__ */ Br(zl), bt = 64, ci = /* @__PURE__ */ new Map();
10659
- function Ul(n) {
10669
+ var Bl = Ml();
10670
+ const Wl = /* @__PURE__ */ Br(Bl), bt = 64, hi = /* @__PURE__ */ new Map();
10671
+ function Hl(n) {
10660
10672
  const r = document.createElement("canvas");
10661
10673
  r.width = bt, r.height = bt;
10662
10674
  const t = r.getContext("2d");
@@ -10664,39 +10676,39 @@ function Ul(n) {
10664
10676
  const e = [...n].length, i = Math.floor(bt * (e <= 2 ? 0.78 : e <= 4 ? 0.4 : 0.22));
10665
10677
  return t.font = `${i}px "Segoe UI Emoji", "Noto Color Emoji", "Apple Color Emoji", sans-serif`, t.textAlign = "center", t.textBaseline = "middle", t.fillStyle = "#cdd6e4", t.fillText(n, bt / 2, bt / 2 + 2), r.toDataURL("image/png");
10666
10678
  }
10667
- function $l(n) {
10679
+ function jl(n) {
10668
10680
  if (n.kind === "url") return n.value;
10669
- let r = ci.get(n.value);
10670
- return r === void 0 && (r = Ul(n.value), ci.set(n.value, r)), r;
10681
+ let r = hi.get(n.value);
10682
+ return r === void 0 && (r = Hl(n.value), hi.set(n.value, r)), r;
10671
10683
  }
10672
- const Ml = 9;
10673
- function Bl(n) {
10674
- return Math.max(n, Ml);
10684
+ const Vl = 9;
10685
+ function ql(n) {
10686
+ return Math.max(n, Vl);
10675
10687
  }
10676
- const fa = 4;
10677
- function Wl(n) {
10678
- return Math.cbrt(Math.max(n, 0)) * fa;
10688
+ const ga = 4;
10689
+ function Kl(n) {
10690
+ return Math.cbrt(Math.max(n, 0)) * ga;
10679
10691
  }
10680
- function Sc(n, r, t, e) {
10692
+ function Dc(n, r, t, e) {
10681
10693
  if (n <= 0) return 0;
10682
10694
  const i = t * Math.PI / 360, a = e / (2 * Math.tan(i));
10683
10695
  return r / n * a;
10684
10696
  }
10685
- function Rc(n) {
10697
+ function Lc(n) {
10686
10698
  return Math.pow(n / Mr, 3);
10687
10699
  }
10688
- const Ac = 2 * fa / Mr, kc = 50, Hl = 60;
10689
- function jl(n, r, t) {
10690
- const e = Math.min(n.width, n.height), i = Number.isFinite(t) ? t : r, a = Math.min(Math.max(i, 0), Math.max(r, ga(e))), o = e - 2 * r, s = e - 2 * a;
10700
+ const Gc = 2 * ga / Mr, Ic = 50, Xl = 60;
10701
+ function Yl(n, r, t) {
10702
+ const e = Math.min(n.width, n.height), i = Number.isFinite(t) ? t : r, a = Math.min(Math.max(i, 0), Math.max(r, pa(e))), o = e - 2 * r, s = e - 2 * a;
10691
10703
  return o > 0 && s > 0 ? o / s : 1;
10692
10704
  }
10693
- function Cc(n, r, t, e, i) {
10705
+ function Pc(n, r, t, e, i) {
10694
10706
  if (!(t > 0) || !(e > 0)) return 0;
10695
10707
  let a = 0;
10696
10708
  for (const l of n) {
10697
10709
  const { x: c = Number.NaN, y: h = Number.NaN, z: v = Number.NaN } = l;
10698
10710
  if (!Number.isFinite(c) || !Number.isFinite(h) || !Number.isFinite(v)) continue;
10699
- const y = Wl(l.val);
10711
+ const y = Kl(l.val);
10700
10712
  a = Math.max(
10701
10713
  a,
10702
10714
  Math.abs(c) + y,
@@ -10713,32 +10725,32 @@ function Cc(n, r, t, e, i) {
10713
10725
  );
10714
10726
  return Number.isFinite(u) ? u : 0;
10715
10727
  }
10716
- function xc(n, r) {
10728
+ function Fc(n, r) {
10717
10729
  const t = Math.hypot(n.x, n.y, n.z);
10718
10730
  if (!(t > 0)) return { x: 0, y: 0, z: r };
10719
10731
  const e = r / t;
10720
10732
  return { x: n.x * e, y: n.y * e, z: n.z * e };
10721
10733
  }
10722
- function ga(n) {
10734
+ function pa(n) {
10723
10735
  return Math.max(n, 0) * 0.4;
10724
10736
  }
10725
- function Dc(n, r) {
10726
- const t = Number.isFinite(n) ? n : Hl;
10727
- return Math.min(Math.max(t, 0), ga(r));
10737
+ function Oc(n, r) {
10738
+ const t = Number.isFinite(n) ? n : Xl;
10739
+ return Math.min(Math.max(t, 0), pa(r));
10728
10740
  }
10729
- function Vl(n, r, t) {
10741
+ function Zl(n, r, t) {
10730
10742
  const e = Number.isFinite(n) ? n : r;
10731
10743
  return Math.max(e, t);
10732
10744
  }
10733
- function ql(n) {
10745
+ function Ql(n) {
10734
10746
  return Rt(n);
10735
10747
  }
10736
- function pa(n, r) {
10737
- if (n < 0) return -pa(-n, r);
10748
+ function va(n, r) {
10749
+ if (n < 0) return -va(-n, r);
10738
10750
  const t = 3.5, e = t * (1 - Math.exp(-r / t)) * rn;
10739
10751
  return r === 0 ? 0 : e * n / r;
10740
10752
  }
10741
- function Xl({
10753
+ function Jl({
10742
10754
  nodes: n,
10743
10755
  edges: r,
10744
10756
  styles: t,
@@ -10753,7 +10765,7 @@ function Xl({
10753
10765
  }, [a]), Qe(() => {
10754
10766
  const b = s.current;
10755
10767
  if (!b) return;
10756
- const R = h.current, w = new Iu(R, b, {
10768
+ const R = h.current, w = new Uu(R, b, {
10757
10769
  allowInvalidContainer: !0,
10758
10770
  // Off by default in Sigma v3 - without it clickEdge never fires, breaking edge
10759
10771
  // selection on the canvas and edge hops in the adjacency preview.
@@ -10775,10 +10787,10 @@ function Xl({
10775
10787
  image: tn()
10776
10788
  },
10777
10789
  edgeProgramClasses: {
10778
- line: Yi,
10790
+ line: Zi,
10779
10791
  arrow: Xi,
10780
- curved: _l,
10781
- curvedArrow: Tl
10792
+ curved: kl,
10793
+ curvedArrow: Cl
10782
10794
  }
10783
10795
  });
10784
10796
  u.current = w, w.on("clickNode", ({ node: E }) => v.current({ kind: "node", id: Number(E) })), w.on("clickEdge", ({ edge: E }) => {
@@ -10790,11 +10802,11 @@ function Xl({
10790
10802
  k.disconnect(), l.current?.kill(), l.current = null, w.kill(), u.current = null;
10791
10803
  };
10792
10804
  }, []), Qe(() => {
10793
- const b = h.current, w = Object.keys(n).length + Object.keys(r).length <= Ba, k = /* @__PURE__ */ new Set();
10805
+ const b = h.current, w = Object.keys(n).length + Object.keys(r).length <= qa, k = /* @__PURE__ */ new Set();
10794
10806
  for (const m of Object.values(n)) {
10795
10807
  const p = String(m.id);
10796
10808
  k.add(p);
10797
- const C = t.nodes[m.id], L = C.image ? $l(C.image) : null, g = {
10809
+ const C = t.nodes[m.id], L = C.image ? jl(C.image) : null, g = {
10798
10810
  label: w && e.showNodeLabels ? m.label ? `${m.label} #${m.id}` : `#${m.id}` : null,
10799
10811
  color: C.color,
10800
10812
  size: C.size,
@@ -10819,7 +10831,7 @@ function Xl({
10819
10831
  E.add(p);
10820
10832
  const g = t.edges[m.id], x = {
10821
10833
  elementId: m.id,
10822
- label: w && e.showEdgeLabels ? vi(m) ?? void 0 : void 0,
10834
+ label: w && e.showEdgeLabels ? mi(m) ?? void 0 : void 0,
10823
10835
  color: g.color,
10824
10836
  size: g.width,
10825
10837
  zIndex: g.zIndex
@@ -10828,33 +10840,33 @@ function Xl({
10828
10840
  }
10829
10841
  for (const m of b.edges())
10830
10842
  E.has(m) || b.dropEdge(m);
10831
- El(b), b.forEachEdge((m, p) => {
10843
+ Al(b), b.forEachEdge((m, p) => {
10832
10844
  const C = p.parallelIndex, L = p.parallelMaxIndex;
10833
10845
  typeof C == "number" ? b.mergeEdgeAttributes(m, {
10834
10846
  type: e.edgeArrows ? "curvedArrow" : "curved",
10835
- curvature: pa(C, L ?? 1)
10847
+ curvature: va(C, L ?? 1)
10836
10848
  }) : b.mergeEdgeAttributes(m, {
10837
10849
  type: e.edgeArrows ? "arrow" : "line",
10838
10850
  curvature: 0
10839
10851
  });
10840
10852
  }), u.current?.refresh();
10841
- }, [n, r, t, e.showNodeLabels, e.showEdgeLabels, e.edgeArrows]), fi(
10853
+ }, [n, r, t, e.showNodeLabels, e.showEdgeLabels, e.edgeArrows]), gi(
10842
10854
  o,
10843
10855
  () => ({
10844
10856
  fitToView(b, R) {
10845
10857
  const w = u.current;
10846
10858
  if (!w) return;
10847
10859
  w.resize();
10848
- const k = w.getStagePadding(), E = jl(w.getDimensions(), k, R ?? k);
10860
+ const k = w.getStagePadding(), E = Yl(w.getDimensions(), k, R ?? k);
10849
10861
  w.getCamera().animate(
10850
10862
  { x: 0.5, y: 0.5, ratio: E, angle: 0 },
10851
10863
  // Floor of 1: sigma cannot take a zero duration (fitDurationMs says why).
10852
- { duration: Vl(b, Kl, 1) }
10864
+ { duration: Zl(b, ec, 1) }
10853
10865
  ), w.scheduleRender();
10854
10866
  },
10855
10867
  getCameraRatio: () => u.current?.getCamera().ratio ?? 1,
10856
10868
  setCameraRatio: (b) => {
10857
- ql(b) && u.current?.getCamera().animate({ ratio: b }, { duration: 1 });
10869
+ Ql(b) && u.current?.getCamera().animate({ ratio: b }, { duration: 1 });
10858
10870
  }
10859
10871
  }),
10860
10872
  []
@@ -10893,8 +10905,8 @@ function Xl({
10893
10905
  }
10894
10906
  if (b.order === 0) return;
10895
10907
  if (!l.current) {
10896
- const w = Nl.inferSettings(b);
10897
- l.current = new Il(b, { settings: w });
10908
+ const w = Wl.inferSettings(b);
10909
+ l.current = new Ul(b, { settings: w });
10898
10910
  }
10899
10911
  l.current.start();
10900
10912
  const R = window.setTimeout(() => l.current?.stop(), 5e3);
@@ -10911,7 +10923,7 @@ function Xl({
10911
10923
  if (!k || !E)
10912
10924
  b.style.display = "none";
10913
10925
  else {
10914
- const { x: m, y: p } = k.framedGraphToViewport({ x: E.x, y: E.y }), C = Bl(k.scaleSize(E.size));
10926
+ const { x: m, y: p } = k.framedGraphToViewport({ x: E.x, y: E.y }), C = ql(k.scaleSize(E.size));
10915
10927
  b.style.display = "block", b.style.left = `${m}px`, b.style.top = `${p}px`, b.style.setProperty("--eclipse-r", `${C}px`);
10916
10928
  }
10917
10929
  R = requestAnimationFrame(w);
@@ -10919,7 +10931,7 @@ function Xl({
10919
10931
  return R = requestAnimationFrame(w), () => {
10920
10932
  cancelAnimationFrame(R), b.style.display = "none";
10921
10933
  };
10922
- }, [i]), /* @__PURE__ */ va("div", { className: "relative h-full w-full", children: [
10934
+ }, [i]), /* @__PURE__ */ ma("div", { className: "relative h-full w-full", children: [
10923
10935
  /* @__PURE__ */ We(
10924
10936
  "div",
10925
10937
  {
@@ -10933,8 +10945,8 @@ function Xl({
10933
10945
  /* @__PURE__ */ We("div", { ref: c, className: "eclipse-highlight", style: { display: "none" }, "aria-hidden": !0 })
10934
10946
  ] });
10935
10947
  }
10936
- const Kl = 600, Yl = ma(() => import("./Canvas3D-BXYc6PEP.js").then((n) => ({ default: n.Canvas3D })));
10937
- function Zl({
10948
+ const ec = 600, tc = ya(() => import("./Canvas3D-DEWoiNMD.js").then((n) => ({ default: n.Canvas3D })));
10949
+ function rc({
10938
10950
  nodes: n,
10939
10951
  edges: r,
10940
10952
  config: t,
@@ -10956,17 +10968,17 @@ function Zl({
10956
10968
  edgeIds: new Set(i.edgeIds),
10957
10969
  active: !0,
10958
10970
  dim: !1
10959
- } : Wa;
10971
+ } : Ka;
10960
10972
  }, [e, i]), c = an(
10961
- () => ao(n, r, l, t),
10973
+ () => co(n, r, l, t),
10962
10974
  [n, r, l, t]
10963
10975
  );
10964
10976
  return t.renderer === "3d" ? /* @__PURE__ */ We(
10965
- ya,
10977
+ ba,
10966
10978
  {
10967
10979
  fallback: /* @__PURE__ */ We("div", { className: "bg-ink text-fg-faint flex h-full w-full items-center justify-center text-[11px]", children: "loading 3D renderer…" }),
10968
10980
  children: /* @__PURE__ */ We(
10969
- Yl,
10981
+ tc,
10970
10982
  {
10971
10983
  nodes: n,
10972
10984
  edges: r,
@@ -10979,7 +10991,7 @@ function Zl({
10979
10991
  )
10980
10992
  }
10981
10993
  ) : /* @__PURE__ */ We(
10982
- Xl,
10994
+ Jl,
10983
10995
  {
10984
10996
  nodes: n,
10985
10997
  edges: r,
@@ -10991,7 +11003,7 @@ function Zl({
10991
11003
  }
10992
11004
  );
10993
11005
  }
10994
- function Lc({
11006
+ function zc({
10995
11007
  nodes: n,
10996
11008
  edges: r,
10997
11009
  config: t = Tr,
@@ -11002,7 +11014,7 @@ function Lc({
11002
11014
  ref: s
11003
11015
  }) {
11004
11016
  const u = Be(null);
11005
- return fi(
11017
+ return gi(
11006
11018
  s,
11007
11019
  () => ({
11008
11020
  fitToView: (l, c) => u.current?.fitToView(l, c),
@@ -11010,8 +11022,8 @@ function Lc({
11010
11022
  setCameraRatio: (l) => u.current?.setCameraRatio(l)
11011
11023
  }),
11012
11024
  []
11013
- ), /* @__PURE__ */ We("div", { className: "f8-studio", style: Oa(o), children: /* @__PURE__ */ We(
11014
- Zl,
11025
+ ), /* @__PURE__ */ We("div", { className: "f8-studio", style: za(o), children: /* @__PURE__ */ We(
11026
+ rc,
11015
11027
  {
11016
11028
  nodes: n,
11017
11029
  edges: r,
@@ -11025,67 +11037,71 @@ function Lc({
11025
11037
  ) });
11026
11038
  }
11027
11039
  export {
11028
- Tc as $,
11029
- sc as A,
11030
- oc as B,
11031
- gc as C,
11040
+ Ba as $,
11041
+ dc as A,
11042
+ hc as B,
11043
+ bc as C,
11032
11044
  Tr as D,
11033
- Xa as E,
11034
- Lc as F,
11045
+ Ja as E,
11046
+ zc as F,
11035
11047
  Sr as G,
11036
11048
  Rr as H,
11037
- Ca as I,
11038
- fc as J,
11039
- vc as K,
11040
- qa as L,
11041
- yc as M,
11049
+ xa as I,
11050
+ yc as J,
11051
+ _c as K,
11052
+ Qa as L,
11053
+ Sc as M,
11042
11054
  Mr as N,
11043
- mc as O,
11044
- Ya as P,
11045
- Ua as Q,
11046
- Zl as R,
11047
- Ac as S,
11048
- Aa as T,
11049
- rc as U,
11050
- ic as V,
11051
- ec as W,
11052
- tc as X,
11053
- ka as Y,
11054
- nc as Z,
11055
- _c as _,
11056
- ja as a,
11057
- wc as a0,
11058
- Ec as a1,
11059
- cc as a2,
11060
- bc as a3,
11061
- dc as a4,
11062
- hc as a5,
11063
- za as a6,
11064
- Na as a7,
11065
- Oa as a8,
11066
- Va as b,
11067
- Ha as c,
11068
- Ka as d,
11069
- Cc as e,
11070
- Dc as f,
11055
+ Tc as O,
11056
+ to as P,
11057
+ $a as Q,
11058
+ rc as R,
11059
+ Gc as S,
11060
+ ka as T,
11061
+ Wa as U,
11062
+ sc as V,
11063
+ lc as W,
11064
+ ac as X,
11065
+ oc as Y,
11066
+ Ca as Z,
11067
+ uc as _,
11068
+ Ya as a,
11069
+ Ma as a0,
11070
+ wc as a1,
11071
+ Cc as a2,
11072
+ xc as a3,
11073
+ Ac as a4,
11074
+ kc as a5,
11075
+ pc as a6,
11076
+ Rc as a7,
11077
+ mc as a8,
11078
+ vc as a9,
11079
+ Na as aa,
11080
+ Ua as ab,
11081
+ za as ac,
11082
+ Za as b,
11083
+ Xa as c,
11084
+ eo as d,
11085
+ Pc as e,
11086
+ Oc as f,
11071
11087
  Br as g,
11072
- Hl as h,
11073
- kc as i,
11074
- Vl as j,
11075
- ql as k,
11076
- Rc as l,
11077
- $l as m,
11078
- vi as n,
11079
- Kl as o,
11080
- Bl as p,
11081
- Sc as q,
11082
- gi as r,
11083
- xc as s,
11084
- Ra as t,
11085
- Fa as u,
11086
- lc as v,
11087
- Wl as w,
11088
- pc as x,
11089
- uc as y,
11090
- ac as z
11088
+ Xl as h,
11089
+ Ic as i,
11090
+ Zl as j,
11091
+ Ql as k,
11092
+ Lc as l,
11093
+ jl as m,
11094
+ mi as n,
11095
+ ec as o,
11096
+ ql as p,
11097
+ Dc as q,
11098
+ pi as r,
11099
+ Fc as s,
11100
+ Aa as t,
11101
+ Oa as u,
11102
+ gc as v,
11103
+ Kl as w,
11104
+ Ec as x,
11105
+ fc as y,
11106
+ cc as z
11091
11107
  };