@arach/arc-iso 0.5.0 → 0.6.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
- import Wt, { useId as yt, useMemo as Nt, useState as dt, useEffect as Ft } from "react";
2
- const Ct = 30 * (Math.PI / 180), It = Math.cos(Ct), Bt = Math.sin(Ct);
1
+ import Nt, { useId as yt, useMemo as It, useState as dt, useEffect as Ft } from "react";
2
+ const Ct = 30 * (Math.PI / 180), Dt = Math.cos(Ct), Bt = Math.sin(Ct);
3
3
  function y(t, r, a = 0) {
4
4
  return {
5
- screenX: (t - r) * It,
5
+ screenX: (t - r) * Dt,
6
6
  screenY: -(t + r) * Bt - a
7
7
  // Negated so +X,+Y go UP on screen
8
8
  };
@@ -24,27 +24,27 @@ function rt(t, r, a, i = 0, s = 0, f = 0) {
24
24
  y: $.screenY + s
25
25
  }), k = Object.fromEntries(
26
26
  Object.entries(x).map(([$, w]) => [$, b(w)])
27
- ), u = ($, w, A, T) => {
28
- if (T <= 0) {
29
- const G = y(0, 0, A), z = y($, 0, A), v = y($, w, A), B = y(0, w, A);
30
- return `M ${G.screenX + i},${G.screenY + s} L ${z.screenX + i},${z.screenY + s} L ${v.screenX + i},${v.screenY + s} L ${B.screenX + i},${B.screenY + s} Z`;
27
+ ), u = ($, w, A, E) => {
28
+ if (E <= 0) {
29
+ const H = y(0, 0, A), z = y($, 0, A), v = y($, w, A), D = y(0, w, A);
30
+ return `M ${H.screenX + i},${H.screenY + s} L ${z.screenX + i},${z.screenY + s} L ${v.screenX + i},${v.screenY + s} L ${D.screenX + i},${D.screenY + s} Z`;
31
31
  }
32
- const I = Math.min($, w) / 2, Y = Math.min(T, I), P = 8, L = [], J = (G, z, v, B) => {
33
- for (let H = 0; H <= P; H++) {
34
- const E = v + (B - v) * (H / P), p = G + Y * Math.cos(E), n = z + Y * Math.sin(E), h = y(p, n, A);
32
+ const F = Math.min($, w) / 2, Y = Math.min(E, F), P = 8, L = [], J = (H, z, v, D) => {
33
+ for (let G = 0; G <= P; G++) {
34
+ const T = v + (D - v) * (G / P), p = H + Y * Math.cos(T), n = z + Y * Math.sin(T), h = y(p, n, A);
35
35
  L.push(`${h.screenX + i},${h.screenY + s}`);
36
36
  }
37
37
  };
38
38
  return J(Y, Y, Math.PI, Math.PI * 1.5), J($ - Y, Y, Math.PI * 1.5, Math.PI * 2), J($ - Y, w - Y, 0, Math.PI * 0.5), J(Y, w - Y, Math.PI * 0.5, Math.PI), `M ${L[0]} L ${L.slice(1).join(" L ")} Z`;
39
- }, l = ($) => `M ${$.map((w) => `${w.x},${w.y}`).join(" L ")} Z`, O = ($, w, A, T, I, Y) => {
39
+ }, l = ($) => `M ${$.map((w) => `${w.x},${w.y}`).join(" L ")} Z`, O = ($, w, A, E, F, Y) => {
40
40
  const L = [];
41
41
  for (let v = 0; v < 6; v++) {
42
- const B = I + (Y - I) * (v / 6), H = I + (Y - I) * ((v + 1) / 6), E = (B + H) / 2, p = Math.cos(E), n = Math.sin(E), _ = p * -0.577 + n * -0.577 + 0 * 0.577, Q = 0.3 + Math.max(0, _ + 0.4) * 0.5, tt = y($ + A * Math.cos(B), w + A * Math.sin(B), 0), W = y($ + A * Math.cos(H), w + A * Math.sin(H), 0), q = y($ + A * Math.cos(B), w + A * Math.sin(B), T), K = y($ + A * Math.cos(H), w + A * Math.sin(H), T), st = `M ${tt.screenX + i},${tt.screenY + s} L ${W.screenX + i},${W.screenY + s} L ${K.screenX + i},${K.screenY + s} L ${q.screenX + i},${q.screenY + s} Z`;
42
+ const D = F + (Y - F) * (v / 6), G = F + (Y - F) * ((v + 1) / 6), T = (D + G) / 2, p = Math.cos(T), n = Math.sin(T), _ = p * -0.577 + n * -0.577 + 0 * 0.577, Q = 0.3 + Math.max(0, _ + 0.4) * 0.5, tt = y($ + A * Math.cos(D), w + A * Math.sin(D), 0), W = y($ + A * Math.cos(G), w + A * Math.sin(G), 0), q = y($ + A * Math.cos(D), w + A * Math.sin(D), E), K = y($ + A * Math.cos(G), w + A * Math.sin(G), E), st = `M ${tt.screenX + i},${tt.screenY + s} L ${W.screenX + i},${W.screenY + s} L ${K.screenX + i},${K.screenY + s} L ${q.screenX + i},${q.screenY + s} Z`;
43
43
  L.push({ path: st, intensity: Q });
44
44
  }
45
45
  return L;
46
46
  }, d = Math.min(f, Math.min(t, r) / 2), c = u(t, r, a, d);
47
- let S, m, R, g, C, N;
47
+ let S, m, M, g, C, N;
48
48
  if (d > 0) {
49
49
  const $ = [
50
50
  { x: y(0, d, 0).screenX + i, y: y(0, d, 0).screenY + s },
@@ -59,24 +59,24 @@ function rt(t, r, a, i = 0, s = 0, f = 0) {
59
59
  { x: y(t - d, 0, a).screenX + i, y: y(t - d, 0, a).screenY + s },
60
60
  { x: y(d, 0, a).screenX + i, y: y(d, 0, a).screenY + s }
61
61
  ];
62
- m = l(w), R = O(d, d, d, a, Math.PI, Math.PI * 1.5), g = O(t - d, d, d, a, Math.PI * 1.5, Math.PI * 2), C = O(d, r - d, d, a, Math.PI * 0.5, Math.PI), N = O(t - d, r - d, d, a, 0, Math.PI * 0.5);
62
+ m = l(w), M = O(d, d, d, a, Math.PI, Math.PI * 1.5), g = O(t - d, d, d, a, Math.PI * 1.5, Math.PI * 2), C = O(d, r - d, d, a, Math.PI * 0.5, Math.PI), N = O(t - d, r - d, d, a, 0, Math.PI * 0.5);
63
63
  } else {
64
64
  const $ = [k.leftBottom, k.backBottom, k.backTop, k.leftTop], w = [k.leftBottom, k.frontBottom, k.frontTop, k.leftTop];
65
- S = l($), m = l(w), R = [], g = [], C = [], N = [];
65
+ S = l($), m = l(w), M = [], g = [], C = [], N = [];
66
66
  }
67
- const M = `M ${k.leftBottom.x},${k.leftBottom.y} L ${k.frontBottom.x},${k.frontBottom.y} L ${k.rightBottom.x},${k.rightBottom.y} L ${k.backBottom.x},${k.backBottom.y} Z`;
67
+ const R = `M ${k.leftBottom.x},${k.leftBottom.y} L ${k.frontBottom.x},${k.frontBottom.y} L ${k.rightBottom.x},${k.rightBottom.y} L ${k.backBottom.x},${k.backBottom.y} Z`;
68
68
  return {
69
69
  top: c,
70
70
  left: S,
71
71
  right: m,
72
- cornerFrontLeft: R,
72
+ cornerFrontLeft: M,
73
73
  cornerFrontRight: g,
74
74
  cornerBackLeft: C,
75
75
  cornerBackRight: N,
76
- outline: M
76
+ outline: R
77
77
  };
78
78
  }
79
- function Dt(t, r = 60, a = 50) {
79
+ function Xt(t, r = 60, a = 50) {
80
80
  return {
81
81
  top: `hsl(${t}, ${r}%, ${Math.min(a + 15, 95)}%)`,
82
82
  right: `hsl(${t}, ${r}%, ${a}%)`,
@@ -93,13 +93,13 @@ const jt = {
93
93
  slate: { hue: 220, saturation: 15, lightness: 50 },
94
94
  zinc: { hue: 240, saturation: 5, lightness: 50 }
95
95
  };
96
- function ke(t) {
96
+ function ge(t) {
97
97
  const r = jt[t] || jt.slate;
98
- return Dt(r.hue, r.saturation, r.lightness);
98
+ return Xt(r.hue, r.saturation, r.lightness);
99
99
  }
100
100
  var ht = { exports: {} }, it = {};
101
101
  var St;
102
- function Xt() {
102
+ function zt() {
103
103
  if (St) return it;
104
104
  St = 1;
105
105
  var t = /* @__PURE__ */ Symbol.for("react.transitional.element"), r = /* @__PURE__ */ Symbol.for("react.fragment");
@@ -122,7 +122,7 @@ function Xt() {
122
122
  }
123
123
  var ct = {};
124
124
  var vt;
125
- function zt() {
125
+ function Ut() {
126
126
  return vt || (vt = 1, process.env.NODE_ENV !== "production" && (function() {
127
127
  function t(n) {
128
128
  if (n == null) return null;
@@ -130,7 +130,7 @@ function zt() {
130
130
  return n.$$typeof === P ? null : n.displayName || n.name || null;
131
131
  if (typeof n == "string") return n;
132
132
  switch (n) {
133
- case R:
133
+ case M:
134
134
  return "Fragment";
135
135
  case C:
136
136
  return "Profiler";
@@ -149,16 +149,16 @@ function zt() {
149
149
  ), n.$$typeof) {
150
150
  case m:
151
151
  return "Portal";
152
- case M:
152
+ case R:
153
153
  return n.displayName || "Context";
154
154
  case N:
155
155
  return (n._context.displayName || "Context") + ".Consumer";
156
156
  case $:
157
157
  var h = n.render;
158
158
  return n = n.displayName, n || (n = h.displayName || h.name || "", n = n !== "" ? "ForwardRef(" + n + ")" : "ForwardRef"), n;
159
- case T:
159
+ case E:
160
160
  return h = n.displayName || null, h !== null ? h : t(n.type) || "Memo";
161
- case I:
161
+ case F:
162
162
  h = n._payload, n = n._init;
163
163
  try {
164
164
  return t(n(h));
@@ -179,17 +179,17 @@ function zt() {
179
179
  }
180
180
  if (h) {
181
181
  h = console;
182
- var _ = h.error, F = typeof Symbol == "function" && Symbol.toStringTag && n[Symbol.toStringTag] || n.constructor.name || "Object";
182
+ var _ = h.error, I = typeof Symbol == "function" && Symbol.toStringTag && n[Symbol.toStringTag] || n.constructor.name || "Object";
183
183
  return _.call(
184
184
  h,
185
185
  "The provided key is an unsupported type %s. This value must be coerced to a string before using it here.",
186
- F
186
+ I
187
187
  ), r(n);
188
188
  }
189
189
  }
190
190
  function i(n) {
191
- if (n === R) return "<>";
192
- if (typeof n == "object" && n !== null && n.$$typeof === I)
191
+ if (n === M) return "<>";
192
+ if (typeof n == "object" && n !== null && n.$$typeof === F)
193
193
  return "<...>";
194
194
  try {
195
195
  var h = t(n);
@@ -226,18 +226,18 @@ function zt() {
226
226
  }
227
227
  function k() {
228
228
  var n = t(this.type);
229
- return B[n] || (B[n] = !0, console.error(
229
+ return D[n] || (D[n] = !0, console.error(
230
230
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
231
231
  )), n = this.props.ref, n !== void 0 ? n : null;
232
232
  }
233
- function u(n, h, _, F, Q, tt) {
233
+ function u(n, h, _, I, Q, tt) {
234
234
  var W = _.ref;
235
235
  return n = {
236
236
  $$typeof: S,
237
237
  type: n,
238
238
  key: h,
239
239
  props: _,
240
- _owner: F
240
+ _owner: I
241
241
  }, (W !== void 0 ? W : null) !== null ? Object.defineProperty(n, "ref", {
242
242
  enumerable: !1,
243
243
  get: k
@@ -263,13 +263,13 @@ function zt() {
263
263
  value: tt
264
264
  }), Object.freeze && (Object.freeze(n.props), Object.freeze(n)), n;
265
265
  }
266
- function l(n, h, _, F, Q, tt) {
266
+ function l(n, h, _, I, Q, tt) {
267
267
  var W = h.children;
268
268
  if (W !== void 0)
269
- if (F)
270
- if (G(W)) {
271
- for (F = 0; F < W.length; F++)
272
- O(W[F]);
269
+ if (I)
270
+ if (H(W)) {
271
+ for (I = 0; I < W.length; I++)
272
+ O(W[I]);
273
273
  Object.freeze && Object.freeze(W);
274
274
  } else
275
275
  console.error(
@@ -281,18 +281,18 @@ function zt() {
281
281
  var q = Object.keys(h).filter(function(st) {
282
282
  return st !== "key";
283
283
  });
284
- F = 0 < q.length ? "{key: someKey, " + q.join(": ..., ") + ": ...}" : "{key: someKey}", p[W + F] || (q = 0 < q.length ? "{" + q.join(": ..., ") + ": ...}" : "{}", console.error(
284
+ I = 0 < q.length ? "{key: someKey, " + q.join(": ..., ") + ": ...}" : "{key: someKey}", p[W + I] || (q = 0 < q.length ? "{" + q.join(": ..., ") + ": ...}" : "{}", console.error(
285
285
  `A props object containing a "key" prop is being spread into JSX:
286
286
  let props = %s;
287
287
  <%s {...props} />
288
288
  React keys must be passed directly to JSX without using spread:
289
289
  let props = %s;
290
290
  <%s key={someKey} {...props} />`,
291
- F,
291
+ I,
292
292
  W,
293
293
  q,
294
294
  W
295
- ), p[W + F] = !0);
295
+ ), p[W + I] = !0);
296
296
  }
297
297
  if (W = null, _ !== void 0 && (a(_), W = "" + _), x(h) && (a(h.key), W = "" + h.key), "key" in h) {
298
298
  _ = {};
@@ -312,12 +312,12 @@ React keys must be passed directly to JSX without using spread:
312
312
  );
313
313
  }
314
314
  function O(n) {
315
- d(n) ? n._store && (n._store.validated = 1) : typeof n == "object" && n !== null && n.$$typeof === I && (n._payload.status === "fulfilled" ? d(n._payload.value) && n._payload.value._store && (n._payload.value._store.validated = 1) : n._store && (n._store.validated = 1));
315
+ d(n) ? n._store && (n._store.validated = 1) : typeof n == "object" && n !== null && n.$$typeof === F && (n._payload.status === "fulfilled" ? d(n._payload.value) && n._payload.value._store && (n._payload.value._store.validated = 1) : n._store && (n._store.validated = 1));
316
316
  }
317
317
  function d(n) {
318
318
  return typeof n == "object" && n !== null && n.$$typeof === S;
319
319
  }
320
- var c = Wt, S = /* @__PURE__ */ Symbol.for("react.transitional.element"), m = /* @__PURE__ */ Symbol.for("react.portal"), R = /* @__PURE__ */ Symbol.for("react.fragment"), g = /* @__PURE__ */ Symbol.for("react.strict_mode"), C = /* @__PURE__ */ Symbol.for("react.profiler"), N = /* @__PURE__ */ Symbol.for("react.consumer"), M = /* @__PURE__ */ Symbol.for("react.context"), $ = /* @__PURE__ */ Symbol.for("react.forward_ref"), w = /* @__PURE__ */ Symbol.for("react.suspense"), A = /* @__PURE__ */ Symbol.for("react.suspense_list"), T = /* @__PURE__ */ Symbol.for("react.memo"), I = /* @__PURE__ */ Symbol.for("react.lazy"), Y = /* @__PURE__ */ Symbol.for("react.activity"), P = /* @__PURE__ */ Symbol.for("react.client.reference"), L = c.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, J = Object.prototype.hasOwnProperty, G = Array.isArray, z = console.createTask ? console.createTask : function() {
320
+ var c = Nt, S = /* @__PURE__ */ Symbol.for("react.transitional.element"), m = /* @__PURE__ */ Symbol.for("react.portal"), M = /* @__PURE__ */ Symbol.for("react.fragment"), g = /* @__PURE__ */ Symbol.for("react.strict_mode"), C = /* @__PURE__ */ Symbol.for("react.profiler"), N = /* @__PURE__ */ Symbol.for("react.consumer"), R = /* @__PURE__ */ Symbol.for("react.context"), $ = /* @__PURE__ */ Symbol.for("react.forward_ref"), w = /* @__PURE__ */ Symbol.for("react.suspense"), A = /* @__PURE__ */ Symbol.for("react.suspense_list"), E = /* @__PURE__ */ Symbol.for("react.memo"), F = /* @__PURE__ */ Symbol.for("react.lazy"), Y = /* @__PURE__ */ Symbol.for("react.activity"), P = /* @__PURE__ */ Symbol.for("react.client.reference"), L = c.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, J = Object.prototype.hasOwnProperty, H = Array.isArray, z = console.createTask ? console.createTask : function() {
321
321
  return null;
322
322
  };
323
323
  c = {
@@ -325,39 +325,39 @@ React keys must be passed directly to JSX without using spread:
325
325
  return n();
326
326
  }
327
327
  };
328
- var v, B = {}, H = c.react_stack_bottom_frame.bind(
328
+ var v, D = {}, G = c.react_stack_bottom_frame.bind(
329
329
  c,
330
330
  f
331
- )(), E = z(i(f)), p = {};
332
- ct.Fragment = R, ct.jsx = function(n, h, _) {
333
- var F = 1e4 > L.recentlyCreatedOwnerStacks++;
331
+ )(), T = z(i(f)), p = {};
332
+ ct.Fragment = M, ct.jsx = function(n, h, _) {
333
+ var I = 1e4 > L.recentlyCreatedOwnerStacks++;
334
334
  return l(
335
335
  n,
336
336
  h,
337
337
  _,
338
338
  !1,
339
- F ? Error("react-stack-top-frame") : H,
340
- F ? z(i(n)) : E
339
+ I ? Error("react-stack-top-frame") : G,
340
+ I ? z(i(n)) : T
341
341
  );
342
342
  }, ct.jsxs = function(n, h, _) {
343
- var F = 1e4 > L.recentlyCreatedOwnerStacks++;
343
+ var I = 1e4 > L.recentlyCreatedOwnerStacks++;
344
344
  return l(
345
345
  n,
346
346
  h,
347
347
  _,
348
348
  !0,
349
- F ? Error("react-stack-top-frame") : H,
350
- F ? z(i(n)) : E
349
+ I ? Error("react-stack-top-frame") : G,
350
+ I ? z(i(n)) : T
351
351
  );
352
352
  };
353
353
  })()), ct;
354
354
  }
355
- var Tt;
356
- function Ut() {
357
- return Tt || (Tt = 1, process.env.NODE_ENV === "production" ? ht.exports = Xt() : ht.exports = zt()), ht.exports;
355
+ var Et;
356
+ function Ht() {
357
+ return Et || (Et = 1, process.env.NODE_ENV === "production" ? ht.exports = zt() : ht.exports = Ut()), ht.exports;
358
358
  }
359
- var e = Ut();
360
- const kt = '"JetBrains Mono", "IBM Plex Mono", "SF Mono", ui-monospace, Menlo, Consolas, monospace', Gt = 0.78, o = (t) => Math.round(t * Gt * 10) / 10, _t = {
359
+ var e = Ht();
360
+ const Gt = ["solid", "blueprint", "cyanotype"], kt = '"JetBrains Mono", "IBM Plex Mono", "SF Mono", ui-monospace, Menlo, Consolas, monospace', Jt = 0.78, o = (t) => Math.round(t * Jt * 10) / 10, _t = {
361
361
  id: "solid",
362
362
  name: "Solid",
363
363
  description: "Shaded isometric boxes",
@@ -375,7 +375,7 @@ const kt = '"JetBrains Mono", "IBM Plex Mono", "SF Mono", ui-monospace, Menlo, C
375
375
  hatchOpacity: { top: 0, right: 0, left: 0 },
376
376
  font: kt,
377
377
  strokeWidth: 0.5
378
- }, Ht = {
378
+ }, Zt = {
379
379
  id: "blueprint",
380
380
  name: "Blueprint",
381
381
  description: "Sepia engineering plate on parchment",
@@ -393,7 +393,7 @@ const kt = '"JetBrains Mono", "IBM Plex Mono", "SF Mono", ui-monospace, Menlo, C
393
393
  hatchOpacity: { top: 0.3, right: 0.55, left: 0.85 },
394
394
  font: kt,
395
395
  strokeWidth: 1
396
- }, Jt = {
396
+ }, qt = {
397
397
  id: "cyanotype",
398
398
  name: "Cyanotype",
399
399
  description: "White linework on classic blueprint blue",
@@ -411,11 +411,13 @@ const kt = '"JetBrains Mono", "IBM Plex Mono", "SF Mono", ui-monospace, Menlo, C
411
411
  hatchOpacity: { top: 0.28, right: 0.5, left: 0.78 },
412
412
  font: kt,
413
413
  strokeWidth: 1
414
- }, Zt = { solid: _t, blueprint: Ht, cyanotype: Jt };
415
- function qt(t) {
416
- return Zt[t] || _t;
414
+ }, Rt = { solid: _t, blueprint: Zt, cyanotype: qt };
415
+ function Vt(t) {
416
+ return Rt[t] || _t;
417
417
  }
418
- const Vt = {
418
+ const Kt = Gt.filter((t) => Rt[t].technical);
419
+ Kt[0];
420
+ const Qt = {
419
421
  violet: "cross",
420
422
  blue: "lines",
421
423
  sky: "lines",
@@ -428,9 +430,9 @@ const Vt = {
428
430
  slate: "plain"
429
431
  };
430
432
  function Mt(t) {
431
- return Vt[t || "zinc"] || "lines";
433
+ return Qt[t || "zinc"] || "lines";
432
434
  }
433
- const Kt = {
435
+ const te = {
434
436
  plain: "PLAIN",
435
437
  lines: "HATCH-A",
436
438
  cross: "HATCH-X",
@@ -438,11 +440,11 @@ const Kt = {
438
440
  dots: "STIPPLE",
439
441
  dashes: "BROKEN"
440
442
  };
441
- function Et(t, r, a, i = 0, s = 0) {
443
+ function Tt(t, r, a, i = 0, s = 0) {
442
444
  const f = (g, C, N) => {
443
- const M = y(g, C, N);
444
- return { x: M.screenX + i, y: M.screenY + s };
445
- }, x = f(0, 0, 0), b = f(t, 0, 0), k = f(t, r, 0), u = f(0, r, 0), l = f(0, 0, a), O = f(t, 0, a), d = f(t, r, a), c = f(0, r, a), S = (g) => `M ${g.map((C) => `${C.x},${C.y}`).join(" L ")} Z`, m = (g, C) => `M ${g.x},${g.y} L ${C.x},${C.y}`, R = [x, b, k, u, l, O, d, c];
445
+ const R = y(g, C, N);
446
+ return { x: R.screenX + i, y: R.screenY + s };
447
+ }, x = f(0, 0, 0), b = f(t, 0, 0), k = f(t, r, 0), u = f(0, r, 0), l = f(0, 0, a), O = f(t, 0, a), d = f(t, r, a), c = f(0, r, a), S = (g) => `M ${g.map((C) => `${C.x},${C.y}`).join(" L ")} Z`, m = (g, C) => `M ${g.x},${g.y} L ${C.x},${C.y}`, M = [x, b, k, u, l, O, d, c];
446
448
  return {
447
449
  top: S([l, O, d, c]),
448
450
  right: S([x, b, O, l]),
@@ -458,26 +460,26 @@ function Et(t, r, a, i = 0, s = 0) {
458
460
  hidden: [m(k, b), m(k, u), m(k, d)].join(" "),
459
461
  topCenter: { x: (l.x + d.x) / 2, y: (l.y + d.y) / 2 },
460
462
  topApex: { x: d.x, y: d.y },
461
- minX: Math.min(...R.map((g) => g.x)),
462
- minY: Math.min(...R.map((g) => g.y)),
463
- maxX: Math.max(...R.map((g) => g.x)),
464
- maxY: Math.max(...R.map((g) => g.y))
463
+ minX: Math.min(...M.map((g) => g.x)),
464
+ minY: Math.min(...M.map((g) => g.y)),
465
+ maxX: Math.max(...M.map((g) => g.x)),
466
+ maxY: Math.max(...M.map((g) => g.y))
465
467
  };
466
468
  }
467
469
  function mt(t) {
468
470
  return String(t).padStart(2, "0");
469
471
  }
470
- const Qt = {
472
+ const ee = {
471
473
  top: ["n30", "p30"],
472
474
  right: ["n30", "v"],
473
475
  left: ["p30", "v"]
474
- }, te = { n30: -30, p30: 30, v: 90 }, ee = [
476
+ }, ne = { n30: -30, p30: 30, v: 90 }, re = [
475
477
  { key: "line", spacing: 6.2, strokeWidth: 0.55 },
476
478
  { key: "dense", spacing: 3.1, strokeWidth: 0.45 },
477
479
  { key: "dash", spacing: 6.2, strokeWidth: 0.55, dash: "2.6 2.6" }
478
480
  ], lt = 22;
479
- function Rt(t, r, a) {
480
- const [i, s] = Qt[a];
481
+ function Pt(t, r, a) {
482
+ const [i, s] = ee[a];
481
483
  switch (r) {
482
484
  case "plain":
483
485
  return [];
@@ -495,7 +497,7 @@ function Rt(t, r, a) {
495
497
  return [`${t}-line-${i}`];
496
498
  }
497
499
  }
498
- const Pt = (t) => `${t}-paper`, At = (t) => `${t}-grain`, ne = (t, r = "line") => `${t}-arrow-${r}`, re = (t) => [`${t}-grid-n30`, `${t}-grid-p30`];
500
+ const At = (t) => `${t}-paper`, Lt = (t) => `${t}-grain`, oe = (t, r = "line") => `${t}-arrow-${r}`, se = (t) => [`${t}-grid-n30`, `${t}-grid-p30`];
499
501
  function bt({
500
502
  uid: t,
501
503
  style: r,
@@ -504,8 +506,8 @@ function bt({
504
506
  gridTransform: a = ""
505
507
  }) {
506
508
  return /* @__PURE__ */ e.jsxs("defs", { children: [
507
- ee.flatMap(
508
- (i) => Object.entries(te).map(([s, f]) => /* @__PURE__ */ e.jsx(
509
+ re.flatMap(
510
+ (i) => Object.entries(ne).map(([s, f]) => /* @__PURE__ */ e.jsx(
509
511
  "pattern",
510
512
  {
511
513
  id: `${t}-${i.key}-${s}`,
@@ -555,18 +557,18 @@ function bt({
555
557
  },
556
558
  i
557
559
  )),
558
- /* @__PURE__ */ e.jsxs("linearGradient", { id: Pt(t), x1: "0", y1: "0", x2: "0.35", y2: "1", children: [
560
+ /* @__PURE__ */ e.jsxs("linearGradient", { id: At(t), x1: "0", y1: "0", x2: "0.35", y2: "1", children: [
559
561
  /* @__PURE__ */ e.jsx("stop", { offset: "0%", stopColor: r.paper.from }),
560
562
  /* @__PURE__ */ e.jsx("stop", { offset: "100%", stopColor: r.paper.to })
561
563
  ] }),
562
- /* @__PURE__ */ e.jsxs("filter", { id: At(t), x: "0%", y: "0%", width: "100%", height: "100%", children: [
564
+ /* @__PURE__ */ e.jsxs("filter", { id: Lt(t), x: "0%", y: "0%", width: "100%", height: "100%", children: [
563
565
  /* @__PURE__ */ e.jsx("feTurbulence", { type: "fractalNoise", baseFrequency: "0.85", numOctaves: 3, stitchTiles: "stitch" }),
564
566
  /* @__PURE__ */ e.jsx("feColorMatrix", { type: "saturate", values: "0" })
565
567
  ] }),
566
568
  ["line", "accent"].map((i) => /* @__PURE__ */ e.jsx(
567
569
  "marker",
568
570
  {
569
- id: ne(t, i),
571
+ id: oe(t, i),
570
572
  markerWidth: "10",
571
573
  markerHeight: "10",
572
574
  refX: "8",
@@ -589,7 +591,7 @@ function bt({
589
591
  ))
590
592
  ] });
591
593
  }
592
- function oe({
594
+ function ae({
593
595
  style: t,
594
596
  rect: r,
595
597
  pan: a,
@@ -599,13 +601,13 @@ function oe({
599
601
  const f = yt().replace(/:/g, ""), x = a ? `translate(${a.x} ${a.y}) scale(${i})` : i !== 1 ? `scale(${i})` : "", b = r ? { x: r.x, y: r.y, width: r.width, height: r.height } : { x: 0, y: 0, width: "100%", height: "100%" };
600
602
  return /* @__PURE__ */ e.jsxs("svg", { className: s, "aria-hidden": "true", children: [
601
603
  /* @__PURE__ */ e.jsx(bt, { uid: f, style: t, gridTransform: x }),
602
- /* @__PURE__ */ e.jsx("rect", { ...b, fill: `url(#${Pt(f)})` }),
603
- re(f).map((k) => /* @__PURE__ */ e.jsx("rect", { ...b, fill: `url(#${k})`, opacity: 0.6 }, k)),
604
- t.paper.grain > 0 && /* @__PURE__ */ e.jsx("rect", { ...b, filter: `url(#${At(f)})`, opacity: t.paper.grain })
604
+ /* @__PURE__ */ e.jsx("rect", { ...b, fill: `url(#${At(f)})` }),
605
+ se(f).map((k) => /* @__PURE__ */ e.jsx("rect", { ...b, fill: `url(#${k})`, opacity: 0.6 }, k)),
606
+ t.paper.grain > 0 && /* @__PURE__ */ e.jsx("rect", { ...b, filter: `url(#${Lt(f)})`, opacity: t.paper.grain })
605
607
  ] });
606
608
  }
607
- const pt = o(10), se = 9, wt = (t, r) => t.length > r ? `${t.slice(0, r - 1)}…` : t;
608
- function ae({
609
+ const pt = o(10), ie = 9, wt = (t, r) => t.length > r ? `${t.slice(0, r - 1)}…` : t;
610
+ function ce({
609
611
  style: t,
610
612
  plate: r,
611
613
  rows: a,
@@ -613,7 +615,7 @@ function ae({
613
615
  tally: s,
614
616
  className: f = "absolute inset-0 w-full h-full pointer-events-none"
615
617
  }) {
616
- const x = yt().replace(/:/g, ""), b = a.slice(0, se), k = a.length - b.length, u = {
618
+ const x = yt().replace(/:/g, ""), b = a.slice(0, ie), k = a.length - b.length, u = {
617
619
  x: r.minX + pt,
618
620
  y: r.minY + pt,
619
621
  width: r.maxX - r.minX - pt * 2,
@@ -621,7 +623,7 @@ function ae({
621
623
  }, l = {
622
624
  fontFamily: t.font,
623
625
  letterSpacing: "0.08em"
624
- }, O = o(236), d = o(13), c = o(16), S = c + Math.max(b.length, 1) * d + (k > 0 ? d : 0), m = u.x + o(14), R = u.y + o(14), g = o(264), C = o(74), N = o(126), M = u.x + u.width - g - o(14), $ = u.y + u.height - C - o(14);
626
+ }, O = o(236), d = o(13), c = o(16), S = c + Math.max(b.length, 1) * d + (k > 0 ? d : 0), m = u.x + o(14), M = u.y + o(14), g = o(264), C = o(74), N = o(126), R = u.x + u.width - g - o(14), $ = u.y + u.height - C - o(14);
625
627
  return /* @__PURE__ */ e.jsxs("svg", { className: f, style: { overflow: "visible" }, "aria-hidden": "true", children: [
626
628
  /* @__PURE__ */ e.jsx(bt, { uid: x, style: t }),
627
629
  /* @__PURE__ */ e.jsx(
@@ -654,10 +656,10 @@ function ae({
654
656
  [u.x + u.width, u.y, -1, 1],
655
657
  [u.x, u.y + u.height, 1, -1],
656
658
  [u.x + u.width, u.y + u.height, -1, -1]
657
- ].map(([w, A, T, I], Y) => /* @__PURE__ */ e.jsx(
659
+ ].map(([w, A, E, F], Y) => /* @__PURE__ */ e.jsx(
658
660
  "path",
659
661
  {
660
- d: `M ${w + T * o(16)} ${A} L ${w} ${A} L ${w} ${A + I * o(16)}`,
662
+ d: `M ${w + E * o(16)} ${A} L ${w} ${A} L ${w} ${A + F * o(16)}`,
661
663
  fill: "none",
662
664
  stroke: t.ink.line,
663
665
  strokeWidth: 1.2
@@ -669,7 +671,7 @@ function ae({
669
671
  "rect",
670
672
  {
671
673
  x: m,
672
- y: R,
674
+ y: M,
673
675
  width: O,
674
676
  height: S,
675
677
  fill: t.paper.from,
@@ -682,19 +684,19 @@ function ae({
682
684
  "line",
683
685
  {
684
686
  x1: m,
685
- y1: R + c,
687
+ y1: M + c,
686
688
  x2: m + O,
687
- y2: R + c,
689
+ y2: M + c,
688
690
  stroke: t.ink.line,
689
691
  strokeWidth: 0.8
690
692
  }
691
693
  ),
692
- /* @__PURE__ */ e.jsx("text", { x: m + o(8), y: R + o(11), fill: t.ink.text, fontSize: o(8), fontWeight: 600, style: l, children: "COMPONENT INDEX" }),
694
+ /* @__PURE__ */ e.jsx("text", { x: m + o(8), y: M + o(11), fill: t.ink.text, fontSize: o(8), fontWeight: 600, style: l, children: "COMPONENT INDEX" }),
693
695
  /* @__PURE__ */ e.jsxs(
694
696
  "text",
695
697
  {
696
698
  x: m + O - o(8),
697
- y: R + o(11),
699
+ y: M + o(11),
698
700
  textAnchor: "end",
699
701
  fill: t.ink.muted,
700
702
  fontSize: o(8),
@@ -706,14 +708,14 @@ function ae({
706
708
  }
707
709
  ),
708
710
  b.map((w, A) => {
709
- const T = R + c + A * d, I = Mt(w.color), Y = Rt(x, I, "top");
711
+ const E = M + c + A * d, F = Mt(w.color), Y = Pt(x, F, "top");
710
712
  return /* @__PURE__ */ e.jsxs("g", { children: [
711
- /* @__PURE__ */ e.jsx("text", { x: m + o(8), y: T + o(9.5), fill: t.ink.muted, fontSize: o(7.5), style: l, children: mt(w.n) }),
713
+ /* @__PURE__ */ e.jsx("text", { x: m + o(8), y: E + o(9.5), fill: t.ink.muted, fontSize: o(7.5), style: l, children: mt(w.n) }),
712
714
  /* @__PURE__ */ e.jsx(
713
715
  "rect",
714
716
  {
715
717
  x: m + o(28),
716
- y: T + o(3),
718
+ y: E + o(3),
717
719
  width: o(14),
718
720
  height: o(7),
719
721
  fill: t.face.right,
@@ -725,7 +727,7 @@ function ae({
725
727
  "rect",
726
728
  {
727
729
  x: m + o(28),
728
- y: T + o(3),
730
+ y: E + o(3),
729
731
  width: o(14),
730
732
  height: o(7),
731
733
  fill: `url(#${P})`,
@@ -733,17 +735,17 @@ function ae({
733
735
  },
734
736
  P
735
737
  )),
736
- /* @__PURE__ */ e.jsx("text", { x: m + o(50), y: T + o(9.5), fill: t.ink.text, fontSize: o(7.5), style: l, children: wt((w.name || "").toUpperCase(), 18) }),
738
+ /* @__PURE__ */ e.jsx("text", { x: m + o(50), y: E + o(9.5), fill: t.ink.text, fontSize: o(7.5), style: l, children: wt((w.name || "").toUpperCase(), 18) }),
737
739
  /* @__PURE__ */ e.jsx(
738
740
  "text",
739
741
  {
740
742
  x: m + O - o(8),
741
- y: T + o(9.5),
743
+ y: E + o(9.5),
742
744
  textAnchor: "end",
743
745
  fill: t.ink.muted,
744
746
  fontSize: o(7),
745
747
  style: l,
746
- children: Kt[I]
748
+ children: te[F]
747
749
  }
748
750
  )
749
751
  ] }, w.n);
@@ -752,7 +754,7 @@ function ae({
752
754
  "text",
753
755
  {
754
756
  x: m + o(8),
755
- y: R + c + b.length * d + o(9.5),
757
+ y: M + c + b.length * d + o(9.5),
756
758
  fill: t.ink.muted,
757
759
  fontSize: o(7.5),
758
760
  style: l,
@@ -764,7 +766,7 @@ function ae({
764
766
  /* @__PURE__ */ e.jsx(
765
767
  "rect",
766
768
  {
767
- x: M,
769
+ x: R,
768
770
  y: $,
769
771
  width: g,
770
772
  height: C,
@@ -774,23 +776,23 @@ function ae({
774
776
  strokeWidth: 0.8
775
777
  }
776
778
  ),
777
- /* @__PURE__ */ e.jsx("line", { x1: M, y1: $ + o(30), x2: M + g, y2: $ + o(30), stroke: t.ink.line, strokeWidth: 0.8 }),
778
- /* @__PURE__ */ e.jsx("line", { x1: M, y1: $ + o(52), x2: M + g, y2: $ + o(52), stroke: t.ink.line, strokeWidth: 0.5 }),
779
- /* @__PURE__ */ e.jsx("line", { x1: M + N, y1: $ + o(30), x2: M + N, y2: $ + C, stroke: t.ink.line, strokeWidth: 0.5 }),
780
- /* @__PURE__ */ e.jsx("text", { x: M + o(9), y: $ + o(12), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "DRAWING TITLE" }),
781
- /* @__PURE__ */ e.jsx("text", { x: M + o(9), y: $ + o(24), fill: t.ink.text, fontSize: o(10), fontWeight: 600, style: l, children: wt((i || "UNTITLED ASSEMBLY").toUpperCase(), 26) }),
782
- /* @__PURE__ */ e.jsx("text", { x: M + o(9), y: $ + o(43), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "PROJECTION" }),
783
- /* @__PURE__ */ e.jsx("text", { x: M + N - o(9), y: $ + o(43), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: "ISOMETRIC 30°" }),
784
- /* @__PURE__ */ e.jsx("text", { x: M + o(9), y: $ + o(65), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "SCALE" }),
785
- /* @__PURE__ */ e.jsx("text", { x: M + N - o(9), y: $ + o(65), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: "1:1" }),
786
- /* @__PURE__ */ e.jsx("text", { x: M + N + o(9), y: $ + o(43), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "QTY" }),
787
- /* @__PURE__ */ e.jsx("text", { x: M + g - o(9), y: $ + o(43), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: s || `${mt(a.length)} CMP` }),
788
- /* @__PURE__ */ e.jsx("text", { x: M + N + o(9), y: $ + o(65), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "SHEET" }),
789
- /* @__PURE__ */ e.jsx("text", { x: M + g - o(9), y: $ + o(65), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: "1 OF 1" })
779
+ /* @__PURE__ */ e.jsx("line", { x1: R, y1: $ + o(30), x2: R + g, y2: $ + o(30), stroke: t.ink.line, strokeWidth: 0.8 }),
780
+ /* @__PURE__ */ e.jsx("line", { x1: R, y1: $ + o(52), x2: R + g, y2: $ + o(52), stroke: t.ink.line, strokeWidth: 0.5 }),
781
+ /* @__PURE__ */ e.jsx("line", { x1: R + N, y1: $ + o(30), x2: R + N, y2: $ + C, stroke: t.ink.line, strokeWidth: 0.5 }),
782
+ /* @__PURE__ */ e.jsx("text", { x: R + o(9), y: $ + o(12), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "DRAWING TITLE" }),
783
+ /* @__PURE__ */ e.jsx("text", { x: R + o(9), y: $ + o(24), fill: t.ink.text, fontSize: o(10), fontWeight: 600, style: l, children: wt((i || "UNTITLED ASSEMBLY").toUpperCase(), 26) }),
784
+ /* @__PURE__ */ e.jsx("text", { x: R + o(9), y: $ + o(43), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "PROJECTION" }),
785
+ /* @__PURE__ */ e.jsx("text", { x: R + N - o(9), y: $ + o(43), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: "ISOMETRIC 30°" }),
786
+ /* @__PURE__ */ e.jsx("text", { x: R + o(9), y: $ + o(65), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "SCALE" }),
787
+ /* @__PURE__ */ e.jsx("text", { x: R + N - o(9), y: $ + o(65), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: "1:1" }),
788
+ /* @__PURE__ */ e.jsx("text", { x: R + N + o(9), y: $ + o(43), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "QTY" }),
789
+ /* @__PURE__ */ e.jsx("text", { x: R + g - o(9), y: $ + o(43), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: s || `${mt(a.length)} CMP` }),
790
+ /* @__PURE__ */ e.jsx("text", { x: R + N + o(9), y: $ + o(65), fill: t.ink.muted, fontSize: o(6.5), style: l, children: "SHEET" }),
791
+ /* @__PURE__ */ e.jsx("text", { x: R + g - o(9), y: $ + o(65), textAnchor: "end", fill: t.ink.text, fontSize: o(7), style: l, children: "1 OF 1" })
790
792
  ] })
791
793
  ] });
792
794
  }
793
- function ie({
795
+ function le({
794
796
  uid: t,
795
797
  style: r,
796
798
  box: a,
@@ -816,7 +818,7 @@ function ie({
816
818
  children: [
817
819
  d.map(({ face: c, path: S }) => /* @__PURE__ */ e.jsxs("g", { children: [
818
820
  /* @__PURE__ */ e.jsx("path", { d: S, fill: r.face[c] }),
819
- Rt(t, u, c).map((m) => /* @__PURE__ */ e.jsx("path", { d: S, fill: `url(#${m})`, opacity: r.hatchOpacity[c] }, m))
821
+ Pt(t, u, c).map((m) => /* @__PURE__ */ e.jsx("path", { d: S, fill: `url(#${m})`, opacity: r.hatchOpacity[c] }, m))
820
822
  ] }, c)),
821
823
  /* @__PURE__ */ e.jsx(
822
824
  "path",
@@ -859,7 +861,7 @@ function ie({
859
861
  }
860
862
  );
861
863
  }
862
- function ce({
864
+ function fe({
863
865
  style: t,
864
866
  box: r,
865
867
  name: a,
@@ -928,7 +930,7 @@ function ce({
928
930
  )
929
931
  ] });
930
932
  }
931
- const Lt = '"JetBrains Mono", "Fira Code", "SF Mono", Consolas, monospace', le = {
933
+ const Yt = '"JetBrains Mono", "Fira Code", "SF Mono", Consolas, monospace', de = {
932
934
  blue: { top: "#3b82f6", side: "#2563eb", front: "#1d4ed8" },
933
935
  violet: { top: "#8b5cf6", side: "#7c3aed", front: "#6d28d9" },
934
936
  cyan: { top: "#06b6d4", side: "#0891b2", front: "#0e7490" },
@@ -936,7 +938,7 @@ const Lt = '"JetBrains Mono", "Fira Code", "SF Mono", Consolas, monospace', le =
936
938
  amber: { top: "#f59e0b", side: "#d97706", front: "#b45309" },
937
939
  rose: { top: "#f43f5e", side: "#e11d48", front: "#be123c" },
938
940
  slate: { top: "#475569", side: "#334155", front: "#1e293b" }
939
- }, fe = {
941
+ }, he = {
940
942
  blue: { top: "#93c5fd", side: "#60a5fa", front: "#3b82f6" },
941
943
  violet: { top: "#c4b5fd", side: "#a78bfa", front: "#8b5cf6" },
942
944
  cyan: { top: "#67e8f9", side: "#22d3ee", front: "#06b6d4" },
@@ -956,7 +958,7 @@ function ut(t, r, a) {
956
958
  }, s = i(t), f = i(r), x = Math.round(s.r + (f.r - s.r) * a), b = Math.round(s.g + (f.g - s.g) * a), k = Math.round(s.b + (f.b - s.b) * a);
957
959
  return `rgb(${x},${b},${k})`;
958
960
  }
959
- function de({ x: t, y: r, z: a, children: i, fontSize: s = 8, color: f = "#1e293b", shadow: x }) {
961
+ function pe({ x: t, y: r, z: a, children: i, fontSize: s = 8, color: f = "#1e293b", shadow: x }) {
960
962
  const b = y(t, r, a);
961
963
  return /* @__PURE__ */ e.jsx("g", { transform: `translate(${b.screenX}, ${b.screenY})`, filter: x, children: /* @__PURE__ */ e.jsx("g", { transform: "matrix(0.866, -0.5, 0.866, 0.5, 0, 0)", children: /* @__PURE__ */ e.jsx(
962
964
  "text",
@@ -967,13 +969,13 @@ function de({ x: t, y: r, z: a, children: i, fontSize: s = 8, color: f = "#1e293
967
969
  fill: f,
968
970
  fontSize: s,
969
971
  fontWeight: 600,
970
- fontFamily: Lt,
972
+ fontFamily: Yt,
971
973
  style: { textTransform: "uppercase", letterSpacing: "0.06em" },
972
974
  children: i
973
975
  }
974
976
  ) }) });
975
977
  }
976
- function he({ width: t, depth: r, elevation: a, color: i, opacity: s, borderColor: f, theme: x, isGround: b }) {
978
+ function ue({ width: t, depth: r, elevation: a, color: i, opacity: s, borderColor: f, theme: x, isGround: b }) {
977
979
  const u = rt(t, r, b ? 8 : 2, 0, 0), l = y(0, 0, a);
978
980
  return /* @__PURE__ */ e.jsxs("g", { transform: `translate(${l.screenX}, ${l.screenY})`, children: [
979
981
  b && /* @__PURE__ */ e.jsx("g", { transform: "translate(4, 4)", opacity: 0.2, children: /* @__PURE__ */ e.jsx("path", { d: u.top, fill: "#000" }) }),
@@ -994,22 +996,22 @@ function he({ width: t, depth: r, elevation: a, color: i, opacity: s, borderColo
994
996
  )
995
997
  ] });
996
998
  }
997
- function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s, onLayerClick: f }) {
998
- const { interactive: x = !0, animate: b = !0, showLabels: k = !0, expandOnHover: u = !0 } = r, { theme: l, canvas: O, origin: d, tiers: c, floorSize: S, nodes: m, cornerRadius: R = 0 } = t, g = qt(t.style), C = g.technical, N = yt().replace(/:/g, ""), M = l === "dark" ? le : fe, $ = C ? g.paper.to : l === "dark" ? "#0f172a" : "#fafafa", w = C ? g.ink.text : l === "dark" ? "#e2e8f0" : "#1e293b", A = C ? g.ink.muted : l === "dark" ? "#64748b" : "#94a3b8", T = Nt(() => {
999
- const E = m.map((n, h) => ({ node: n, i: h })).sort((n, h) => n.node.tier - h.node.tier || n.node.y - h.node.y || n.node.x - h.node.x), p = /* @__PURE__ */ new Map();
1000
- return E.forEach(({ i: n }, h) => p.set(n, h + 1)), p;
1001
- }, [m]), I = { minX: 16, minY: 16, maxX: O.width - 16, maxY: O.height - 16 }, [Y, P] = dt(/* @__PURE__ */ new Set());
999
+ function $e({ config: t, options: r = {}, className: a, style: i, onNodeClick: s, onLayerClick: f }) {
1000
+ const { interactive: x = !0, animate: b = !0, showLabels: k = !0, expandOnHover: u = !0 } = r, { theme: l, canvas: O, origin: d, tiers: c, floorSize: S, nodes: m, cornerRadius: M = 0 } = t, g = Vt(t.style), C = g.technical, N = yt().replace(/:/g, ""), R = l === "dark" ? de : he, $ = C ? g.paper.to : l === "dark" ? "#0f172a" : "#fafafa", w = C ? g.ink.text : l === "dark" ? "#e2e8f0" : "#1e293b", A = C ? g.ink.muted : l === "dark" ? "#64748b" : "#94a3b8", E = It(() => {
1001
+ const T = m.map((n, h) => ({ node: n, i: h })).sort((n, h) => n.node.tier - h.node.tier || n.node.y - h.node.y || n.node.x - h.node.x), p = /* @__PURE__ */ new Map();
1002
+ return T.forEach(({ i: n }, h) => p.set(n, h + 1)), p;
1003
+ }, [m]), F = { minX: 16, minY: 16, maxX: O.width - 16, maxY: O.height - 16 }, [Y, P] = dt(/* @__PURE__ */ new Set());
1002
1004
  Ft(() => {
1003
- b ? (P(/* @__PURE__ */ new Set()), c.forEach((E, p) => {
1005
+ b ? (P(/* @__PURE__ */ new Set()), c.forEach((T, p) => {
1004
1006
  setTimeout(() => {
1005
1007
  P((n) => /* @__PURE__ */ new Set([...n, p]));
1006
1008
  }, p * 150 + 100);
1007
- })) : P(new Set(c.map((E, p) => p)));
1009
+ })) : P(new Set(c.map((T, p) => p)));
1008
1010
  }, [t.id, b, c.length]);
1009
- const [L, J] = dt(null), [G, z] = dt(null), [v, B] = dt(null), H = [...m].sort((E, p) => {
1010
- const n = c[E.tier]?.elevation || 0, h = c[p.tier]?.elevation || 0;
1011
+ const [L, J] = dt(null), [H, z] = dt(null), [v, D] = dt(null), G = [...m].sort((T, p) => {
1012
+ const n = c[T.tier]?.elevation || 0, h = c[p.tier]?.elevation || 0;
1011
1013
  if (n !== h) return n - h;
1012
- const _ = E.x + E.width + (E.y + E.depth);
1014
+ const _ = T.x + T.width + (T.y + T.depth);
1013
1015
  return p.x + p.width + (p.y + p.depth) - _;
1014
1016
  });
1015
1017
  return /* @__PURE__ */ e.jsx("div", { className: a, style: { display: "inline-block", ...i }, children: /* @__PURE__ */ e.jsxs(
@@ -1019,7 +1021,7 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1019
1021
  height: O.height,
1020
1022
  style: { backgroundColor: $ },
1021
1023
  onClick: () => {
1022
- x && (B(null), z(null));
1024
+ x && (D(null), z(null));
1023
1025
  },
1024
1026
  children: [
1025
1027
  /* @__PURE__ */ e.jsxs("defs", { children: [
@@ -1054,7 +1056,7 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1054
1056
  C ? /* @__PURE__ */ e.jsxs(e.Fragment, { children: [
1055
1057
  /* @__PURE__ */ e.jsx(bt, { uid: N, style: g }),
1056
1058
  /* @__PURE__ */ e.jsx(
1057
- oe,
1059
+ ae,
1058
1060
  {
1059
1061
  style: g,
1060
1062
  rect: { x: 0, y: 0, width: O.width, height: O.height },
@@ -1065,8 +1067,8 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1065
1067
  /* @__PURE__ */ e.jsx("rect", { width: "100%", height: "100%", fill: `url(#bg-${t.id})` }),
1066
1068
  /* @__PURE__ */ e.jsx("rect", { width: "100%", height: "100%", fill: `url(#grid-${t.id})`, opacity: "0.5" })
1067
1069
  ] }),
1068
- /* @__PURE__ */ e.jsx("g", { transform: `translate(${d.x}, ${d.y})`, children: c.map((E, p) => {
1069
- const n = H.filter((j) => j.tier === p), h = Y.has(p), _ = x && (G === p || G === null && v === null && L === p), F = x && (G !== null || L !== null || v !== null), Q = v?.tier === p, tt = F && !_ && !Q, W = h ? 0 : 60, q = h ? 1 : 0, K = _ && u ? { x: 10, y: -34 } : { x: 0, y: 0 }, st = _ ? 1.03 : 1, ft = y(S.width / 2, S.depth / 2, E.elevation), gt = E.offset || { x: 0, y: 0 };
1070
+ /* @__PURE__ */ e.jsx("g", { transform: `translate(${d.x}, ${d.y})`, children: c.map((T, p) => {
1071
+ const n = G.filter((j) => j.tier === p), h = Y.has(p), _ = x && (H === p || H === null && v === null && L === p), I = x && (H !== null || L !== null || v !== null), Q = v?.tier === p, tt = I && !_ && !Q, W = h ? 0 : 60, q = h ? 1 : 0, K = _ && u ? { x: 10, y: -34 } : { x: 0, y: 0 }, st = _ ? 1.03 : 1, ft = y(S.width / 2, S.depth / 2, T.elevation), gt = T.offset || { x: 0, y: 0 };
1070
1072
  return /* @__PURE__ */ e.jsxs(
1071
1073
  "g",
1072
1074
  {
@@ -1074,7 +1076,7 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1074
1076
  onMouseEnter: () => x && J(p),
1075
1077
  onMouseLeave: () => x && J(null),
1076
1078
  onClick: (j) => {
1077
- x && (j.stopPropagation(), B(null), z((D) => D === p ? null : p), f?.(p));
1079
+ x && (j.stopPropagation(), D(null), z((B) => B === p ? null : p), f?.(p));
1078
1080
  },
1079
1081
  style: {
1080
1082
  transform: `translate(${gt.x + K.x}px, ${gt.y + K.y}px) translate(${ft.screenX}px, ${ft.screenY + W}px) scale(${st}) translate(${-ft.screenX}px, ${-ft.screenY}px)`,
@@ -1085,54 +1087,54 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1085
1087
  },
1086
1088
  children: [
1087
1089
  C ? /* @__PURE__ */ e.jsx(
1088
- pe,
1090
+ xe,
1089
1091
  {
1090
1092
  width: S.width,
1091
1093
  depth: S.depth,
1092
- elevation: p === 0 ? -2 : E.elevation,
1094
+ elevation: p === 0 ? -2 : T.elevation,
1093
1095
  ink: p === 0 ? g.ink.line : g.ink.hidden,
1094
1096
  isGround: p === 0
1095
1097
  }
1096
1098
  ) : /* @__PURE__ */ e.jsx(
1097
- he,
1099
+ ue,
1098
1100
  {
1099
1101
  width: S.width,
1100
1102
  depth: S.depth,
1101
- elevation: p === 0 ? -2 : E.elevation,
1102
- color: E.floorColor || (l === "dark" ? "#0f172a" : "#f8fafc"),
1103
- opacity: E.floorOpacity || (p === 0 ? 0.95 : 0.5),
1104
- borderColor: E.borderColor,
1103
+ elevation: p === 0 ? -2 : T.elevation,
1104
+ color: T.floorColor || (l === "dark" ? "#0f172a" : "#f8fafc"),
1105
+ opacity: T.floorOpacity || (p === 0 ? 0.95 : 0.5),
1106
+ borderColor: T.borderColor,
1105
1107
  theme: l,
1106
1108
  isGround: p === 0
1107
1109
  }
1108
1110
  ),
1109
- C && n.map((j, D) => {
1110
- const ot = E.elevation + 5, et = y(j.x, j.y, ot), U = Et(j.width, j.depth, j.height, et.screenX, et.screenY), X = v?.tier === p && v?.index === D, nt = x && v !== null && !X;
1111
+ C && n.map((j, B) => {
1112
+ const ot = T.elevation + 5, et = y(j.x, j.y, ot), U = Tt(j.width, j.depth, j.height, et.screenX, et.screenY), X = v?.tier === p && v?.index === B, nt = x && v !== null && !X;
1111
1113
  return /* @__PURE__ */ e.jsx(
1112
- ie,
1114
+ le,
1113
1115
  {
1114
1116
  uid: N,
1115
1117
  style: g,
1116
1118
  box: U,
1117
1119
  color: j.color,
1118
- tag: T.get(m.indexOf(j)),
1120
+ tag: E.get(m.indexOf(j)),
1119
1121
  selected: X,
1120
1122
  opacity: (j.opacity ?? 1) * (nt ? 0.3 : 1),
1121
1123
  onClick: x ? () => {
1122
- if (z(null), B((at) => at && at.tier === p && at.index === D ? null : { tier: p, index: D }), s?.(j, { tier: p, index: D }), j.link)
1124
+ if (z(null), D((at) => at && at.tier === p && at.index === B ? null : { tier: p, index: B }), s?.(j, { tier: p, index: B }), j.link)
1123
1125
  try {
1124
1126
  window.open(j.link, "_blank");
1125
1127
  } catch {
1126
1128
  }
1127
1129
  } : void 0
1128
1130
  },
1129
- `tech-${D}`
1131
+ `tech-${B}`
1130
1132
  );
1131
1133
  }),
1132
- C && k && n.map((j, D) => {
1133
- const ot = E.elevation + 5, et = y(j.x, j.y, ot), U = Et(j.width, j.depth, j.height, et.screenX, et.screenY), X = v?.tier === p && v?.index === D, nt = x && v !== null && !X;
1134
+ C && k && n.map((j, B) => {
1135
+ const ot = T.elevation + 5, et = y(j.x, j.y, ot), U = Tt(j.width, j.depth, j.height, et.screenX, et.screenY), X = v?.tier === p && v?.index === B, nt = x && v !== null && !X;
1134
1136
  return /* @__PURE__ */ e.jsx(
1135
- ce,
1137
+ fe,
1136
1138
  {
1137
1139
  style: g,
1138
1140
  box: U,
@@ -1140,18 +1142,18 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1140
1142
  selected: X,
1141
1143
  opacity: nt ? 0.3 : 1
1142
1144
  },
1143
- `tech-label-${D}`
1145
+ `tech-label-${B}`
1144
1146
  );
1145
1147
  }),
1146
- !C && n.map((j, D) => {
1147
- const ot = E.elevation + 5, et = y(j.x, j.y, ot), U = rt(j.width, j.depth, j.height, et.screenX, et.screenY, R), X = M[j.color] || M.slate, nt = v?.tier === p && v?.index === D, at = x && v !== null && !nt, $t = y(j.x - 3, j.y - 3, E.elevation), Yt = rt(j.width + 6, j.depth + 6, 0, $t.screenX, $t.screenY, R).top;
1148
+ !C && n.map((j, B) => {
1149
+ const ot = T.elevation + 5, et = y(j.x, j.y, ot), U = rt(j.width, j.depth, j.height, et.screenX, et.screenY, M), X = R[j.color] || R.slate, nt = v?.tier === p && v?.index === B, at = x && v !== null && !nt, $t = y(j.x - 3, j.y - 3, T.elevation), Wt = rt(j.width + 6, j.depth + 6, 0, $t.screenX, $t.screenY, M).top;
1148
1150
  return /* @__PURE__ */ e.jsxs(
1149
1151
  "g",
1150
1152
  {
1151
- "data-node": `${p}-${D}`,
1153
+ "data-node": `${p}-${B}`,
1152
1154
  opacity: (j.opacity ?? 1) * (at ? 0.3 : 1),
1153
1155
  onClick: x ? (Z) => {
1154
- if (Z.stopPropagation(), z(null), B((V) => V && V.tier === p && V.index === D ? null : { tier: p, index: D }), s?.(j, { tier: p, index: D }), j.link)
1156
+ if (Z.stopPropagation(), z(null), D((V) => V && V.tier === p && V.index === B ? null : { tier: p, index: B }), s?.(j, { tier: p, index: B }), j.link)
1155
1157
  try {
1156
1158
  window.open(j.link, "_blank");
1157
1159
  } catch {
@@ -1159,7 +1161,7 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1159
1161
  } : void 0,
1160
1162
  style: { cursor: x ? "pointer" : "default", transition: "opacity 0.3s ease-out" },
1161
1163
  children: [
1162
- /* @__PURE__ */ e.jsx("path", { d: Yt, fill: "#000000", opacity: 0.3, filter: `url(#contact-${t.id})` }),
1164
+ /* @__PURE__ */ e.jsx("path", { d: Wt, fill: "#000000", opacity: 0.3, filter: `url(#contact-${t.id})` }),
1163
1165
  U.cornerBackRight?.map((Z, V) => /* @__PURE__ */ e.jsx(
1164
1166
  "path",
1165
1167
  {
@@ -1209,7 +1211,7 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1209
1211
  }
1210
1212
  ),
1211
1213
  k && j.label && /* @__PURE__ */ e.jsx(
1212
- de,
1214
+ pe,
1213
1215
  {
1214
1216
  x: j.x + j.width / 2,
1215
1217
  y: j.y + j.depth / 2,
@@ -1222,21 +1224,21 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1222
1224
  )
1223
1225
  ]
1224
1226
  },
1225
- D
1227
+ B
1226
1228
  );
1227
1229
  }),
1228
1230
  k && /* @__PURE__ */ e.jsx(
1229
1231
  "text",
1230
1232
  {
1231
- x: y(-25, S.depth / 2, E.elevation + 15).screenX - 35,
1232
- y: y(-25, S.depth / 2, E.elevation + 15).screenY,
1233
+ x: y(-25, S.depth / 2, T.elevation + 15).screenX - 35,
1234
+ y: y(-25, S.depth / 2, T.elevation + 15).screenY,
1233
1235
  fill: A,
1234
1236
  fontSize: 9,
1235
1237
  fontWeight: 500,
1236
- fontFamily: Lt,
1238
+ fontFamily: Yt,
1237
1239
  opacity: C ? 0.9 : 0.6,
1238
1240
  style: { letterSpacing: "0.05em", textTransform: C ? "uppercase" : "none" },
1239
- children: E.name
1241
+ children: T.name
1240
1242
  }
1241
1243
  )
1242
1244
  ]
@@ -1245,16 +1247,16 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1245
1247
  );
1246
1248
  }) }),
1247
1249
  C && /* @__PURE__ */ e.jsx(
1248
- ae,
1250
+ ce,
1249
1251
  {
1250
1252
  style: g,
1251
- plate: I,
1252
- rows: m.map((E, p) => ({
1253
- n: T.get(p) || p + 1,
1254
- name: E.label,
1255
- subtitle: c[E.tier]?.name,
1256
- color: E.color
1257
- })).sort((E, p) => E.n - p.n),
1253
+ plate: F,
1254
+ rows: m.map((T, p) => ({
1255
+ n: E.get(p) || p + 1,
1256
+ name: T.label,
1257
+ subtitle: c[T.tier]?.name,
1258
+ color: T.color
1259
+ })).sort((T, p) => T.n - p.n),
1258
1260
  title: t.title,
1259
1261
  tally: `${String(m.length).padStart(2, "0")} CMP / ${String(c.length).padStart(2, "0")} TIER`,
1260
1262
  className: ""
@@ -1264,7 +1266,7 @@ function be({ config: t, options: r = {}, className: a, style: i, onNodeClick: s
1264
1266
  }
1265
1267
  ) });
1266
1268
  }
1267
- function pe({ width: t, depth: r, elevation: a, ink: i, isGround: s }) {
1269
+ function xe({ width: t, depth: r, elevation: a, ink: i, isGround: s }) {
1268
1270
  const f = y(0, 0, a), x = rt(t, r, 0, f.screenX, f.screenY).top;
1269
1271
  return /* @__PURE__ */ e.jsx(
1270
1272
  "path",
@@ -1278,7 +1280,7 @@ function pe({ width: t, depth: r, elevation: a, ink: i, isGround: s }) {
1278
1280
  }
1279
1281
  );
1280
1282
  }
1281
- const Ot = '"JetBrains Mono", "Fira Code", "SF Mono", Consolas, monospace', ue = {
1283
+ const Ot = '"JetBrains Mono", "Fira Code", "SF Mono", Consolas, monospace', me = {
1282
1284
  blue: { top: "#3b82f6", side: "#2563eb", front: "#1d4ed8" },
1283
1285
  violet: { top: "#8b5cf6", side: "#7c3aed", front: "#6d28d9" },
1284
1286
  cyan: { top: "#06b6d4", side: "#0891b2", front: "#0e7490" },
@@ -1286,7 +1288,7 @@ const Ot = '"JetBrains Mono", "Fira Code", "SF Mono", Consolas, monospace', ue =
1286
1288
  amber: { top: "#f59e0b", side: "#d97706", front: "#b45309" },
1287
1289
  rose: { top: "#f43f5e", side: "#e11d48", front: "#be123c" },
1288
1290
  slate: { top: "#475569", side: "#334155", front: "#1e293b" }
1289
- }, xe = {
1291
+ }, ye = {
1290
1292
  blue: { top: "#93c5fd", side: "#60a5fa", front: "#3b82f6" },
1291
1293
  violet: { top: "#c4b5fd", side: "#a78bfa", front: "#8b5cf6" },
1292
1294
  cyan: { top: "#67e8f9", side: "#22d3ee", front: "#06b6d4" },
@@ -1306,10 +1308,10 @@ function xt(t, r, a) {
1306
1308
  }, s = i(t), f = i(r), x = Math.round(s.r + (f.r - s.r) * a), b = Math.round(s.g + (f.g - s.g) * a), k = Math.round(s.b + (f.b - s.b) * a);
1307
1309
  return `rgb(${x},${b},${k})`;
1308
1310
  }
1309
- function me(t) {
1310
- const { theme: r, canvas: a, origin: i, tiers: s, floorSize: f, nodes: x, cornerRadius: b = 0 } = t, k = r === "dark" ? ue : xe, u = r === "dark" ? "#0f172a" : "#fafafa", l = r === "dark" ? "#e2e8f0" : "#1e293b", O = r === "dark" ? "#64748b" : "#94a3b8", d = [...x].sort((S, m) => {
1311
- const R = s[S.tier]?.elevation || 0, g = s[m.tier]?.elevation || 0;
1312
- return R !== g ? R - g : m.x + m.width + (m.y + m.depth) - (S.x + S.width + (S.y + S.depth));
1311
+ function ke(t) {
1312
+ const { theme: r, canvas: a, origin: i, tiers: s, floorSize: f, nodes: x, cornerRadius: b = 0 } = t, k = r === "dark" ? me : ye, u = r === "dark" ? "#0f172a" : "#fafafa", l = r === "dark" ? "#e2e8f0" : "#1e293b", O = r === "dark" ? "#64748b" : "#94a3b8", d = [...x].sort((S, m) => {
1313
+ const M = s[S.tier]?.elevation || 0, g = s[m.tier]?.elevation || 0;
1314
+ return M !== g ? M - g : m.x + m.width + (m.y + m.depth) - (S.x + S.width + (S.y + S.depth));
1313
1315
  });
1314
1316
  let c = `<svg xmlns="http://www.w3.org/2000/svg" width="${a.width}" height="${a.height}" style="background:${u}">`;
1315
1317
  c += `<defs>
@@ -1327,14 +1329,14 @@ function me(t) {
1327
1329
  <filter id="labelshadow" x="-40%" y="-40%" width="180%" height="180%"><feDropShadow dx="0" dy="0.5" stdDeviation="0.7" flood-color="#000000" flood-opacity="0.7"/></filter>
1328
1330
  </defs>`, c += '<rect width="100%" height="100%" fill="url(#bg)"/>', c += '<rect width="100%" height="100%" fill="url(#grid)" opacity="0.5"/>', c += `<g transform="translate(${i.x},${i.y})">`;
1329
1331
  for (let S = 0; S < s.length; S++) {
1330
- const m = s[S], R = d.filter((T) => T.tier === S), g = m.offset || { x: 0, y: 0 };
1332
+ const m = s[S], M = d.filter((E) => E.tier === S), g = m.offset || { x: 0, y: 0 };
1331
1333
  c += `<g transform="translate(${g.x},${g.y})">`;
1332
- const C = S === 0 ? 8 : 2, N = rt(f.width, f.depth, C, 0, 0), M = y(0, 0, S === 0 ? -2 : m.elevation), $ = m.floorColor || (r === "dark" ? "#0f172a" : "#f8fafc"), w = m.floorOpacity || (S === 0 ? 0.95 : 0.5);
1333
- c += `<g transform="translate(${M.screenX},${M.screenY})">`, S === 0 && (c += `<g transform="translate(4,4)" opacity="0.2"><path d="${N.top}" fill="#000"/></g>`), c += `<path d="${N.top}" fill="${$}" opacity="${w}"/>`, S === 0 && (c += `<path d="${N.left}" fill="${r === "dark" ? "#0f172a" : "#cbd5e1"}" opacity="0.8"/>`, c += `<path d="${N.right}" fill="${r === "dark" ? "#1e293b" : "#94a3b8"}" opacity="0.8"/>`), c += `<path d="${N.top}" fill="none" stroke="${m.borderColor || (r === "dark" ? "#475569" : "#94a3b8")}" stroke-width="${S === 0 ? 1.5 : 0.75}" opacity="${S === 0 ? 1 : 0.6}"/>`, c += "</g>";
1334
- for (const T of R) {
1335
- const I = m.elevation + 5, Y = y(T.x, T.y, I), P = rt(T.width, T.depth, T.height, Y.screenX, Y.screenY, b), L = k[T.color] || k.slate, J = T.opacity ?? 1;
1334
+ const C = S === 0 ? 8 : 2, N = rt(f.width, f.depth, C, 0, 0), R = y(0, 0, S === 0 ? -2 : m.elevation), $ = m.floorColor || (r === "dark" ? "#0f172a" : "#f8fafc"), w = m.floorOpacity || (S === 0 ? 0.95 : 0.5);
1335
+ c += `<g transform="translate(${R.screenX},${R.screenY})">`, S === 0 && (c += `<g transform="translate(4,4)" opacity="0.2"><path d="${N.top}" fill="#000"/></g>`), c += `<path d="${N.top}" fill="${$}" opacity="${w}"/>`, S === 0 && (c += `<path d="${N.left}" fill="${r === "dark" ? "#0f172a" : "#cbd5e1"}" opacity="0.8"/>`, c += `<path d="${N.right}" fill="${r === "dark" ? "#1e293b" : "#94a3b8"}" opacity="0.8"/>`), c += `<path d="${N.top}" fill="none" stroke="${m.borderColor || (r === "dark" ? "#475569" : "#94a3b8")}" stroke-width="${S === 0 ? 1.5 : 0.75}" opacity="${S === 0 ? 1 : 0.6}"/>`, c += "</g>";
1336
+ for (const E of M) {
1337
+ const F = m.elevation + 5, Y = y(E.x, E.y, F), P = rt(E.width, E.depth, E.height, Y.screenX, Y.screenY, b), L = k[E.color] || k.slate, J = E.opacity ?? 1;
1336
1338
  c += `<g opacity="${J}">`;
1337
- const G = y(T.x - 3, T.y - 3, m.elevation), z = rt(T.width + 6, T.depth + 6, 0, G.screenX, G.screenY, b).top;
1339
+ const H = y(E.x - 3, E.y - 3, m.elevation), z = rt(E.width + 6, E.depth + 6, 0, H.screenX, H.screenY, b).top;
1338
1340
  if (c += `<path d="${z}" fill="#000000" opacity="0.3" filter="url(#contact)"/>`, P.cornerBackRight)
1339
1341
  for (const v of P.cornerBackRight)
1340
1342
  c += `<path d="${v.path}" fill="${xt(L.front, L.side, v.intensity)}"/>`;
@@ -1347,9 +1349,9 @@ function me(t) {
1347
1349
  if (P.cornerFrontLeft)
1348
1350
  for (const v of P.cornerFrontLeft)
1349
1351
  c += `<path d="${v.path}" fill="${xt(L.front, L.side, v.intensity)}"/>`;
1350
- if (c += `<path d="${P.top}" fill="${L.top}"/>`, c += `<path d="${P.top}" fill="url(#sheen)"/>`, c += `<path d="${P.top}" fill="none" stroke="rgba(255,255,255,0.28)" stroke-width="0.75" stroke-linejoin="round"/>`, T.label) {
1351
- const v = y(T.x + T.width / 2, T.y + T.depth / 2, I + T.height + 2), B = T.width > 70 ? 9 : 8;
1352
- c += `<g transform="translate(${v.screenX},${v.screenY})" filter="url(#labelshadow)">`, c += '<g transform="matrix(0.866,-0.5,0.866,0.5,0,0)">', c += `<text x="0" y="0" text-anchor="middle" fill="${l}" font-size="${B}" font-weight="600" font-family='${Ot}' style="text-transform:uppercase;letter-spacing:0.06em">${T.label}</text>`, c += "</g></g>";
1352
+ if (c += `<path d="${P.top}" fill="${L.top}"/>`, c += `<path d="${P.top}" fill="url(#sheen)"/>`, c += `<path d="${P.top}" fill="none" stroke="rgba(255,255,255,0.28)" stroke-width="0.75" stroke-linejoin="round"/>`, E.label) {
1353
+ const v = y(E.x + E.width / 2, E.y + E.depth / 2, F + E.height + 2), D = E.width > 70 ? 9 : 8;
1354
+ c += `<g transform="translate(${v.screenX},${v.screenY})" filter="url(#labelshadow)">`, c += '<g transform="matrix(0.866,-0.5,0.866,0.5,0,0)">', c += `<text x="0" y="0" text-anchor="middle" fill="${l}" font-size="${D}" font-weight="600" font-family='${Ot}' style="text-transform:uppercase;letter-spacing:0.06em">${E.label}</text>`, c += "</g></g>";
1353
1355
  }
1354
1356
  c += "</g>";
1355
1357
  }
@@ -1358,14 +1360,14 @@ function me(t) {
1358
1360
  }
1359
1361
  return c += "</g></svg>", c;
1360
1362
  }
1361
- function ge(t, r) {
1362
- t.innerHTML = me(r);
1363
+ function je(t, r) {
1364
+ t.innerHTML = ke(r);
1363
1365
  }
1364
1366
  export {
1365
- be as ArcDiagram,
1366
- ke as getColorShading,
1367
+ $e as ArcDiagram,
1368
+ ge as getColorShading,
1367
1369
  rt as isoBox,
1368
1370
  y as isoToScreen,
1369
- ge as renderToElement,
1370
- me as renderToString
1371
+ je as renderToElement,
1372
+ ke as renderToString
1371
1373
  };