@pixerate/editor 0.96.0 → 0.98.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.
Files changed (52) hide show
  1. package/THIRD_PARTY_NOTICES.md +4 -2
  2. package/dist/animation-editor/index.cjs +55 -53
  3. package/dist/animation-editor/index.cjs.map +1 -1
  4. package/dist/animation-editor/index.d.cts +3 -2
  5. package/dist/animation-editor/index.d.ts +3 -2
  6. package/dist/animation-editor/index.js +11 -9
  7. package/dist/animation-editor/index.js.map +1 -1
  8. package/dist/chunk-DWGZUSES.cjs +694 -0
  9. package/dist/chunk-DWGZUSES.cjs.map +1 -0
  10. package/dist/chunk-GX332W2C.js +181 -0
  11. package/dist/chunk-GX332W2C.js.map +1 -0
  12. package/dist/{chunk-7MD7C6XQ.cjs → chunk-JF5PXN7W.cjs} +96 -744
  13. package/dist/chunk-JF5PXN7W.cjs.map +1 -0
  14. package/dist/chunk-KKREERP2.js +694 -0
  15. package/dist/chunk-KKREERP2.js.map +1 -0
  16. package/dist/chunk-MUUXNRU4.cjs +181 -0
  17. package/dist/chunk-MUUXNRU4.cjs.map +1 -0
  18. package/dist/{chunk-KFTQ2PKP.js → chunk-WIR377F6.js} +1001 -61
  19. package/dist/chunk-WIR377F6.js.map +1 -0
  20. package/dist/{chunk-T422YCHR.cjs → chunk-WT6ZAWJP.cjs} +1023 -83
  21. package/dist/chunk-WT6ZAWJP.cjs.map +1 -0
  22. package/dist/{chunk-4JLB2USO.js → chunk-YGZNGDIT.js} +45 -693
  23. package/dist/chunk-YGZNGDIT.js.map +1 -0
  24. package/dist/image-editor/index.cjs +1519 -360
  25. package/dist/image-editor/index.cjs.map +1 -1
  26. package/dist/image-editor/index.d.cts +378 -5
  27. package/dist/image-editor/index.d.ts +378 -5
  28. package/dist/image-editor/index.js +1244 -85
  29. package/dist/image-editor/index.js.map +1 -1
  30. package/dist/raster/index.cjs +25 -2
  31. package/dist/raster/index.cjs.map +1 -1
  32. package/dist/raster/index.d.cts +143 -4
  33. package/dist/raster/index.d.ts +143 -4
  34. package/dist/raster/index.js +25 -2
  35. package/dist/{svg-ymShkNtu.d.cts → svg-C9r284x8.d.cts} +6 -9
  36. package/dist/{svg-Dh17jCyA.d.ts → svg-MVKBqwD4.d.ts} +6 -9
  37. package/dist/types-CwMPoRMU.d.cts +40 -0
  38. package/dist/types-CwMPoRMU.d.ts +40 -0
  39. package/dist/vector/index.cjs +490 -554
  40. package/dist/vector/index.cjs.map +1 -1
  41. package/dist/vector/index.d.cts +154 -292
  42. package/dist/vector/index.d.ts +154 -292
  43. package/dist/vector/index.js +91 -155
  44. package/dist/vector/index.js.map +1 -1
  45. package/dist/warp-B8rAguzs.d.ts +165 -0
  46. package/dist/warp-nYs2DPrx.d.cts +165 -0
  47. package/package.json +1 -1
  48. package/skills/pixerate-image-editor/SKILL.md +49 -3
  49. package/dist/chunk-4JLB2USO.js.map +0 -1
  50. package/dist/chunk-7MD7C6XQ.cjs.map +0 -1
  51. package/dist/chunk-KFTQ2PKP.js.map +0 -1
  52. package/dist/chunk-T422YCHR.cjs.map +0 -1
@@ -10,6 +10,7 @@ var _chunkJEYDXRWQcjs = require('../chunk-JEYDXRWQ.cjs');
10
10
 
11
11
 
12
12
 
13
+ var _chunkMUUXNRU4cjs = require('../chunk-MUUXNRU4.cjs');
13
14
 
14
15
 
15
16
 
@@ -240,6 +241,7 @@ var _chunkJEYDXRWQcjs = require('../chunk-JEYDXRWQ.cjs');
240
241
 
241
242
 
242
243
 
244
+ var _chunkJF5PXN7Wcjs = require('../chunk-JF5PXN7W.cjs');
243
245
 
244
246
 
245
247
 
@@ -263,11 +265,11 @@ var _chunkJEYDXRWQcjs = require('../chunk-JEYDXRWQ.cjs');
263
265
 
264
266
 
265
267
 
268
+ var _chunkXGD3FSNCcjs = require('../chunk-XGD3FSNC.cjs');
266
269
 
267
270
 
268
271
 
269
272
 
270
- var _chunk7MD7C6XQcjs = require('../chunk-7MD7C6XQ.cjs');
271
273
 
272
274
 
273
275
 
@@ -291,7 +293,16 @@ var _chunk7MD7C6XQcjs = require('../chunk-7MD7C6XQ.cjs');
291
293
 
292
294
 
293
295
 
294
- var _chunkXGD3FSNCcjs = require('../chunk-XGD3FSNC.cjs');
296
+
297
+
298
+
299
+
300
+
301
+
302
+
303
+
304
+
305
+ var _chunkDWGZUSEScjs = require('../chunk-DWGZUSES.cjs');
295
306
 
296
307
 
297
308
  var _chunkQKLRAA4Tcjs = require('../chunk-QKLRAA4T.cjs');
@@ -313,9 +324,9 @@ var fmt = (n) => Math.round(n * 100) / 100;
313
324
  var apply = (m, p) => ({ x: m[0] * p.x + m[2] * p.y + m[4], y: m[1] * p.x + m[3] * p.y + m[5] });
314
325
  function vectorGradientTargetPath(doc, selection, target) {
315
326
  for (const id of selection) {
316
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, id);
327
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, id);
317
328
  if (!node) continue;
318
- const path = _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node).find((p) => _chunk7MD7C6XQcjs.isVectorGradient.call(void 0, p[target]));
329
+ const path = _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node).find((p) => _chunkJF5PXN7Wcjs.isVectorGradient.call(void 0, p[target]));
319
330
  if (path) return path;
320
331
  }
321
332
  return null;
@@ -324,23 +335,23 @@ function getVectorGradientAnnotator(doc, selection, viewport, target) {
324
335
  const path = vectorGradientTargetPath(doc, selection, target);
325
336
  if (!path) return null;
326
337
  const gradient = path[target];
327
- const world = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, doc.nodes, path.id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
328
- const screen = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, world, [viewport.zoom, 0, 0, viewport.zoom, viewport.x, viewport.y]);
329
- const bounds = _chunk7MD7C6XQcjs.vectorPathLocalBounds.call(void 0, path);
330
- const h = _chunk7MD7C6XQcjs.vectorGradientHandles.call(void 0, gradient, bounds, screen);
338
+ const world = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, doc.nodes, path.id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
339
+ const screen = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, world, [viewport.zoom, 0, 0, viewport.zoom, viewport.x, viewport.y]);
340
+ const bounds = _chunkJF5PXN7Wcjs.vectorPathLocalBounds.call(void 0, path);
341
+ const h = _chunkJF5PXN7Wcjs.vectorGradientHandles.call(void 0, gradient, bounds, screen);
331
342
  const v = { x: h.end.x - h.start.x, y: h.end.y - h.start.y };
332
343
  const len = Math.hypot(v.x, v.y);
333
344
  const normal = len > 1e-9 ? { x: -v.y / len, y: v.x / len } : { x: 0, y: 1 };
334
345
  const at = (t, gap) => ({ x: h.start.x + v.x * t + normal.x * gap, y: h.start.y + v.y * t + normal.y * gap });
335
- const sorted = _chunk7MD7C6XQcjs.sortedVectorGradientStops.call(void 0, gradient);
346
+ const sorted = _chunkJF5PXN7Wcjs.sortedVectorGradientStops.call(void 0, gradient);
336
347
  const stops = sorted.map((s, index) => ({ ...s, index, ...at(s.offset, VECTOR_GRADIENT_STOP_GAP) }));
337
348
  const midpoints = sorted.slice(0, -1).flatMap((s, index) => {
338
- const pos = _chunk7MD7C6XQcjs.vectorGradientMidpointPosition.call(void 0, sorted, index);
349
+ const pos = _chunkJF5PXN7Wcjs.vectorGradientMidpointPosition.call(void 0, sorted, index);
339
350
  return pos === null || sorted[index + 1].offset - s.offset < 1e-6 ? [] : [{ index, midpoint: _nullishCoalesce(s.midpoint, () => ( 0.5)), ...at(pos, -VECTOR_GRADIENT_MIDPOINT_GAP) }];
340
351
  });
341
352
  let extent = null;
342
- if (_chunk7MD7C6XQcjs.isCentredVectorGradient.call(void 0, gradient.type)) {
343
- const frame = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.vectorGradientMatrix.call(void 0, gradient, bounds), screen);
353
+ if (_chunkJF5PXN7Wcjs.isCentredVectorGradient.call(void 0, gradient.type)) {
354
+ const frame = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.vectorGradientMatrix.call(void 0, gradient, bounds), screen);
344
355
  const pts = gradient.type === "diamond" ? [{ x: 1, y: 0 }, { x: 0, y: 1 }, { x: -1, y: 0 }, { x: 0, y: -1 }] : Array.from({ length: 48 }, (_, k) => ({ x: Math.cos(k * Math.PI / 24), y: Math.sin(k * Math.PI / 24) }));
345
356
  extent = `M${pts.map((p) => apply(frame, p)).map((p) => `${fmt(p.x)} ${fmt(p.y)}`).join("L")}Z`;
346
357
  }
@@ -357,7 +368,7 @@ function hitVectorGradientAnnotator(a, p) {
357
368
  const near2 = (q, r) => !!q && Math.hypot(q.x - p.x, q.y - p.y) <= r;
358
369
  for (let i = a.stops.length - 1; i >= 0; i--) if (near2(a.stops[i], STOP_HIT)) return { kind: "stop", index: a.stops[i].index };
359
370
  for (const m of a.midpoints) if (near2(m, MIDPOINT_HIT)) return { kind: "midpoint", index: m.index };
360
- const centred = _chunk7MD7C6XQcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
371
+ const centred = _chunkJF5PXN7Wcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
361
372
  if (near2(a.end, HANDLE_HIT)) return { kind: "handle", handle: centred ? "radius" : "end" };
362
373
  if (a.focal && near2(a.focal, HANDLE_HIT) && !near2(a.start, 1)) return { kind: "handle", handle: "focal" };
363
374
  if (near2(a.start, HANDLE_HIT)) return { kind: "handle", handle: "start" };
@@ -393,8 +404,8 @@ function paintColors(p) {
393
404
  return [];
394
405
  }
395
406
  function vectorBlendColorDistance(a, b) {
396
- const pa = _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, a)[0];
397
- const pb = _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, b)[0];
407
+ const pa = _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, a)[0];
408
+ const pb = _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, b)[0];
398
409
  if (!pa || !pb) return 0;
399
410
  let d = 0;
400
411
  for (const key of ["fill", "stroke"]) {
@@ -412,7 +423,7 @@ function vectorBlendColorDistance(a, b) {
412
423
  return d;
413
424
  }
414
425
  var centreOf = (n) => {
415
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n);
426
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n);
416
427
  return b ? [b.x + b.width / 2, b.y + b.height / 2] : [0, 0];
417
428
  };
418
429
  function vectorBlendStepCount(a, b, options, length) {
@@ -424,8 +435,8 @@ function vectorBlendStepCount(a, b, options, length) {
424
435
  if (o.spacing === "smoothColor") {
425
436
  const cd = vectorBlendColorDistance(a, b);
426
437
  if (cd > 1 / 255) return Math.min(VECTOR_BLEND_MAX_SMOOTH_STEPS, Math.max(1, Math.ceil(cd * 255 / 2)));
427
- const ba = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, a);
428
- const bb = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, b);
438
+ const ba = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, a);
439
+ const bb = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, b);
429
440
  const dist3 = ba && bb ? Math.max(Math.abs(ba.x - bb.x), Math.abs(ba.y - bb.y), Math.abs(ba.x + ba.width - bb.x - bb.width), Math.abs(ba.y + ba.height - bb.y - bb.height)) : length;
430
441
  return Math.min(VECTOR_BLEND_MAX_SMOOTH_STEPS, Math.max(1, Math.ceil(dist3 / 2)));
431
442
  }
@@ -440,9 +451,9 @@ function vectorBlendRail(sp) {
440
451
  pts.push(p);
441
452
  angles.push(Math.atan2(tangent[1], tangent[0]));
442
453
  };
443
- const count = _chunk7MD7C6XQcjs.subpathSegmentCount.call(void 0, sp);
454
+ const count = _chunkJF5PXN7Wcjs.subpathSegmentCount.call(void 0, sp);
444
455
  for (let i = 0; i < count; i++) {
445
- const seg = _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, i);
456
+ const seg = _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, i);
446
457
  const samples = seg.length === 2 ? 1 : 32;
447
458
  if (i === 0) push(seg[0], _chunkXGD3FSNCcjs.segmentTangent.call(void 0, seg, 0));
448
459
  for (let k = 1; k <= samples; k++) push(_chunkXGD3FSNCcjs.segmentPoint.call(void 0, seg, k / samples), _chunkXGD3FSNCcjs.segmentTangent.call(void 0, seg, k / samples));
@@ -500,7 +511,7 @@ function morphFor(a, b, blend) {
500
511
  let byKey = inner.get(b);
501
512
  if (!byKey) inner.set(b, byKey = /* @__PURE__ */ new Map());
502
513
  let morph = byKey.get(key);
503
- if (!morph) byKey.set(key, morph = _chunk7MD7C6XQcjs.createVectorMorph.call(void 0, a, b, { linear: blend.linear, starts }));
514
+ if (!morph) byKey.set(key, morph = _chunkJF5PXN7Wcjs.createVectorMorph.call(void 0, a, b, { linear: blend.linear, starts }));
504
515
  return morph;
505
516
  }
506
517
  var wrapAngle = (a) => Math.atan2(Math.sin(a), Math.cos(a));
@@ -533,16 +544,16 @@ function generateVectorBlendChildren(group) {
533
544
  const p = vectorBlendRailAt(spine.rail, s0 + (s1 - s0) * t);
534
545
  const dx = p.point[0] - (p0.point[0] + (p1.point[0] - p0.point[0]) * t);
535
546
  const dy = p.point[1] - (p0.point[1] + (p1.point[1] - p0.point[1]) * t);
536
- let m = Math.hypot(dx, dy) > 1e-9 ? _chunk7MD7C6XQcjs.translateMatrix.call(void 0, dx, dy) : _chunk7MD7C6XQcjs.IDENTITY_MATRIX;
547
+ let m = Math.hypot(dx, dy) > 1e-9 ? _chunkDWGZUSEScjs.translateMatrix.call(void 0, dx, dy) : _chunkDWGZUSEScjs.IDENTITY_MATRIX;
537
548
  if (blend.orientToSpine) {
538
549
  const turn = wrapAngle(p.angle - (p0.angle + wrapAngle(p1.angle - p0.angle) * t));
539
550
  if (Math.abs(turn) > 1e-9) {
540
551
  const c = centreOf(step);
541
552
  const origin = { x: c[0] + m[4], y: c[1] + m[5] };
542
- m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, m, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, turn * 180 / Math.PI, origin));
553
+ m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, m, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, turn * 180 / Math.PI, origin));
543
554
  }
544
555
  }
545
- if (m !== _chunk7MD7C6XQcjs.IDENTITY_MATRIX) step = _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, step, m);
556
+ if (m !== _chunkDWGZUSEScjs.IDENTITY_MATRIX) step = _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, step, m);
546
557
  }
547
558
  out.push(asStep(step, `${group.id}~${++counter}`));
548
559
  }
@@ -589,86 +600,13 @@ function expandVectorBlend(group, newId) {
589
600
  return { ...rest, children: group.children.map((c) => c.blendStep ? plain(c, newId) : c) };
590
601
  }
591
602
  function releaseVectorBlend(group, newId) {
592
- const m = _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, group);
603
+ const m = _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, group);
593
604
  const opacity = group.opacity;
594
- const keys = vectorBlendKeys(group).map((c) => group.transform ? _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c);
605
+ const keys = vectorBlendKeys(group).map((c) => group.transform ? _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c);
595
606
  const spine = _optionalChain([group, 'access', _13 => _13.blend, 'optionalAccess', _14 => _14.spine]);
596
607
  if (!spine || spine.anchors.length < 2) return keys;
597
608
  const path = { id: newId(), type: "path", name: "Spine", fill: null, stroke: null, subpaths: [{ closed: spine.closed, anchors: spine.anchors.map((a) => ({ ...a })) }] };
598
- return [...keys, group.transform ? _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, path, m) : path];
599
- }
600
-
601
- // src/vector/perspective.ts
602
- function solve8(rows) {
603
- const m = rows.map((r) => r.slice());
604
- for (let col = 0; col < 8; col++) {
605
- let pivot = col;
606
- for (let r = col + 1; r < 8; r++) if (Math.abs(m[r][col]) > Math.abs(m[pivot][col])) pivot = r;
607
- if (!(Math.abs(m[pivot][col]) >= 1e-12)) return null;
608
- [m[col], m[pivot]] = [m[pivot], m[col]];
609
- const p = m[col];
610
- for (let r = 0; r < 8; r++) {
611
- if (r === col) continue;
612
- const f = m[r][col] / p[col];
613
- if (f !== 0) for (let k = 0; k < 9; k++) m[r][k] -= f * p[k];
614
- }
615
- }
616
- const out = [];
617
- for (let i = 0; i < 8; i++) {
618
- const v = m[i][8] / m[i][i];
619
- if (!Number.isFinite(v)) return null;
620
- out.push(v);
621
- }
622
- return out;
623
- }
624
- function applyVectorHomography(h, p) {
625
- const w = h[6] * p.x + h[7] * p.y + h[8];
626
- if (!Number.isFinite(w) || Math.abs(w) < 1e-12) return null;
627
- const x = (h[0] * p.x + h[1] * p.y + h[2]) / w;
628
- const y = (h[3] * p.x + h[4] * p.y + h[5]) / w;
629
- return Number.isFinite(x) && Number.isFinite(y) ? { x, y } : null;
630
- }
631
- var finite = (p) => Number.isFinite(p.x) && Number.isFinite(p.y);
632
- function vectorHomography(from, to) {
633
- if (from.length !== 4 || to.length !== 4 || ![...from, ...to].every(finite)) return null;
634
- const rows = [];
635
- for (let i = 0; i < 4; i++) {
636
- const { x, y } = from[i];
637
- const { x: u, y: v } = to[i];
638
- rows.push([x, y, 1, 0, 0, 0, -u * x, -u * y, u]);
639
- rows.push([0, 0, 0, x, y, 1, -v * x, -v * y, v]);
640
- }
641
- const h = solve8(rows);
642
- if (!h) return null;
643
- const out = [h[0], h[1], h[2], h[3], h[4], h[5], h[6], h[7], 1];
644
- for (let i = 0; i < 4; i++) {
645
- const r = applyVectorHomography(out, from[i]);
646
- const q = to[i];
647
- const scale = 1 + Math.max(Math.abs(q.x), Math.abs(q.y));
648
- if (!r || Math.abs(r.x - q.x) > 1e-6 * scale || Math.abs(r.y - q.y) > 1e-6 * scale) return null;
649
- }
650
- return out;
651
- }
652
- function vectorHomographyKeepsQuad(h, quad) {
653
- const ws = quad.map((p) => h[6] * p.x + h[7] * p.y + h[8]);
654
- return ws.every((w) => w > 1e-9) || ws.every((w) => w < -1e-9);
655
- }
656
- function orderVectorQuad(points) {
657
- if (points.length !== 4 || !points.every(finite)) return null;
658
- const cx = points.reduce((s, p) => s + p.x, 0) / 4;
659
- const cy = points.reduce((s, p) => s + p.y, 0) / 4;
660
- const q = points.slice().sort((a, b) => Math.atan2(a.y - cy, a.x - cx) - Math.atan2(b.y - cy, b.x - cx));
661
- let first = 0;
662
- for (let i = 1; i < 4; i++) if (q[i].x + q[i].y < q[first].x + q[first].y) first = i;
663
- const ordered = [...q.slice(first), ...q.slice(0, first)];
664
- const cross = (o, a, b) => (a.x - o.x) * (b.y - o.y) - (a.y - o.y) * (b.x - o.x);
665
- const turns = ordered.map((_, i) => cross(ordered[i], ordered[(i + 1) % 4], ordered[(i + 2) % 4]));
666
- const area = turns.reduce((s, t) => s + t, 0) / 2;
667
- const xs = ordered.map((p) => p.x);
668
- const ys = ordered.map((p) => p.y);
669
- const size = Math.max(Math.max(...xs) - Math.min(...xs), Math.max(...ys) - Math.min(...ys));
670
- const convex = turns.every((t) => t > 1e-9 * size * size);
671
- return convex && area > 1e-6 * size * size ? ordered : null;
609
+ return [...keys, group.transform ? _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, path, m) : path];
672
610
  }
673
611
 
674
612
  // src/vector/distort.ts
@@ -705,7 +643,7 @@ function vectorDistortQuad(b, handle, d, mode = "distort") {
705
643
  if (side) for (const k of side) q[k] = { x: q[k].x + d.x, y: q[k].y + d.y };
706
644
  return q;
707
645
  }
708
- var about = (o, m) => _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, [1, 0, 0, 1, -o.x, -o.y], m), [1, 0, 0, 1, o.x, o.y]);
646
+ var about = (o, m) => _chunkDWGZUSEScjs.matrixAbout.call(void 0, m, o);
709
647
  function vectorShearForSide(b, handle, d, fromCenter = false) {
710
648
  const center = { x: b.x + b.width / 2, y: b.y + b.height / 2 };
711
649
  if (handle === "n" || handle === "s") {
@@ -721,24 +659,22 @@ function vectorShearForSide(b, handle, d, fromCenter = false) {
721
659
  return [1, 0, 0, 1, 0, 0];
722
660
  }
723
661
  function vectorSkewMatrix(ax, ay, origin = { x: 0, y: 0 }) {
724
- const tx = Math.tan(ax * Math.PI / 180);
725
- const ty = Math.tan(ay * Math.PI / 180);
726
- return about(origin, [1, ty, tx, 1, 0, 0]);
662
+ return _chunkDWGZUSEScjs.skewMatrix.call(void 0, ax, ay, origin);
727
663
  }
728
664
  function mapEffects(node, f) {
729
665
  if (!_optionalChain([node, 'access', _15 => _15.effects, 'optionalAccess', _16 => _16.length])) return void 0;
730
666
  return node.effects.map((e) => {
731
667
  if (e.type !== "envelope") return e;
732
- if (e.params.style === "mesh") return e.params.mesh ? { ...e, params: { ...e.params, mesh: _chunk7MD7C6XQcjs.mapVectorMeshPoints.call(void 0, e.params.mesh, f) } } : e;
733
- const bounds = _chunk7MD7C6XQcjs.vectorEffectInputBounds.call(void 0, node, e.id);
734
- if (!bounds || !_chunk7MD7C6XQcjs.vectorEnvelopeMap.call(void 0, e.params, bounds)) return e;
735
- return { ...e, params: { ...e.params, style: "mesh", mesh: _chunk7MD7C6XQcjs.mapVectorMeshPoints.call(void 0, _chunk7MD7C6XQcjs.vectorEnvelopeMesh.call(void 0, e.params, bounds), f) } };
668
+ if (e.params.style === "mesh") return e.params.mesh ? { ...e, params: { ...e.params, mesh: _chunkDWGZUSEScjs.mapWarpMeshPoints.call(void 0, e.params.mesh, f) } } : e;
669
+ const bounds = _chunkJF5PXN7Wcjs.vectorEffectInputBounds.call(void 0, node, e.id);
670
+ if (!bounds || !_chunkJF5PXN7Wcjs.vectorEnvelopeMap.call(void 0, e.params, bounds)) return e;
671
+ return { ...e, params: { ...e.params, style: "mesh", mesh: _chunkDWGZUSEScjs.mapWarpMeshPoints.call(void 0, _chunkJF5PXN7Wcjs.vectorEnvelopeMesh.call(void 0, e.params, bounds), f) } };
736
672
  });
737
673
  }
738
674
  function distortVectorNode(node, parentToDoc, f, tolerance = VECTOR_DISTORT_TOLERANCE) {
739
- const toDoc = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node), parentToDoc);
740
- const inv = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, toDoc);
741
- const local = (p) => _chunk7MD7C6XQcjs.applyMatrix.call(void 0, inv, f(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, p)));
675
+ const toDoc = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node), parentToDoc);
676
+ const inv = _chunkDWGZUSEScjs.invertMatrix.call(void 0, toDoc);
677
+ const local = (p) => _chunkDWGZUSEScjs.applyMatrix.call(void 0, inv, f(_chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, p)));
742
678
  const effects = mapEffects(node, local);
743
679
  if (node.type === "group") {
744
680
  const group = node;
@@ -748,16 +684,16 @@ function distortVectorNode(node, parentToDoc, f, tolerance = VECTOR_DISTORT_TOLE
748
684
  ...group,
749
685
  children,
750
686
  ...effects ? { effects } : {},
751
- ...spine ? { blend: { ...group.blend, spine: _chunk7MD7C6XQcjs.mapVectorSubpaths.call(void 0, [spine], local, tolerance)[0] } } : {}
687
+ ...spine ? { blend: { ...group.blend, spine: _chunkJF5PXN7Wcjs.mapVectorSubpaths.call(void 0, [spine], local, tolerance)[0] } } : {}
752
688
  };
753
689
  }
754
690
  const path = node;
755
691
  return {
756
692
  ...path,
757
693
  ...effects ? { effects } : {},
758
- ...path.fill !== void 0 ? { fill: _chunk7MD7C6XQcjs.mapVectorPaint.call(void 0, path.fill, local) } : {},
759
- ...path.stroke !== void 0 ? { stroke: _chunk7MD7C6XQcjs.mapVectorPaint.call(void 0, path.stroke, local) } : {},
760
- subpaths: _chunk7MD7C6XQcjs.mapVectorSubpaths.call(void 0, path.subpaths, local, tolerance)
694
+ ...path.fill !== void 0 ? { fill: _chunkJF5PXN7Wcjs.mapVectorPaint.call(void 0, path.fill, local) } : {},
695
+ ...path.stroke !== void 0 ? { stroke: _chunkJF5PXN7Wcjs.mapVectorPaint.call(void 0, path.stroke, local) } : {},
696
+ subpaths: _chunkJF5PXN7Wcjs.mapVectorSubpaths.call(void 0, path.subpaths, local, tolerance)
761
697
  };
762
698
  }
763
699
 
@@ -818,11 +754,11 @@ var LABELS = {
818
754
  };
819
755
  var fmtLength = (n) => String(Math.round(n * 100) / 100);
820
756
  function nodeFrame(node, parent, aabb) {
821
- const angle = _chunk7MD7C6XQcjs.matrixRotation.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node), parent));
822
- const b = angle ? _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, node, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, parent, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -angle))) : aabb !== void 0 ? aabb : _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, node, parent);
757
+ const angle = _chunkDWGZUSEScjs.matrixRotation.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node), parent));
758
+ const b = angle ? _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, node, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, parent, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -angle))) : aabb !== void 0 ? aabb : _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, node, parent);
823
759
  if (!b) return null;
824
760
  const c = { x: b.x + b.width / 2, y: b.y + b.height / 2 };
825
- return { width: b.width, height: b.height, centre: angle ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, angle), c) : c };
761
+ return { width: b.width, height: b.height, centre: angle ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, angle), c) : c };
826
762
  }
827
763
  function contains(node, ids) {
828
764
  if (ids.has(node.id)) return true;
@@ -894,13 +830,13 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
894
830
  let segmentBudget = segments ? BUDGET : 0;
895
831
  const visit = (list, parent) => {
896
832
  for (const n of list) {
897
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent);
833
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent);
898
834
  if (n.type === "group") visit(n.children, m);
899
835
  else if (ids.has(n.id) && n.visible !== false) {
900
836
  n.subpaths.forEach((sp, s) => {
901
837
  sp.anchors.forEach((a, i) => {
902
838
  if (anchors <= 0 || moving(n.id, s, i)) return;
903
- this.pushAnchor(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, a));
839
+ this.pushAnchor(_chunkDWGZUSEScjs.applyMatrix.call(void 0, m, a));
904
840
  anchors--;
905
841
  });
906
842
  segmentBudget = this.pushSegments(sp, m, (i) => moving(n.id, s, i), segmentBudget);
@@ -908,7 +844,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
908
844
  }
909
845
  }
910
846
  };
911
- visit(doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
847
+ visit(doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
912
848
  }
913
849
  pushAnchor(p) {
914
850
  this.points.push({ p, kind: "anchor" });
@@ -918,10 +854,10 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
918
854
  /** The segments of `sp` (mapped by `m`) that stay put while the anchors `moving` accepts move. */
919
855
  pushSegments(sp, m, moving, budget) {
920
856
  const n = sp.anchors.length;
921
- const count = _chunk7MD7C6XQcjs.subpathSegmentCount.call(void 0, sp);
857
+ const count = _chunkJF5PXN7Wcjs.subpathSegmentCount.call(void 0, sp);
922
858
  for (let i = 0; i < count && budget > 0; i++) {
923
859
  if (moving(i) || moving((i + 1) % n)) continue;
924
- const seg = _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, i).map((q) => toPoint(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, toVec(q))));
860
+ const seg = _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, i).map((q) => toPoint(_chunkDWGZUSEScjs.applyMatrix.call(void 0, m, toVec(q))));
925
861
  let minX = Infinity;
926
862
  let minY = Infinity;
927
863
  let maxX = -Infinity;
@@ -976,8 +912,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
976
912
  const visit = (list, parent) => {
977
913
  for (const stored of list) {
978
914
  if (exclude.has(stored.id) || stored.visible === false) continue;
979
- const n = contains(stored, exclude) ? stored : _chunk7MD7C6XQcjs.expandVectorAppearance.call(void 0, stored);
980
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent);
915
+ const n = contains(stored, exclude) ? stored : _chunkJF5PXN7Wcjs.expandVectorAppearance.call(void 0, stored);
916
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent);
981
917
  if (n.type === "group") {
982
918
  visit(n.children, m);
983
919
  continue;
@@ -986,32 +922,32 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
986
922
  for (const sp of n.subpaths) {
987
923
  for (const a of sp.anchors) {
988
924
  if (anchors-- <= 0) break;
989
- const p = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, a);
925
+ const p = _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, a);
990
926
  if (gather === "drawing") self.pushAnchor(p);
991
927
  else self.points.push({ p, kind: "anchor" });
992
928
  }
993
929
  if (gather !== "bounds") segments = self.pushSegments(sp, m, () => false, segments);
994
930
  }
995
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n, parent);
931
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n, parent);
996
932
  const f = nodeFrame(n, parent, b);
997
933
  if (b) self.pushRect(b, "edge", _nullishCoalesce(_optionalChain([f, 'optionalAccess', _24 => _24.centre]), () => ( null)));
998
934
  }
999
935
  };
1000
- visit(doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
936
+ visit(doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
1001
937
  const objects = (list, parent) => {
1002
938
  for (const n of list) {
1003
939
  if (exclude.has(n.id) || n.visible === false || self.boxes.length >= BUDGET) continue;
1004
940
  if (n.type === "group" && contains(n, exclude)) {
1005
- objects(n.children, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent));
941
+ objects(n.children, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent));
1006
942
  continue;
1007
943
  }
1008
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n, parent);
944
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n, parent);
1009
945
  if (b) self.boxes.push(b);
1010
946
  const f = nodeFrame(n, parent, b);
1011
947
  if (f) self.sizes.push(f.width, f.height);
1012
948
  }
1013
949
  };
1014
- objects(doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
950
+ objects(doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
1015
951
  return sort ? self.index() : self;
1016
952
  }
1017
953
  // -------------------------------------------------------------------------
@@ -1292,8 +1228,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1292
1228
  * may match another object's width or height instead.
1293
1229
  */
1294
1230
  snapScale(frame, handle, sx, sy, mods, tol) {
1295
- const toDoc = frame.angle ? _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, frame.angle) : _chunk7MD7C6XQcjs.IDENTITY_MATRIX;
1296
- const toLocal = frame.angle ? _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -frame.angle) : _chunk7MD7C6XQcjs.IDENTITY_MATRIX;
1231
+ const toDoc = frame.angle ? _chunkDWGZUSEScjs.rotateMatrix.call(void 0, frame.angle) : _chunkDWGZUSEScjs.IDENTITY_MATRIX;
1232
+ const toLocal = frame.angle ? _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -frame.angle) : _chunkDWGZUSEScjs.IDENTITY_MATRIX;
1297
1233
  const corner = handle.length === 2;
1298
1234
  const proportional = !!mods.shift;
1299
1235
  const centre = { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 };
@@ -1310,7 +1246,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1310
1246
  let ny = sy;
1311
1247
  let snap = { hx: null, hy: null, on: null };
1312
1248
  if (corner && !proportional) {
1313
- const p = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * sx, y: origin.y + d0.y * sy });
1249
+ const p = _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * sx, y: origin.y + d0.y * sy });
1314
1250
  const hx = nearest(p.x, this.xs);
1315
1251
  const hy = nearest(p.y, this.ys);
1316
1252
  const on = this.nearestPoint(p, tol);
@@ -1321,7 +1257,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1321
1257
  tries.push({ tx: null, ty: _nullishCoalesce(_optionalChain([hy, 'optionalAccess', _37 => _37.v]), () => ( null)), s: { hx: null, hy, on: null } });
1322
1258
  for (const { tx, ty, s } of tries) {
1323
1259
  if (tx === null && ty === null) continue;
1324
- const q = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toLocal, { x: _nullishCoalesce(tx, () => ( p.x)), y: _nullishCoalesce(ty, () => ( p.y)) });
1260
+ const q = _chunkDWGZUSEScjs.applyMatrix.call(void 0, toLocal, { x: _nullishCoalesce(tx, () => ( p.x)), y: _nullishCoalesce(ty, () => ( p.y)) });
1325
1261
  let cx = (q.x - origin.x) / d0.x;
1326
1262
  let cy = (q.y - origin.y) / d0.y;
1327
1263
  if (!frame.angle) {
@@ -1355,8 +1291,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1355
1291
  for (const h of [handle, ...ends]) {
1356
1292
  const hv = handlePos(h, frame);
1357
1293
  const v = { x: hv.x - origin.x, y: hv.y - origin.y };
1358
- const base = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + c.x * v.x, y: origin.y + c.y * v.y });
1359
- const dir = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, { x: e.x * v.x, y: e.y * v.y });
1294
+ const base = _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, { x: origin.x + c.x * v.x, y: origin.y + c.y * v.y });
1295
+ const dir = _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, { x: e.x * v.x, y: e.y * v.y });
1360
1296
  const p = { x: base.x + dir.x * s0, y: base.y + dir.y * s0 };
1361
1297
  const l2 = dir.x * dir.x + dir.y * dir.y;
1362
1298
  const on = l2 > 1e-18 ? this.nearestPoint(p, tol) : null;
@@ -1378,7 +1314,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1378
1314
  }
1379
1315
  }
1380
1316
  const out = { sx: nx, sy: ny, snapped: false, lines: [], labels: [] };
1381
- const handleAt = () => _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * out.sx, y: origin.y + d0.y * out.sy });
1317
+ const handleAt = () => _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * out.sx, y: origin.y + d0.y * out.sy });
1382
1318
  if (snap.on) {
1383
1319
  out.snapped = true;
1384
1320
  out.labels.push(this.label(snap.on.p, snap.on.kind));
@@ -1413,7 +1349,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1413
1349
  { x: box.x1, y: box.y0 },
1414
1350
  { x: box.x1, y: box.y1 },
1415
1351
  { x: box.x0, y: box.y1 }
1416
- ].map((q) => _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, q));
1352
+ ].map((q) => _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, q));
1417
1353
  const pminY = Math.min(...page.map((q) => q.y));
1418
1354
  const pmaxY = Math.max(...page.map((q) => q.y));
1419
1355
  const pminX = Math.min(...page.map((q) => q.x));
@@ -1428,8 +1364,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1428
1364
  out.snapped = true;
1429
1365
  const off = tol * 2;
1430
1366
  const [a, b] = axis === "x" ? [{ x: box.x0, y: box.y1 + off }, { x: box.x1, y: box.y1 + off }] : [{ x: box.x1 + off, y: box.y0 }, { x: box.x1 + off, y: box.y1 }];
1431
- const pa = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, a);
1432
- const pb = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toDoc, b);
1367
+ const pa = _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, a);
1368
+ const pb = _chunkDWGZUSEScjs.applyMatrix.call(void 0, toDoc, b);
1433
1369
  out.lines.push(line("size", pa, pb));
1434
1370
  out.labels.push(this.label({ x: (pa.x + pb.x) / 2, y: (pa.y + pb.y) / 2 }, "size", `${axis === "x" ? "W" : "H"} ${fmtLength(axis === "x" ? box.x1 - box.x0 : box.y1 - box.y0)}`));
1435
1371
  }
@@ -1520,12 +1456,12 @@ var unit = (x, y) => {
1520
1456
  return l > 1e-12 && Number.isFinite(l) ? [x / l, y / l] : null;
1521
1457
  };
1522
1458
  function cubicOf(sp, i) {
1523
- const s = _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, i);
1459
+ const s = _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, i);
1524
1460
  if (s.length === 4) return s;
1525
1461
  const [a, b] = s;
1526
1462
  return [a, [a[0] + (b[0] - a[0]) / 3, a[1] + (b[1] - a[1]) / 3], [a[0] + 2 * (b[0] - a[0]) / 3, a[1] + 2 * (b[1] - a[1]) / 3], b];
1527
1463
  }
1528
- var isLine = (sp, i) => _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, i).length === 2;
1464
+ var isLine = (sp, i) => _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, i).length === 2;
1529
1465
  function startTangent(c) {
1530
1466
  for (let k = 1; k < 4; k++) {
1531
1467
  const u = unit(c[k][0] - c[0][0], c[k][1] - c[0][1]);
@@ -1545,10 +1481,10 @@ function sample(c, n, out, withStart) {
1545
1481
  }
1546
1482
  var onAnchor = (a, h) => !h || Math.abs(h.x - a.x) < EPS && Math.abs(h.y - a.y) < EPS;
1547
1483
  function tidy(a, keepType = true) {
1548
- const next = _chunk7MD7C6XQcjs.cloneAnchor.call(void 0, a);
1484
+ const next = _chunkJF5PXN7Wcjs.cloneAnchor.call(void 0, a);
1549
1485
  if (onAnchor(next, next.in)) delete next.in;
1550
1486
  if (onAnchor(next, next.out)) delete next.out;
1551
- const shown = _chunk7MD7C6XQcjs.inferAnchorType.call(void 0, next);
1487
+ const shown = _chunkJF5PXN7Wcjs.inferAnchorType.call(void 0, next);
1552
1488
  const type = keepType && a.type ? a.type === "symmetric" && shown !== "symmetric" ? shown === "corner" ? "corner" : "smooth" : a.type === "smooth" && shown === "corner" ? "corner" : a.type : shown;
1553
1489
  if (type === "corner") delete next.type;
1554
1490
  else next.type = type;
@@ -1592,7 +1528,7 @@ function fitAcross(pts, N, t0, t1) {
1592
1528
  return goldenMin(fit, 0, 1);
1593
1529
  }
1594
1530
  function removeAnchorKeepingShape(sp, index) {
1595
- const anchors = sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor);
1531
+ const anchors = sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor);
1596
1532
  const n = anchors.length;
1597
1533
  if (index < 0 || index >= n) return { anchors, closed: sp.closed };
1598
1534
  if ((sp.closed || index > 0 && index < n - 1) && n >= 3) {
@@ -1626,12 +1562,12 @@ function removeAnchorKeepingShape(sp, index) {
1626
1562
  }
1627
1563
  function removeAnchorsKeepingShape(sp, indices) {
1628
1564
  const order = [...new Set(indices)].filter((i) => i >= 0 && i < sp.anchors.length).sort((a, b) => b - a);
1629
- return order.reduce((acc, i) => removeAnchorKeepingShape(acc, i), { anchors: sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor), closed: sp.closed });
1565
+ return order.reduce((acc, i) => removeAnchorKeepingShape(acc, i), { anchors: sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor), closed: sp.closed });
1630
1566
  }
1631
1567
  function bendSegment(sp, segment, t, p) {
1632
- const anchors = sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor);
1568
+ const anchors = sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor);
1633
1569
  const n = anchors.length;
1634
- if (segment < 0 || segment >= _chunk7MD7C6XQcjs.subpathSegmentCount.call(void 0, sp) || !Number.isFinite(t) || !Number.isFinite(p.x) || !Number.isFinite(p.y)) return { anchors, closed: sp.closed };
1570
+ if (segment < 0 || segment >= _chunkJF5PXN7Wcjs.subpathSegmentCount.call(void 0, sp) || !Number.isFinite(t) || !Number.isFinite(p.x) || !Number.isFinite(p.y)) return { anchors, closed: sp.closed };
1635
1571
  const tc = Math.min(0.95, Math.max(0.05, t));
1636
1572
  const ia = segment;
1637
1573
  const ib = (segment + 1) % n;
@@ -1642,16 +1578,16 @@ function bendSegment(sp, segment, t, p) {
1642
1578
  const oy = (p.y - (a.y + (b.y - a.y) * tc)) / k;
1643
1579
  const c1 = { x: a.x + (b.x - a.x) / 3 + ox, y: a.y + (b.y - a.y) / 3 + oy };
1644
1580
  const c2 = { x: b.x + (a.x - b.x) / 3 + ox, y: b.y + (a.y - b.y) / 3 + oy };
1645
- anchors[ia] = _chunk7MD7C6XQcjs.moveAnchorHandle.call(void 0, a, "out", c1);
1646
- anchors[ib] = _chunk7MD7C6XQcjs.moveAnchorHandle.call(void 0, b, "in", c2);
1581
+ anchors[ia] = _chunkJF5PXN7Wcjs.moveAnchorHandle.call(void 0, a, "out", c1);
1582
+ anchors[ib] = _chunkJF5PXN7Wcjs.moveAnchorHandle.call(void 0, b, "in", c2);
1647
1583
  return { anchors, closed: sp.closed };
1648
1584
  }
1649
1585
  function subpathPointAt(sp, segment, t) {
1650
- const [x, y] = _chunkXGD3FSNCcjs.segmentPoint.call(void 0, _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, segment), t);
1586
+ const [x, y] = _chunkXGD3FSNCcjs.segmentPoint.call(void 0, _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, segment), t);
1651
1587
  return { x, y };
1652
1588
  }
1653
1589
  function curvatureMoveAnchor(sp, index, q) {
1654
- const anchors = sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor);
1590
+ const anchors = sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor);
1655
1591
  const a = sp.anchors[index];
1656
1592
  if (!a) return { anchors, closed: sp.closed };
1657
1593
  const own = [
@@ -1696,7 +1632,7 @@ function curvatureMoveAnchor(sp, index, q) {
1696
1632
  function cutSubpathAt(sp, at) {
1697
1633
  const n = sp.anchors.length;
1698
1634
  const cuts = [...new Set(at)].filter((i) => Number.isInteger(i) && i >= 0 && i < n && (sp.closed || i > 0 && i < n - 1)).sort((a, b) => a - b);
1699
- if (!cuts.length || n < 2) return [{ anchors: sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor), closed: sp.closed }];
1635
+ if (!cuts.length || n < 2) return [{ anchors: sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor), closed: sp.closed }];
1700
1636
  const first = cuts[0];
1701
1637
  const run = sp.closed ? Array.from({ length: n + 1 }, (_, i) => sp.anchors[(first + i) % n]) : sp.anchors;
1702
1638
  const cutSet = new Set(sp.closed ? [...cuts.map((c) => (c - first + n) % n), n] : cuts);
@@ -1704,7 +1640,7 @@ function cutSubpathAt(sp, at) {
1704
1640
  let cur = [];
1705
1641
  run.forEach((a, i) => {
1706
1642
  if (!cutSet.has(i)) {
1707
- cur.push(_chunk7MD7C6XQcjs.cloneAnchor.call(void 0, a));
1643
+ cur.push(_chunkJF5PXN7Wcjs.cloneAnchor.call(void 0, a));
1708
1644
  return;
1709
1645
  }
1710
1646
  if (cur.length) {
@@ -1719,10 +1655,10 @@ function cutSubpathAt(sp, at) {
1719
1655
  }
1720
1656
  function splitSubpathAt(sp, segment, t, endTolerance = 1e-6) {
1721
1657
  const n = sp.anchors.length;
1722
- if (segment < 0 || segment >= _chunk7MD7C6XQcjs.subpathSegmentCount.call(void 0, sp)) return [{ anchors: sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor), closed: sp.closed }];
1658
+ if (segment < 0 || segment >= _chunkJF5PXN7Wcjs.subpathSegmentCount.call(void 0, sp)) return [{ anchors: sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor), closed: sp.closed }];
1723
1659
  if (t <= endTolerance) return cutSubpathAt(sp, [segment]);
1724
1660
  if (t >= 1 - endTolerance) return cutSubpathAt(sp, [(segment + 1) % n]);
1725
- const { subpath, index } = _chunk7MD7C6XQcjs.insertAnchor.call(void 0, sp, segment, t);
1661
+ const { subpath, index } = _chunkJF5PXN7Wcjs.insertAnchor.call(void 0, sp, segment, t);
1726
1662
  return cutSubpathAt(subpath, [index]);
1727
1663
  }
1728
1664
  var endOf = (sp, last) => sp.anchors[last ? sp.anchors.length - 1 : 0];
@@ -1744,7 +1680,7 @@ function joinSubpaths(subpaths, tolerance) {
1744
1680
  const closed = [];
1745
1681
  let open = [];
1746
1682
  for (const sp of subpaths) {
1747
- const copy = { anchors: sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor), closed: sp.closed };
1683
+ const copy = { anchors: sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor), closed: sp.closed };
1748
1684
  if (sp.closed || sp.anchors.length < 2) {
1749
1685
  if (sp.anchors.length) closed.push(copy);
1750
1686
  } else open.push(copy);
@@ -1799,7 +1735,7 @@ function smoothSubpath(sp, amount = 1, only) {
1799
1735
  const t = Math.min(1, Math.max(0, amount));
1800
1736
  const orig = sp.anchors;
1801
1737
  const n = orig.length;
1802
- const anchors = orig.map(_chunk7MD7C6XQcjs.cloneAnchor);
1738
+ const anchors = orig.map(_chunkJF5PXN7Wcjs.cloneAnchor);
1803
1739
  if (n < 3 || t === 0) return { anchors, closed: sp.closed };
1804
1740
  for (let i = 0; i < n; i++) {
1805
1741
  if (!sp.closed && (i === 0 || i === n - 1)) continue;
@@ -1828,8 +1764,8 @@ function smoothSubpath(sp, amount = 1, only) {
1828
1764
  }
1829
1765
  function segsOf(sp) {
1830
1766
  const out = [];
1831
- for (let i = 0; i < _chunk7MD7C6XQcjs.subpathSegmentCount.call(void 0, sp); i++) {
1832
- const s = _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, i);
1767
+ for (let i = 0; i < _chunkJF5PXN7Wcjs.subpathSegmentCount.call(void 0, sp); i++) {
1768
+ const s = _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, i);
1833
1769
  out.push(s.length === 2 ? { c: s, line: true } : { c: s, line: false });
1834
1770
  }
1835
1771
  return out;
@@ -1886,7 +1822,7 @@ function removeRedundantPoints(sp, tolerance) {
1886
1822
  const tol = Math.max(tolerance, 1e-9);
1887
1823
  const types = new Map(sp.anchors.filter((a) => a.type).map((a) => [`${a.x},${a.y}`, a.type]));
1888
1824
  const segs = segsOf(sp).filter((s) => !isZeroSeg(s));
1889
- if (!segs.length) return { anchors: sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor), closed: sp.closed };
1825
+ if (!segs.length) return { anchors: sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor), closed: sp.closed };
1890
1826
  const minSegs = sp.closed ? 2 : 1;
1891
1827
  let changed = true;
1892
1828
  while (changed && segs.length > minSegs) {
@@ -1904,7 +1840,7 @@ function removeRedundantPoints(sp, tolerance) {
1904
1840
  break;
1905
1841
  }
1906
1842
  }
1907
- return _nullishCoalesce(segsToSubpath(segs, sp.closed, types), () => ( { anchors: sp.anchors.map(_chunk7MD7C6XQcjs.cloneAnchor), closed: sp.closed }));
1843
+ return _nullishCoalesce(segsToSubpath(segs, sp.closed, types), () => ( { anchors: sp.anchors.map(_chunkJF5PXN7Wcjs.cloneAnchor), closed: sp.closed }));
1908
1844
  }
1909
1845
 
1910
1846
  // src/vector/pathCut.ts
@@ -2143,14 +2079,14 @@ function eraseFromOutline(sp, region) {
2143
2079
  const regionSegs = _chunkXGD3FSNCcjs.pathToContours.call(void 0, region).flatMap((c) => _chunkXGD3FSNCcjs.closeContour.call(void 0, c, true));
2144
2080
  if (!regionSegs.length) return null;
2145
2081
  const rb = _chunkXGD3FSNCcjs.bezierPathBounds.call(void 0, region);
2146
- const count = _chunk7MD7C6XQcjs.subpathSegmentCount.call(void 0, sp);
2082
+ const count = _chunkJF5PXN7Wcjs.subpathSegmentCount.call(void 0, sp);
2147
2083
  if (!rb || count === 0) return null;
2148
2084
  const removed = (p) => _chunkXGD3FSNCcjs.pointInBezierPath.call(void 0, region, p, "nonzero");
2149
2085
  const runs = [];
2150
2086
  let cur = [];
2151
2087
  let any = false;
2152
2088
  for (let i = 0; i < count; i++) {
2153
- const seg = _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, i);
2089
+ const seg = _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, i);
2154
2090
  const sb = _chunkXGD3FSNCcjs.segmentBounds.call(void 0, seg);
2155
2091
  const ts = [0, 1];
2156
2092
  if (!(sb.maxX < rb.minX || sb.minX > rb.maxX || sb.maxY < rb.minY || sb.minY > rb.maxY)) {
@@ -2184,7 +2120,7 @@ function eraseFromOutline(sp, region) {
2184
2120
  for (const run of runs) {
2185
2121
  const anchors = [];
2186
2122
  for (const { seg, t0, t1 } of run) {
2187
- const c = _chunkXGD3FSNCcjs.subSegment.call(void 0, _chunk7MD7C6XQcjs.subpathSegment.call(void 0, sp, seg), t0, t1);
2123
+ const c = _chunkXGD3FSNCcjs.subSegment.call(void 0, _chunkJF5PXN7Wcjs.subpathSegment.call(void 0, sp, seg), t0, t1);
2188
2124
  const line2 = c.length === 2;
2189
2125
  const start = c[0];
2190
2126
  const end = c[c.length - 1];
@@ -2196,7 +2132,7 @@ function eraseFromOutline(sp, region) {
2196
2132
  }
2197
2133
  if (anchors.length < 2) continue;
2198
2134
  for (const a of anchors) {
2199
- const type = _chunk7MD7C6XQcjs.inferAnchorType.call(void 0, a);
2135
+ const type = _chunkJF5PXN7Wcjs.inferAnchorType.call(void 0, a);
2200
2136
  if (type !== "corner") a.type = type;
2201
2137
  }
2202
2138
  out.push({ anchors, closed: false });
@@ -2478,22 +2414,22 @@ function vectorPathEntries(doc, roots, options = {}) {
2478
2414
  const out = [];
2479
2415
  const visit = (stored, parent, inside) => {
2480
2416
  if (stored.visible === false || stored.locked && !options.locked) return;
2481
- const node = options.expand === false ? stored : _chunk7MD7C6XQcjs.expandVectorAppearance.call(void 0, stored);
2417
+ const node = options.expand === false ? stored : _chunkJF5PXN7Wcjs.expandVectorAppearance.call(void 0, stored);
2482
2418
  const picked = inside || roots === null || roots.includes(node.id);
2483
2419
  if (node.type === "group") {
2484
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node), parent);
2420
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node), parent);
2485
2421
  for (const c of node.children) visit(c, m, picked);
2486
2422
  } else if (picked) out.push({ node, parent });
2487
2423
  };
2488
- for (const n of doc.nodes) visit(n, _chunk7MD7C6XQcjs.IDENTITY_MATRIX, false);
2424
+ for (const n of doc.nodes) visit(n, _chunkDWGZUSEScjs.IDENTITY_MATRIX, false);
2489
2425
  return out;
2490
2426
  }
2491
2427
  var usable = (sp) => sp.anchors.length > 1;
2492
2428
  function worldOf(entry, subpaths) {
2493
- return _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, { ...entry.node, subpaths }, entry.parent);
2429
+ return _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, { ...entry.node, subpaths }, entry.parent);
2494
2430
  }
2495
2431
  function subpathEnclosesArea(sp) {
2496
- const contour = _chunkXGD3FSNCcjs.pathToContours.call(void 0, _chunk7MD7C6XQcjs.subpathsToBezier.call(void 0, [{ ...sp, closed: true }]))[0];
2432
+ const contour = _chunkXGD3FSNCcjs.pathToContours.call(void 0, _chunkJF5PXN7Wcjs.subpathsToBezier.call(void 0, [{ ...sp, closed: true }]))[0];
2497
2433
  if (!contour) return false;
2498
2434
  const segs = _chunkXGD3FSNCcjs.closeContour.call(void 0, contour, true);
2499
2435
  const b = _chunkXGD3FSNCcjs.bezierPathBounds.call(void 0, _chunkXGD3FSNCcjs.contoursToPath.call(void 0, [{ segments: segs, closed: true }]));
@@ -2508,11 +2444,11 @@ function vectorPathfinderShape(entry, op) {
2508
2444
  const subpaths = node.subpaths.filter(usable);
2509
2445
  const closed = subpaths.map((s) => ({ ...s, closed: true }));
2510
2446
  const fillRule = _nullishCoalesce(node.fillRule, () => ( "nonzero"));
2511
- if (_chunk7MD7C6XQcjs.hasPaint.call(void 0, node.fill)) return { path: worldOf(entry, closed), fillRule, key: `fill:${paintKey(node.fill)}`, paint: "fill" };
2447
+ if (_chunkJF5PXN7Wcjs.hasPaint.call(void 0, node.fill)) return { path: worldOf(entry, closed), fillRule, key: `fill:${paintKey(node.fill)}`, paint: "fill" };
2512
2448
  const open = subpaths.length > 0 && subpaths.every((s) => !s.closed);
2513
2449
  if (op === "divide" && open) return { path: worldOf(entry, subpaths), line: true, paint: "line" };
2514
- if (_chunk7MD7C6XQcjs.hasPaint.call(void 0, node.stroke) && (_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0) {
2515
- const path = _chunk7MD7C6XQcjs.vectorStrokeOutline.call(void 0, { ...node, subpaths }, entry.parent);
2450
+ if (_chunkJF5PXN7Wcjs.hasPaint.call(void 0, node.stroke) && (_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0) {
2451
+ const path = _chunkJF5PXN7Wcjs.vectorStrokeOutline.call(void 0, { ...node, subpaths }, entry.parent);
2516
2452
  return { path, fillRule: "nonzero", key: `fill:${paintKey(node.stroke)}`, paint: "stroke" };
2517
2453
  }
2518
2454
  return { path: worldOf(entry, closed), fillRule, key: "none", paint: "outline" };
@@ -2536,7 +2472,7 @@ function vectorResultStyle(node, paint, edge = false) {
2536
2472
  const base = { ...rest, fillRule: "nonzero" };
2537
2473
  if (edge) {
2538
2474
  for (const k of STROKE_KEYS) delete base[k];
2539
- const stroke = paint === "stroke" || !_chunk7MD7C6XQcjs.hasPaint.call(void 0, node.fill) ? node.stroke : node.fill;
2475
+ const stroke = paint === "stroke" || !_chunkJF5PXN7Wcjs.hasPaint.call(void 0, node.fill) ? node.stroke : node.fill;
2540
2476
  return { ...base, fill: null, stroke: _nullishCoalesce(stroke, () => ( "#000000")), strokeWidth: _nullishCoalesce(node.strokeWidth, () => ( 1)) };
2541
2477
  }
2542
2478
  if (paint === "stroke") {
@@ -2548,7 +2484,7 @@ function vectorResultStyle(node, paint, edge = false) {
2548
2484
  function vectorShapeBuilderMap(entries) {
2549
2485
  const lines = [];
2550
2486
  const inputs = entries.map((entry) => {
2551
- const filled = _chunk7MD7C6XQcjs.hasPaint.call(void 0, entry.node.fill);
2487
+ const filled = _chunkJF5PXN7Wcjs.hasPaint.call(void 0, entry.node.fill);
2552
2488
  const subpaths = entry.node.subpaths.filter(usable).map((sp) => !sp.closed && filled && subpathEnclosesArea(sp) ? { ...sp, closed: true } : sp);
2553
2489
  lines.push(!subpaths.some((s) => s.closed));
2554
2490
  return { path: worldOf(entry, subpaths), fillRule: _nullishCoalesce(entry.node.fillRule, () => ( "nonzero")) };
@@ -2653,7 +2589,7 @@ function planShapeBuilder(m, touched, erase) {
2653
2589
  const kept = faces.flatMap((_, f) => sourcesOf[f].includes(i) && !picked.has(f) ? [f] : []);
2654
2590
  rest = kept.length ? m.map.merge(kept) : [];
2655
2591
  } else rest = worldOf(entry, entry.node.subpaths.filter(usable));
2656
- const fillCloses = _chunk7MD7C6XQcjs.hasPaint.call(void 0, entry.node.fill);
2592
+ const fillCloses = _chunkJF5PXN7Wcjs.hasPaint.call(void 0, entry.node.fill);
2657
2593
  let cut = false;
2658
2594
  for (const piece of cuts) {
2659
2595
  const r = rest.length ? _chunkJEYDXRWQcjs.cutOutPiece.call(void 0, rest, piece, fillCloses, m.tolerance) : null;
@@ -2742,18 +2678,18 @@ function getEditablePathIds(state) {
2742
2678
  if (state.tool === "direct") {
2743
2679
  if (state.editingId) ids.add(state.editingId);
2744
2680
  for (const id of state.selection) {
2745
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
2681
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
2746
2682
  if (node && !node.locked) {
2747
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) if (!p.locked) ids.add(p.id);
2683
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) if (!p.locked) ids.add(p.id);
2748
2684
  }
2749
2685
  }
2750
2686
  }
2751
- return [...ids].filter((id) => _optionalChain([_chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _38 => _38.type]) === "path");
2687
+ return [...ids].filter((id) => _optionalChain([_chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _38 => _38.type]) === "path");
2752
2688
  }
2753
2689
  function getVisibleAnchors(state) {
2754
2690
  const out = [];
2755
2691
  for (const id of getEditablePathIds(state)) {
2756
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
2692
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
2757
2693
  node.subpaths.forEach((sp, s) => sp.anchors.forEach((_, i) => out.push({ nodeId: id, subpath: s, index: i })));
2758
2694
  }
2759
2695
  return out;
@@ -2771,7 +2707,7 @@ function getVisibleHandles(state) {
2771
2707
  out.push({ nodeId: node.id, subpath: s, index: i, handle });
2772
2708
  };
2773
2709
  if (state.tool === "pen" && state.pen) {
2774
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, state.pen.nodeId);
2710
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, state.pen.nodeId);
2775
2711
  const sp = _optionalChain([node, 'optionalAccess', _41 => _41.type]) === "path" ? node.subpaths[state.pen.subpath] : void 0;
2776
2712
  if (_optionalChain([node, 'optionalAccess', _42 => _42.type]) === "path" && sp) {
2777
2713
  const last = sp.anchors.length - 1;
@@ -2784,7 +2720,7 @@ function getVisibleHandles(state) {
2784
2720
  const editable = new Set(getEditablePathIds(state));
2785
2721
  for (const ref of state.selectedAnchors) {
2786
2722
  if (!editable.has(ref.nodeId)) continue;
2787
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, ref.nodeId);
2723
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, ref.nodeId);
2788
2724
  const sp = node.subpaths[ref.subpath];
2789
2725
  if (!sp) continue;
2790
2726
  const n = sp.anchors.length;
@@ -2803,26 +2739,26 @@ function getVectorCornerWidgets(state) {
2803
2739
  const zoom = state.viewport.zoom;
2804
2740
  const out = [];
2805
2741
  for (const id of getEditablePathIds(state)) {
2806
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
2742
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
2807
2743
  const picked = state.selectedAnchors.filter((r) => r.nodeId === id);
2808
- const m = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
2809
- for (const c of _chunk7MD7C6XQcjs.vectorCorners.call(void 0, node.subpaths)) {
2744
+ const m = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
2745
+ for (const c of _chunkJF5PXN7Wcjs.vectorCorners.call(void 0, node.subpaths)) {
2810
2746
  if (picked.length && !picked.some((r) => r.subpath === c.subpath && r.index === c.index)) continue;
2811
2747
  const side = Math.min(c.lu, c.lv);
2812
2748
  if (side * zoom < 3 * VECTOR_CORNER_WIDGET_INSET) continue;
2813
2749
  const a = node.subpaths[c.subpath].anchors[c.index];
2814
2750
  const radius = _nullishCoalesce(_optionalChain([a, 'access', _43 => _43.corner, 'optionalAccess', _44 => _44.radius]), () => ( 0));
2815
- const drawn = _chunk7MD7C6XQcjs.fitCornerRadius.call(void 0, c, radius);
2751
+ const drawn = _chunkJF5PXN7Wcjs.fitCornerRadius.call(void 0, c, radius);
2816
2752
  const k = Math.min(Math.max(drawn / c.sin, VECTOR_CORNER_WIDGET_INSET / (zoom * Math.sqrt(1 + c.cos))), side / 2);
2817
- const p = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, _chunk7MD7C6XQcjs.cornerBisectorPoint.call(void 0, c, k));
2753
+ const p = _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, _chunkJF5PXN7Wcjs.cornerBisectorPoint.call(void 0, c, k));
2818
2754
  out.push({ ref: { nodeId: id, subpath: c.subpath, index: c.index }, x: p.x, y: p.y, radius, drawnRadius: drawn, kind: _nullishCoalesce(_optionalChain([a, 'access', _45 => _45.corner, 'optionalAccess', _46 => _46.kind]), () => ( "round")), corner: c });
2819
2755
  }
2820
2756
  }
2821
2757
  return out;
2822
2758
  }
2823
2759
  function vectorStrokeWidthGeometry(node) {
2824
- if (!_chunk7MD7C6XQcjs.hasPaint.call(void 0, node.stroke) || !((_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0)) return null;
2825
- const parts = _chunk7MD7C6XQcjs.vectorStrokeParts.call(void 0, _chunk7MD7C6XQcjs.subpathsToBezier.call(void 0, node.subpaths), node);
2760
+ if (!_chunkJF5PXN7Wcjs.hasPaint.call(void 0, node.stroke) || !((_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0)) return null;
2761
+ const parts = _chunkJF5PXN7Wcjs.vectorStrokeParts.call(void 0, _chunkJF5PXN7Wcjs.subpathsToBezier.call(void 0, node.subpaths), node);
2826
2762
  return parts.line.length ? { line: parts.line, unit: parts.drawWidth / 2 } : null;
2827
2763
  }
2828
2764
  function shiftWidthPoints(profile, indices, dt) {
@@ -2835,30 +2771,30 @@ function getVectorWidthHandles(state) {
2835
2771
  if (state.tool !== "width") return [];
2836
2772
  const ids = /* @__PURE__ */ new Set();
2837
2773
  for (const id of state.selection) {
2838
- const n = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
2839
- if (n) for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, n)) ids.add(p.id);
2774
+ const n = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
2775
+ if (n) for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, n)) ids.add(p.id);
2840
2776
  }
2841
2777
  if (_optionalChain([state, 'access', _47 => _47.hover, 'optionalAccess', _48 => _48.nodeId])) ids.add(state.hover.nodeId);
2842
2778
  if (_optionalChain([state, 'access', _49 => _49.interaction, 'optionalAccess', _50 => _50.type]) === "width") ids.add(state.interaction.ref.nodeId);
2843
2779
  for (const r of state.selectedWidthPoints) ids.add(r.nodeId);
2844
2780
  const out = [];
2845
2781
  for (const id of ids) {
2846
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
2782
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
2847
2783
  if (_optionalChain([node, 'optionalAccess', _51 => _51.type]) !== "path" || node.visible === false || !_optionalChain([node, 'access', _52 => _52.strokeWidthProfile, 'optionalAccess', _53 => _53.length])) continue;
2848
2784
  const g = vectorStrokeWidthGeometry(node);
2849
2785
  if (!g) continue;
2850
- const profile = _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
2851
- const m = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
2786
+ const profile = _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
2787
+ const m = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
2852
2788
  const contours = node.subpaths.length;
2853
2789
  for (let sp = 0; sp < contours; sp++) {
2854
2790
  profile.forEach((w, index) => {
2855
- const at = _chunk7MD7C6XQcjs.strokePositionPoint.call(void 0, g.line, sp, w.t);
2791
+ const at = _chunkJF5PXN7Wcjs.strokePositionPoint.call(void 0, g.line, sp, w.t);
2856
2792
  if (!at) return;
2857
2793
  const n = { x: at.tangent[1], y: -at.tangent[0] };
2858
2794
  const c = { x: at.point[0], y: at.point[1] };
2859
- const p = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, c);
2860
- const l = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: c.x + n.x * w.left * g.unit, y: c.y + n.y * w.left * g.unit });
2861
- const r = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: c.x - n.x * w.right * g.unit, y: c.y - n.y * w.right * g.unit });
2795
+ const p = _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, c);
2796
+ const l = _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: c.x + n.x * w.left * g.unit, y: c.y + n.y * w.left * g.unit });
2797
+ const r = _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: c.x - n.x * w.right * g.unit, y: c.y - n.y * w.right * g.unit });
2862
2798
  out.push({
2863
2799
  ref: { nodeId: id, index, subpath: sp },
2864
2800
  x: p.x,
@@ -2876,24 +2812,24 @@ function getVectorWidthHandles(state) {
2876
2812
  return out;
2877
2813
  }
2878
2814
  function getAnchor(doc, ref) {
2879
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
2815
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
2880
2816
  return _optionalChain([node, 'optionalAccess', _54 => _54.type]) === "path" ? _optionalChain([node, 'access', _55 => _55.subpaths, 'access', _56 => _56[ref.subpath], 'optionalAccess', _57 => _57.anchors, 'access', _58 => _58[ref.index]]) : void 0;
2881
2817
  }
2882
2818
  function getAnchorWorld(doc, ref) {
2883
2819
  const a = getAnchor(doc, ref);
2884
2820
  if (!a) return void 0;
2885
- const m = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, doc.nodes, ref.nodeId), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
2886
- const p = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, a);
2887
- return { x: p.x, y: p.y, ...a.in ? { in: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, a.in) } : {}, ...a.out ? { out: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, a.out) } : {}, ...a.type ? { type: a.type } : {} };
2821
+ const m = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, doc.nodes, ref.nodeId), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
2822
+ const p = _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, a);
2823
+ return { x: p.x, y: p.y, ...a.in ? { in: _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, a.in) } : {}, ...a.out ? { out: _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, a.out) } : {}, ...a.type ? { type: a.type } : {} };
2888
2824
  }
2889
2825
  function getVectorSelectionFrame(doc, ids) {
2890
- const nodes = ids.map((id) => ({ node: _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, id), parent: _nullishCoalesce(_chunk7MD7C6XQcjs.vectorParentMatrix.call(void 0, doc.nodes, id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX)) })).filter((n) => n.node);
2826
+ const nodes = ids.map((id) => ({ node: _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, id), parent: _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorParentMatrix.call(void 0, doc.nodes, id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX)) })).filter((n) => n.node);
2891
2827
  if (!nodes.length) return null;
2892
- const angles = nodes.map((n) => _chunk7MD7C6XQcjs.matrixRotation.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n.node), n.parent)));
2828
+ const angles = nodes.map((n) => _chunkDWGZUSEScjs.matrixRotation.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n.node), n.parent)));
2893
2829
  const same = angles.every((a) => Math.abs(normalizeAngle(a - angles[0])) < 1e-6);
2894
2830
  const angle = same ? angles[0] : 0;
2895
- const unrotate = _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -angle);
2896
- const b = _chunk7MD7C6XQcjs.unionBounds.call(void 0, nodes.map((n) => _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n.node, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, n.parent, unrotate))));
2831
+ const unrotate = _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -angle);
2832
+ const b = _chunkJF5PXN7Wcjs.unionBounds.call(void 0, nodes.map((n) => _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n.node, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, n.parent, unrotate))));
2897
2833
  return b ? { ...b, angle } : null;
2898
2834
  }
2899
2835
  var normalizeAngle = (a) => ((a + 180) % 360 + 360) % 360 - 180;
@@ -2914,8 +2850,8 @@ function getTransformHandlePositions(box) {
2914
2850
  function getVectorSelectionBoxGeometry(frame, viewport) {
2915
2851
  const z = viewport.zoom;
2916
2852
  const box = { x: frame.x * z + viewport.x, y: frame.y * z + viewport.y, width: frame.width * z, height: frame.height * z };
2917
- const rot = _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, frame.angle, { x: viewport.x, y: viewport.y });
2918
- const toScreen2 = (p) => frame.angle ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, rot, p) : { x: p.x, y: p.y };
2853
+ const rot = _chunkDWGZUSEScjs.rotateMatrix.call(void 0, frame.angle, { x: viewport.x, y: viewport.y });
2854
+ const toScreen2 = (p) => frame.angle ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, rot, p) : { x: p.x, y: p.y };
2919
2855
  const handles = getTransformHandlePositions(box).map((h) => ({ ...h, screen: toScreen2(h) }));
2920
2856
  const corners2 = [
2921
2857
  { x: box.x, y: box.y },
@@ -2928,10 +2864,10 @@ function getVectorSelectionBoxGeometry(frame, viewport) {
2928
2864
  }
2929
2865
  function getVectorEnvelopeTarget(doc, selection) {
2930
2866
  if (selection.length !== 1) return null;
2931
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, selection[0]);
2932
- if (!node || !_chunk7MD7C6XQcjs.vectorNodeEnvelope.call(void 0, node)) return null;
2933
- const frame = _chunk7MD7C6XQcjs.vectorEnvelopeFrame.call(void 0, node);
2934
- return frame ? { node, frame, world: _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, doc.nodes, node.id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX)) } : null;
2867
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, selection[0]);
2868
+ if (!node || !_chunkJF5PXN7Wcjs.vectorNodeEnvelope.call(void 0, node)) return null;
2869
+ const frame = _chunkJF5PXN7Wcjs.vectorEnvelopeFrame.call(void 0, node);
2870
+ return frame ? { node, frame, world: _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, doc.nodes, node.id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX)) } : null;
2935
2871
  }
2936
2872
  var RESIZE_CURSOR_ORDER = ["ew-resize", "nwse-resize", "ns-resize", "nesw-resize"];
2937
2873
  var HANDLE_ANGLES = { e: 0, se: 45, s: 90, sw: 135, w: 180, nw: 225, n: 270, ne: 315 };
@@ -3081,7 +3017,7 @@ var placementOf = (n) => ({
3081
3017
  ...n.locked ? { locked: true } : {},
3082
3018
  ...n.booleanOperation ? { booleanOperation: n.booleanOperation } : {}
3083
3019
  });
3084
- var isRoot = (m) => m === _chunk7MD7C6XQcjs.IDENTITY_MATRIX || m[0] === 1 && m[1] === 0 && m[2] === 0 && m[3] === 1 && m[4] === 0 && m[5] === 0;
3020
+ var isRoot = (m) => m === _chunkDWGZUSEScjs.IDENTITY_MATRIX || m[0] === 1 && m[1] === 0 && m[2] === 0 && m[3] === 1 && m[4] === 0 && m[5] === 0;
3085
3021
  var idCounter = 0;
3086
3022
  var defaultCreateId = () => `vn-${Date.now().toString(36)}${(++idCounter).toString(36)}`;
3087
3023
  var VectorEditorController = (_class3 = class {
@@ -3133,7 +3069,7 @@ var VectorEditorController = (_class3 = class {
3133
3069
 
3134
3070
  constructor(options = {}) {;_class3.prototype.__init9.call(this);_class3.prototype.__init10.call(this);_class3.prototype.__init11.call(this);_class3.prototype.__init12.call(this);_class3.prototype.__init13.call(this);_class3.prototype.__init14.call(this);_class3.prototype.__init15.call(this);_class3.prototype.__init16.call(this);_class3.prototype.__init17.call(this);_class3.prototype.__init18.call(this);_class3.prototype.__init19.call(this);_class3.prototype.__init20.call(this);_class3.prototype.__init21.call(this);_class3.prototype.__init22.call(this);_class3.prototype.__init23.call(this);_class3.prototype.__init24.call(this);_class3.prototype.__init25.call(this);_class3.prototype.__init26.call(this);_class3.prototype.__init27.call(this);_class3.prototype.__init28.call(this);_class3.prototype.__init29.call(this);_class3.prototype.__init30.call(this);_class3.prototype.__init31.call(this);_class3.prototype.__init32.call(this);_class3.prototype.__init33.call(this);_class3.prototype.__init34.call(this);_class3.prototype.__init35.call(this);_class3.prototype.__init36.call(this);_class3.prototype.__init37.call(this);_class3.prototype.__init38.call(this);
3135
3071
  this.history = _nullishCoalesce(options.history, () => ( new (0, _chunkQKLRAA4Tcjs.HistoryManager)()));
3136
- this.doc = options.document ? _chunk7MD7C6XQcjs.cloneVectorDocument.call(void 0, options.document) : { width: 800, height: 600, nodes: [] };
3072
+ this.doc = options.document ? _chunkJF5PXN7Wcjs.cloneVectorDocument.call(void 0, options.document) : { width: 800, height: 600, nodes: [] };
3137
3073
  this.doc = this.refreshed(this.doc);
3138
3074
  this.tool = _nullishCoalesce(options.tool, () => ( "select"));
3139
3075
  this.defaults = { ...DEFAULT_DEFAULTS, ..._nullishCoalesce(options.defaults, () => ( {})) };
@@ -3186,7 +3122,7 @@ var VectorEditorController = (_class3 = class {
3186
3122
  return this.doc;
3187
3123
  }
3188
3124
  getNode(id) {
3189
- return _chunk7MD7C6XQcjs.findVectorNode.call(void 0, this.doc.nodes, id);
3125
+ return _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, this.doc.nodes, id);
3190
3126
  }
3191
3127
  computeState() {
3192
3128
  const h = this.history.getState();
@@ -3245,10 +3181,10 @@ var VectorEditorController = (_class3 = class {
3245
3181
  });
3246
3182
  }
3247
3183
  boundsOf(ids) {
3248
- return _chunk7MD7C6XQcjs.unionBounds.call(void 0,
3184
+ return _chunkJF5PXN7Wcjs.unionBounds.call(void 0,
3249
3185
  ids.map((id) => {
3250
3186
  const n = this.getNode(id);
3251
- return n ? _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunk7MD7C6XQcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX))) : null;
3187
+ return n ? _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX))) : null;
3252
3188
  })
3253
3189
  );
3254
3190
  }
@@ -3257,11 +3193,11 @@ var VectorEditorController = (_class3 = class {
3257
3193
  }
3258
3194
  /** Local → document matrix of a node in `doc` (default: the current document). */
3259
3195
  worldOf(id, doc = this.doc) {
3260
- return _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, doc.nodes, id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
3196
+ return _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, doc.nodes, id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
3261
3197
  }
3262
3198
  /** A document point in node `id`'s own space. */
3263
3199
  toLocal(id, p, doc = this.doc) {
3264
- return _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(id, doc)), p);
3200
+ return _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(id, doc)), p);
3265
3201
  }
3266
3202
  cursorFor() {
3267
3203
  if (_optionalChain([this, 'access', _61 => _61.drag, 'optionalAccess', _62 => _62.kind]) === "pan" || this.spaceHeld) return this.drag ? "grabbing" : "grab";
@@ -3374,9 +3310,9 @@ var VectorEditorController = (_class3 = class {
3374
3310
  this.setDoc(mapTree(this.doc.nodes, (n) => n.id === id ? next : n));
3375
3311
  }
3376
3312
  freshIds(node) {
3377
- const copy = _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, node);
3313
+ const copy = _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, node);
3378
3314
  const used = /* @__PURE__ */ new Set();
3379
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
3315
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
3380
3316
  const next = () => {
3381
3317
  let id = this.createId();
3382
3318
  while (used.has(id)) id = this.createId();
@@ -3544,7 +3480,7 @@ var VectorEditorController = (_class3 = class {
3544
3480
  /** Replaces the document. Undoable unless `{ history: false }` (then history is cleared). */
3545
3481
  setDocument(doc, options = {}) {
3546
3482
  this.cancelDrag();
3547
- const next = _chunk7MD7C6XQcjs.cloneVectorDocument.call(void 0, doc);
3483
+ const next = _chunkJF5PXN7Wcjs.cloneVectorDocument.call(void 0, doc);
3548
3484
  if (options.history === false) {
3549
3485
  this.doc = next;
3550
3486
  this.selection = [];
@@ -3572,7 +3508,7 @@ var VectorEditorController = (_class3 = class {
3572
3508
  /** Replaces the document with parsed SVG markup (one undo step). */
3573
3509
  loadSvg(svg, options = {}) {
3574
3510
  try {
3575
- const doc = _chunk7MD7C6XQcjs.parseVectorSvg.call(void 0, svg, { createId: () => this.createId() });
3511
+ const doc = _chunkJF5PXN7Wcjs.parseVectorSvg.call(void 0, svg, { createId: () => this.createId() });
3576
3512
  this.setDocument(doc, { history: options.history, label: "Import SVG" });
3577
3513
  return { ok: true };
3578
3514
  } catch (error) {
@@ -3582,7 +3518,7 @@ var VectorEditorController = (_class3 = class {
3582
3518
  /** Adds the nodes of SVG markup on top of the document, selected. */
3583
3519
  importSvg(svg) {
3584
3520
  try {
3585
- const parsed = _chunk7MD7C6XQcjs.parseVectorSvg.call(void 0, svg);
3521
+ const parsed = _chunkJF5PXN7Wcjs.parseVectorSvg.call(void 0, svg);
3586
3522
  const nodes = parsed.nodes.map((n) => this.freshIds(n));
3587
3523
  if (!nodes.length) return { ok: false, message: "The SVG has no shapes the editor can read." };
3588
3524
  this.change("Import SVG", () => {
@@ -3596,21 +3532,21 @@ var VectorEditorController = (_class3 = class {
3596
3532
  }
3597
3533
  }
3598
3534
  toSvg(options) {
3599
- return _chunk7MD7C6XQcjs.vectorDocumentToSvg.call(void 0, this.doc, options);
3535
+ return _chunkJF5PXN7Wcjs.vectorDocumentToSvg.call(void 0, this.doc, options);
3600
3536
  }
3601
3537
  toJSON() {
3602
- return _chunk7MD7C6XQcjs.cloneVectorDocument.call(void 0, this.doc);
3538
+ return _chunkJF5PXN7Wcjs.cloneVectorDocument.call(void 0, this.doc);
3603
3539
  }
3604
3540
  /** Adds a node (ids are kept unless taken). Returns its id. */
3605
3541
  addNode(node, options = {}) {
3606
3542
  const taken = (() => {
3607
3543
  let clash = false;
3608
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, [node], (n) => {
3544
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, [node], (n) => {
3609
3545
  if (this.getNode(n.id)) clash = true;
3610
3546
  });
3611
3547
  return clash;
3612
3548
  })();
3613
- const next = taken ? this.freshIds(node) : _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, node);
3549
+ const next = taken ? this.freshIds(node) : _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, node);
3614
3550
  this.change(_nullishCoalesce(options.label, () => ( `Add ${next.type === "group" ? "Group" : _nullishCoalesce(next.name, () => ( "Path"))}`)), () => {
3615
3551
  const insert = (list) => {
3616
3552
  const copy = list.slice();
@@ -3634,24 +3570,24 @@ var VectorEditorController = (_class3 = class {
3634
3570
  let subpath;
3635
3571
  switch (input.kind) {
3636
3572
  case "rect":
3637
- subpath = _chunk7MD7C6XQcjs.rectSubpath.call(void 0, b);
3573
+ subpath = _chunkJF5PXN7Wcjs.rectSubpath.call(void 0, b);
3638
3574
  break;
3639
3575
  case "ellipse":
3640
- subpath = _chunk7MD7C6XQcjs.ellipseSubpath.call(void 0, b);
3576
+ subpath = _chunkJF5PXN7Wcjs.ellipseSubpath.call(void 0, b);
3641
3577
  break;
3642
3578
  case "polygon":
3643
- subpath = _chunk7MD7C6XQcjs.polygonSubpath.call(void 0, b, _nullishCoalesce(input.sides, () => ( d.polygonSides)));
3579
+ subpath = _chunkJF5PXN7Wcjs.polygonSubpath.call(void 0, b, _nullishCoalesce(input.sides, () => ( d.polygonSides)));
3644
3580
  break;
3645
3581
  case "star":
3646
- subpath = _chunk7MD7C6XQcjs.starSubpath.call(void 0, b, _nullishCoalesce(input.points, () => ( d.starPoints)), _nullishCoalesce(input.innerRatio, () => ( d.starInnerRatio)));
3582
+ subpath = _chunkJF5PXN7Wcjs.starSubpath.call(void 0, b, _nullishCoalesce(input.points, () => ( d.starPoints)), _nullishCoalesce(input.innerRatio, () => ( d.starInnerRatio)));
3647
3583
  break;
3648
3584
  case "line":
3649
- subpath = _chunk7MD7C6XQcjs.lineSubpath.call(void 0, { x: b.x, y: b.y }, { x: b.x + b.width, y: b.y + b.height });
3585
+ subpath = _chunkJF5PXN7Wcjs.lineSubpath.call(void 0, { x: b.x, y: b.y }, { x: b.x + b.width, y: b.y + b.height });
3650
3586
  break;
3651
3587
  }
3652
3588
  const radius = _nullishCoalesce(input.cornerRadius, () => ( d.cornerRadius));
3653
3589
  const kind = _nullishCoalesce(input.cornerKind, () => ( d.cornerKind));
3654
- if ((input.kind === "rect" || input.kind === "polygon" || input.kind === "star") && radius > 0) subpath = _chunk7MD7C6XQcjs.setSubpathCorners.call(void 0, subpath, radius, kind);
3590
+ if ((input.kind === "rect" || input.kind === "polygon" || input.kind === "star") && radius > 0) subpath = _chunkJF5PXN7Wcjs.setSubpathCorners.call(void 0, subpath, radius, kind);
3655
3591
  const names = { rect: "Rectangle", ellipse: "Ellipse", polygon: "Polygon", star: "Star", line: "Line" };
3656
3592
  const style = this.styleFor(input.kind === "line");
3657
3593
  const own = {};
@@ -3667,7 +3603,7 @@ var VectorEditorController = (_class3 = class {
3667
3603
  }
3668
3604
  /** Adds a path from SVG path data. Returns its id. */
3669
3605
  addPath(d, style = {}, options = {}) {
3670
- const subpaths = _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, d);
3606
+ const subpaths = _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, d);
3671
3607
  const node = { id: this.newId(), type: "path", name: _nullishCoalesce(style.name, () => ( "Path")), ...this.styleFor(false), ...style, subpaths };
3672
3608
  return this.addNode(node, { label: "Add Path", ...options });
3673
3609
  }
@@ -3697,7 +3633,7 @@ var VectorEditorController = (_class3 = class {
3697
3633
  for (const id of ids) {
3698
3634
  const node = this.getNode(id);
3699
3635
  if (!node) return { ok: false, message: `There is no node "${id}".` };
3700
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) targets.add(p.id);
3636
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) targets.add(p.id);
3701
3637
  }
3702
3638
  if (!targets.size) return { ok: false, message: "Nothing is selected." };
3703
3639
  this.change(_nullishCoalesce(options.label, () => ( "Change Style")), () => {
@@ -3714,13 +3650,13 @@ var VectorEditorController = (_class3 = class {
3714
3650
  let points;
3715
3651
  if (profile === null) points = [];
3716
3652
  else if (typeof profile === "string") {
3717
- const preset = _chunk7MD7C6XQcjs.widthProfilePreset.call(void 0, profile);
3653
+ const preset = _chunkJF5PXN7Wcjs.widthProfilePreset.call(void 0, profile);
3718
3654
  if (!preset) return { ok: false, message: `There is no width profile "${profile}".` };
3719
3655
  points = preset;
3720
- } else if (Array.isArray(profile)) points = _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, profile);
3656
+ } else if (Array.isArray(profile)) points = _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, profile);
3721
3657
  else {
3722
3658
  const p = profile;
3723
- points = p.taper || p.wave ? _chunk7MD7C6XQcjs.generateWidthProfile.call(void 0, p) : [];
3659
+ points = p.taper || p.wave ? _chunkJF5PXN7Wcjs.generateWidthProfile.call(void 0, p) : [];
3724
3660
  }
3725
3661
  this.widthPoints = [];
3726
3662
  this.widthEdit = null;
@@ -3751,7 +3687,7 @@ var VectorEditorController = (_class3 = class {
3751
3687
  for (const id of ids) {
3752
3688
  const node = this.getNode(id);
3753
3689
  if (node && !node.locked) {
3754
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
3690
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
3755
3691
  }
3756
3692
  }
3757
3693
  return [...out.values()];
@@ -3768,8 +3704,8 @@ var VectorEditorController = (_class3 = class {
3768
3704
  const next = /* @__PURE__ */ new Map();
3769
3705
  for (const path of paths) {
3770
3706
  const paint = path[target];
3771
- const base = _chunk7MD7C6XQcjs.isVectorGradient.call(void 0, paint) ? paint : _chunk7MD7C6XQcjs.defaultVectorGradient.call(void 0, _nullishCoalesce(patch.type, () => ( "linear")), paint);
3772
- const g = _chunk7MD7C6XQcjs.applyVectorGradientPatch.call(void 0, base, patch);
3707
+ const base = _chunkJF5PXN7Wcjs.isVectorGradient.call(void 0, paint) ? paint : _chunkJF5PXN7Wcjs.defaultVectorGradient.call(void 0, _nullishCoalesce(patch.type, () => ( "linear")), paint);
3708
+ const g = _chunkJF5PXN7Wcjs.applyVectorGradientPatch.call(void 0, base, patch);
3773
3709
  if (!g) return { ok: false, message: "That is not a valid gradient: it needs at least one stop with an offset and a colour." };
3774
3710
  next.set(path.id, { ...path, [target]: g });
3775
3711
  }
@@ -3781,12 +3717,12 @@ var VectorEditorController = (_class3 = class {
3781
3717
  /** Applies `fn` to every target gradient of the selection (paths whose paint is not a gradient are skipped). */
3782
3718
  editGradients(label, fn, merge) {
3783
3719
  const target = this.gradientEdit.target;
3784
- const paths = this.gradientPaths().filter((p) => _chunk7MD7C6XQcjs.isVectorGradient.call(void 0, p[target]));
3720
+ const paths = this.gradientPaths().filter((p) => _chunkJF5PXN7Wcjs.isVectorGradient.call(void 0, p[target]));
3785
3721
  if (!paths.length) return { ok: false, message: "The selection has no gradient." };
3786
3722
  const next = /* @__PURE__ */ new Map();
3787
3723
  for (const path of paths) {
3788
3724
  const g = path[target];
3789
- const stops = fn(_chunk7MD7C6XQcjs.sortedVectorGradientStops.call(void 0, g));
3725
+ const stops = fn(_chunkJF5PXN7Wcjs.sortedVectorGradientStops.call(void 0, g));
3790
3726
  if (!stops) return { ok: false, message: "A gradient keeps at least two stops." };
3791
3727
  next.set(path.id, { ...path, [target]: { ...g, stops } });
3792
3728
  }
@@ -3816,7 +3752,7 @@ var VectorEditorController = (_class3 = class {
3816
3752
  }
3817
3753
  return out;
3818
3754
  });
3819
- if (patch.offset !== void 0 && Number.isFinite(patch.offset)) ({ stops: next, index: moved } = _chunk7MD7C6XQcjs.moveVectorGradientStop.call(void 0, next, index, patch.offset));
3755
+ if (patch.offset !== void 0 && Number.isFinite(patch.offset)) ({ stops: next, index: moved } = _chunkJF5PXN7Wcjs.moveVectorGradientStop.call(void 0, next, index, patch.offset));
3820
3756
  return next;
3821
3757
  },
3822
3758
  options.merge
@@ -3829,8 +3765,8 @@ var VectorEditorController = (_class3 = class {
3829
3765
  let index = 0;
3830
3766
  const target = this.gradientEdit.target;
3831
3767
  const result = this.editGradients("Add Gradient Stop", (stops) => {
3832
- const path = this.gradientPaths().find((p) => _chunk7MD7C6XQcjs.isVectorGradient.call(void 0, p[target]));
3833
- const r = _chunk7MD7C6XQcjs.insertVectorGradientStop.call(void 0, { ...path[target], stops }, offset);
3768
+ const path = this.gradientPaths().find((p) => _chunkJF5PXN7Wcjs.isVectorGradient.call(void 0, p[target]));
3769
+ const r = _chunkJF5PXN7Wcjs.insertVectorGradientStop.call(void 0, { ...path[target], stops }, offset);
3834
3770
  index = r.index;
3835
3771
  return r.stops;
3836
3772
  });
@@ -3839,7 +3775,7 @@ var VectorEditorController = (_class3 = class {
3839
3775
  }
3840
3776
  /** Removes stop `index` of the selection's gradients (never below two stops). */
3841
3777
  removeGradientStop(index) {
3842
- const result = this.editGradients("Delete Gradient Stop", (stops) => _chunk7MD7C6XQcjs.removeVectorGradientStop.call(void 0, stops, index));
3778
+ const result = this.editGradients("Delete Gradient Stop", (stops) => _chunkJF5PXN7Wcjs.removeVectorGradientStop.call(void 0, stops, index));
3843
3779
  if (result.ok) this.selectGradientStop(null);
3844
3780
  return result;
3845
3781
  }
@@ -3892,48 +3828,48 @@ var VectorEditorController = (_class3 = class {
3892
3828
  const end = constrained(drag.startDoc, p);
3893
3829
  let doc = base;
3894
3830
  for (const id2 of drag.targets) {
3895
- const node2 = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, base.nodes, id2);
3831
+ const node2 = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, base.nodes, id2);
3896
3832
  if (!node2) continue;
3897
3833
  const paint = node2[target];
3898
- const g2 = _chunk7MD7C6XQcjs.isVectorGradient.call(void 0, paint) ? paint : _chunk7MD7C6XQcjs.defaultVectorGradient.call(void 0, "linear", paint);
3899
- doc = this.withGradient(doc, id2, target, _chunk7MD7C6XQcjs.setVectorGradientVector.call(void 0, g2, _chunk7MD7C6XQcjs.vectorPathLocalBounds.call(void 0, node2), this.toLocal(id2, drag.startDoc, base), this.toLocal(id2, end, base)));
3834
+ const g2 = _chunkJF5PXN7Wcjs.isVectorGradient.call(void 0, paint) ? paint : _chunkJF5PXN7Wcjs.defaultVectorGradient.call(void 0, "linear", paint);
3835
+ doc = this.withGradient(doc, id2, target, _chunkJF5PXN7Wcjs.setVectorGradientVector.call(void 0, g2, _chunkJF5PXN7Wcjs.vectorPathLocalBounds.call(void 0, node2), this.toLocal(id2, drag.startDoc, base), this.toLocal(id2, end, base)));
3900
3836
  }
3901
3837
  this.doc = doc;
3902
3838
  this.notify(true);
3903
3839
  return;
3904
3840
  }
3905
3841
  const id = drag.nodeId;
3906
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, base.nodes, id);
3842
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, base.nodes, id);
3907
3843
  const g = node[target];
3908
- const bounds = _chunk7MD7C6XQcjs.vectorPathLocalBounds.call(void 0, node);
3844
+ const bounds = _chunkJF5PXN7Wcjs.vectorPathLocalBounds.call(void 0, node);
3909
3845
  const local = (q) => this.toLocal(id, q, base);
3910
3846
  const part = drag.part;
3911
3847
  let next = g;
3912
3848
  if (part.kind === "handle") {
3913
3849
  let to = p;
3914
3850
  if (part.handle === "end" || part.handle === "radius") to = constrained(this.screenToDocument(drag.annotator.start), p);
3915
- next = _chunk7MD7C6XQcjs.moveVectorGradientHandle.call(void 0, g, bounds, part.handle, local(to), local(drag.startDoc));
3851
+ next = _chunkJF5PXN7Wcjs.moveVectorGradientHandle.call(void 0, g, bounds, part.handle, local(to), local(drag.startDoc));
3916
3852
  } else if (part.kind === "bar") {
3917
- next = _chunk7MD7C6XQcjs.moveVectorGradientHandle.call(void 0, g, bounds, "start", local(p), local(drag.startDoc));
3853
+ next = _chunkJF5PXN7Wcjs.moveVectorGradientHandle.call(void 0, g, bounds, "start", local(p), local(drag.startDoc));
3918
3854
  } else {
3919
3855
  const a = drag.annotator;
3920
3856
  const pos = vectorGradientBarPosition(a, screen);
3921
- const stops = _chunk7MD7C6XQcjs.sortedVectorGradientStops.call(void 0, g);
3857
+ const stops = _chunkJF5PXN7Wcjs.sortedVectorGradientStops.call(void 0, g);
3922
3858
  if (part.kind === "stop") {
3923
3859
  const off = Math.abs(pos.across - VECTOR_GRADIENT_STOP_GAP) > VECTOR_GRADIENT_OFF_BAR;
3924
- const removed = off ? _chunk7MD7C6XQcjs.removeVectorGradientStop.call(void 0, stops, part.index) : null;
3860
+ const removed = off ? _chunkJF5PXN7Wcjs.removeVectorGradientStop.call(void 0, stops, part.index) : null;
3925
3861
  if (removed) {
3926
3862
  next = { ...g, stops: removed };
3927
3863
  drag.stop = null;
3928
3864
  } else {
3929
- const r = _chunk7MD7C6XQcjs.moveVectorGradientStop.call(void 0, stops, part.index, Math.min(1, Math.max(0, pos.offset)));
3865
+ const r = _chunkJF5PXN7Wcjs.moveVectorGradientStop.call(void 0, stops, part.index, Math.min(1, Math.max(0, pos.offset)));
3930
3866
  next = { ...g, stops: r.stops };
3931
3867
  drag.stop = r.index;
3932
3868
  }
3933
3869
  this.interaction = { type: "gradient", part: "stop", ...removed ? { removing: true } : {} };
3934
3870
  this.gradientEdit = { ...this.gradientEdit, stop: drag.stop };
3935
3871
  } else {
3936
- const m = _chunk7MD7C6XQcjs.vectorGradientMidpointFromPosition.call(void 0, stops, part.index, pos.offset);
3872
+ const m = _chunkJF5PXN7Wcjs.vectorGradientMidpointFromPosition.call(void 0, stops, part.index, pos.offset);
3937
3873
  if (m !== null) next = { ...g, stops: stops.map((s, i) => i !== part.index ? s : Math.abs(m - 0.5) < 1e-3 ? (({ midpoint: _m, ...rest }) => rest)(s) : { ...s, midpoint: m }) };
3938
3874
  }
3939
3875
  }
@@ -3972,7 +3908,7 @@ var VectorEditorController = (_class3 = class {
3972
3908
  this.change(count > 1 ? "Delete Width Points" : "Delete Width Point", () => {
3973
3909
  for (const [id, indices] of byNode) {
3974
3910
  const node = this.getNode(id);
3975
- const rest = _chunk7MD7C6XQcjs.removeWidthPoints.call(void 0, _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile), indices);
3911
+ const rest = _chunkJF5PXN7Wcjs.removeWidthPoints.call(void 0, _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile), indices);
3976
3912
  this.replaceNode(id, withStyle(node, { strokeWidthProfile: rest.length ? rest : null }));
3977
3913
  }
3978
3914
  });
@@ -4008,25 +3944,25 @@ var VectorEditorController = (_class3 = class {
4008
3944
  const left = num(values.left);
4009
3945
  const right = num(values.right);
4010
3946
  const scale = (w) => w === void 0 ? void 0 : Math.max(0, w) / g.unit;
4011
- const profile = _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
3947
+ const profile = _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4012
3948
  let points;
4013
3949
  let index;
4014
3950
  const existing = _nullishCoalesce(target.index, () => ( null));
4015
3951
  if (existing === null) {
4016
3952
  if (t === void 0) return { ok: false, message: "A new width point needs a position t." };
4017
- if (profile.length >= _chunk7MD7C6XQcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS) return { ok: false, message: "The profile has too many width points." };
4018
- ({ points, index } = _chunk7MD7C6XQcjs.insertWidthPoint.call(void 0, profile.length ? profile : null, t, { left: scale(left), right: scale(right) }, { step: true }));
3953
+ if (profile.length >= _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS) return { ok: false, message: "The profile has too many width points." };
3954
+ ({ points, index } = _chunkJF5PXN7Wcjs.insertWidthPoint.call(void 0, profile.length ? profile : null, t, { left: scale(left), right: scale(right) }, { step: true }));
4019
3955
  } else {
4020
3956
  const p = profile[existing];
4021
3957
  if (!p) return { ok: false, message: "There is no such width point." };
4022
3958
  const sides2 = { left: _nullishCoalesce(scale(left), () => ( p.left)), right: _nullishCoalesce(scale(right), () => ( p.right)) };
4023
3959
  const tt = t === void 0 ? p.t : Math.min(Math.max(t, 0), 1);
4024
- if (Math.abs(tt - p.t) <= _chunk7MD7C6XQcjs.VECTOR_WIDTH_SAME_T) {
4025
- points = _chunk7MD7C6XQcjs.setWidthPoint.call(void 0, profile, existing, sides2);
3960
+ if (Math.abs(tt - p.t) <= _chunkJF5PXN7Wcjs.VECTOR_WIDTH_SAME_T) {
3961
+ points = _chunkJF5PXN7Wcjs.setWidthPoint.call(void 0, profile, existing, sides2);
4026
3962
  index = existing;
4027
3963
  } else {
4028
- const rest = _chunk7MD7C6XQcjs.removeWidthPoints.call(void 0, profile, [existing]);
4029
- if (rest.length) ({ points, index } = _chunk7MD7C6XQcjs.insertWidthPoint.call(void 0, rest, tt, sides2, { step: true }));
3964
+ const rest = _chunkJF5PXN7Wcjs.removeWidthPoints.call(void 0, profile, [existing]);
3965
+ if (rest.length) ({ points, index } = _chunkJF5PXN7Wcjs.insertWidthPoint.call(void 0, rest, tt, sides2, { step: true }));
4030
3966
  else {
4031
3967
  points = [{ t: tt, ...sides2 }];
4032
3968
  index = 0;
@@ -4074,15 +4010,15 @@ var VectorEditorController = (_class3 = class {
4074
4010
  if (_optionalChain([node, 'optionalAccess', _140 => _140.type]) !== "path") return null;
4075
4011
  const g = vectorStrokeWidthGeometry(node);
4076
4012
  if (!g) return null;
4077
- const profile = _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4013
+ const profile = _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4078
4014
  const p = index === null ? null : profile[index];
4079
4015
  if (index !== null && !p) return null;
4080
4016
  const tt = p ? p.t : Math.min(Math.max(_nullishCoalesce(t, () => ( 0)), 0), 1);
4081
- const sides2 = _nullishCoalesce(p, () => ( _chunk7MD7C6XQcjs.widthProfileAt.call(void 0, profile.length ? profile : null, tt)));
4017
+ const sides2 = _nullishCoalesce(p, () => ( _chunkJF5PXN7Wcjs.widthProfileAt.call(void 0, profile.length ? profile : null, tt)));
4082
4018
  const sp = Math.min(Math.max(0, subpath), Math.max(0, node.subpaths.length - 1));
4083
- const at = _chunk7MD7C6XQcjs.strokePositionPoint.call(void 0, g.line, sp, tt);
4019
+ const at = _chunkJF5PXN7Wcjs.strokePositionPoint.call(void 0, g.line, sp, tt);
4084
4020
  const round = (v) => Math.round(v * 1e6) / 1e6;
4085
- const q = at ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, this.worldOf(nodeId), { x: at.point[0], y: at.point[1] }) : { x: 0, y: 0 };
4021
+ const q = at ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, this.worldOf(nodeId), { x: at.point[0], y: at.point[1] }) : { x: 0, y: 0 };
4086
4022
  const point = { x: round(q.x), y: round(q.y) };
4087
4023
  return { nodeId, subpath: sp, index, t: round(tt), left: round(sides2.left * g.unit), right: round(sides2.right * g.unit), point };
4088
4024
  }
@@ -4096,7 +4032,7 @@ var VectorEditorController = (_class3 = class {
4096
4032
  const refs = this.cornerTargets(options);
4097
4033
  if (!refs.length) return { ok: false, message: "Nothing is selected." };
4098
4034
  this.change(radius > 0 ? "Corner Radius" : "Sharpen Corners", () => {
4099
- this.doc = this.updateAnchors(this.doc, refs, (a) => _chunk7MD7C6XQcjs.setAnchorCorner.call(void 0, a, radius, options.kind));
4035
+ this.doc = this.updateAnchors(this.doc, refs, (a) => _chunkJF5PXN7Wcjs.setAnchorCorner.call(void 0, a, radius, options.kind));
4100
4036
  });
4101
4037
  return { ok: true };
4102
4038
  }
@@ -4105,7 +4041,7 @@ var VectorEditorController = (_class3 = class {
4105
4041
  const refs = this.cornerTargets(options);
4106
4042
  if (!refs.length) return { ok: false, message: "Nothing is selected." };
4107
4043
  this.change("Corner Kind", () => {
4108
- this.doc = this.updateAnchors(this.doc, refs, (a) => _chunk7MD7C6XQcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _141 => _141.corner, 'optionalAccess', _142 => _142.radius]), () => ( 0)), kind));
4044
+ this.doc = this.updateAnchors(this.doc, refs, (a) => _chunkJF5PXN7Wcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _141 => _141.corner, 'optionalAccess', _142 => _142.radius]), () => ( 0)), kind));
4109
4045
  });
4110
4046
  return { ok: true };
4111
4047
  }
@@ -4117,7 +4053,7 @@ var VectorEditorController = (_class3 = class {
4117
4053
  for (const id of _nullishCoalesce(options.ids, () => ( this.selection))) {
4118
4054
  const node = this.getNode(id);
4119
4055
  if (!node) continue;
4120
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) {
4056
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) {
4121
4057
  if (p.locked) continue;
4122
4058
  p.subpaths.forEach((sp, s) => sp.anchors.forEach((_, i) => out.push({ nodeId: p.id, subpath: s, index: i })));
4123
4059
  }
@@ -4135,14 +4071,14 @@ var VectorEditorController = (_class3 = class {
4135
4071
  for (const id of roots) {
4136
4072
  const node = this.getNode(id);
4137
4073
  if (node) {
4138
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) if (!p.locked && _chunk7MD7C6XQcjs.hasPaint.call(void 0, p.stroke) && (_nullishCoalesce(p.strokeWidth, () => ( 1))) > 0) paths.push(p);
4074
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) if (!p.locked && _chunkJF5PXN7Wcjs.hasPaint.call(void 0, p.stroke) && (_nullishCoalesce(p.strokeWidth, () => ( 1))) > 0) paths.push(p);
4139
4075
  }
4140
4076
  }
4141
4077
  if (!paths.length) return [];
4142
4078
  const created = [];
4143
4079
  const replace = /* @__PURE__ */ new Map();
4144
4080
  for (const p of paths) {
4145
- const outline = _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, _chunk7MD7C6XQcjs.vectorStrokeOutlinePath.call(void 0, _chunk7MD7C6XQcjs.vectorAppearanceOutline.call(void 0, p), p));
4081
+ const outline = _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, _chunkJF5PXN7Wcjs.vectorStrokeOutlinePath.call(void 0, _chunkJF5PXN7Wcjs.vectorAppearanceOutline.call(void 0, p), p));
4146
4082
  if (!outline.length) continue;
4147
4083
  const {
4148
4084
  stroke,
@@ -4159,10 +4095,10 @@ var VectorEditorController = (_class3 = class {
4159
4095
  strokeWidthProfile: _wp,
4160
4096
  effects,
4161
4097
  ...rest
4162
- } = _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, p);
4098
+ } = _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, p);
4163
4099
  const id = this.newId();
4164
4100
  const strokeNode = { ...rest, id, name: `${_nullishCoalesce(p.name, () => ( "Path"))} Stroke`, subpaths: outline, fill: _nullishCoalesce(stroke, () => ( null)), stroke: null, fillRule: "nonzero" };
4165
- const list = _chunk7MD7C6XQcjs.hasPaint.call(void 0, p.fill) ? [{ ...rest, ...effects ? { effects } : {}, stroke: null }, strokeNode] : [strokeNode];
4101
+ const list = _chunkJF5PXN7Wcjs.hasPaint.call(void 0, p.fill) ? [{ ...rest, ...effects ? { effects } : {}, stroke: null }, strokeNode] : [strokeNode];
4166
4102
  created.push(id);
4167
4103
  replace.set(p.id, list);
4168
4104
  }
@@ -4191,7 +4127,7 @@ var VectorEditorController = (_class3 = class {
4191
4127
  */
4192
4128
  addEffect(type, options = {}) {
4193
4129
  const targets = this.effectTargets(options.ids);
4194
- if (!targets.length || !_chunk7MD7C6XQcjs.createVectorEffect.call(void 0, type, "")) return [];
4130
+ if (!targets.length || !_chunkJF5PXN7Wcjs.createVectorEffect.call(void 0, type, "")) return [];
4195
4131
  const created = [];
4196
4132
  const next = /* @__PURE__ */ new Map();
4197
4133
  for (const node of targets) {
@@ -4200,15 +4136,15 @@ var VectorEditorController = (_class3 = class {
4200
4136
  while (list.some((e) => e.id === `fx${k}`)) k++;
4201
4137
  const params = { ..._nullishCoalesce(options.params, () => ( {})) };
4202
4138
  if (type === "repeater" && params.position === void 0) {
4203
- const b = _chunkXGD3FSNCcjs.bezierPathBounds.call(void 0, _chunk7MD7C6XQcjs.vectorAppearanceOutline.call(void 0, node));
4139
+ const b = _chunkXGD3FSNCcjs.bezierPathBounds.call(void 0, _chunkJF5PXN7Wcjs.vectorAppearanceOutline.call(void 0, node));
4204
4140
  if (b && b.maxX - b.minX > 0) params.position = { x: Math.round((b.maxX - b.minX) * 1.25 * 100) / 100, y: 0 };
4205
4141
  }
4206
- const effect = _chunk7MD7C6XQcjs.createVectorEffect.call(void 0, type, `fx${k}`, params);
4142
+ const effect = _chunkJF5PXN7Wcjs.createVectorEffect.call(void 0, type, `fx${k}`, params);
4207
4143
  const at = options.index === void 0 ? list.length : Math.min(list.length, Math.max(0, Math.round(options.index)));
4208
4144
  next.set(node.id, { ...node, effects: [...list.slice(0, at), effect, ...list.slice(at)] });
4209
4145
  created.push(effect.id);
4210
4146
  }
4211
- this.change(`Add ${_chunk7MD7C6XQcjs.VECTOR_EFFECT_LABELS[type]}`, () => this.setDoc(mapTree(this.doc.nodes, (n) => _nullishCoalesce(next.get(n.id), () => ( n)))));
4147
+ this.change(`Add ${_chunkJF5PXN7Wcjs.VECTOR_EFFECT_LABELS[type]}`, () => this.setDoc(mapTree(this.doc.nodes, (n) => _nullishCoalesce(next.get(n.id), () => ( n)))));
4212
4148
  return created;
4213
4149
  }
4214
4150
  editEffects(nodeId, label, fn, merge) {
@@ -4228,7 +4164,7 @@ var VectorEditorController = (_class3 = class {
4228
4164
  const merge = options.merge === true ? `effect:${nodeId}:${effectId}` : options.merge || void 0;
4229
4165
  const node = this.getNode(nodeId);
4230
4166
  const current = _optionalChain([node, 'optionalAccess', _143 => _143.effects, 'optionalAccess', _144 => _144.find, 'call', _145 => _145((e) => e.id === effectId)]);
4231
- const label = current ? _nullishCoalesce(_chunk7MD7C6XQcjs.VECTOR_EFFECT_LABELS[current.type], () => ( "Effect")) : "Effect";
4167
+ const label = current ? _nullishCoalesce(_chunkJF5PXN7Wcjs.VECTOR_EFFECT_LABELS[current.type], () => ( "Effect")) : "Effect";
4232
4168
  return this.editEffects(
4233
4169
  nodeId,
4234
4170
  `Edit ${label}`,
@@ -4237,7 +4173,7 @@ var VectorEditorController = (_class3 = class {
4237
4173
  if (i < 0) return `Node "${nodeId}" has no effect "${effectId}".`;
4238
4174
  const e = list[i];
4239
4175
  const raw = patch.params && e.type === "envelope" && node ? this.envelopeParams(node, e, patch.params) : patch.params;
4240
- const params = raw ? _chunk7MD7C6XQcjs.normalizeVectorEffectParams.call(void 0, e.type, raw, e.params) : e.params;
4176
+ const params = raw ? _chunkJF5PXN7Wcjs.normalizeVectorEffectParams.call(void 0, e.type, raw, e.params) : e.params;
4241
4177
  const next = { ...e, params, ...patch.enabled !== void 0 ? { enabled: patch.enabled } : {} };
4242
4178
  if (next.enabled !== false) delete next.enabled;
4243
4179
  return list.map((x, j) => j === i ? next : x);
@@ -4268,16 +4204,16 @@ var VectorEditorController = (_class3 = class {
4268
4204
  * nodes (empty when none was live).
4269
4205
  */
4270
4206
  expandAppearance(options = {}) {
4271
- const roots = (_nullishCoalesce(options.ids, () => ( this.selectedRoots()))).map((id) => this.getNode(id)).filter((n) => !!n && _chunk7MD7C6XQcjs.hasVectorAppearance.call(void 0, n));
4207
+ const roots = (_nullishCoalesce(options.ids, () => ( this.selectedRoots()))).map((id) => this.getNode(id)).filter((n) => !!n && _chunkJF5PXN7Wcjs.hasVectorAppearance.call(void 0, n));
4272
4208
  if (!roots.length) return [];
4273
4209
  const fresh = (n) => {
4274
4210
  const id = n.id.includes("~fx") ? this.newId() : n.id;
4275
4211
  return n.type === "group" ? { ...n, id, children: n.children.map(fresh) } : { ...n, id };
4276
4212
  };
4277
4213
  const bake = (n) => {
4278
- if (!_chunk7MD7C6XQcjs.hasVectorAppearance.call(void 0, n)) return n;
4279
- if (!_chunk7MD7C6XQcjs.hasOwnVectorAppearance.call(void 0, n)) return { ...n, children: n.children.map(bake) };
4280
- let e = _chunk7MD7C6XQcjs.expandVectorAppearance.call(void 0, n);
4214
+ if (!_chunkJF5PXN7Wcjs.hasVectorAppearance.call(void 0, n)) return n;
4215
+ if (!_chunkJF5PXN7Wcjs.hasOwnVectorAppearance.call(void 0, n)) return { ...n, children: n.children.map(bake) };
4216
+ let e = _chunkJF5PXN7Wcjs.expandVectorAppearance.call(void 0, n);
4281
4217
  if (e.type === "group" && e.children.length === 1 && e.children[0].type === "path") {
4282
4218
  const { id: _id, opacity, name, ...child } = e.children[0];
4283
4219
  const k = (_nullishCoalesce(e.opacity, () => ( 1))) * (_nullishCoalesce(opacity, () => ( 1)));
@@ -4360,11 +4296,11 @@ var VectorEditorController = (_class3 = class {
4360
4296
  selectedRoots() {
4361
4297
  return this.selection.filter((id) => {
4362
4298
  let covered = false;
4363
- const loc = _chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, id);
4299
+ const loc = _chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, id);
4364
4300
  let parent = _nullishCoalesce(_optionalChain([loc, 'optionalAccess', _146 => _146.parent]), () => ( null));
4365
4301
  while (parent) {
4366
4302
  if (this.selection.includes(parent.id)) covered = true;
4367
- parent = _nullishCoalesce(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, parent.id), 'optionalAccess', _147 => _147.parent]), () => ( null));
4303
+ parent = _nullishCoalesce(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, parent.id), 'optionalAccess', _147 => _147.parent]), () => ( null));
4368
4304
  }
4369
4305
  return !covered;
4370
4306
  });
@@ -4375,12 +4311,12 @@ var VectorEditorController = (_class3 = class {
4375
4311
  /** `m`, given in a frame rotated by `angle`, as a document-space matrix. */
4376
4312
  inFrame(angle, m) {
4377
4313
  if (!angle) return m;
4378
- return _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -angle), m), _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, angle));
4314
+ return _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -angle), m), _chunkDWGZUSEScjs.rotateMatrix.call(void 0, angle));
4379
4315
  }
4380
4316
  /** The selection frame's corners in document space, clockwise from the top left. */
4381
4317
  frameCorners(frame) {
4382
- const rot = _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, frame.angle);
4383
- return vectorBoxCorners(frame).map((c) => frame.angle ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, rot, c) : c);
4318
+ const rot = _chunkDWGZUSEScjs.rotateMatrix.call(void 0, frame.angle);
4319
+ return vectorBoxCorners(frame).map((c) => frame.angle ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, rot, c) : c);
4384
4320
  }
4385
4321
  /** `doc` with nodes `ids` sent through `f` (a map of document space), each in its own space (see `distortVectorNode`). */
4386
4322
  distorted(doc, ids, f, tolerance = VECTOR_DISTORT_TOLERANCE) {
@@ -4390,7 +4326,7 @@ var VectorEditorController = (_class3 = class {
4390
4326
  let next = n;
4391
4327
  if (ids.has(n.id) && !n.locked) next = distortVectorNode(n, parent, f, tolerance);
4392
4328
  else if (n.type === "group") {
4393
- const children = visit(n.children, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent));
4329
+ const children = visit(n.children, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent));
4394
4330
  if (children !== n.children) next = { ...n, children };
4395
4331
  }
4396
4332
  if (next !== n) changed = true;
@@ -4398,7 +4334,7 @@ var VectorEditorController = (_class3 = class {
4398
4334
  });
4399
4335
  return changed ? out : list;
4400
4336
  };
4401
- const nodes = visit(doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
4337
+ const nodes = visit(doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
4402
4338
  return nodes === doc.nodes ? doc : { ...doc, nodes };
4403
4339
  }
4404
4340
  /**
@@ -4424,10 +4360,10 @@ var VectorEditorController = (_class3 = class {
4424
4360
  if (!frame) return { ok: false, message: "Nothing is selected." };
4425
4361
  if (!(frame.width > 0 && frame.height > 0)) return { ok: false, message: "The selection has no area to distort." };
4426
4362
  const from = this.frameCorners(frame);
4427
- const h = corners2.length === 4 ? vectorHomography(from, corners2) : null;
4428
- if (!h || !vectorHomographyKeepsQuad(h, from)) return { ok: false, message: "The four corners must make a convex quadrilateral, clockwise from the top left." };
4363
+ const h = corners2.length === 4 ? _chunkMUUXNRU4cjs.homographyFromPoints.call(void 0, from, corners2) : null;
4364
+ if (!h || !_chunkMUUXNRU4cjs.homographyKeepsQuad.call(void 0, h, from)) return { ok: false, message: "The four corners must make a convex quadrilateral, clockwise from the top left." };
4429
4365
  this.change("Distort", () => {
4430
- this.doc = this.distorted(this.doc, new Set(ids), (p) => _nullishCoalesce(applyVectorHomography(h, p), () => ( p)), options.tolerance);
4366
+ this.doc = this.distorted(this.doc, new Set(ids), (p) => _nullishCoalesce(_chunkMUUXNRU4cjs.applyHomography.call(void 0, h, p), () => ( p)), options.tolerance);
4431
4367
  });
4432
4368
  return { ok: true };
4433
4369
  }
@@ -4440,13 +4376,13 @@ var VectorEditorController = (_class3 = class {
4440
4376
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4441
4377
  if (!frame) return { ok: false, message: "Nothing is selected." };
4442
4378
  if (![ax, ay].every((v) => Number.isFinite(v) && Math.abs(v) < 89.9)) return { ok: false, message: "Skew angles must be between \u221289.9\xB0 and 89.9\xB0." };
4443
- const origin = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4379
+ const origin = _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4444
4380
  return this.transform(this.inFrame(frame.angle, vectorSkewMatrix(ax, ay, origin)), { ids: options.ids, label: "Skew" });
4445
4381
  }
4446
4382
  /** A selection box handle dragged in Free Distort mode. */
4447
4383
  moveDistort(drag, p, input) {
4448
4384
  const angle = drag.frame.angle;
4449
- const unrotate = (v) => angle ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -angle), v) : v;
4385
+ const unrotate = (v) => angle ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -angle), v) : v;
4450
4386
  const q = unrotate(p);
4451
4387
  const q0 = unrotate(drag.start);
4452
4388
  const d = { x: q.x - q0.x, y: q.y - q0.y };
@@ -4458,17 +4394,17 @@ var VectorEditorController = (_class3 = class {
4458
4394
  const m = this.inFrame(angle, vectorShearForSide(drag.frame, drag.handle, d, !!input.alt));
4459
4395
  drag.op = "Skew";
4460
4396
  this.doc = this.transformed(drag.base, ids, m);
4461
- this.interaction = { type: "distort", mode: "skew", corners: from.map((c) => _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, c)) };
4397
+ this.interaction = { type: "distort", mode: "skew", corners: from.map((c) => _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, c)) };
4462
4398
  this.notify(true);
4463
4399
  return;
4464
4400
  }
4465
4401
  const mode = corner && input.mod && input.alt && input.shift ? "perspective" : "distort";
4466
- const rot = _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, angle);
4467
- const quad = vectorDistortQuad(drag.frame, drag.handle, d, mode).map((c) => angle ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, rot, c) : c);
4468
- const h = vectorHomography(from, quad);
4469
- if (!h || !vectorHomographyKeepsQuad(h, from)) return;
4402
+ const rot = _chunkDWGZUSEScjs.rotateMatrix.call(void 0, angle);
4403
+ const quad = vectorDistortQuad(drag.frame, drag.handle, d, mode).map((c) => angle ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, rot, c) : c);
4404
+ const h = _chunkMUUXNRU4cjs.homographyFromPoints.call(void 0, from, quad);
4405
+ if (!h || !_chunkMUUXNRU4cjs.homographyKeepsQuad.call(void 0, h, from)) return;
4470
4406
  drag.op = mode === "perspective" ? "Perspective" : "Distort";
4471
- this.doc = this.distorted(drag.base, ids, (pt) => _nullishCoalesce(applyVectorHomography(h, pt), () => ( pt)));
4407
+ this.doc = this.distorted(drag.base, ids, (pt) => _nullishCoalesce(_chunkMUUXNRU4cjs.applyHomography.call(void 0, h, pt), () => ( pt)));
4472
4408
  this.interaction = { type: "distort", mode, corners: quad };
4473
4409
  this.notify(true);
4474
4410
  }
@@ -4482,11 +4418,11 @@ var VectorEditorController = (_class3 = class {
4482
4418
  /** Envelope parameters for `node` after `patch`: a preset switched to a mesh becomes the mesh it stood for. */
4483
4419
  envelopeParams(node, current, patch) {
4484
4420
  if (patch.style !== "mesh" || patch.mesh !== void 0 || !current || current.params.style === "mesh") return patch;
4485
- const frame = _chunk7MD7C6XQcjs.vectorEnvelopeFrame.call(void 0, node, current.id);
4421
+ const frame = _chunkJF5PXN7Wcjs.vectorEnvelopeFrame.call(void 0, node, current.id);
4486
4422
  if (!frame) return patch;
4487
4423
  const rows = typeof patch.rows === "number" ? patch.rows : current.params.rows;
4488
4424
  const columns = typeof patch.columns === "number" ? patch.columns : current.params.columns;
4489
- return { ...patch, mesh: _chunk7MD7C6XQcjs.resizeVectorMesh.call(void 0, frame.mesh, columns, rows) };
4425
+ return { ...patch, mesh: _chunkDWGZUSEScjs.resizeWarpMesh.call(void 0, frame.mesh, columns, rows) };
4490
4426
  }
4491
4427
  /**
4492
4428
  * Gives the selected (or given) nodes an envelope distortion, or changes the one they have: a
@@ -4506,14 +4442,14 @@ var VectorEditorController = (_class3 = class {
4506
4442
  const list = _nullishCoalesce(node.effects, () => ( []));
4507
4443
  const current = _nullishCoalesce(list.find((e) => e.type === "envelope"), () => ( null));
4508
4444
  if (current) {
4509
- const p = _chunk7MD7C6XQcjs.normalizeVectorEffectParams.call(void 0, "envelope", this.envelopeParams(node, current, raw), current.params);
4445
+ const p = _chunkJF5PXN7Wcjs.normalizeVectorEffectParams.call(void 0, "envelope", this.envelopeParams(node, current, raw), current.params);
4510
4446
  const { enabled: _e, ...rest } = current;
4511
4447
  next.set(node.id, { ...node, effects: list.map((e) => e === current ? { ...rest, params: p } : e) });
4512
4448
  out.push({ nodeId: node.id, effectId: current.id });
4513
4449
  } else {
4514
4450
  let k = list.length + 1;
4515
4451
  while (list.some((e) => e.id === `fx${k}`)) k++;
4516
- const effect = _chunk7MD7C6XQcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, raw);
4452
+ const effect = _chunkJF5PXN7Wcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, raw);
4517
4453
  next.set(node.id, { ...node, effects: [...list, effect] });
4518
4454
  out.push({ nodeId: node.id, effectId: effect.id });
4519
4455
  }
@@ -4533,7 +4469,7 @@ var VectorEditorController = (_class3 = class {
4533
4469
  const ids = _nullishCoalesce(options.ids, () => ( this.selectedRoots()));
4534
4470
  if (ids.length < 2) return { ok: false, message: "Select the objects and, on top of them, the shape to use as the envelope." };
4535
4471
  const order = /* @__PURE__ */ new Map();
4536
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => order.set(n.id, order.size));
4472
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => order.set(n.id, order.size));
4537
4473
  const sorted = ids.filter((id) => order.has(id)).sort((a, b) => order.get(a) - order.get(b));
4538
4474
  const topId = sorted[sorted.length - 1];
4539
4475
  const top = this.getNode(topId);
@@ -4541,26 +4477,26 @@ var VectorEditorController = (_class3 = class {
4541
4477
  if (!top || !outline) return { ok: false, message: "The top object must be a path with a closed outline." };
4542
4478
  const contents = sorted.slice(0, -1).map((id) => this.getNode(id));
4543
4479
  if (contents.some((n) => n.locked)) return { ok: false, message: "Locked objects cannot be enveloped." };
4544
- const parents = contents.map((n) => _nullishCoalesce(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _154 => _154.parent, 'optionalAccess', _155 => _155.id]), () => ( null)));
4480
+ const parents = contents.map((n) => _nullishCoalesce(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _154 => _154.parent, 'optionalAccess', _155 => _155.id]), () => ( null)));
4545
4481
  if (parents.some((p) => p !== parents[0])) return { ok: false, message: "The objects to envelope must be in the same group." };
4546
4482
  const target = contents.length === 1 ? contents[0] : { id: this.newId(), type: "group", name: "Envelope", children: contents.map((n) => n) };
4547
- const parentToDoc = parents[0] ? this.worldOf(parents[0]) : _chunk7MD7C6XQcjs.IDENTITY_MATRIX;
4548
- const targetToDoc = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, target), parentToDoc);
4549
- const toLocal = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, this.worldOf(topId), _chunk7MD7C6XQcjs.invertMatrix.call(void 0, targetToDoc));
4483
+ const parentToDoc = parents[0] ? this.worldOf(parents[0]) : _chunkDWGZUSEScjs.IDENTITY_MATRIX;
4484
+ const targetToDoc = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, target), parentToDoc);
4485
+ const toLocal = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, this.worldOf(topId), _chunkDWGZUSEScjs.invertMatrix.call(void 0, targetToDoc));
4550
4486
  const local = {
4551
4487
  closed: true,
4552
4488
  anchors: outline.anchors.map((a) => ({
4553
- ..._chunk7MD7C6XQcjs.applyMatrix.call(void 0, toLocal, a),
4554
- ...a.in ? { in: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toLocal, a.in) } : {},
4555
- ...a.out ? { out: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, toLocal, a.out) } : {}
4489
+ ..._chunkDWGZUSEScjs.applyMatrix.call(void 0, toLocal, a),
4490
+ ...a.in ? { in: _chunkDWGZUSEScjs.applyMatrix.call(void 0, toLocal, a.in) } : {},
4491
+ ...a.out ? { out: _chunkDWGZUSEScjs.applyMatrix.call(void 0, toLocal, a.out) } : {}
4556
4492
  }))
4557
4493
  };
4558
- const mesh = _chunk7MD7C6XQcjs.vectorMeshFromOutline.call(void 0, local, _nullishCoalesce(options.columns, () => ( 4)), _nullishCoalesce(options.rows, () => ( 4)));
4494
+ const mesh = _chunkJF5PXN7Wcjs.vectorMeshFromOutline.call(void 0, local, _nullishCoalesce(options.columns, () => ( 4)), _nullishCoalesce(options.rows, () => ( 4)));
4559
4495
  if (!mesh) return { ok: false, message: "The top object\u2019s outline is too small to use as an envelope." };
4560
4496
  const list = _nullishCoalesce(target.effects, () => ( []));
4561
4497
  let k = list.length + 1;
4562
4498
  while (list.some((e) => e.id === `fx${k}`)) k++;
4563
- const effect = _chunk7MD7C6XQcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, { style: "mesh", mesh });
4499
+ const effect = _chunkJF5PXN7Wcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, { style: "mesh", mesh });
4564
4500
  const enveloped = { ...target, effects: [...list, effect] };
4565
4501
  this.change("Make Envelope with Top Object", () => {
4566
4502
  let nodes = spliceTree(this.doc.nodes, topId, []);
@@ -4588,7 +4524,7 @@ var VectorEditorController = (_class3 = class {
4588
4524
  const replace = /* @__PURE__ */ new Map();
4589
4525
  for (const node of targets) {
4590
4526
  const effect = node.effects.find((e) => e.type === "envelope");
4591
- const frame = _chunk7MD7C6XQcjs.vectorEnvelopeFrame.call(void 0, node, effect.id);
4527
+ const frame = _chunkJF5PXN7Wcjs.vectorEnvelopeFrame.call(void 0, node, effect.id);
4592
4528
  const rest = node.effects.filter((e) => e !== effect);
4593
4529
  const { effects: _e, ...plain2 } = node;
4594
4530
  const kept = rest.length ? { ...plain2, effects: rest } : plain2;
@@ -4603,7 +4539,7 @@ var VectorEditorController = (_class3 = class {
4603
4539
  type: "path",
4604
4540
  name: "Envelope",
4605
4541
  ...node.transform ? { transform: node.transform } : {},
4606
- subpaths: [_chunk7MD7C6XQcjs.vectorMeshOutline.call(void 0, frame.mesh)],
4542
+ subpaths: [_chunkJF5PXN7Wcjs.vectorMeshOutline.call(void 0, frame.mesh)],
4607
4543
  fill: null,
4608
4544
  stroke: "#808080",
4609
4545
  strokeWidth: 1
@@ -4629,11 +4565,11 @@ var VectorEditorController = (_class3 = class {
4629
4565
  const target = this.envelopeTarget();
4630
4566
  if (!target) return null;
4631
4567
  const { mesh } = target.frame;
4632
- const pts = _chunk7MD7C6XQcjs.vectorMeshEditPoints.call(void 0, mesh);
4568
+ const pts = _chunkDWGZUSEScjs.warpMeshEditPoints.call(void 0, mesh);
4633
4569
  let best = null;
4634
4570
  let bestD = Infinity;
4635
4571
  for (const index of [...pts.handles.map((h) => h.index), ...pts.anchors]) {
4636
- const s = this.documentToScreen(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, target.world, mesh.points[index]));
4572
+ const s = this.documentToScreen(_chunkDWGZUSEScjs.applyMatrix.call(void 0, target.world, mesh.points[index]));
4637
4573
  const d = Math.hypot(s.x - screen.x, s.y - screen.y);
4638
4574
  if (d <= this.hitRadius && d < bestD - 0.5) {
4639
4575
  best = index;
@@ -4641,8 +4577,8 @@ var VectorEditorController = (_class3 = class {
4641
4577
  }
4642
4578
  }
4643
4579
  if (best !== null) return { target, index: best, s: 0, t: 0 };
4644
- const local = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, target.world), p);
4645
- const at = _chunk7MD7C6XQcjs.vectorMeshParamAt.call(void 0, mesh, local);
4580
+ const local = _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.invertMatrix.call(void 0, target.world), p);
4581
+ const at = _chunkDWGZUSEScjs.warpMeshParamAt.call(void 0, mesh, local);
4646
4582
  if (at.distance > this.tolerance()) return null;
4647
4583
  return { target, index: null, s: at.s, t: at.t };
4648
4584
  }
@@ -4667,7 +4603,7 @@ var VectorEditorController = (_class3 = class {
4667
4603
  this.notify();
4668
4604
  return;
4669
4605
  }
4670
- const node = _chunk7MD7C6XQcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
4606
+ const node = _chunkJF5PXN7Wcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
4671
4607
  if (node) this.selection = input.shift ? this.selection.includes(node.id) ? this.selection.filter((id) => id !== node.id) : [...this.selection, node.id] : [node.id];
4672
4608
  else if (!input.shift) this.selection = [];
4673
4609
  this.anchors = [];
@@ -4678,7 +4614,7 @@ var VectorEditorController = (_class3 = class {
4678
4614
  const d = { x: local.x - drag.start.x, y: local.y - drag.start.y };
4679
4615
  if (!drag.moved && Math.hypot(d.x, d.y) * this.viewport.zoom < 1) return;
4680
4616
  drag.moved = true;
4681
- const mesh = drag.index !== null ? _chunk7MD7C6XQcjs.dragVectorMeshPoint.call(void 0, drag.base, drag.index, d) : _chunk7MD7C6XQcjs.pullVectorMesh.call(void 0, drag.base, drag.s, drag.t, d);
4617
+ const mesh = drag.index !== null ? _chunkDWGZUSEScjs.dragWarpMeshPoint.call(void 0, drag.base, drag.index, d) : _chunkDWGZUSEScjs.pullWarpMesh.call(void 0, drag.base, drag.s, drag.t, d);
4682
4618
  const nodes = mapTree(drag.baseDoc.nodes, (n) => {
4683
4619
  if (n.id !== drag.nodeId) return n;
4684
4620
  const effects = (_nullishCoalesce(n.effects, () => ( []))).map(
@@ -4705,10 +4641,10 @@ var VectorEditorController = (_class3 = class {
4705
4641
  const out = list.map((n) => {
4706
4642
  let next = n;
4707
4643
  if (ids.has(n.id) && !n.locked) {
4708
- const local = isRoot(parent) ? m : _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, parent, m), _chunk7MD7C6XQcjs.invertMatrix.call(void 0, parent));
4709
- next = _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, n, local);
4644
+ const local = isRoot(parent) ? m : _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, parent, m), _chunkDWGZUSEScjs.invertMatrix.call(void 0, parent));
4645
+ next = _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, n, local);
4710
4646
  } else if (n.type === "group") {
4711
- const children = visit(n.children, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent));
4647
+ const children = visit(n.children, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent));
4712
4648
  if (children !== n.children) next = { ...n, children };
4713
4649
  }
4714
4650
  if (next !== n) changed = true;
@@ -4716,7 +4652,7 @@ var VectorEditorController = (_class3 = class {
4716
4652
  });
4717
4653
  return changed ? out : list;
4718
4654
  };
4719
- const nodes = visit(doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
4655
+ const nodes = visit(doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
4720
4656
  return nodes === doc.nodes ? doc : { ...doc, nodes };
4721
4657
  }
4722
4658
  translate(dx, dy, options = {}) {
@@ -4726,11 +4662,11 @@ var VectorEditorController = (_class3 = class {
4726
4662
  });
4727
4663
  return { ok: true };
4728
4664
  }
4729
- return this.transform(_chunk7MD7C6XQcjs.translateMatrix.call(void 0, dx, dy), { ids: options.ids, label: "Move" });
4665
+ return this.transform(_chunkDWGZUSEScjs.translateMatrix.call(void 0, dx, dy), { ids: options.ids, label: "Move" });
4730
4666
  }
4731
4667
  /** The selection frame's centre in document space. */
4732
4668
  frameCenter(frame) {
4733
- return _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
4669
+ return _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
4734
4670
  }
4735
4671
  /**
4736
4672
  * Scales along the selection box's own axes (rotated with the selection when its nodes
@@ -4739,15 +4675,15 @@ var VectorEditorController = (_class3 = class {
4739
4675
  scale(sx, sy = sx, options = {}) {
4740
4676
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4741
4677
  if (!frame) return { ok: false, message: "Nothing is selected." };
4742
- const origin = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4743
- return this.transform(this.inFrame(frame.angle, _chunk7MD7C6XQcjs.scaleMatrix.call(void 0, sx, sy, origin)), { ids: options.ids, label: "Scale" });
4678
+ const origin = _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4679
+ return this.transform(this.inFrame(frame.angle, _chunkDWGZUSEScjs.scaleMatrix.call(void 0, sx, sy, origin)), { ids: options.ids, label: "Scale" });
4744
4680
  }
4745
4681
  /** Rotates clockwise by `degrees` around `origin` (default: the selection centre). */
4746
4682
  rotate(degrees, options = {}) {
4747
4683
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4748
4684
  if (!frame) return { ok: false, message: "Nothing is selected." };
4749
4685
  const origin = _nullishCoalesce(options.origin, () => ( this.frameCenter(frame)));
4750
- return this.transform(_chunk7MD7C6XQcjs.rotateMatrix.call(void 0, degrees, origin), { ids: options.ids, label: "Rotate" });
4686
+ return this.transform(_chunkDWGZUSEScjs.rotateMatrix.call(void 0, degrees, origin), { ids: options.ids, label: "Rotate" });
4751
4687
  }
4752
4688
  /** Sets each selected (or given) node's rotation to `degrees`, turning it around its own centre. */
4753
4689
  setRotation(degrees, options = {}) {
@@ -4758,7 +4694,7 @@ var VectorEditorController = (_class3 = class {
4758
4694
  const frame = this.frameOf([id]);
4759
4695
  if (!frame) continue;
4760
4696
  const delta = normalizeAngle(degrees - frame.angle);
4761
- if (Math.abs(delta) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, delta, this.frameCenter(frame)));
4697
+ if (Math.abs(delta) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunkDWGZUSEScjs.rotateMatrix.call(void 0, delta, this.frameCenter(frame)));
4762
4698
  }
4763
4699
  });
4764
4700
  return { ok: true };
@@ -4768,7 +4704,7 @@ var VectorEditorController = (_class3 = class {
4768
4704
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4769
4705
  if (!frame) return { ok: false, message: "Nothing is selected." };
4770
4706
  const c = { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 };
4771
- const m = axis === "horizontal" ? _chunk7MD7C6XQcjs.scaleMatrix.call(void 0, -1, 1, c) : _chunk7MD7C6XQcjs.scaleMatrix.call(void 0, 1, -1, c);
4707
+ const m = axis === "horizontal" ? _chunkDWGZUSEScjs.scaleMatrix.call(void 0, -1, 1, c) : _chunkDWGZUSEScjs.scaleMatrix.call(void 0, 1, -1, c);
4772
4708
  return this.transform(this.inFrame(frame.angle, m), { ids: options.ids, label: axis === "horizontal" ? "Flip Horizontal" : "Flip Vertical" });
4773
4709
  }
4774
4710
  /**
@@ -4791,7 +4727,7 @@ var VectorEditorController = (_class3 = class {
4791
4727
  if (edge === "top") dy = target.y - b.y;
4792
4728
  if (edge === "middle") dy = target.y + target.height / 2 - (b.y + b.height / 2);
4793
4729
  if (edge === "bottom") dy = target.y + target.height - (b.y + b.height);
4794
- if (dx || dy) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunk7MD7C6XQcjs.translateMatrix.call(void 0, dx, dy));
4730
+ if (dx || dy) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunkDWGZUSEScjs.translateMatrix.call(void 0, dx, dy));
4795
4731
  }
4796
4732
  });
4797
4733
  return { ok: true };
@@ -4813,7 +4749,7 @@ var VectorEditorController = (_class3 = class {
4813
4749
  let cursor = pos(first);
4814
4750
  for (const item of items) {
4815
4751
  const d = cursor - pos(item.b);
4816
- if (Math.abs(d) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([item.id]), horizontal ? _chunk7MD7C6XQcjs.translateMatrix.call(void 0, d, 0) : _chunk7MD7C6XQcjs.translateMatrix.call(void 0, 0, d));
4752
+ if (Math.abs(d) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([item.id]), horizontal ? _chunkDWGZUSEScjs.translateMatrix.call(void 0, d, 0) : _chunkDWGZUSEScjs.translateMatrix.call(void 0, 0, d));
4817
4753
  cursor += size(item.b) + gap;
4818
4754
  }
4819
4755
  });
@@ -4837,14 +4773,14 @@ var VectorEditorController = (_class3 = class {
4837
4773
  }
4838
4774
  withDuplicates(doc, ids, offset, created) {
4839
4775
  const set = new Set(ids);
4840
- const m = _chunk7MD7C6XQcjs.translateMatrix.call(void 0, offset.x, offset.y);
4776
+ const m = _chunkDWGZUSEScjs.translateMatrix.call(void 0, offset.x, offset.y);
4841
4777
  const insert = (list) => {
4842
4778
  const out = [];
4843
4779
  for (const node of list) {
4844
4780
  const n = node.type === "group" ? { ...node, children: insert(node.children) } : node;
4845
4781
  out.push(n);
4846
4782
  if (set.has(node.id)) {
4847
- const copy = _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, this.freshIds(node), m);
4783
+ const copy = _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, this.freshIds(node), m);
4848
4784
  created.push(copy.id);
4849
4785
  out.push(copy);
4850
4786
  }
@@ -4857,7 +4793,7 @@ var VectorEditorController = (_class3 = class {
4857
4793
  group(options = {}) {
4858
4794
  const ids = _nullishCoalesce(options.ids, () => ( this.selectedRoots()));
4859
4795
  if (!ids.length) return null;
4860
- const locs = ids.map((id2) => _chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
4796
+ const locs = ids.map((id2) => _chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
4861
4797
  if (locs.some((l) => !l)) return null;
4862
4798
  const parent = _nullishCoalesce(_optionalChain([locs, 'access', _159 => _159[0], 'access', _160 => _160.parent, 'optionalAccess', _161 => _161.id]), () => ( null));
4863
4799
  if (locs.some((l) => (_nullishCoalesce(_optionalChain([l, 'access', _162 => _162.parent, 'optionalAccess', _163 => _163.id]), () => ( null))) !== parent)) return null;
@@ -4894,9 +4830,9 @@ var VectorEditorController = (_class3 = class {
4894
4830
  if (set.has(n.id) && n.type === "group") {
4895
4831
  changed = true;
4896
4832
  const opacity = n.opacity;
4897
- const m = _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n);
4833
+ const m = _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n);
4898
4834
  out.push(
4899
- ...n.children.map((c) => c.blendStep ? (({ blendStep: _s, locked: _l, ...rest }) => rest)(c) : c).map((c) => c.booleanOperation ? (({ booleanOperation: _b, ...rest }) => rest)(c) : c).map((c) => n.transform ? _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c)
4835
+ ...n.children.map((c) => c.blendStep ? (({ blendStep: _s, locked: _l, ...rest }) => rest)(c) : c).map((c) => c.booleanOperation ? (({ booleanOperation: _b, ...rest }) => rest)(c) : c).map((c) => n.transform ? _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c)
4900
4836
  );
4901
4837
  } else if (n.type === "group") {
4902
4838
  const children = flatten(n.children);
@@ -4948,16 +4884,16 @@ var VectorEditorController = (_class3 = class {
4948
4884
  const result = _chunkXGD3FSNCcjs.pathBoolean.call(void 0,
4949
4885
  BOOLEAN_OPS[op],
4950
4886
  entries.map((e) => ({
4951
- path: _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, { ...e.node, subpaths: e.node.subpaths.filter((s) => s.anchors.length > 1).map((s) => ({ ...s, closed: true })) }, e.parent),
4887
+ path: _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, { ...e.node, subpaths: e.node.subpaths.filter((s) => s.anchors.length > 1).map((s) => ({ ...s, closed: true })) }, e.parent),
4952
4888
  fillRule: _nullishCoalesce(e.node.fillRule, () => ( "nonzero"))
4953
4889
  }))
4954
4890
  );
4955
4891
  const base = entries[0].node;
4956
4892
  const anchorRoot = _nullishCoalesce(roots.find((r) => this.holds(r, base.id)), () => ( base.id));
4957
- const subpaths = _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(anchorRoot, result.path));
4893
+ const subpaths = _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(anchorRoot, result.path));
4958
4894
  if (result.error || !subpaths.length) return null;
4959
4895
  const id = this.newId();
4960
- const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, base);
4896
+ const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, base);
4961
4897
  const node = { ...baseRest, id, name: BOOLEAN_LABELS[op], subpaths };
4962
4898
  const drop = /* @__PURE__ */ new Set([...entries.map((e) => e.node.id), ...roots]);
4963
4899
  this.change(BOOLEAN_LABELS[op], () => {
@@ -4971,20 +4907,20 @@ var VectorEditorController = (_class3 = class {
4971
4907
  /** Whether stored node `rootId` holds `id` as drawn (`id` may be an expanded path inside it). */
4972
4908
  holds(rootId, id) {
4973
4909
  const n = this.getNode(rootId);
4974
- return !!n && (!!_chunk7MD7C6XQcjs.findVectorNode.call(void 0, [n], id) || !!_chunk7MD7C6XQcjs.findVectorNode.call(void 0, [_chunk7MD7C6XQcjs.expandVectorAppearance.call(void 0, n)], id));
4910
+ return !!n && (!!_chunkJF5PXN7Wcjs.findVectorNode.call(void 0, [n], id) || !!_chunkJF5PXN7Wcjs.findVectorNode.call(void 0, [_chunkJF5PXN7Wcjs.expandVectorAppearance.call(void 0, n)], id));
4975
4911
  }
4976
4912
  liveBooleanOp(op, roots) {
4977
4913
  const nodes = roots.map((id2) => this.getNode(id2));
4978
4914
  if (!nodes.length || nodes.some((n) => !n)) return null;
4979
4915
  const label = `Live ${BOOLEAN_LABELS[op]}`;
4980
4916
  const lone = nodes.length === 1 ? nodes[0] : null;
4981
- if (_chunk7MD7C6XQcjs.isVectorLiveBoolean.call(void 0, lone)) {
4917
+ if (_chunkJF5PXN7Wcjs.isVectorLiveBoolean.call(void 0, lone)) {
4982
4918
  const children = lone.children.map((c) => c.booleanOperation ? (({ booleanOperation: _b, ...rest }) => rest)(c) : c);
4983
4919
  this.change(label, () => this.replaceNode(lone.id, { ...lone, liveBoolean: op, children }));
4984
4920
  return lone.id;
4985
4921
  }
4986
- const parents = roots.map((id2) => _nullishCoalesce(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, id2), 'optionalAccess', _165 => _165.parent]), () => ( null)));
4987
- if (parents.every((g) => _chunk7MD7C6XQcjs.isVectorLiveBoolean.call(void 0, g))) {
4922
+ const parents = roots.map((id2) => _nullishCoalesce(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, id2), 'optionalAccess', _165 => _165.parent]), () => ( null)));
4923
+ if (parents.every((g) => _chunkJF5PXN7Wcjs.isVectorLiveBoolean.call(void 0, g))) {
4988
4924
  const set = new Set(roots);
4989
4925
  this.change(
4990
4926
  label,
@@ -5035,8 +4971,8 @@ var VectorEditorController = (_class3 = class {
5035
4971
  const paths = entries.map((e) => e.node);
5036
4972
  const id = this.newId();
5037
4973
  const first = _nullishCoalesce(roots.find((r) => this.holds(r, paths[0].id)), () => ( paths[0].id));
5038
- const subpaths = entries.flatMap((e) => _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(first, _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, e.node, e.parent))));
5039
- const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, paths[0]);
4974
+ const subpaths = entries.flatMap((e) => _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(first, _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, e.node, e.parent))));
4975
+ const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, paths[0]);
5040
4976
  const node = { ...baseRest, id, name: "Compound Path", subpaths };
5041
4977
  const drop = /* @__PURE__ */ new Set([...paths.map((p) => p.id), ...roots]);
5042
4978
  this.change("Combine", () => {
@@ -5048,8 +4984,8 @@ var VectorEditorController = (_class3 = class {
5048
4984
  }
5049
4985
  /** A document-space path mapped into the parent space of node `id`. */
5050
4986
  intoParentSpace(id, path) {
5051
- const parent = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
5052
- return isRoot(parent) ? path : _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, path, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, parent));
4987
+ const parent = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
4988
+ return isRoot(parent) ? path : _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, path, _chunkDWGZUSEScjs.invertMatrix.call(void 0, parent));
5053
4989
  }
5054
4990
  /** Splits selected compound paths into one path per subpath. */
5055
4991
  breakApart(options = {}) {
@@ -5094,7 +5030,7 @@ var VectorEditorController = (_class3 = class {
5094
5030
  const topRoot = _nullishCoalesce([...roots].reverse().find((r) => this.holds(r, last)), () => ( last));
5095
5031
  const nodes = [];
5096
5032
  for (const piece of result.pieces) {
5097
- const subpaths = _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(topRoot, piece.path)).map((sp) => piece.open ? { ...sp, closed: false } : sp);
5033
+ const subpaths = _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(topRoot, piece.path)).map((sp) => piece.open ? { ...sp, closed: false } : sp);
5098
5034
  if (!subpaths.length) continue;
5099
5035
  const source = entries[piece.source].node;
5100
5036
  const style = vectorResultStyle(source, shapes[piece.source].paint, op === "outline");
@@ -5121,7 +5057,7 @@ var VectorEditorController = (_class3 = class {
5121
5057
  const out = /* @__PURE__ */ new Map();
5122
5058
  for (const id of _nullishCoalesce(ids, () => ( this.selection))) {
5123
5059
  const node = this.getNode(id);
5124
- const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _170 => _170.parent]);
5060
+ const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _170 => _170.parent]);
5125
5061
  if (isVectorBlendGroup(group)) out.set(group.id, group);
5126
5062
  }
5127
5063
  return [...out.values()];
@@ -5138,7 +5074,7 @@ var VectorEditorController = (_class3 = class {
5138
5074
  return !!n && !n.blendStep && !n.locked;
5139
5075
  });
5140
5076
  if (ids.length < 2) return null;
5141
- const locs = ids.map((id2) => _chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
5077
+ const locs = ids.map((id2) => _chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
5142
5078
  const parent = _nullishCoalesce(_optionalChain([locs, 'access', _171 => _171[0], 'access', _172 => _172.parent, 'optionalAccess', _173 => _173.id]), () => ( null));
5143
5079
  if (locs.some((l) => (_nullishCoalesce(_optionalChain([l, 'access', _174 => _174.parent, 'optionalAccess', _175 => _175.id]), () => ( null))) !== parent)) return null;
5144
5080
  const order = input.keepOrder ? ids : ids.slice().sort((a, b) => locs[ids.indexOf(a)].index - locs[ids.indexOf(b)].index);
@@ -5182,13 +5118,13 @@ var VectorEditorController = (_class3 = class {
5182
5118
  const node = this.getNode(nodeId);
5183
5119
  if (!isVectorBlendGroup(group)) return { ok: false, message: `"${blendId}" is not a blend.` };
5184
5120
  if (!node || node.blendStep || node.locked || node.id === blendId) return { ok: false, message: `"${nodeId}" cannot be a key.` };
5185
- const parentOf = (id) => _nullishCoalesce(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _176 => _176.parent, 'optionalAccess', _177 => _177.id]), () => ( null));
5121
+ const parentOf = (id) => _nullishCoalesce(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _176 => _176.parent, 'optionalAccess', _177 => _177.id]), () => ( null));
5186
5122
  if (parentOf(blendId) !== parentOf(nodeId)) return { ok: false, message: "The new key must sit beside the blend (same parent)." };
5187
5123
  const start = options.start;
5188
5124
  this.change("Blend", () => {
5189
5125
  const blend = start !== null && start !== void 0 ? { ...group.blend, starts: { ...group.blend.starts, [nodeId]: start } } : group.blend;
5190
- const m = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, group));
5191
- const key = group.transform ? _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, node, m) : node;
5126
+ const m = _chunkDWGZUSEScjs.invertMatrix.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, group));
5127
+ const key = group.transform ? _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, node, m) : node;
5192
5128
  const without = mapTree(this.doc.nodes, (n) => n.id === nodeId ? null : n);
5193
5129
  this.setDoc(spliceTree(without, blendId, [{ ...group, blend, children: [...group.children, key] }]));
5194
5130
  this.selection = [blendId];
@@ -5214,7 +5150,7 @@ var VectorEditorController = (_class3 = class {
5214
5150
  if (!groups.length) return [];
5215
5151
  const set = new Set(groups.map((g) => g.id));
5216
5152
  const used = /* @__PURE__ */ new Set();
5217
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
5153
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
5218
5154
  const fresh = () => {
5219
5155
  let id = this.createId();
5220
5156
  while (used.has(id)) id = this.createId();
@@ -5252,14 +5188,14 @@ var VectorEditorController = (_class3 = class {
5252
5188
  replaceBlendSpine(options = {}) {
5253
5189
  const roots = _nullishCoalesce(options.ids, () => ( this.selectedRoots()));
5254
5190
  const groups = this.blendTargets(roots);
5255
- const paths = roots.map((id) => this.getNode(id)).filter((n) => _optionalChain([n, 'optionalAccess', _178 => _178.type]) === "path" && !n.blendStep && !isVectorBlendGroup(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _179 => _179.parent])));
5191
+ const paths = roots.map((id) => this.getNode(id)).filter((n) => _optionalChain([n, 'optionalAccess', _178 => _178.type]) === "path" && !n.blendStep && !isVectorBlendGroup(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _179 => _179.parent])));
5256
5192
  if (groups.length !== 1 || paths.length !== 1) return { ok: false, message: "Select one blend and one path to be its spine." };
5257
5193
  const group = groups[0];
5258
5194
  const path = paths[0];
5259
5195
  const first = path.subpaths.find((sp) => sp.anchors.length >= 2);
5260
5196
  if (!first) return { ok: false, message: "The spine needs a path with at least two points." };
5261
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, this.worldOf(path.id), _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(group.id)));
5262
- const spine = _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, { id: "", type: "path", subpaths: [first] }, m).subpaths[0];
5197
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, this.worldOf(path.id), _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(group.id)));
5198
+ const spine = _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, { id: "", type: "path", subpaths: [first] }, m).subpaths[0];
5263
5199
  this.change("Replace Spine", () => {
5264
5200
  const withSpine = { ...group, blend: { ...group.blend, spine } };
5265
5201
  const targets = vectorBlendKeyTargets(withSpine);
@@ -5267,11 +5203,11 @@ var VectorEditorController = (_class3 = class {
5267
5203
  const children = withSpine.children.map((c) => {
5268
5204
  if (c.blendStep) return c;
5269
5205
  const target = targets[k++];
5270
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, c);
5206
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, c);
5271
5207
  if (!target || !b) return c;
5272
5208
  const dx = target[0] - (b.x + b.width / 2);
5273
5209
  const dy = target[1] - (b.y + b.height / 2);
5274
- return Math.hypot(dx, dy) > 1e-9 ? _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, c, _chunk7MD7C6XQcjs.translateMatrix.call(void 0, dx, dy)) : c;
5210
+ return Math.hypot(dx, dy) > 1e-9 ? _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, c, _chunkDWGZUSEScjs.translateMatrix.call(void 0, dx, dy)) : c;
5275
5211
  });
5276
5212
  this.setDoc(mapTree(this.doc.nodes, (n) => n.id === path.id ? null : n.id === group.id ? { ...withSpine, children } : n));
5277
5213
  this.selection = [group.id];
@@ -5339,15 +5275,15 @@ var VectorEditorController = (_class3 = class {
5339
5275
  let nodes = this.doc.nodes;
5340
5276
  m.entries.forEach((entry, i) => {
5341
5277
  const node = entry.node;
5342
- const toLocal = (path) => _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, path, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node), entry.parent)));
5278
+ const toLocal = (path) => _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, path, _chunkDWGZUSEScjs.invertMatrix.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node), entry.parent)));
5343
5279
  const list = [];
5344
5280
  const r = plan.replace.get(i);
5345
5281
  if (r === void 0) list.push(node);
5346
- else if (_optionalChain([r, 'optionalAccess', _182 => _182.kind]) === "fill") list.push({ ...node, fillRule: "nonzero", subpaths: _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5347
- else if (_optionalChain([r, 'optionalAccess', _183 => _183.kind]) === "outline") list.push({ ...node, subpaths: _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5282
+ else if (_optionalChain([r, 'optionalAccess', _182 => _182.kind]) === "fill") list.push({ ...node, fillRule: "nonzero", subpaths: _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5283
+ else if (_optionalChain([r, 'optionalAccess', _183 => _183.kind]) === "outline") list.push({ ...node, subpaths: _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5348
5284
  else if (_optionalChain([r, 'optionalAccess', _184 => _184.kind]) === "pieces") {
5349
5285
  r.paths.forEach(
5350
- (path, k) => list.push({ ...node, id: k === 0 ? node.id : this.newId(), subpaths: _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, toLocal(path)).map((sp) => ({ ...sp, closed: false })) })
5286
+ (path, k) => list.push({ ...node, id: k === 0 ? node.id : this.newId(), subpaths: _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, toLocal(path)).map((sp) => ({ ...sp, closed: false })) })
5351
5287
  );
5352
5288
  }
5353
5289
  if (plan.merged && plan.merged.style === i) {
@@ -5358,9 +5294,9 @@ var VectorEditorController = (_class3 = class {
5358
5294
  id: mergedId,
5359
5295
  name: "Shape",
5360
5296
  ...node.transform ? { transform: node.transform } : {},
5361
- subpaths: _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, toLocal(plan.merged.path))
5297
+ subpaths: _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, toLocal(plan.merged.path))
5362
5298
  };
5363
- if (plan.merged.currentFill || !_chunk7MD7C6XQcjs.hasPaint.call(void 0, merged.fill)) merged.fill = _chunk7MD7C6XQcjs.hasPaint.call(void 0, this.defaults.fill) ? this.defaults.fill : "#808080";
5299
+ if (plan.merged.currentFill || !_chunkJF5PXN7Wcjs.hasPaint.call(void 0, merged.fill)) merged.fill = _chunkJF5PXN7Wcjs.hasPaint.call(void 0, this.defaults.fill) ? this.defaults.fill : "#808080";
5364
5300
  list.push(merged);
5365
5301
  }
5366
5302
  if (r === void 0 && list.length === 1) return;
@@ -5397,14 +5333,14 @@ var VectorEditorController = (_class3 = class {
5397
5333
  if (!_optionalChain([region, 'optionalAccess', _191 => _191.length])) return null;
5398
5334
  let below = null;
5399
5335
  const roots = new Set(this.selectedRoots());
5400
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5336
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5401
5337
  if (!below && roots.has(n.id)) below = n.id;
5402
5338
  });
5403
- const subpaths = _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, below ? this.intoParentSpace(below, region) : region);
5339
+ const subpaths = _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, below ? this.intoParentSpace(below, region) : region);
5404
5340
  if (!subpaths.length) return null;
5405
5341
  const id = this.newId();
5406
5342
  const node = { id, type: "path", name: "Fill", ...this.styleFor(false), stroke: null, fillRule: "nonzero", subpaths };
5407
- if (!_chunk7MD7C6XQcjs.hasPaint.call(void 0, node.fill)) node.fill = "#808080";
5343
+ if (!_chunkJF5PXN7Wcjs.hasPaint.call(void 0, node.fill)) node.fill = "#808080";
5408
5344
  const target = below;
5409
5345
  this.change("Fill Region", () => {
5410
5346
  if (target) {
@@ -5506,10 +5442,10 @@ var VectorEditorController = (_class3 = class {
5506
5442
  /** Moves anchors by a document-space offset (converted into each node's own space). */
5507
5443
  movedAnchors(doc, refs, dx, dy) {
5508
5444
  const local = /* @__PURE__ */ new Map();
5509
- for (const r of refs) if (!local.has(r.nodeId)) local.set(r.nodeId, _chunk7MD7C6XQcjs.applyMatrixLinear.call(void 0, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(r.nodeId, doc)), { x: dx, y: dy }));
5445
+ for (const r of refs) if (!local.has(r.nodeId)) local.set(r.nodeId, _chunkDWGZUSEScjs.applyMatrixLinear.call(void 0, _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(r.nodeId, doc)), { x: dx, y: dy }));
5510
5446
  return this.updateAnchors(doc, refs, (a, ref) => {
5511
5447
  const d = local.get(ref.nodeId);
5512
- return _chunk7MD7C6XQcjs.translateAnchor.call(void 0, a, d.x, d.y);
5448
+ return _chunkJF5PXN7Wcjs.translateAnchor.call(void 0, a, d.x, d.y);
5513
5449
  });
5514
5450
  }
5515
5451
  /**
@@ -5527,7 +5463,7 @@ var VectorEditorController = (_class3 = class {
5527
5463
  }
5528
5464
  /** `doc` with anchor `ref` moved to document point `to` by a Curvature-tool move. */
5529
5465
  curvatureMoved(doc, ref, to) {
5530
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5466
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5531
5467
  if (_optionalChain([node, 'optionalAccess', _196 => _196.type]) !== "path" || node.locked || !node.subpaths[ref.subpath]) return doc;
5532
5468
  const q = this.toLocal(ref.nodeId, to, doc);
5533
5469
  const subpaths = node.subpaths.map((sp, i) => i === ref.subpath ? curvatureMoveAnchor(sp, ref.index, q) : sp);
@@ -5536,7 +5472,7 @@ var VectorEditorController = (_class3 = class {
5536
5472
  }
5537
5473
  /** `doc` with segment `ref` bent through document point `p` at parameter `t`. */
5538
5474
  bent(doc, ref, t, p) {
5539
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5475
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5540
5476
  if (_optionalChain([node, 'optionalAccess', _197 => _197.type]) !== "path" || node.locked || !node.subpaths[ref.subpath]) return doc;
5541
5477
  const q = this.toLocal(ref.nodeId, p, doc);
5542
5478
  const subpaths = node.subpaths.map((sp, i) => i === ref.subpath ? bendSegment(sp, ref.segment, t, q) : sp);
@@ -5561,7 +5497,7 @@ var VectorEditorController = (_class3 = class {
5561
5497
  if (!getAnchor(this.doc, ref)) return { ok: false, message: "There is no such anchor." };
5562
5498
  const local = this.toLocal(ref.nodeId, to);
5563
5499
  this.change("Move Handle", () => {
5564
- this.doc = this.updateAnchors(this.doc, [ref], (a) => _chunk7MD7C6XQcjs.moveAnchorHandle.call(void 0, a, ref.handle, local, options.breakHandles));
5500
+ this.doc = this.updateAnchors(this.doc, [ref], (a) => _chunkJF5PXN7Wcjs.moveAnchorHandle.call(void 0, a, ref.handle, local, options.breakHandles));
5565
5501
  });
5566
5502
  return { ok: true };
5567
5503
  }
@@ -5573,7 +5509,7 @@ var VectorEditorController = (_class3 = class {
5573
5509
  if (n.type !== "path") return n;
5574
5510
  const mine = refs.filter((r) => r.nodeId === n.id);
5575
5511
  if (!mine.length) return n;
5576
- const subpaths = n.subpaths.map((sp, s) => mine.filter((r) => r.subpath === s).reduce((acc, r) => _chunk7MD7C6XQcjs.convertAnchor.call(void 0, acc, r.index, type), sp));
5512
+ const subpaths = n.subpaths.map((sp, s) => mine.filter((r) => r.subpath === s).reduce((acc, r) => _chunkJF5PXN7Wcjs.convertAnchor.call(void 0, acc, r.index, type), sp));
5577
5513
  return { ...n, subpaths };
5578
5514
  });
5579
5515
  this.setDoc(nodes);
@@ -5584,9 +5520,9 @@ var VectorEditorController = (_class3 = class {
5584
5520
  insertAnchorAt(nodeId, point) {
5585
5521
  const node = this.getNode(nodeId);
5586
5522
  if (_optionalChain([node, 'optionalAccess', _199 => _199.type]) !== "path") return null;
5587
- const hit = _chunk7MD7C6XQcjs.nearestSegment.call(void 0, node, this.toLocal(nodeId, point));
5523
+ const hit = _chunkJF5PXN7Wcjs.nearestSegment.call(void 0, node, this.toLocal(nodeId, point));
5588
5524
  if (!hit) return null;
5589
- const { subpath, index } = _chunk7MD7C6XQcjs.insertAnchor.call(void 0, node.subpaths[hit.subpath], hit.segment, hit.t);
5525
+ const { subpath, index } = _chunkJF5PXN7Wcjs.insertAnchor.call(void 0, node.subpaths[hit.subpath], hit.segment, hit.t);
5590
5526
  const ref = { nodeId, subpath: hit.subpath, index };
5591
5527
  this.change("Add Point", () => {
5592
5528
  this.replaceNode(nodeId, { ...node, subpaths: node.subpaths.map((sp, i) => i === hit.subpath ? subpath : sp) });
@@ -5611,7 +5547,7 @@ var VectorEditorController = (_class3 = class {
5611
5547
  const subpaths = n.subpaths.map((sp, s) => {
5612
5548
  const indices = mine.filter((r) => r.subpath === s).map((r) => r.index);
5613
5549
  if (!indices.length) return sp;
5614
- return keepShape ? removeAnchorsKeepingShape(sp, indices) : _chunk7MD7C6XQcjs.removeAnchors.call(void 0, sp, indices);
5550
+ return keepShape ? removeAnchorsKeepingShape(sp, indices) : _chunkJF5PXN7Wcjs.removeAnchors.call(void 0, sp, indices);
5615
5551
  }).filter((sp) => sp.anchors.length > 1);
5616
5552
  return subpaths.length ? { ...n, subpaths } : null;
5617
5553
  });
@@ -5642,13 +5578,13 @@ var VectorEditorController = (_class3 = class {
5642
5578
  }
5643
5579
  /** Reverses the direction of every subpath of the selected paths. */
5644
5580
  reversePaths(ids = this.selection) {
5645
- const set = new Set(ids.flatMap((id) => this.getNode(id) ? _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, this.getNode(id)) : []).map((p) => p.id));
5581
+ const set = new Set(ids.flatMap((id) => this.getNode(id) ? _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, this.getNode(id)) : []).map((p) => p.id));
5646
5582
  if (!set.size) return { ok: false, message: "Select a path." };
5647
5583
  this.change("Reverse Path", () => {
5648
5584
  this.setDoc(
5649
5585
  mapTree(
5650
5586
  this.doc.nodes,
5651
- (n) => n.type === "path" && set.has(n.id) ? { ...n, subpaths: n.subpaths.map(_chunk7MD7C6XQcjs.reverseSubpath), ..._optionalChain([n, 'access', _201 => _201.strokeWidthProfile, 'optionalAccess', _202 => _202.length]) ? { strokeWidthProfile: _chunk7MD7C6XQcjs.reverseWidthProfile.call(void 0, n.strokeWidthProfile) } : {} } : n
5587
+ (n) => n.type === "path" && set.has(n.id) ? { ...n, subpaths: n.subpaths.map(_chunkJF5PXN7Wcjs.reverseSubpath), ..._optionalChain([n, 'access', _201 => _201.strokeWidthProfile, 'optionalAccess', _202 => _202.length]) ? { strokeWidthProfile: _chunkJF5PXN7Wcjs.reverseWidthProfile.call(void 0, n.strokeWidthProfile) } : {} } : n
5652
5588
  )
5653
5589
  );
5654
5590
  this.anchors = [];
@@ -5665,20 +5601,20 @@ var VectorEditorController = (_class3 = class {
5665
5601
  for (const id of roots) {
5666
5602
  const node = this.getNode(id);
5667
5603
  if (node && !node.locked) {
5668
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
5604
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
5669
5605
  }
5670
5606
  }
5671
5607
  const order = [];
5672
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5608
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5673
5609
  if (out.has(n.id)) order.push(n.id);
5674
5610
  });
5675
5611
  return order.map((id) => out.get(id));
5676
5612
  }
5677
5613
  /** Subpaths of node `from` mapped into node `to`'s own space. */
5678
5614
  subpathsIn(from, to) {
5679
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, this.worldOf(from.id), _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(to)));
5615
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, this.worldOf(from.id), _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(to)));
5680
5616
  if (isRoot(m)) return from.subpaths;
5681
- const map = (p) => _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, p);
5617
+ const map = (p) => _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, p);
5682
5618
  return from.subpaths.map((sp) => ({
5683
5619
  closed: sp.closed,
5684
5620
  anchors: sp.anchors.map((a) => ({ ...map(a), ...a.in ? { in: map(a.in) } : {}, ...a.out ? { out: map(a.out) } : {}, ...a.type ? { type: a.type } : {}, ...a.corner ? { corner: { ...a.corner } } : {} }))
@@ -5788,7 +5724,7 @@ var VectorEditorController = (_class3 = class {
5788
5724
  const node = this.getNode(nodeId);
5789
5725
  if (_optionalChain([node, 'optionalAccess', _203 => _203.type]) !== "path" || node.locked) return null;
5790
5726
  const local = this.toLocal(nodeId, point);
5791
- const hit = _chunk7MD7C6XQcjs.nearestSegment.call(void 0, node, local);
5727
+ const hit = _chunkJF5PXN7Wcjs.nearestSegment.call(void 0, node, local);
5792
5728
  if (!hit) return null;
5793
5729
  const sp = node.subpaths[hit.subpath];
5794
5730
  const n = sp.anchors.length;
@@ -5832,7 +5768,7 @@ var VectorEditorController = (_class3 = class {
5832
5768
  /** Visible, unlocked paths a stroke over `points` can reach: in `ids`, the selection, or (with neither) any whose bounds it crosses. */
5833
5769
  strokeTargets(points, ids, pad) {
5834
5770
  const blocked = /* @__PURE__ */ new Set();
5835
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n, parent) => {
5771
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n, parent) => {
5836
5772
  if (n.visible === false || n.locked || parent && blocked.has(parent.id)) blocked.add(n.id);
5837
5773
  });
5838
5774
  const visible = (p) => !blocked.has(p.id);
@@ -5840,17 +5776,17 @@ var VectorEditorController = (_class3 = class {
5840
5776
  const box = polylineBounds(points.map(toPoint2), pad);
5841
5777
  if (!box) return [];
5842
5778
  const out = [];
5843
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5779
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5844
5780
  if (n.type !== "path" || !visible(n)) return;
5845
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunk7MD7C6XQcjs.vectorParentMatrix.call(void 0, this.doc.nodes, n.id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX)));
5846
- if (b && _chunk7MD7C6XQcjs.boundsIntersect.call(void 0, b, box)) out.push(n);
5781
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorParentMatrix.call(void 0, this.doc.nodes, n.id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX)));
5782
+ if (b && _chunkJF5PXN7Wcjs.boundsIntersect.call(void 0, b, box)) out.push(n);
5847
5783
  });
5848
5784
  return out;
5849
5785
  }
5850
5786
  /** A stroke's points in node `id`'s own space. */
5851
5787
  localPoints(id, points) {
5852
- const inv = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(id));
5853
- return points.map((p) => toPoint2(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, inv, p)));
5788
+ const inv = _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(id));
5789
+ return points.map((p) => toPoint2(_chunkDWGZUSEScjs.applyMatrix.call(void 0, inv, p)));
5854
5790
  }
5855
5791
  /**
5856
5792
  * Knife: cuts closed paths along the polyline `points` (document space) wherever it crosses
@@ -5865,8 +5801,8 @@ var VectorEditorController = (_class3 = class {
5865
5801
  for (const node of this.strokeTargets(pts, options.ids, 0)) {
5866
5802
  const closed = node.subpaths.filter((sp) => sp.anchors.length > 1);
5867
5803
  if (!closed.length || closed.some((sp) => !sp.closed)) continue;
5868
- const result = knifePath(_chunk7MD7C6XQcjs.subpathsToBezier.call(void 0, closed), _nullishCoalesce(node.fillRule, () => ( "nonzero")), this.localPoints(node.id, pts));
5869
- if (result) plan.push({ node, pieces: result.map((path) => _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, path)) });
5804
+ const result = knifePath(_chunkJF5PXN7Wcjs.subpathsToBezier.call(void 0, closed), _nullishCoalesce(node.fillRule, () => ( "nonzero")), this.localPoints(node.id, pts));
5805
+ if (result) plan.push({ node, pieces: result.map((path) => _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, path)) });
5870
5806
  }
5871
5807
  if (!plan.length) return [];
5872
5808
  const created = [];
@@ -5895,12 +5831,12 @@ var VectorEditorController = (_class3 = class {
5895
5831
  const rb = _chunkXGD3FSNCcjs.bezierPathBounds.call(void 0, region);
5896
5832
  const reach = rb ? [{ x: rb.minX, y: rb.minY }, { x: rb.maxX, y: rb.maxY }] : points;
5897
5833
  for (const node of this.strokeTargets(reach, options.ids, 0)) {
5898
- const local = _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, region, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(node.id)));
5834
+ const local = _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, region, _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(node.id)));
5899
5835
  const live = node.subpaths.filter((sp) => sp.anchors.length > 1);
5900
5836
  if (!live.length) continue;
5901
- if (_chunk7MD7C6XQcjs.hasPaint.call(void 0, node.fill) && live.every((sp) => sp.closed)) {
5902
- const faces = eraseFromFill(_chunk7MD7C6XQcjs.subpathsToBezier.call(void 0, live), _nullishCoalesce(node.fillRule, () => ( "nonzero")), local);
5903
- if (faces) plan.push({ node, pieces: faces.map((f) => _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, f)) });
5837
+ if (_chunkJF5PXN7Wcjs.hasPaint.call(void 0, node.fill) && live.every((sp) => sp.closed)) {
5838
+ const faces = eraseFromFill(_chunkJF5PXN7Wcjs.subpathsToBezier.call(void 0, live), _nullishCoalesce(node.fillRule, () => ( "nonzero")), local);
5839
+ if (faces) plan.push({ node, pieces: faces.map((f) => _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, f)) });
5904
5840
  continue;
5905
5841
  }
5906
5842
  const results = live.map((sp) => eraseFromOutline(sp, local));
@@ -5945,7 +5881,7 @@ var VectorEditorController = (_class3 = class {
5945
5881
  // -------------------------------------------------------------------------
5946
5882
  /** Copies the selection. Returns JSON text for the system clipboard (or null). */
5947
5883
  copy() {
5948
- const nodes = this.selectedRoots().map((id) => this.getNode(id)).filter((n) => !!n).map((n) => _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, n));
5884
+ const nodes = this.selectedRoots().map((id) => this.getNode(id)).filter((n) => !!n).map((n) => _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, n));
5949
5885
  if (!nodes.length) return null;
5950
5886
  this.clipboard = nodes;
5951
5887
  return JSON.stringify({ type: VECTOR_CLIPBOARD_TYPE, nodes });
@@ -5972,7 +5908,7 @@ var VectorEditorController = (_class3 = class {
5972
5908
  }
5973
5909
  } else if (/<svg[\s>]/i.test(trimmed)) {
5974
5910
  try {
5975
- nodes = _chunk7MD7C6XQcjs.parseVectorSvg.call(void 0, trimmed).nodes;
5911
+ nodes = _chunkJF5PXN7Wcjs.parseVectorSvg.call(void 0, trimmed).nodes;
5976
5912
  } catch (e4) {
5977
5913
  nodes = null;
5978
5914
  }
@@ -5980,13 +5916,13 @@ var VectorEditorController = (_class3 = class {
5980
5916
  } else nodes = this.clipboard;
5981
5917
  if (!_optionalChain([nodes, 'optionalAccess', _208 => _208.length])) return [];
5982
5918
  const offset = _nullishCoalesce(options.offset, () => ( (text && !text.trim().startsWith("{") ? { x: 0, y: 0 } : { x: 10, y: 10 })));
5983
- const copies = nodes.map((n) => _chunk7MD7C6XQcjs.transformVectorNode.call(void 0, this.freshIds(n), _chunk7MD7C6XQcjs.translateMatrix.call(void 0, offset.x, offset.y)));
5919
+ const copies = nodes.map((n) => _chunkJF5PXN7Wcjs.transformVectorNode.call(void 0, this.freshIds(n), _chunkDWGZUSEScjs.translateMatrix.call(void 0, offset.x, offset.y)));
5984
5920
  this.change("Paste", () => {
5985
5921
  this.setDoc([...this.doc.nodes, ...copies]);
5986
5922
  this.selection = copies.map((n) => n.id);
5987
5923
  this.anchors = [];
5988
5924
  });
5989
- if (!text) this.clipboard = copies.map((n) => _chunk7MD7C6XQcjs.cloneVectorNode.call(void 0, n));
5925
+ if (!text) this.clipboard = copies.map((n) => _chunkJF5PXN7Wcjs.cloneVectorNode.call(void 0, n));
5990
5926
  return copies.map((n) => n.id);
5991
5927
  }
5992
5928
  // -------------------------------------------------------------------------
@@ -6070,7 +6006,7 @@ var VectorEditorController = (_class3 = class {
6070
6006
  /** Deepest unlocked visible path under `p`. */
6071
6007
  /** Live groups being edited (selected, or holding the selection or the edited path): their children are hit as stored. */
6072
6008
  enteredGroups() {
6073
- return _chunk7MD7C6XQcjs.vectorEnteredGroups.call(void 0, this.doc.nodes, this.editingId ? [...this.selection, this.editingId] : this.selection);
6009
+ return _chunkJF5PXN7Wcjs.vectorEnteredGroups.call(void 0, this.doc.nodes, this.editingId ? [...this.selection, this.editingId] : this.selection);
6074
6010
  }
6075
6011
  hitPath(p) {
6076
6012
  const tol = this.tolerance();
@@ -6080,19 +6016,19 @@ var VectorEditorController = (_class3 = class {
6080
6016
  const n = list[i];
6081
6017
  if (n.visible === false || n.locked) continue;
6082
6018
  if (n.type === "group") {
6083
- if (_chunk7MD7C6XQcjs.hasOwnVectorAppearance.call(void 0, n) && !entered.has(n.id) && !_chunk7MD7C6XQcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) continue;
6084
- const found = search(n.children, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent));
6019
+ if (_chunkJF5PXN7Wcjs.hasOwnVectorAppearance.call(void 0, n) && !entered.has(n.id) && !_chunkJF5PXN7Wcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) continue;
6020
+ const found = search(n.children, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent));
6085
6021
  if (found) return found;
6086
- } else if (_chunk7MD7C6XQcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) return n;
6022
+ } else if (_chunkJF5PXN7Wcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) return n;
6087
6023
  }
6088
6024
  return null;
6089
6025
  };
6090
- return search(this.doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
6026
+ return search(this.doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
6091
6027
  }
6092
6028
  /** Endpoints of open subpaths of unlocked visible paths (pen tool resumes from them). */
6093
6029
  openEndpoints() {
6094
6030
  const out = [];
6095
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6031
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6096
6032
  if (n.type !== "path" || n.locked || n.visible === false) return;
6097
6033
  n.subpaths.forEach((sp, s) => {
6098
6034
  if (sp.closed || sp.anchors.length < 1) return;
@@ -6108,7 +6044,7 @@ var VectorEditorController = (_class3 = class {
6108
6044
  case "select": {
6109
6045
  const handle = this.hitTransformHandle(screen);
6110
6046
  if (handle) return { nodeId: null, transformHandle: handle };
6111
- const node = _chunk7MD7C6XQcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6047
+ const node = _chunkJF5PXN7Wcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6112
6048
  return node ? { nodeId: node.id } : null;
6113
6049
  }
6114
6050
  case "direct": {
@@ -6120,9 +6056,9 @@ var VectorEditorController = (_class3 = class {
6120
6056
  if (widget) return { nodeId: widget.ref.nodeId, corner: widget.ref };
6121
6057
  for (const id of getEditablePathIds(this.view())) {
6122
6058
  const node = this.getNode(id);
6123
- const seg = _chunk7MD7C6XQcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6059
+ const seg = _chunkJF5PXN7Wcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6124
6060
  if (seg && seg.distance <= this.tolerance()) {
6125
- const point = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, this.worldOf(id), seg.point);
6061
+ const point = _chunkDWGZUSEScjs.applyMatrix.call(void 0, this.worldOf(id), seg.point);
6126
6062
  return { nodeId: id, segment: { nodeId: id, subpath: seg.subpath, segment: seg.segment, t: seg.t, point } };
6127
6063
  }
6128
6064
  }
@@ -6159,7 +6095,7 @@ var VectorEditorController = (_class3 = class {
6159
6095
  case "envelope": {
6160
6096
  const hit = this.hitEnvelope(screen, p);
6161
6097
  if (hit) return { nodeId: hit.target.node.id, envelope: { nodeId: hit.target.node.id, index: hit.index } };
6162
- const node = _chunk7MD7C6XQcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6098
+ const node = _chunkJF5PXN7Wcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6163
6099
  return node ? { nodeId: node.id } : null;
6164
6100
  }
6165
6101
  default:
@@ -6195,19 +6131,19 @@ var VectorEditorController = (_class3 = class {
6195
6131
  strokeSpotAt(p) {
6196
6132
  let best = null;
6197
6133
  const tol = this.tolerance();
6198
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6134
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6199
6135
  if (n.type !== "path" || n.visible === false || n.locked) return;
6200
6136
  if (hiddenOrLocked(this.doc.nodes, n.id)) return;
6201
6137
  const g = vectorStrokeWidthGeometry(n);
6202
6138
  if (!g) return;
6203
6139
  const m = this.worldOf(n.id);
6204
- const local = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, m), p);
6205
- const near2 = _chunk7MD7C6XQcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6140
+ const local = _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.invertMatrix.call(void 0, m), p);
6141
+ const near2 = _chunkJF5PXN7Wcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6206
6142
  if (!near2) return;
6207
- const profile = _chunk7MD7C6XQcjs.strokeWidthProfileOf.call(void 0, n);
6208
- const w = _chunk7MD7C6XQcjs.widthProfileAt.call(void 0, profile, near2.t);
6143
+ const profile = _chunkJF5PXN7Wcjs.strokeWidthProfileOf.call(void 0, n);
6144
+ const w = _chunkJF5PXN7Wcjs.widthProfileAt.call(void 0, profile, near2.t);
6209
6145
  const reach = Math.max(near2.side === "left" ? w.left : w.right, 0) * g.unit + tol;
6210
- if (near2.distance > reach || near2.distance > _chunk7MD7C6XQcjs.widthProfileMaxScale.call(void 0, profile) * g.unit + tol) return;
6146
+ if (near2.distance > reach || near2.distance > _chunkJF5PXN7Wcjs.widthProfileMaxScale.call(void 0, profile) * g.unit + tol) return;
6211
6147
  if (best && near2.distance >= best.distance) return;
6212
6148
  const nx = near2.tangent[1];
6213
6149
  const ny = -near2.tangent[0];
@@ -6216,9 +6152,9 @@ var VectorEditorController = (_class3 = class {
6216
6152
  nodeId: n.id,
6217
6153
  subpath: near2.contour,
6218
6154
  t: near2.t,
6219
- point: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: cx, y: cy }),
6220
- left: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: cx + nx * w.left * g.unit, y: cy + ny * w.left * g.unit }),
6221
- right: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: cx - nx * w.right * g.unit, y: cy - ny * w.right * g.unit }),
6155
+ point: _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: cx, y: cy }),
6156
+ left: _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: cx + nx * w.left * g.unit, y: cy + ny * w.left * g.unit }),
6157
+ right: _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: cx - nx * w.right * g.unit, y: cy - ny * w.right * g.unit }),
6222
6158
  distance: near2.distance
6223
6159
  };
6224
6160
  });
@@ -6249,11 +6185,11 @@ var VectorEditorController = (_class3 = class {
6249
6185
  let t;
6250
6186
  let subpath;
6251
6187
  if (hit) {
6252
- profile = _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
6188
+ profile = _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
6253
6189
  ref = { nodeId: node.id, index: hit.ref.index, subpath: hit.ref.subpath };
6254
6190
  t = _nullishCoalesce(_optionalChain([profile, 'access', _216 => _216[ref.index], 'optionalAccess', _217 => _217.t]), () => ( 0));
6255
6191
  subpath = hit.ref.subpath;
6256
- if (hit.ref.part === "center") mode = input.alt && profile.length < _chunk7MD7C6XQcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS ? "copy" : "move";
6192
+ if (hit.ref.part === "center") mode = input.alt && profile.length < _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS ? "copy" : "move";
6257
6193
  else if (input.alt) side = hit.ref.part;
6258
6194
  const same = this.widthPoints.length > 0 && this.widthPoints[0].nodeId === node.id;
6259
6195
  const selected = same && this.widthPoints.some((r) => r.index === ref.index);
@@ -6268,8 +6204,8 @@ var VectorEditorController = (_class3 = class {
6268
6204
  } else if (mode === "copy" || !selected) this.widthPoints = [ref];
6269
6205
  if (mode !== "copy") group = this.widthPoints.filter((r) => r.index !== ref.index).map((r) => r.index);
6270
6206
  } else {
6271
- const near2 = _chunk7MD7C6XQcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6272
- const inserted = _chunk7MD7C6XQcjs.insertWidthPoint.call(void 0, _chunk7MD7C6XQcjs.strokeWidthProfileOf.call(void 0, node), near2.t);
6207
+ const near2 = _chunkJF5PXN7Wcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6208
+ const inserted = _chunkJF5PXN7Wcjs.insertWidthPoint.call(void 0, _chunkJF5PXN7Wcjs.strokeWidthProfileOf.call(void 0, node), near2.t);
6273
6209
  profile = inserted.points;
6274
6210
  subpath = near2.contour;
6275
6211
  t = near2.t;
@@ -6277,7 +6213,7 @@ var VectorEditorController = (_class3 = class {
6277
6213
  if (input.alt) side = near2.side;
6278
6214
  this.widthPoints = [ref];
6279
6215
  }
6280
- const at = _chunk7MD7C6XQcjs.strokePositionPoint.call(void 0, g.line, subpath, t);
6216
+ const at = _chunkJF5PXN7Wcjs.strokePositionPoint.call(void 0, g.line, subpath, t);
6281
6217
  if (!at) return;
6282
6218
  const base = { ...this.doc, nodes: mapTree(this.doc.nodes, (n) => n.id === node.id ? { ...n, strokeWidthProfile: profile } : n) };
6283
6219
  this.doc = base;
@@ -6311,16 +6247,16 @@ var VectorEditorController = (_class3 = class {
6311
6247
  */
6312
6248
  snapWidthT(drag, node, line2, t, skip) {
6313
6249
  const m = this.worldOf(node.id, drag.base);
6314
- const at = _chunk7MD7C6XQcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, t);
6250
+ const at = _chunkJF5PXN7Wcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, t);
6315
6251
  if (!at) return t;
6316
- const here = this.documentToScreen(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: at.point[0], y: at.point[1] }));
6252
+ const here = this.documentToScreen(_chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: at.point[0], y: at.point[1] }));
6317
6253
  let best = t;
6318
6254
  let bestD = this.hitRadius;
6319
6255
  drag.profile.forEach((w, i) => {
6320
6256
  if (i === skip || drag.group.includes(i)) return;
6321
- const q = _chunk7MD7C6XQcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, w.t);
6257
+ const q = _chunkJF5PXN7Wcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, w.t);
6322
6258
  if (!q) return;
6323
- const s = this.documentToScreen(_chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, { x: q.point[0], y: q.point[1] }));
6259
+ const s = this.documentToScreen(_chunkDWGZUSEScjs.applyMatrix.call(void 0, m, { x: q.point[0], y: q.point[1] }));
6324
6260
  const d = Math.hypot(s.x - here.x, s.y - here.y);
6325
6261
  if (d <= bestD) {
6326
6262
  best = w.t;
@@ -6337,18 +6273,18 @@ var VectorEditorController = (_class3 = class {
6337
6273
  for (let i = list.length - 1; i >= 0; i--) {
6338
6274
  const n = list[i];
6339
6275
  if (n.visible === false || n.locked) continue;
6340
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, n), parent);
6276
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, n), parent);
6341
6277
  if (n.type === "group") {
6342
6278
  visit(n.children, m);
6343
6279
  continue;
6344
6280
  }
6345
- const hit = _chunk7MD7C6XQcjs.nearestSegment.call(void 0, n, _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.invertMatrix.call(void 0, m), p));
6281
+ const hit = _chunkJF5PXN7Wcjs.nearestSegment.call(void 0, n, _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.invertMatrix.call(void 0, m), p));
6346
6282
  if (hit && hit.distance <= tol && (!best || hit.distance < best.distance - 1e-9)) {
6347
- best = { nodeId: n.id, subpath: hit.subpath, segment: hit.segment, t: hit.t, point: _chunk7MD7C6XQcjs.applyMatrix.call(void 0, m, hit.point), distance: hit.distance };
6283
+ best = { nodeId: n.id, subpath: hit.subpath, segment: hit.segment, t: hit.t, point: _chunkDWGZUSEScjs.applyMatrix.call(void 0, m, hit.point), distance: hit.distance };
6348
6284
  }
6349
6285
  }
6350
6286
  };
6351
- visit(this.doc.nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX);
6287
+ visit(this.doc.nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX);
6352
6288
  if (!best) return null;
6353
6289
  const { distance: _d, ...seg } = best;
6354
6290
  return seg;
@@ -6405,7 +6341,7 @@ var VectorEditorController = (_class3 = class {
6405
6341
  }
6406
6342
  /** The shape under the pointer for the Blend tool, and the anchor of its first subpath under it. */
6407
6343
  blendHit(screen, p) {
6408
- const node = _chunk7MD7C6XQcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance());
6344
+ const node = _chunkJF5PXN7Wcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance());
6409
6345
  if (!node) return null;
6410
6346
  let anchor = null;
6411
6347
  if (node.type === "path" && node.subpaths[0]) {
@@ -6448,13 +6384,13 @@ var VectorEditorController = (_class3 = class {
6448
6384
  if (handle) {
6449
6385
  const frame = this.frameOf(this.selectedRoots());
6450
6386
  const before = this.snapshot();
6451
- const center = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
6387
+ const center = _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
6452
6388
  this.drag = handle === "rotate" ? { kind: "rotate", start: p, center, before, base: this.doc } : { kind: "scale", handle, start: p, frame, before, base: this.doc };
6453
6389
  this.interaction = handle === "rotate" ? { type: "rotate", angle: 0 } : { type: "scale", handle, sx: 1, sy: 1 };
6454
6390
  this.notify();
6455
6391
  return;
6456
6392
  }
6457
- const node = _chunk7MD7C6XQcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6393
+ const node = _chunkJF5PXN7Wcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6458
6394
  if (node) {
6459
6395
  const selected = this.selection.includes(node.id);
6460
6396
  if (input.shift) {
@@ -6522,12 +6458,12 @@ var VectorEditorController = (_class3 = class {
6522
6458
  }
6523
6459
  for (const id of getEditablePathIds(this.view())) {
6524
6460
  const node = this.getNode(id);
6525
- const seg = _chunk7MD7C6XQcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6461
+ const seg = _chunkJF5PXN7Wcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6526
6462
  if (!seg || seg.distance > this.tolerance()) continue;
6527
6463
  const sp = node.subpaths[seg.subpath];
6528
6464
  if (input.alt) {
6529
6465
  const before = this.snapshot();
6530
- const { subpath, index } = _chunk7MD7C6XQcjs.insertAnchor.call(void 0, sp, seg.segment, seg.t);
6466
+ const { subpath, index } = _chunkJF5PXN7Wcjs.insertAnchor.call(void 0, sp, seg.segment, seg.t);
6531
6467
  this.replaceNode(id, { ...node, subpaths: node.subpaths.map((s, i) => i === seg.subpath ? subpath : s) });
6532
6468
  const ref = { nodeId: id, subpath: seg.subpath, index };
6533
6469
  this.anchors = [ref];
@@ -6594,7 +6530,7 @@ var VectorEditorController = (_class3 = class {
6594
6530
  let node2 = this.getNode(endpoint.nodeId);
6595
6531
  let index = endpoint.index;
6596
6532
  if (index === 0 && node2.subpaths[endpoint.subpath].anchors.length > 1) {
6597
- node2 = { ...node2, subpaths: node2.subpaths.map((s, i) => i === endpoint.subpath ? _chunk7MD7C6XQcjs.reverseSubpath.call(void 0, s) : s) };
6533
+ node2 = { ...node2, subpaths: node2.subpaths.map((s, i) => i === endpoint.subpath ? _chunkJF5PXN7Wcjs.reverseSubpath.call(void 0, s) : s) };
6598
6534
  this.replaceNode(node2.id, node2);
6599
6535
  index = node2.subpaths[endpoint.subpath].anchors.length - 1;
6600
6536
  }
@@ -6697,7 +6633,7 @@ var VectorEditorController = (_class3 = class {
6697
6633
  drag.targets = void 0;
6698
6634
  }
6699
6635
  ({ dx, dy } = this.snapMove(drag, dx, dy, input));
6700
- this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunk7MD7C6XQcjs.translateMatrix.call(void 0, dx, dy));
6636
+ this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunkDWGZUSEScjs.translateMatrix.call(void 0, dx, dy));
6701
6637
  this.interaction = { type: "move", dx, dy };
6702
6638
  this.notify(true);
6703
6639
  return;
@@ -6705,7 +6641,7 @@ var VectorEditorController = (_class3 = class {
6705
6641
  case "scale": {
6706
6642
  if (this.freeDistort && drag.handle !== "rotate") return this.moveDistort(drag, p, input);
6707
6643
  const angle = drag.frame.angle;
6708
- const q = angle ? _chunk7MD7C6XQcjs.applyMatrix.call(void 0, _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, -angle), p) : p;
6644
+ const q = angle ? _chunkDWGZUSEScjs.applyMatrix.call(void 0, _chunkDWGZUSEScjs.rotateMatrix.call(void 0, -angle), p) : p;
6709
6645
  let { sx, sy, origin } = scaleFor(drag.handle, drag.frame, q, input);
6710
6646
  if (this.snap.objects && !input.mod && drag.handle !== "rotate") {
6711
6647
  drag.targets ??= VectorSnapTargets.forResize(drag.base, this.selectedRoots());
@@ -6714,7 +6650,7 @@ var VectorEditorController = (_class3 = class {
6714
6650
  this.setGuides(res);
6715
6651
  } else this.setGuides(null);
6716
6652
  const ids = new Set(this.selectedRoots());
6717
- this.doc = this.transformed(drag.base, ids, this.inFrame(angle, _chunk7MD7C6XQcjs.scaleMatrix.call(void 0, sx, sy, origin)));
6653
+ this.doc = this.transformed(drag.base, ids, this.inFrame(angle, _chunkDWGZUSEScjs.scaleMatrix.call(void 0, sx, sy, origin)));
6718
6654
  this.interaction = { type: "scale", handle: drag.handle, sx, sy };
6719
6655
  this.notify(true);
6720
6656
  return;
@@ -6724,13 +6660,13 @@ var VectorEditorController = (_class3 = class {
6724
6660
  const a1 = Math.atan2(p.y - drag.center.y, p.x - drag.center.x);
6725
6661
  let angle = (a1 - a0) * 180 / Math.PI;
6726
6662
  if (input.shift) angle = Math.round(angle / 15) * 15;
6727
- this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, angle, drag.center));
6663
+ this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunkDWGZUSEScjs.rotateMatrix.call(void 0, angle, drag.center));
6728
6664
  this.interaction = { type: "rotate", angle };
6729
6665
  this.notify(true);
6730
6666
  return;
6731
6667
  }
6732
6668
  case "marquee": {
6733
- const bounds = _chunk7MD7C6XQcjs.boundsFromPoints.call(void 0, drag.start, p);
6669
+ const bounds = _chunkJF5PXN7Wcjs.boundsFromPoints.call(void 0, drag.start, p);
6734
6670
  this.interaction = { type: "marquee", bounds };
6735
6671
  if (drag.anchorsMode) {
6736
6672
  const inside = getVisibleAnchors(this.view()).filter((r) => {
@@ -6740,8 +6676,8 @@ var VectorEditorController = (_class3 = class {
6740
6676
  this.anchors = [...drag.baseAnchors, ...inside.filter((r) => !drag.baseAnchors.some((b) => sameRef(b, r)))];
6741
6677
  } else {
6742
6678
  const hits = this.doc.nodes.filter((n) => !n.locked && n.visible !== false).filter((n) => {
6743
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n);
6744
- return b && _chunk7MD7C6XQcjs.boundsIntersect.call(void 0, b, bounds);
6679
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n);
6680
+ return b && _chunkJF5PXN7Wcjs.boundsIntersect.call(void 0, b, bounds);
6745
6681
  }).map((n) => n.id);
6746
6682
  this.selection = [.../* @__PURE__ */ new Set([...drag.base, ...hits])];
6747
6683
  }
@@ -6773,7 +6709,7 @@ var VectorEditorController = (_class3 = class {
6773
6709
  const leave = anchor ? { at: { x: anchor.x, y: anchor.y }, constrain: input.shift ? "angle" : null } : null;
6774
6710
  const pt = this.snapDrawn(p, leave, input, () => drag.targets ??= VectorSnapTargets.forHandle(drag.base, drag.ref.nodeId));
6775
6711
  const local = this.toLocal(drag.ref.nodeId, pt, drag.base);
6776
- this.doc = this.updateAnchors(drag.base, [drag.ref], (a) => _chunk7MD7C6XQcjs.moveAnchorHandle.call(void 0, a, drag.ref.handle, local, input.alt));
6712
+ this.doc = this.updateAnchors(drag.base, [drag.ref], (a) => _chunkJF5PXN7Wcjs.moveAnchorHandle.call(void 0, a, drag.ref.handle, local, input.alt));
6777
6713
  this.interaction = { type: "handle", ref: drag.ref };
6778
6714
  this.notify(true);
6779
6715
  return;
@@ -6782,10 +6718,10 @@ var VectorEditorController = (_class3 = class {
6782
6718
  if (!drag.moved && Math.hypot(p.x - drag.start.x, p.y - drag.start.y) * this.viewport.zoom < 3) return;
6783
6719
  drag.moved = true;
6784
6720
  const c = drag.widget.corner;
6785
- const inv = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, this.worldOf(drag.widget.ref.nodeId, drag.base));
6786
- const d = _chunk7MD7C6XQcjs.applyMatrixLinear.call(void 0, inv, { x: p.x - drag.start.x, y: p.y - drag.start.y });
6787
- const radius = Math.max(0, Math.min(c.maxRadius, drag.widget.drawnRadius + _chunk7MD7C6XQcjs.cornerRadiusChange.call(void 0, c, d)));
6788
- this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunk7MD7C6XQcjs.setAnchorCorner.call(void 0, a, radius));
6721
+ const inv = _chunkDWGZUSEScjs.invertMatrix.call(void 0, this.worldOf(drag.widget.ref.nodeId, drag.base));
6722
+ const d = _chunkDWGZUSEScjs.applyMatrixLinear.call(void 0, inv, { x: p.x - drag.start.x, y: p.y - drag.start.y });
6723
+ const radius = Math.max(0, Math.min(c.maxRadius, drag.widget.drawnRadius + _chunkJF5PXN7Wcjs.cornerRadiusChange.call(void 0, c, d)));
6724
+ this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunkJF5PXN7Wcjs.setAnchorCorner.call(void 0, a, radius));
6789
6725
  this.interaction = { type: "corner", ref: drag.widget.ref, radius };
6790
6726
  this.notify(true);
6791
6727
  return;
@@ -6822,8 +6758,8 @@ var VectorEditorController = (_class3 = class {
6822
6758
  const side = drag.closing ? "in" : "out";
6823
6759
  const pos = this.toLocal(drag.ref.nodeId, drag.closing ? { x: 2 * anchor.x - pt.x, y: 2 * anchor.y - pt.y } : pt, drag.base);
6824
6760
  this.doc = this.updateAnchors(drag.base, [drag.ref], (a) => {
6825
- if (drag.outOnly || drag.altBreaks && input.alt) return _chunk7MD7C6XQcjs.moveAnchorHandle.call(void 0, a, side, pos, true);
6826
- return _chunk7MD7C6XQcjs.moveAnchorHandle.call(void 0, { ...a, type: "symmetric" }, side, pos);
6761
+ if (drag.outOnly || drag.altBreaks && input.alt) return _chunkJF5PXN7Wcjs.moveAnchorHandle.call(void 0, a, side, pos, true);
6762
+ return _chunkJF5PXN7Wcjs.moveAnchorHandle.call(void 0, { ...a, type: "symmetric" }, side, pos);
6827
6763
  });
6828
6764
  this.notify(true);
6829
6765
  return;
@@ -6851,7 +6787,7 @@ var VectorEditorController = (_class3 = class {
6851
6787
  if (input.alt) start = { x: start.x - w, y: start.y - h };
6852
6788
  const x2 = drag.start.x + w;
6853
6789
  const y2 = drag.start.y + h;
6854
- bounds = _chunk7MD7C6XQcjs.boundsFromPoints.call(void 0, start, { x: x2, y: y2 });
6790
+ bounds = _chunkJF5PXN7Wcjs.boundsFromPoints.call(void 0, start, { x: x2, y: y2 });
6855
6791
  }
6856
6792
  const shaped = this.createShapeNode({ kind: drag.tool, ...bounds });
6857
6793
  this.replaceNode(drag.nodeId, { ...node, subpaths: shaped.subpaths });
@@ -6862,32 +6798,32 @@ var VectorEditorController = (_class3 = class {
6862
6798
  case "width": {
6863
6799
  if (!drag.moved && Math.hypot(p.x - drag.start.x, p.y - drag.start.y) * this.viewport.zoom < 2) return;
6864
6800
  drag.moved = true;
6865
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, drag.base.nodes, drag.ref.nodeId);
6801
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, drag.base.nodes, drag.ref.nodeId);
6866
6802
  const local = this.toLocal(node.id, p, drag.base);
6867
6803
  const src = drag.profile[drag.source];
6868
6804
  let profile;
6869
6805
  let index = drag.source;
6870
6806
  if (drag.mode !== "width") {
6871
6807
  const g = vectorStrokeWidthGeometry(node);
6872
- const near2 = g ? _chunk7MD7C6XQcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y], drag.ref.subpath) : null;
6808
+ const near2 = g ? _chunkJF5PXN7Wcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y], drag.ref.subpath) : null;
6873
6809
  if (!g || !near2) return;
6874
6810
  const t = drag.group.length ? near2.t : this.snapWidthT(drag, node, g.line, near2.t, drag.source);
6875
6811
  if (drag.mode === "copy") {
6876
- ({ points: profile, index } = _chunk7MD7C6XQcjs.insertWidthPoint.call(void 0, drag.profile, t, { left: src.left, right: src.right }, { step: true }));
6812
+ ({ points: profile, index } = _chunkJF5PXN7Wcjs.insertWidthPoint.call(void 0, drag.profile, t, { left: src.left, right: src.right }, { step: true }));
6877
6813
  } else if (drag.group.length) {
6878
6814
  const shifted = shiftWidthPoints(drag.profile, [drag.source, ...drag.group], t - src.t);
6879
6815
  profile = shifted.points;
6880
6816
  drag.renumber = shifted.renumber;
6881
6817
  index = _nullishCoalesce(shifted.renumber.get(drag.source), () => ( drag.source));
6882
- } else profile = _chunk7MD7C6XQcjs.setWidthPoint.call(void 0, drag.profile, drag.source, { t });
6818
+ } else profile = _chunkJF5PXN7Wcjs.setWidthPoint.call(void 0, drag.profile, drag.source, { t });
6883
6819
  } else {
6884
6820
  const off = ((local.x - drag.origin.x) * drag.normal.x + (local.y - drag.origin.y) * drag.normal.y) / drag.unit;
6885
6821
  const patch = drag.side === "both" ? { left: Math.abs(off), right: Math.abs(off) } : drag.side === "left" ? { left: Math.max(0, off) } : { right: Math.max(0, -off) };
6886
- profile = _chunk7MD7C6XQcjs.setWidthPoint.call(void 0, drag.profile, drag.source, patch);
6822
+ profile = _chunkJF5PXN7Wcjs.setWidthPoint.call(void 0, drag.profile, drag.source, patch);
6887
6823
  if (drag.group.length) {
6888
6824
  const dl = profile[drag.source].left - src.left;
6889
6825
  const dr = profile[drag.source].right - src.right;
6890
- for (const i of drag.group) profile = _chunk7MD7C6XQcjs.setWidthPoint.call(void 0, profile, i, { left: Math.max(0, drag.profile[i].left + dl), right: Math.max(0, drag.profile[i].right + dr) });
6826
+ for (const i of drag.group) profile = _chunkJF5PXN7Wcjs.setWidthPoint.call(void 0, profile, i, { left: Math.max(0, drag.profile[i].left + dl), right: Math.max(0, drag.profile[i].right + dr) });
6891
6827
  }
6892
6828
  }
6893
6829
  this.doc = { ...drag.base, nodes: mapTree(drag.base.nodes, (n) => n.id === node.id ? { ...n, strokeWidthProfile: profile } : n) };
@@ -7032,8 +6968,8 @@ var VectorEditorController = (_class3 = class {
7032
6968
  case "corner": {
7033
6969
  if (drag.moved) return this.commit("Corner Radius", drag.before);
7034
6970
  if (drag.alt) {
7035
- const kind = _chunk7MD7C6XQcjs.nextVectorCornerKind.call(void 0, drag.widget.kind);
7036
- this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunk7MD7C6XQcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _234 => _234.corner, 'optionalAccess', _235 => _235.radius]), () => ( 0)), kind));
6971
+ const kind = _chunkJF5PXN7Wcjs.nextVectorCornerKind.call(void 0, drag.widget.kind);
6972
+ this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunkJF5PXN7Wcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _234 => _234.corner, 'optionalAccess', _235 => _235.radius]), () => ( 0)), kind));
7037
6973
  return this.commit("Corner Kind", drag.before);
7038
6974
  }
7039
6975
  const ref = drag.widget.ref;
@@ -7078,7 +7014,7 @@ var VectorEditorController = (_class3 = class {
7078
7014
  return this.commit(drag.label, drag.before);
7079
7015
  case "shape": {
7080
7016
  const node = this.getNode(drag.nodeId);
7081
- const b = node ? _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, node) : null;
7017
+ const b = node ? _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, node) : null;
7082
7018
  const min = 2 / this.viewport.zoom;
7083
7019
  if (!b || b.width < min && b.height < min) {
7084
7020
  this.doc = drag.before.doc;
@@ -7114,7 +7050,7 @@ var VectorEditorController = (_class3 = class {
7114
7050
  anchors[anchors.length - 1].out = { x: c.p1[0], y: c.p1[1] };
7115
7051
  anchors.push({ x: c.p3[0], y: c.p3[1], in: { x: c.p2[0], y: c.p2[1] } });
7116
7052
  }
7117
- const subpaths = anchors.length > 1 ? _chunk7MD7C6XQcjs.bezierToSubpaths.call(void 0, _chunk7MD7C6XQcjs.subpathsToBezier.call(void 0, [{ anchors, closed: false }])) : node.subpaths;
7053
+ const subpaths = anchors.length > 1 ? _chunkJF5PXN7Wcjs.bezierToSubpaths.call(void 0, _chunkJF5PXN7Wcjs.subpathsToBezier.call(void 0, [{ anchors, closed: false }])) : node.subpaths;
7118
7054
  const profile = drag.pressures ? pencilPressureProfile(drag.points, drag.pressures) : [];
7119
7055
  this.replaceNode(drag.nodeId, { ...node, subpaths, ...profile.length ? { strokeWidthProfile: profile } : {} });
7120
7056
  this.selection = [drag.nodeId];
@@ -7177,7 +7113,7 @@ var VectorEditorController = (_class3 = class {
7177
7113
  const id = _nullishCoalesce(_optionalChain([this, 'access', _243 => _243.hover, 'optionalAccess', _244 => _244.segment, 'optionalAccess', _245 => _245.nodeId]), () => ( this.editingId));
7178
7114
  if (id) {
7179
7115
  const node = this.getNode(id);
7180
- const seg = node ? _chunk7MD7C6XQcjs.nearestSegment.call(void 0, node, this.toLocal(id, p)) : null;
7116
+ const seg = node ? _chunkJF5PXN7Wcjs.nearestSegment.call(void 0, node, this.toLocal(id, p)) : null;
7181
7117
  if (seg && seg.distance <= this.tolerance()) this.insertAnchorAt(id, p);
7182
7118
  }
7183
7119
  return;
@@ -7326,11 +7262,11 @@ function inkShapeLabel(shape) {
7326
7262
  function inkShapeSubpath(shape) {
7327
7263
  switch (shape.kind) {
7328
7264
  case "line":
7329
- return _chunk7MD7C6XQcjs.lineSubpath.call(void 0, { x: shape.a[0], y: shape.a[1] }, { x: shape.b[0], y: shape.b[1] });
7265
+ return _chunkJF5PXN7Wcjs.lineSubpath.call(void 0, { x: shape.a[0], y: shape.a[1] }, { x: shape.b[0], y: shape.b[1] });
7330
7266
  case "rect":
7331
- return _chunk7MD7C6XQcjs.rectSubpath.call(void 0, shape);
7267
+ return _chunkJF5PXN7Wcjs.rectSubpath.call(void 0, shape);
7332
7268
  case "ellipse":
7333
- return _chunk7MD7C6XQcjs.ellipseSubpath.call(void 0, shape);
7269
+ return _chunkJF5PXN7Wcjs.ellipseSubpath.call(void 0, shape);
7334
7270
  case "polygon":
7335
7271
  return { anchors: shape.points.map(([x, y]) => ({ x, y })), closed: true };
7336
7272
  }
@@ -7366,14 +7302,14 @@ function scaleFor(handle, b, p, mods = {}) {
7366
7302
  function withStyle(node, style) {
7367
7303
  const next = { ...node, ...style };
7368
7304
  if ("strokeWidthProfile" in style) {
7369
- const p = style.strokeWidthProfile ? _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, style.strokeWidthProfile) : [];
7305
+ const p = style.strokeWidthProfile ? _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, style.strokeWidthProfile) : [];
7370
7306
  if (p.length) next.strokeWidthProfile = p;
7371
7307
  else delete next.strokeWidthProfile;
7372
7308
  }
7373
7309
  return next;
7374
7310
  }
7375
7311
  function hiddenOrLocked(nodes, id) {
7376
- const loc = _chunk7MD7C6XQcjs.locateVectorNode.call(void 0, nodes, id);
7312
+ const loc = _chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, nodes, id);
7377
7313
  if (!loc) return false;
7378
7314
  const n = loc.list[loc.index];
7379
7315
  if (n.locked || n.visible === false) return true;
@@ -7386,7 +7322,7 @@ function pencilPressureProfile(points, pressures) {
7386
7322
  for (let i = 1; i < n; i++) s.push(s[i - 1] + Math.hypot(points[i][0] - points[i - 1][0], points[i][1] - points[i - 1][1]));
7387
7323
  const total = s[n - 1];
7388
7324
  if (!(total > 0)) return [];
7389
- return _chunk7MD7C6XQcjs.pressureWidthProfile.call(void 0, s.map((d, i) => ({ t: d / total, pressure: pressures[i] })));
7325
+ return _chunkJF5PXN7Wcjs.pressureWidthProfile.call(void 0, s.map((d, i) => ({ t: d / total, pressure: pressures[i] })));
7390
7326
  }
7391
7327
 
7392
7328
  // src/vector/render.ts
@@ -7395,21 +7331,21 @@ var fmtMatrix = (m) => `matrix(${m.map((n) => Math.round(n * 1e6) / 1e6).join("
7395
7331
  var VECTOR_BUILDER_HATCH_GAP = 6;
7396
7332
  function renderNode(stored, defs, idPrefix) {
7397
7333
  if (stored.visible === false) return null;
7398
- const node = _chunk7MD7C6XQcjs.expandVectorAppearance.call(void 0, stored);
7334
+ const node = _chunkJF5PXN7Wcjs.expandVectorAppearance.call(void 0, stored);
7399
7335
  if (node.type === "group") {
7400
7336
  const children = node.children.map((c) => renderNode(c, defs, idPrefix)).filter((c) => !!c);
7401
7337
  return { kind: "group", id: node.id, ...node.transform ? { transform: fmtMatrix(node.transform) } : {}, opacity: _nullishCoalesce(node.opacity, () => ( 1)), children };
7402
7338
  }
7403
- const fill = _chunk7MD7C6XQcjs.vectorPaintToSvg.call(void 0, node.fill, `${idPrefix}fill-${node.id}`, { node });
7404
- const stroke = _chunk7MD7C6XQcjs.vectorPaintToSvg.call(void 0, node.stroke, `${idPrefix}stroke-${node.id}`, { node, role: "stroke" });
7339
+ const fill = _chunkJF5PXN7Wcjs.vectorPaintToSvg.call(void 0, node.fill, `${idPrefix}fill-${node.id}`, { node });
7340
+ const stroke = _chunkJF5PXN7Wcjs.vectorPaintToSvg.call(void 0, node.stroke, `${idPrefix}stroke-${node.id}`, { node, role: "stroke" });
7405
7341
  defs.push(...fill.defs, ...stroke.defs);
7406
- const strokeParts = stroke.value !== "none" ? _chunk7MD7C6XQcjs.vectorStrokeSvgParts.call(void 0, node, `${idPrefix}clip-${node.id}`) : void 0;
7342
+ const strokeParts = stroke.value !== "none" ? _chunkJF5PXN7Wcjs.vectorStrokeSvgParts.call(void 0, node, `${idPrefix}clip-${node.id}`) : void 0;
7407
7343
  return {
7408
7344
  kind: "path",
7409
7345
  id: node.id,
7410
7346
  ...node.transform ? { transform: fmtMatrix(node.transform) } : {},
7411
7347
  ...strokeParts ? { strokeParts } : {},
7412
- d: _chunk7MD7C6XQcjs.vectorPathData.call(void 0, node),
7348
+ d: _chunkJF5PXN7Wcjs.vectorPathData.call(void 0, node),
7413
7349
  fill: fill.value,
7414
7350
  stroke: stroke.value,
7415
7351
  strokeWidth: _nullishCoalesce(node.strokeWidth, () => ( 1)),
@@ -7438,17 +7374,17 @@ var toScreen = (state, p) => ({ x: p.x * state.viewport.zoom + state.viewport.x,
7438
7374
  function screenOutline(state, node, entered) {
7439
7375
  const v = state.viewport;
7440
7376
  const view = [v.zoom, 0, 0, v.zoom, v.x, v.y];
7441
- const parent = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorParentMatrix.call(void 0, state.document.nodes, node.id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
7377
+ const parent = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorParentMatrix.call(void 0, state.document.nodes, node.id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
7442
7378
  return outlinePaths(node, parent, entered).map((path) => _chunkXGD3FSNCcjs.bezierPathToSvg.call(void 0, _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, path, view), { precision: 2 })).join(" ");
7443
7379
  }
7444
7380
  function outlinePaths(node, parent, entered) {
7445
- if (node.type === "path") return [_chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, node, parent, { effects: false })];
7446
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node), parent);
7447
- if (_chunk7MD7C6XQcjs.hasOwnVectorAppearance.call(void 0, node) && !entered.has(node.id)) return [_chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunk7MD7C6XQcjs.vectorAppearanceOutline.call(void 0, node), m)];
7381
+ if (node.type === "path") return [_chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, node, parent, { effects: false })];
7382
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node), parent);
7383
+ if (_chunkJF5PXN7Wcjs.hasOwnVectorAppearance.call(void 0, node) && !entered.has(node.id)) return [_chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunkJF5PXN7Wcjs.vectorAppearanceOutline.call(void 0, node), m)];
7448
7384
  return node.children.filter((c) => c.visible !== false).flatMap((c) => outlinePaths(c, m, entered));
7449
7385
  }
7450
7386
  function getVectorEnteredGroups(state) {
7451
- return _chunk7MD7C6XQcjs.vectorEnteredGroups.call(void 0, state.document.nodes, state.editingId ? [...state.selection, state.editingId] : state.selection);
7387
+ return _chunkJF5PXN7Wcjs.vectorEnteredGroups.call(void 0, state.document.nodes, state.editingId ? [...state.selection, state.editingId] : state.selection);
7452
7388
  }
7453
7389
  function collect(node) {
7454
7390
  if (node.type === "path") return [node];
@@ -7462,7 +7398,7 @@ function getVectorOverlayRenderData(state) {
7462
7398
  const seen = /* @__PURE__ */ new Set();
7463
7399
  const outline = (id, selected2) => {
7464
7400
  if (seen.has(id)) return;
7465
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, id);
7401
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, id);
7466
7402
  if (!node || node.visible === false) return;
7467
7403
  seen.add(id);
7468
7404
  outlines.push({ id, d: screenOutline(state, node, entered), selected: selected2 });
@@ -7481,7 +7417,7 @@ function getVectorOverlayRenderData(state) {
7481
7417
  const a = getAnchorWorld(doc, ref);
7482
7418
  const s = toScreen(state, a);
7483
7419
  const closes = !!state.pen && state.pen.nodeId === ref.nodeId && state.pen.subpath === ref.subpath && ref.index === 0;
7484
- return { ref, x: s.x, y: s.y, type: _nullishCoalesce(a.type, () => ( _chunk7MD7C6XQcjs.inferAnchorType.call(void 0, a))), selected: selected(ref), hovered: sameAnchor(_optionalChain([state, 'access', _257 => _257.hover, 'optionalAccess', _258 => _258.anchor]), ref), closes };
7420
+ return { ref, x: s.x, y: s.y, type: _nullishCoalesce(a.type, () => ( _chunkJF5PXN7Wcjs.inferAnchorType.call(void 0, a))), selected: selected(ref), hovered: sameAnchor(_optionalChain([state, 'access', _257 => _257.hover, 'optionalAccess', _258 => _258.anchor]), ref), closes };
7485
7421
  });
7486
7422
  if (state.tool === "pen" && !state.pen && _optionalChain([state, 'access', _259 => _259.hover, 'optionalAccess', _260 => _260.anchor])) {
7487
7423
  const a = getAnchorWorld(doc, state.hover.anchor);
@@ -7507,7 +7443,7 @@ function getVectorOverlayRenderData(state) {
7507
7443
  }
7508
7444
  let penPreview = null;
7509
7445
  if (state.tool === "pen" && state.pen && state.pointer && !state.interaction) {
7510
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, state.pen.nodeId);
7446
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, state.pen.nodeId);
7511
7447
  const sp = _optionalChain([node, 'optionalAccess', _266 => _266.type]) === "path" ? node.subpaths[state.pen.subpath] : void 0;
7512
7448
  const last = sp ? getAnchorWorld(doc, { nodeId: state.pen.nodeId, subpath: state.pen.subpath, index: sp.anchors.length - 1 }) : void 0;
7513
7449
  if (last) {
@@ -7524,7 +7460,7 @@ function getVectorOverlayRenderData(state) {
7524
7460
  if (_optionalChain([it, 'optionalAccess', _267 => _267.type]) === "rotate") status = `${Math.round(it.angle)}\xB0`;
7525
7461
  else if (_optionalChain([it, 'optionalAccess', _268 => _268.type]) === "move" || _optionalChain([it, 'optionalAccess', _269 => _269.type]) === "anchors") status = `\u0394 ${fmt2(it.dx)}, ${fmt2(it.dy)}`;
7526
7462
  else if (_optionalChain([it, 'optionalAccess', _270 => _270.type]) === "scale" || _optionalChain([it, 'optionalAccess', _271 => _271.type]) === "draw") {
7527
- const b = it.type === "draw" ? _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId) ? _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId)) : null : state.selectionFrame;
7463
+ const b = it.type === "draw" ? _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId) ? _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId)) : null : state.selectionFrame;
7528
7464
  if (b) status = `W ${fmt2(b.width)} \xD7 H ${fmt2(b.height)}`;
7529
7465
  }
7530
7466
  const guides = { lines: [], labels: [] };
@@ -7614,17 +7550,17 @@ function envelopeOverlay(state) {
7614
7550
  const target = getVectorEnvelopeTarget(state.document, state.selection);
7615
7551
  if (!target) return null;
7616
7552
  const v = state.viewport;
7617
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, target.world, [v.zoom, 0, 0, v.zoom, v.x, v.y]);
7553
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, target.world, [v.zoom, 0, 0, v.zoom, v.x, v.y]);
7618
7554
  const sc = (p) => ({ x: fmt2(m[0] * p.x + m[2] * p.y + m[4]), y: fmt2(m[1] * p.x + m[3] * p.y + m[5]) });
7619
7555
  const { mesh } = target.frame;
7620
- const grid = _chunk7MD7C6XQcjs.vectorMeshGridCurves.call(void 0, mesh).map((c) => {
7556
+ const grid = _chunkDWGZUSEScjs.warpMeshGridCurves.call(void 0, mesh).map((c) => {
7621
7557
  const [a, b, cc, d] = c.map(sc);
7622
7558
  return `M${a.x} ${a.y}C${b.x} ${b.y} ${cc.x} ${cc.y} ${d.x} ${d.y}`;
7623
7559
  }).join("");
7624
7560
  const hover = _optionalChain([state, 'access', _289 => _289.hover, 'optionalAccess', _290 => _290.envelope, 'optionalAccess', _291 => _291.nodeId]) === target.node.id ? state.hover.envelope.index : void 0;
7625
7561
  const it = state.interaction;
7626
7562
  const active = _optionalChain([it, 'optionalAccess', _292 => _292.type]) === "envelope" && it.nodeId === target.node.id ? it.index : void 0;
7627
- const pts = _chunk7MD7C6XQcjs.vectorMeshEditPoints.call(void 0, mesh);
7563
+ const pts = _chunkDWGZUSEScjs.warpMeshEditPoints.call(void 0, mesh);
7628
7564
  return {
7629
7565
  nodeId: target.node.id,
7630
7566
  grid,
@@ -7636,16 +7572,16 @@ function envelopeOverlay(state) {
7636
7572
  };
7637
7573
  }
7638
7574
  var VECTOR_ENVELOPE_STYLE_OPTIONS = [
7639
- ..._chunk7MD7C6XQcjs.VECTOR_WARP_STYLES.map((value) => ({ value, label: _chunk7MD7C6XQcjs.VECTOR_WARP_STYLE_LABELS[value] })),
7575
+ ..._chunkDWGZUSEScjs.WARP_STYLES.map((value) => ({ value, label: _chunkDWGZUSEScjs.WARP_STYLE_LABELS[value] })),
7640
7576
  { value: "mesh", label: "Mesh" }
7641
7577
  ];
7642
7578
  function getVectorEnvelopePanel(state) {
7643
- const nodes = state.selection.map((id) => _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7579
+ const nodes = state.selection.map((id) => _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7644
7580
  if (!nodes.length) return null;
7645
7581
  const one = nodes.length === 1 ? nodes[0] : null;
7646
7582
  const first = _optionalChain([one, 'optionalAccess', _293 => _293.effects, 'optionalAccess', _294 => _294.find, 'call', _295 => _295((e) => e.type === "envelope")]);
7647
7583
  const order = /* @__PURE__ */ new Map();
7648
- _chunk7MD7C6XQcjs.walkVectorNodes.call(void 0, state.document.nodes, (n) => order.set(n.id, order.size));
7584
+ _chunkJF5PXN7Wcjs.walkVectorNodes.call(void 0, state.document.nodes, (n) => order.set(n.id, order.size));
7649
7585
  const top = nodes.length > 1 ? nodes.slice().sort((a, b) => (_nullishCoalesce(order.get(a.id), () => ( 0))) - (_nullishCoalesce(order.get(b.id), () => ( 0))))[nodes.length - 1] : null;
7650
7586
  return {
7651
7587
  nodeId: _nullishCoalesce(_optionalChain([one, 'optionalAccess', _296 => _296.id]), () => ( null)),
@@ -7662,7 +7598,7 @@ function gradientOverlay(state) {
7662
7598
  const hover = state.interaction ? null : _optionalChain([state, 'access', _302 => _302.hover, 'optionalAccess', _303 => _303.gradient]);
7663
7599
  const handleHovered = (h) => _optionalChain([hover, 'optionalAccess', _304 => _304.kind]) === "handle" && hover.handle === h;
7664
7600
  const pt = (p) => ({ x: fmt2(p.x), y: fmt2(p.y) });
7665
- const centred = _chunk7MD7C6XQcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
7601
+ const centred = _chunkJF5PXN7Wcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
7666
7602
  const removing = _optionalChain([state, 'access', _305 => _305.interaction, 'optionalAccess', _306 => _306.type]) === "gradient" && !!state.interaction.removing;
7667
7603
  return {
7668
7604
  nodeId: a.nodeId,
@@ -7689,8 +7625,8 @@ function gradientOverlay(state) {
7689
7625
  function selectedBlends(state) {
7690
7626
  const out = /* @__PURE__ */ new Map();
7691
7627
  for (const id of state.selection) {
7692
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
7693
- const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _309 => _309.parent]);
7628
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
7629
+ const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _309 => _309.parent]);
7694
7630
  if (isVectorBlendGroup(group)) out.set(group.id, group);
7695
7631
  }
7696
7632
  return [...out.values()];
@@ -7706,8 +7642,8 @@ function blendOverlay(state) {
7706
7642
  const spines = selectedBlends(state).flatMap((g) => {
7707
7643
  const s = vectorBlendSpine(g);
7708
7644
  if (!s) return [];
7709
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _nullishCoalesce(_chunk7MD7C6XQcjs.vectorWorldMatrix.call(void 0, doc.nodes, g.id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX)), view);
7710
- const d = _chunkXGD3FSNCcjs.bezierPathToSvg.call(void 0, _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunk7MD7C6XQcjs.subpathsToBezier.call(void 0, [s.spine], { corners: false }), m), { precision: 2 });
7645
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorWorldMatrix.call(void 0, doc.nodes, g.id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX)), view);
7646
+ const d = _chunkXGD3FSNCcjs.bezierPathToSvg.call(void 0, _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunkJF5PXN7Wcjs.subpathsToBezier.call(void 0, [s.spine], { corners: false }), m), { precision: 2 });
7711
7647
  const keys = s.stops.map((stop) => {
7712
7648
  const p = vectorBlendRailAt(s.rail, stop).point;
7713
7649
  return sc({ x: p[0], y: p[1] }, m);
@@ -7717,12 +7653,12 @@ function blendOverlay(state) {
7717
7653
  let start = null;
7718
7654
  const anchors = [];
7719
7655
  if (state.tool === "blend") {
7720
- const from = state.blendStart ? _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, state.blendStart.nodeId) : void 0;
7656
+ const from = state.blendStart ? _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, state.blendStart.nodeId) : void 0;
7721
7657
  if (from && state.blendStart) {
7722
7658
  const a = state.blendStart.anchor === null ? void 0 : getAnchorWorld(doc, { nodeId: from.id, subpath: 0, index: state.blendStart.anchor });
7723
7659
  start = { d: screenOutline(state, from, /* @__PURE__ */ new Set()), anchor: a ? sc(a, view) : null };
7724
7660
  }
7725
- const hovered = _optionalChain([state, 'access', _310 => _310.hover, 'optionalAccess', _311 => _311.nodeId]) ? _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, state.hover.nodeId) : void 0;
7661
+ const hovered = _optionalChain([state, 'access', _310 => _310.hover, 'optionalAccess', _311 => _311.nodeId]) ? _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, state.hover.nodeId) : void 0;
7726
7662
  if (_optionalChain([hovered, 'optionalAccess', _312 => _312.type]) === "path" && hovered.subpaths[0]) {
7727
7663
  hovered.subpaths[0].anchors.forEach((_, index) => {
7728
7664
  const a = getAnchorWorld(doc, { nodeId: hovered.id, subpath: 0, index });
@@ -7736,11 +7672,11 @@ function getVectorBlendControls(state) {
7736
7672
  const blends = selectedBlends(state);
7737
7673
  const doc = state.document;
7738
7674
  const roots = state.selection.filter((id) => {
7739
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, id);
7740
- return !!node && !node.blendStep && !node.locked && !state.selection.includes(_nullishCoalesce(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _316 => _316.parent, 'optionalAccess', _317 => _317.id]), () => ( "")));
7675
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, id);
7676
+ return !!node && !node.blendStep && !node.locked && !state.selection.includes(_nullishCoalesce(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _316 => _316.parent, 'optionalAccess', _317 => _317.id]), () => ( "")));
7741
7677
  });
7742
- const parents = new Set(roots.map((id) => _nullishCoalesce(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _318 => _318.parent, 'optionalAccess', _319 => _319.id]), () => ( null))));
7743
- const paths = roots.filter((id) => _optionalChain([_chunk7MD7C6XQcjs.findVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _320 => _320.type]) === "path" && !isVectorBlendGroup(_optionalChain([_chunk7MD7C6XQcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _321 => _321.parent])));
7678
+ const parents = new Set(roots.map((id) => _nullishCoalesce(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _318 => _318.parent, 'optionalAccess', _319 => _319.id]), () => ( null))));
7679
+ const paths = roots.filter((id) => _optionalChain([_chunkJF5PXN7Wcjs.findVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _320 => _320.type]) === "path" && !isVectorBlendGroup(_optionalChain([_chunkJF5PXN7Wcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _321 => _321.parent])));
7744
7680
  const first = blends[0];
7745
7681
  return {
7746
7682
  ids: blends.map((g) => g.id),
@@ -7805,14 +7741,14 @@ function isVectorTextTarget(target) {
7805
7741
  function getVectorSelectionStyle(state) {
7806
7742
  const paths = [];
7807
7743
  for (const id of state.selection) {
7808
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
7744
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
7809
7745
  if (node) paths.push(...collect(node));
7810
7746
  }
7811
7747
  const anchorMode = state.tool === "direct" && !!_optionalChain([state, 'access', _326 => _326.selectedAnchors, 'optionalAccess', _327 => _327.length]);
7812
7748
  if (anchorMode) {
7813
7749
  for (const r of state.selectedAnchors) {
7814
7750
  if (paths.some((p) => p.id === r.nodeId)) continue;
7815
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, r.nodeId);
7751
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, r.nodeId);
7816
7752
  if (_optionalChain([node, 'optionalAccess', _328 => _328.type]) === "path") paths.push(node);
7817
7753
  }
7818
7754
  }
@@ -7821,7 +7757,7 @@ function getVectorSelectionStyle(state) {
7821
7757
  const same = (get) => paths.every((p) => JSON.stringify(_nullishCoalesce(get(p), () => ( null))) === JSON.stringify(_nullishCoalesce(get(first), () => ( null))));
7822
7758
  const corners2 = [];
7823
7759
  for (const p of paths) {
7824
- for (const c of _chunk7MD7C6XQcjs.vectorCorners.call(void 0, p.subpaths)) {
7760
+ for (const c of _chunkJF5PXN7Wcjs.vectorCorners.call(void 0, p.subpaths)) {
7825
7761
  if (anchorMode && !state.selectedAnchors.some((r) => r.nodeId === p.id && r.subpath === c.subpath && r.index === c.index)) continue;
7826
7762
  const corner = p.subpaths[c.subpath].anchors[c.index].corner;
7827
7763
  corners2.push({ radius: _nullishCoalesce(_optionalChain([corner, 'optionalAccess', _329 => _329.radius]), () => ( 0)), kind: _nullishCoalesce(_optionalChain([corner, 'optionalAccess', _330 => _330.kind]), () => ( "round")) });
@@ -7840,7 +7776,7 @@ function getVectorSelectionStyle(state) {
7840
7776
  startArrowScale: _nullishCoalesce(first.startArrowScale, () => ( 1)),
7841
7777
  endArrowScale: _nullishCoalesce(first.endArrowScale, () => ( 1)),
7842
7778
  strokeWidthProfile: profileOf(first),
7843
- widthProfile: _chunk7MD7C6XQcjs.widthProfilePresetId.call(void 0, profileOf(first)),
7779
+ widthProfile: _chunkJF5PXN7Wcjs.widthProfilePresetId.call(void 0, profileOf(first)),
7844
7780
  cornerRadius: c0.radius,
7845
7781
  cornerKind: c0.kind,
7846
7782
  corners: corners2.length,
@@ -7864,8 +7800,8 @@ function getVectorSelectionStyle(state) {
7864
7800
  };
7865
7801
  }
7866
7802
  function profileOf(p) {
7867
- const points = _chunk7MD7C6XQcjs.sanitizeWidthProfile.call(void 0, p.strokeWidthProfile);
7868
- return points.length && _chunk7MD7C6XQcjs.widthProfilePresetId.call(void 0, points) !== "uniform" ? points : null;
7803
+ const points = _chunkJF5PXN7Wcjs.sanitizeWidthProfile.call(void 0, p.strokeWidthProfile);
7804
+ return points.length && _chunkJF5PXN7Wcjs.widthProfilePresetId.call(void 0, points) !== "uniform" ? points : null;
7869
7805
  }
7870
7806
  var VECTOR_STROKE_ALIGN_LABELS = { center: "Center", inside: "Inside", outside: "Outside" };
7871
7807
  var VECTOR_CORNER_KIND_LABELS = { round: "Round", inverted: "Inverted", chamfer: "Chamfer" };
@@ -7891,19 +7827,19 @@ var VECTOR_STROKE_GRADIENT_MODE_LABELS = { within: "Within stroke", along: "Alon
7891
7827
  function getVectorGradientEditor(state) {
7892
7828
  const paths = [];
7893
7829
  for (const id of state.selection) {
7894
- const node = _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id);
7830
+ const node = _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id);
7895
7831
  if (node) paths.push(...collect(node));
7896
7832
  }
7897
7833
  if (!paths.length) return null;
7898
7834
  const target = state.gradientEdit.target;
7899
7835
  const paint = paths[0][target];
7900
- const gradient = _chunk7MD7C6XQcjs.isVectorGradient.call(void 0, paint) ? paint : null;
7901
- const sorted = gradient ? _chunk7MD7C6XQcjs.sortedVectorGradientStops.call(void 0, gradient) : [];
7836
+ const gradient = _chunkJF5PXN7Wcjs.isVectorGradient.call(void 0, paint) ? paint : null;
7837
+ const sorted = gradient ? _chunkJF5PXN7Wcjs.sortedVectorGradientStops.call(void 0, gradient) : [];
7902
7838
  const stopIndex = state.gradientEdit.stop;
7903
7839
  const stops = sorted.map((s, index) => ({ ...s, index, selected: index === stopIndex }));
7904
7840
  const sel = stopIndex !== null && sorted[stopIndex] ? { ...sorted[stopIndex], index: stopIndex, last: stopIndex === sorted.length - 1 } : null;
7905
- const preview = gradient ? `linear-gradient(to right, ${_chunk7MD7C6XQcjs.expandVectorGradientStops.call(void 0, gradient).map((s) => {
7906
- const c = _chunk7MD7C6XQcjs.parseVectorColor.call(void 0, s.color);
7841
+ const preview = gradient ? `linear-gradient(to right, ${_chunkJF5PXN7Wcjs.expandVectorGradientStops.call(void 0, gradient).map((s) => {
7842
+ const c = _chunkJF5PXN7Wcjs.parseVectorColor.call(void 0, s.color);
7907
7843
  const a = (_nullishCoalesce(_optionalChain([c, 'optionalAccess', _331 => _331[3]]), () => ( 1))) * (_nullishCoalesce(s.opacity, () => ( 1)));
7908
7844
  const color = c ? `rgba(${Math.round(c[0] * 255)}, ${Math.round(c[1] * 255)}, ${Math.round(c[2] * 255)}, ${Math.round(a * 1e3) / 1e3})` : s.color;
7909
7845
  return `${color} ${Math.round(s.offset * 1e4) / 100}%`;
@@ -7944,9 +7880,9 @@ var VECTOR_EDIT_TOGGLES = [
7944
7880
  { key: "curvatureMoves", label: "Curv", title: "Curvature point moves (Alt flips while dragging)" },
7945
7881
  { key: "recognizeShapes", label: "Shapes", title: "Turn pencil scribbles into shapes" }
7946
7882
  ];
7947
- var VECTOR_EFFECT_MENU = _chunk7MD7C6XQcjs.VECTOR_EFFECT_TYPES.map((type) => ({ type, label: _chunk7MD7C6XQcjs.VECTOR_EFFECT_LABELS[type] }));
7883
+ var VECTOR_EFFECT_MENU = _chunkJF5PXN7Wcjs.VECTOR_EFFECT_TYPES.map((type) => ({ type, label: _chunkJF5PXN7Wcjs.VECTOR_EFFECT_LABELS[type] }));
7948
7884
  function getVectorEffectsPanel(state) {
7949
- const nodes = state.selection.map((id) => _chunk7MD7C6XQcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7885
+ const nodes = state.selection.map((id) => _chunkJF5PXN7Wcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7950
7886
  if (!nodes.length) return null;
7951
7887
  const one = nodes.length === 1 ? nodes[0] : null;
7952
7888
  return {
@@ -7955,13 +7891,13 @@ function getVectorEffectsPanel(state) {
7955
7891
  effects: (_nullishCoalesce(_optionalChain([one, 'optionalAccess', _338 => _338.effects]), () => ( []))).map((e) => ({
7956
7892
  id: e.id,
7957
7893
  type: e.type,
7958
- label: _nullishCoalesce(_chunk7MD7C6XQcjs.VECTOR_EFFECT_LABELS[e.type], () => ( e.type)),
7894
+ label: _nullishCoalesce(_chunkJF5PXN7Wcjs.VECTOR_EFFECT_LABELS[e.type], () => ( e.type)),
7959
7895
  enabled: e.enabled !== false,
7960
7896
  params: e.params,
7961
7897
  // The Envelope panel (`getVectorEnvelopePanel`) edits an envelope's warp and mesh.
7962
- specs: e.type === "envelope" ? [] : _nullishCoalesce(_chunk7MD7C6XQcjs.VECTOR_EFFECT_PARAM_SPECS[e.type], () => ( []))
7898
+ specs: e.type === "envelope" ? [] : _nullishCoalesce(_chunkJF5PXN7Wcjs.VECTOR_EFFECT_PARAM_SPECS[e.type], () => ( []))
7963
7899
  })),
7964
- expandable: nodes.some(_chunk7MD7C6XQcjs.hasVectorAppearance)
7900
+ expandable: nodes.some(_chunkJF5PXN7Wcjs.hasVectorAppearance)
7965
7901
  };
7966
7902
  }
7967
7903
 
@@ -8007,13 +7943,13 @@ var BLEND_PROPS = {
8007
7943
  linear: { type: "boolean", description: "Move anchors in straight lines instead of the rotation-aware morph." }
8008
7944
  };
8009
7945
  var checkBlendOptions = (params) => {
8010
- if (_optionalChain([params, 'optionalAccess', _339 => _339.spacing]) !== void 0 && !_chunk7MD7C6XQcjs.VECTOR_BLEND_SPACINGS.includes(params.spacing)) fail(`Unknown blend spacing "${params.spacing}".`);
7946
+ if (_optionalChain([params, 'optionalAccess', _339 => _339.spacing]) !== void 0 && !_chunkJF5PXN7Wcjs.VECTOR_BLEND_SPACINGS.includes(params.spacing)) fail(`Unknown blend spacing "${params.spacing}".`);
8011
7947
  if (_optionalChain([params, 'optionalAccess', _340 => _340.steps]) !== void 0 && !(Number.isFinite(params.steps) && params.steps >= 1)) fail("steps must be at least 1.");
8012
7948
  if (_optionalChain([params, 'optionalAccess', _341 => _341.distance]) !== void 0 && !(Number.isFinite(params.distance) && params.distance > 0)) fail("distance must be positive.");
8013
7949
  };
8014
7950
  var POINT = { type: "object", properties: { x: { type: "number" }, y: { type: "number" } }, required: ["x", "y"] };
8015
7951
  var GRADIENT_PROPS = {
8016
- type: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_GRADIENT_TYPES, description: "linear, radial, conic (an angle sweep), reflected (linear mirrored about the start) or diamond." },
7952
+ type: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_TYPES, description: "linear, radial, conic (an angle sweep), reflected (linear mirrored about the start) or diamond." },
8017
7953
  stops: {
8018
7954
  type: "array",
8019
7955
  minItems: 1,
@@ -8038,10 +7974,10 @@ var GRADIENT_PROPS = {
8038
7974
  focal: { ...POINT, description: "Radial focal point (where t = 0), in `units`." },
8039
7975
  focalRadius: { type: "number", minimum: 0, maximum: 0.99, description: "Radial focal circle radius as a fraction of the radius (SVG fr)." },
8040
7976
  units: { type: "string", enum: ["objectBoundingBox", "userSpaceOnUse"], description: "Space of start / end / width / focal: fractions of the shape box (default) or the node's own coordinates." },
8041
- spread: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_GRADIENT_SPREADS, description: "What paints past the ends: pad (default), reflect or repeat." },
8042
- interpolation: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_GRADIENT_INTERPOLATIONS, description: "Colour mixing space: srgb (default), linear (light) or oklab." },
7977
+ spread: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_SPREADS, description: "What paints past the ends: pad (default), reflect or repeat." },
7978
+ interpolation: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_INTERPOLATIONS, description: "Colour mixing space: srgb (default), linear (light) or oklab." },
8043
7979
  smoothness: { type: "number", minimum: 0, maximum: 1, description: "Bends the ramp along a smooth spline through the stops (0 = straight)." },
8044
- strokeMode: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_STROKE_GRADIENT_MODES, description: "On strokes: within (default, like a fill), along the path or across it." }
7980
+ strokeMode: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_STROKE_GRADIENT_MODES, description: "On strokes: within (default, like a fill), along the path or across it." }
8045
7981
  };
8046
7982
  var PAINT = {
8047
7983
  description: 'A CSS colour, `null` for none, or a gradient object: `{ type: "linear" | "radial" | "conic" | "reflected" | "diamond", stops: [{ offset, color, opacity?, midpoint? }] }` plus the shorthand `angle` / `cx, cy, r` or explicit `start`, `end`, `width`, `focal`, `focalRadius`, `units`, and `spread`, `interpolation`, `smoothness`, `strokeMode` (see vector.setGradient).',
@@ -8056,8 +7992,8 @@ var STYLE_PROPS = {
8056
7992
  strokeDasharray: { type: "array", items: { type: "number" } },
8057
7993
  fillRule: { type: "string", enum: ["nonzero", "evenodd"] },
8058
7994
  strokeAlign: { type: "string", enum: ["center", "inside", "outside"], description: "Where the stroke sits on the outline (closed shapes only; open paths stroke centred)." },
8059
- startArrow: { type: ["string", "null"], enum: [..._chunk7MD7C6XQcjs.VECTOR_ARROWHEADS, null], description: "Head at the start of an open path, or null for none." },
8060
- endArrow: { type: ["string", "null"], enum: [..._chunk7MD7C6XQcjs.VECTOR_ARROWHEADS, null], description: "Head at the end of an open path, or null for none." },
7995
+ startArrow: { type: ["string", "null"], enum: [..._chunkJF5PXN7Wcjs.VECTOR_ARROWHEADS, null], description: "Head at the start of an open path, or null for none." },
7996
+ endArrow: { type: ["string", "null"], enum: [..._chunkJF5PXN7Wcjs.VECTOR_ARROWHEADS, null], description: "Head at the end of an open path, or null for none." },
8061
7997
  arrowAlign: { type: "string", enum: ["extend", "tip"], description: "`extend`: the tip sits past the end point; `tip`: on it, the stroke shortened under the head." },
8062
7998
  startArrowScale: { type: "number", exclusiveMinimum: 0, description: "Start head size as a multiple of the stroke width (default 1)." },
8063
7999
  endArrowScale: { type: "number", exclusiveMinimum: 0, description: "End head size as a multiple of the stroke width (default 1)." },
@@ -8068,7 +8004,7 @@ var pickStyle = (params) => {
8068
8004
  for (const key of Object.keys(STYLE_PROPS)) if (params[key] !== void 0) out[key] = params[key];
8069
8005
  for (const key of ["fill", "stroke"]) {
8070
8006
  const paint = out[key];
8071
- if (paint && typeof paint === "object") out[key] = _nullishCoalesce(_chunk7MD7C6XQcjs.sanitizeVectorGradient.call(void 0, paint), () => ( fail(`${key} is not a valid gradient: give a type and at least one stop { offset, color }.`)));
8007
+ if (paint && typeof paint === "object") out[key] = _nullishCoalesce(_chunkJF5PXN7Wcjs.sanitizeVectorGradient.call(void 0, paint), () => ( fail(`${key} is not a valid gradient: give a type and at least one stop { offset, color }.`)));
8072
8008
  }
8073
8009
  return out;
8074
8010
  };
@@ -8100,19 +8036,19 @@ function createVectorCommands(controller, options = {}) {
8100
8036
  const out = [];
8101
8037
  const visit = (nodes, depth) => {
8102
8038
  for (const n of nodes) {
8103
- const parent = _nullishCoalesce(_chunk7MD7C6XQcjs.vectorParentMatrix.call(void 0, state.document.nodes, n.id), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX));
8104
- const b = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, n, parent);
8039
+ const parent = _nullishCoalesce(_chunkJF5PXN7Wcjs.vectorParentMatrix.call(void 0, state.document.nodes, n.id), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX));
8040
+ const b = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, n, parent);
8105
8041
  out.push({
8106
8042
  id: n.id,
8107
8043
  type: n.type,
8108
8044
  ...n.name ? { name: n.name } : {},
8109
8045
  depth,
8110
- rotation: Math.round(_chunk7MD7C6XQcjs.vectorNodeRotation.call(void 0, n, parent) * 100) / 100,
8046
+ rotation: Math.round(_chunkJF5PXN7Wcjs.vectorNodeRotation.call(void 0, n, parent) * 100) / 100,
8111
8047
  bounds: b && { x: Math.round(b.x * 100) / 100, y: Math.round(b.y * 100) / 100, width: Math.round(b.width * 100) / 100, height: Math.round(b.height * 100) / 100 },
8112
8048
  visible: n.visible !== false,
8113
8049
  locked: !!n.locked,
8114
8050
  selected: state.selection.includes(n.id),
8115
- ...n.type === "path" ? { fill: _nullishCoalesce(n.fill, () => ( null)), stroke: _nullishCoalesce(n.stroke, () => ( null)), strokeWidth: _nullishCoalesce(n.strokeWidth, () => ( 1)), d: _chunk7MD7C6XQcjs.vectorPathData.call(void 0, n, 2) } : { children: n.children.length },
8051
+ ...n.type === "path" ? { fill: _nullishCoalesce(n.fill, () => ( null)), stroke: _nullishCoalesce(n.stroke, () => ( null)), strokeWidth: _nullishCoalesce(n.strokeWidth, () => ( 1)), d: _chunkJF5PXN7Wcjs.vectorPathData.call(void 0, n, 2) } : { children: n.children.length },
8116
8052
  ...n.type === "group" && n.blend ? { blend: { ...resolveVectorBlendOptions(n.blend), spine: !!n.blend.spine, keys: vectorBlendKeys(n).map((k) => k.id) } } : {},
8117
8053
  ...n.blendStep ? { blendStep: true } : {},
8118
8054
  ..._optionalChain([n, 'access', _350 => _350.effects, 'optionalAccess', _351 => _351.length]) ? { effects: n.effects } : {},
@@ -8164,7 +8100,7 @@ function createVectorCommands(controller, options = {}) {
8164
8100
  width: { type: "number", description: "For a line: the x offset of its end." },
8165
8101
  height: { type: "number", description: "For a line: the y offset of its end." },
8166
8102
  cornerRadius: { type: "number", minimum: 0, description: "Live corner radius of a rect, polygon or star." },
8167
- cornerKind: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_CORNER_KINDS },
8103
+ cornerKind: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_CORNER_KINDS },
8168
8104
  sides: { type: "integer", minimum: 3 },
8169
8105
  points: { type: "integer", minimum: 3 },
8170
8106
  innerRatio: { type: "number", minimum: 0, maximum: 1 },
@@ -8221,7 +8157,7 @@ function createVectorCommands(controller, options = {}) {
8221
8157
  undoable: true,
8222
8158
  run: (_ctx, params) => {
8223
8159
  const { ids: _i, target, ...patch } = _nullishCoalesce(params, () => ( {}));
8224
- if (patch.type !== void 0 && !_chunk7MD7C6XQcjs.VECTOR_GRADIENT_TYPES.includes(patch.type)) fail(`Unknown gradient type "${patch.type}".`);
8160
+ if (patch.type !== void 0 && !_chunkJF5PXN7Wcjs.VECTOR_GRADIENT_TYPES.includes(patch.type)) fail(`Unknown gradient type "${patch.type}".`);
8225
8161
  if (patch.stops !== void 0 && !(Array.isArray(patch.stops) && patch.stops.length)) fail("stops needs at least one { offset, color }.");
8226
8162
  check(controller.setGradient(patch, { ids: ids(params), target: _nullishCoalesce(target, () => ( "fill")) }));
8227
8163
  const id = ids(params)[0];
@@ -8236,7 +8172,7 @@ function createVectorCommands(controller, options = {}) {
8236
8172
  label: "Corner Radius\u2026",
8237
8173
  keywords: ["round", "rounded", "corners", "radius", "fillet", "chamfer", "live corners"],
8238
8174
  description: "Sets the live corner radius (and optionally `kind`: round, inverted or chamfer) of `anchors`, else the selected points (direct tool), else every corner of `ids` / the selection. Radius 0 makes corners sharp; radii shrink to fit short sides. The anchors stay editable.",
8239
- params: { type: "object", properties: { radius: { type: "number", minimum: 0 }, kind: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_CORNER_KINDS }, ids: IDS, anchors: ANCHORS } },
8175
+ params: { type: "object", properties: { radius: { type: "number", minimum: 0 }, kind: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_CORNER_KINDS }, ids: IDS, anchors: ANCHORS } },
8240
8176
  undoable: true,
8241
8177
  run: (_ctx, params) => {
8242
8178
  const refs = _optionalChain([params, 'optionalAccess', _354 => _354.anchors]) ? anchorsOf(params.anchors) : void 0;
@@ -8257,7 +8193,7 @@ function createVectorCommands(controller, options = {}) {
8257
8193
  type: "object",
8258
8194
  properties: {
8259
8195
  ids: IDS,
8260
- preset: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_WIDTH_PRESET_IDS },
8196
+ preset: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PRESET_IDS },
8261
8197
  points: WIDTH_POINTS,
8262
8198
  taper: {
8263
8199
  type: "object",
@@ -8380,7 +8316,7 @@ function createVectorCommands(controller, options = {}) {
8380
8316
  type: "object",
8381
8317
  properties: {
8382
8318
  ids: IDS,
8383
- preset: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_WARP_STYLES },
8319
+ preset: { type: "string", enum: _chunkDWGZUSEScjs.WARP_STYLES },
8384
8320
  bend: { type: "number", minimum: -100, maximum: 100 },
8385
8321
  horizontal: { type: "number", minimum: -100, maximum: 100 },
8386
8322
  vertical: { type: "number", minimum: -100, maximum: 100 },
@@ -8409,7 +8345,7 @@ function createVectorCommands(controller, options = {}) {
8409
8345
  check(r);
8410
8346
  return { nodeId: r.nodeId };
8411
8347
  }
8412
- if (params.preset !== void 0 && !_chunk7MD7C6XQcjs.VECTOR_WARP_STYLES.includes(params.preset)) fail(`Unknown warp preset "${params.preset}".`);
8348
+ if (params.preset !== void 0 && !_chunkDWGZUSEScjs.WARP_STYLES.includes(params.preset)) fail(`Unknown warp preset "${params.preset}".`);
8413
8349
  const patch = {};
8414
8350
  if (params.preset) patch.style = params.preset;
8415
8351
  for (const k of ["bend", "horizontal", "vertical"]) if (params[k] !== void 0) patch[k] = params[k];
@@ -8424,7 +8360,7 @@ function createVectorCommands(controller, options = {}) {
8424
8360
  if (params.mesh.points) {
8425
8361
  const even = (n) => Array.from({ length: n + 1 }, (_, i) => i / n);
8426
8362
  const mesh = { us: even(columns), vs: even(rows), points: params.mesh.points.map((p) => ({ x: p.x, y: p.y })) };
8427
- if (!_chunk7MD7C6XQcjs.isValidVectorMesh.call(void 0, mesh)) fail(`A ${columns} \xD7 ${rows} mesh needs ${(3 * columns + 1) * (3 * rows + 1)} finite points.`);
8363
+ if (!_chunkDWGZUSEScjs.isValidWarpMesh.call(void 0, mesh)) fail(`A ${columns} \xD7 ${rows} mesh needs ${(3 * columns + 1) * (3 * rows + 1)} finite points.`);
8428
8364
  patch.mesh = mesh;
8429
8365
  }
8430
8366
  }
@@ -8507,7 +8443,7 @@ function createVectorCommands(controller, options = {}) {
8507
8443
  params: {
8508
8444
  type: "object",
8509
8445
  properties: {
8510
- type: { type: "string", enum: _chunk7MD7C6XQcjs.VECTOR_EFFECT_TYPES },
8446
+ type: { type: "string", enum: _chunkJF5PXN7Wcjs.VECTOR_EFFECT_TYPES },
8511
8447
  params: { type: "object", description: EFFECT_PARAMS_DESCRIPTION },
8512
8448
  index: { type: "integer", minimum: 0, description: "Position in the stack (default: last)." },
8513
8449
  ids: IDS
@@ -8517,7 +8453,7 @@ function createVectorCommands(controller, options = {}) {
8517
8453
  undoable: true,
8518
8454
  enabled: enabledFor,
8519
8455
  run: (_ctx, params) => {
8520
- if (!_chunk7MD7C6XQcjs.VECTOR_EFFECT_TYPES.includes(params.type)) fail(`Unknown effect type "${params.type}".`);
8456
+ if (!_chunkJF5PXN7Wcjs.VECTOR_EFFECT_TYPES.includes(params.type)) fail(`Unknown effect type "${params.type}".`);
8521
8457
  const targets = ids(params);
8522
8458
  const created = controller.addEffect(params.type, { ids: targets, params: params.params, index: params.index });
8523
8459
  if (!created.length) fail("Nothing to add the effect to.");
@@ -8662,10 +8598,10 @@ function createVectorCommands(controller, options = {}) {
8662
8598
  label: "Pathfinder\u2026",
8663
8599
  keywords: ["divide", "trim", "merge", "crop", "outline", "minus back", "split", "faces"],
8664
8600
  description: "Pathfinder over the given paths (bottom to top): divide (every face its own shape, painted like the top-most shape over it; open unfilled paths cut), trim (hidden parts removed), merge (trim, then touching parts of one fill joined), crop (the top shape crops the others), outline (outlines cut into open strokes where they meet) or minusBack (the top shape minus everything below). Results replace the paths, grouped when there are several.",
8665
- params: { type: "object", properties: { operation: { type: "string", enum: [..._chunk7MD7C6XQcjs.VECTOR_PATHFINDER_OPERATIONS] }, ids: IDS }, required: ["operation"] },
8601
+ params: { type: "object", properties: { operation: { type: "string", enum: [..._chunkJF5PXN7Wcjs.VECTOR_PATHFINDER_OPERATIONS] }, ids: IDS }, required: ["operation"] },
8666
8602
  undoable: true,
8667
8603
  run: (_ctx, params) => {
8668
- if (!_chunk7MD7C6XQcjs.VECTOR_PATHFINDER_OPERATIONS.includes(params.operation)) fail(`Unknown Pathfinder operation "${params.operation}".`);
8604
+ if (!_chunkJF5PXN7Wcjs.VECTOR_PATHFINDER_OPERATIONS.includes(params.operation)) fail(`Unknown Pathfinder operation "${params.operation}".`);
8669
8605
  const created = controller.pathfinder(params.operation, { ids: ids(params) });
8670
8606
  if (!created.length) fail("Nothing came out: select paths that overlap (two or more, except for divide and outline).");
8671
8607
  return { ids: created, selection: [...controller.getState().selection] };
@@ -8971,7 +8907,7 @@ function createVectorCommands(controller, options = {}) {
8971
8907
  label: "Choose Tool\u2026",
8972
8908
  keywords: ["pen", "pencil", "select", "rectangle", "ellipse"],
8973
8909
  description: "Switches the canvas tool.",
8974
- params: { type: "object", properties: { tool: { type: "string", enum: [..._chunk7MD7C6XQcjs.VECTOR_TOOLS] } }, required: ["tool"] },
8910
+ params: { type: "object", properties: { tool: { type: "string", enum: [..._chunkJF5PXN7Wcjs.VECTOR_TOOLS] } }, required: ["tool"] },
8975
8911
  run: (_ctx, params) => {
8976
8912
  controller.setTool(params.tool);
8977
8913
  return { tool: params.tool };
@@ -9393,5 +9329,5 @@ function createVectorCommands(controller, options = {}) {
9393
9329
 
9394
9330
 
9395
9331
 
9396
- exports.DEFAULT_VECTOR_BLEND_DISTANCE = DEFAULT_VECTOR_BLEND_DISTANCE; exports.DEFAULT_VECTOR_BLEND_STEPS = DEFAULT_VECTOR_BLEND_STEPS; exports.DEFAULT_VECTOR_PATH_EDIT = DEFAULT_VECTOR_PATH_EDIT; exports.DEFAULT_VECTOR_SNAP = DEFAULT_VECTOR_SNAP; exports.IDENTITY_MATRIX = _chunk7MD7C6XQcjs.IDENTITY_MATRIX; exports.KAPPA = _chunk7MD7C6XQcjs.KAPPA; exports.LazyMouse = LazyMouse; exports.VECTOR_ARROWHEADS = _chunk7MD7C6XQcjs.VECTOR_ARROWHEADS; exports.VECTOR_ARROWHEAD_LABELS = VECTOR_ARROWHEAD_LABELS; exports.VECTOR_BLEND_MAX_SMOOTH_STEPS = VECTOR_BLEND_MAX_SMOOTH_STEPS; exports.VECTOR_BLEND_MAX_STEPS = VECTOR_BLEND_MAX_STEPS; exports.VECTOR_BLEND_SPACINGS = _chunk7MD7C6XQcjs.VECTOR_BLEND_SPACINGS; exports.VECTOR_BLEND_SPACING_LABELS = VECTOR_BLEND_SPACING_LABELS; exports.VECTOR_BUILDER_HATCH_GAP = VECTOR_BUILDER_HATCH_GAP; exports.VECTOR_CLIPBOARD_TYPE = VECTOR_CLIPBOARD_TYPE; exports.VECTOR_CONSTRUCTION_ANGLES = VECTOR_CONSTRUCTION_ANGLES; exports.VECTOR_CORNER_KINDS = _chunk7MD7C6XQcjs.VECTOR_CORNER_KINDS; exports.VECTOR_CORNER_KIND_LABELS = VECTOR_CORNER_KIND_LABELS; exports.VECTOR_CORNER_WIDGET_INSET = VECTOR_CORNER_WIDGET_INSET; exports.VECTOR_DISTORT_TOLERANCE = VECTOR_DISTORT_TOLERANCE; exports.VECTOR_EDIT_TOGGLES = VECTOR_EDIT_TOGGLES; exports.VECTOR_EFFECT_DEFAULTS = _chunk7MD7C6XQcjs.VECTOR_EFFECT_DEFAULTS; exports.VECTOR_EFFECT_LABELS = _chunk7MD7C6XQcjs.VECTOR_EFFECT_LABELS; exports.VECTOR_EFFECT_MENU = VECTOR_EFFECT_MENU; exports.VECTOR_EFFECT_PARAM_SPECS = _chunk7MD7C6XQcjs.VECTOR_EFFECT_PARAM_SPECS; exports.VECTOR_EFFECT_TYPES = _chunk7MD7C6XQcjs.VECTOR_EFFECT_TYPES; exports.VECTOR_ENVELOPE_STYLE_OPTIONS = VECTOR_ENVELOPE_STYLE_OPTIONS; exports.VECTOR_FILL_GAP = VECTOR_FILL_GAP; exports.VECTOR_GRADIENT_INTERPOLATIONS = _chunk7MD7C6XQcjs.VECTOR_GRADIENT_INTERPOLATIONS; exports.VECTOR_GRADIENT_INTERPOLATION_LABELS = VECTOR_GRADIENT_INTERPOLATION_LABELS; exports.VECTOR_GRADIENT_MAX_PERIODS = _chunk7MD7C6XQcjs.VECTOR_GRADIENT_MAX_PERIODS; exports.VECTOR_GRADIENT_MIDPOINT_GAP = VECTOR_GRADIENT_MIDPOINT_GAP; exports.VECTOR_GRADIENT_MIN_STOPS = _chunk7MD7C6XQcjs.VECTOR_GRADIENT_MIN_STOPS; exports.VECTOR_GRADIENT_OFF_BAR = VECTOR_GRADIENT_OFF_BAR; exports.VECTOR_GRADIENT_SPREADS = _chunk7MD7C6XQcjs.VECTOR_GRADIENT_SPREADS; exports.VECTOR_GRADIENT_SPREAD_LABELS = VECTOR_GRADIENT_SPREAD_LABELS; exports.VECTOR_GRADIENT_STOP_GAP = VECTOR_GRADIENT_STOP_GAP; exports.VECTOR_GRADIENT_TYPES = _chunk7MD7C6XQcjs.VECTOR_GRADIENT_TYPES; exports.VECTOR_GRADIENT_TYPE_LABELS = VECTOR_GRADIENT_TYPE_LABELS; exports.VECTOR_INK_MAX_CORNERS = VECTOR_INK_MAX_CORNERS; exports.VECTOR_MERGE_MODES = _chunk7MD7C6XQcjs.VECTOR_MERGE_MODES; exports.VECTOR_OVERLAY_THEME = VECTOR_OVERLAY_THEME; exports.VECTOR_PATHFINDER_ACTIONS = VECTOR_PATHFINDER_ACTIONS; exports.VECTOR_PATHFINDER_LABELS = VECTOR_PATHFINDER_LABELS; exports.VECTOR_PATHFINDER_OPERATIONS = _chunk7MD7C6XQcjs.VECTOR_PATHFINDER_OPERATIONS; exports.VECTOR_PATH_ACTIONS = VECTOR_PATH_ACTIONS; exports.VECTOR_PENCIL_STRING_PX = VECTOR_PENCIL_STRING_PX; exports.VECTOR_PRESSURE_NOMINAL = _chunk7MD7C6XQcjs.VECTOR_PRESSURE_NOMINAL; exports.VECTOR_ROTATE_HANDLE_OFFSET = VECTOR_ROTATE_HANDLE_OFFSET; exports.VECTOR_STROKE_ALIGN_LABELS = VECTOR_STROKE_ALIGN_LABELS; exports.VECTOR_STROKE_GRADIENT_MODES = _chunk7MD7C6XQcjs.VECTOR_STROKE_GRADIENT_MODES; exports.VECTOR_STROKE_GRADIENT_MODE_LABELS = VECTOR_STROKE_GRADIENT_MODE_LABELS; exports.VECTOR_STYLE_KEYS = VECTOR_STYLE_KEYS; exports.VECTOR_TOOLS = _chunk7MD7C6XQcjs.VECTOR_TOOLS; exports.VECTOR_TOOL_GLYPHS = VECTOR_TOOL_GLYPHS; exports.VECTOR_TOOL_SHORTCUTS = VECTOR_TOOL_SHORTCUTS; exports.VECTOR_TRANSFORM_HANDLES = _chunk7MD7C6XQcjs.VECTOR_TRANSFORM_HANDLES; exports.VECTOR_WARP_STYLES = _chunk7MD7C6XQcjs.VECTOR_WARP_STYLES; exports.VECTOR_WARP_STYLE_LABELS = _chunk7MD7C6XQcjs.VECTOR_WARP_STYLE_LABELS; exports.VECTOR_WIDTH_PRESETS = _chunk7MD7C6XQcjs.VECTOR_WIDTH_PRESETS; exports.VECTOR_WIDTH_PRESET_IDS = _chunk7MD7C6XQcjs.VECTOR_WIDTH_PRESET_IDS; exports.VECTOR_WIDTH_PROFILE_MAX_POINTS = _chunk7MD7C6XQcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS; exports.VECTOR_WIDTH_PROFILE_MAX_SCALE = _chunk7MD7C6XQcjs.VECTOR_WIDTH_PROFILE_MAX_SCALE; exports.VECTOR_WIDTH_SAME_T = _chunk7MD7C6XQcjs.VECTOR_WIDTH_SAME_T; exports.VectorEditorController = VectorEditorController; exports.VectorSnapTargets = VectorSnapTargets; exports.activeVectorEffects = _chunk7MD7C6XQcjs.activeVectorEffects; exports.addBuilderHit = addBuilderHit; exports.applyMatrix = _chunk7MD7C6XQcjs.applyMatrix; exports.applyMatrixLinear = _chunk7MD7C6XQcjs.applyMatrixLinear; exports.applyVectorBlendOptions = applyVectorBlendOptions; exports.applyVectorCornersAttribute = _chunk7MD7C6XQcjs.applyVectorCornersAttribute; exports.applyVectorEffects = _chunk7MD7C6XQcjs.applyVectorEffects; exports.applyVectorGradientPatch = _chunk7MD7C6XQcjs.applyVectorGradientPatch; exports.applyVectorGradientSpread = _chunk7MD7C6XQcjs.applyVectorGradientSpread; exports.applyVectorHomography = applyVectorHomography; exports.arrowheadInset = _chunk7MD7C6XQcjs.arrowheadInset; exports.arrowheadPath = _chunk7MD7C6XQcjs.arrowheadPath; exports.arrowheadWeight = _chunk7MD7C6XQcjs.arrowheadWeight; exports.bendSegment = bendSegment; exports.bezierToSubpaths = _chunk7MD7C6XQcjs.bezierToSubpaths; exports.boundsFromPoints = _chunk7MD7C6XQcjs.boundsFromPoints; exports.boundsIntersect = _chunk7MD7C6XQcjs.boundsIntersect; exports.clearVectorLiveBooleanCache = _chunk7MD7C6XQcjs.clearVectorLiveBooleanCache; exports.cloneAnchor = _chunk7MD7C6XQcjs.cloneAnchor; exports.cloneSubpath = _chunk7MD7C6XQcjs.cloneSubpath; exports.cloneVectorDocument = _chunk7MD7C6XQcjs.cloneVectorDocument; exports.cloneVectorNode = _chunk7MD7C6XQcjs.cloneVectorNode; exports.collectPathNodes = _chunk7MD7C6XQcjs.collectPathNodes; exports.constrainToLeave = constrainToLeave; exports.convertAnchor = _chunk7MD7C6XQcjs.convertAnchor; exports.convertVectorGradient = _chunk7MD7C6XQcjs.convertVectorGradient; exports.cornerBisectorPoint = _chunk7MD7C6XQcjs.cornerBisectorPoint; exports.cornerRadiusChange = _chunk7MD7C6XQcjs.cornerRadiusChange; exports.cornerSetback = _chunk7MD7C6XQcjs.cornerSetback; exports.correspondMorphContours = _chunk7MD7C6XQcjs.correspondMorphContours; exports.createVectorCommands = createVectorCommands; exports.createVectorEffect = _chunk7MD7C6XQcjs.createVectorEffect; exports.createVectorMorph = _chunk7MD7C6XQcjs.createVectorMorph; exports.curvatureMoveAnchor = curvatureMoveAnchor; exports.cutSubpathAt = cutSubpathAt; exports.dashIntervals = _chunk7MD7C6XQcjs.dashIntervals; exports.decomposeRigid = _chunk7MD7C6XQcjs.decomposeRigid; exports.defaultVectorGradient = _chunk7MD7C6XQcjs.defaultVectorGradient; exports.distortVectorNode = distortVectorNode; exports.dragVectorMeshPoint = _chunk7MD7C6XQcjs.dragVectorMeshPoint; exports.effectPathLength = _chunk7MD7C6XQcjs.effectPathLength; exports.effectPathVertexCount = _chunk7MD7C6XQcjs.effectPathVertexCount; exports.effectiveStrokeAlign = _chunk7MD7C6XQcjs.effectiveStrokeAlign; exports.ellipseSubpath = _chunk7MD7C6XQcjs.ellipseSubpath; exports.eraseFromFill = eraseFromFill; exports.eraseFromOutline = eraseFromOutline; exports.eraserRegion = eraserRegion; exports.evalVectorMesh = _chunk7MD7C6XQcjs.evalVectorMesh; exports.evaluateVectorPathKeyframes = _chunk7MD7C6XQcjs.evaluateVectorPathKeyframes; exports.expandVectorAppearance = _chunk7MD7C6XQcjs.expandVectorAppearance; exports.expandVectorAppearances = _chunk7MD7C6XQcjs.expandVectorAppearances; exports.expandVectorBlend = expandVectorBlend; exports.expandVectorCorners = _chunk7MD7C6XQcjs.expandVectorCorners; exports.expandVectorCornersOf = _chunk7MD7C6XQcjs.expandVectorCornersOf; exports.expandVectorGradientSpread = _chunk7MD7C6XQcjs.expandVectorGradientSpread; exports.expandVectorGradientStops = _chunk7MD7C6XQcjs.expandVectorGradientStops; exports.explicitVectorGradient = _chunk7MD7C6XQcjs.explicitVectorGradient; exports.findVectorNode = _chunk7MD7C6XQcjs.findVectorNode; exports.fitCornerRadius = _chunk7MD7C6XQcjs.fitCornerRadius; exports.fitVectorMesh = _chunk7MD7C6XQcjs.fitVectorMesh; exports.foldVectorBooleanOperands = _chunk7MD7C6XQcjs.foldVectorBooleanOperands; exports.generateVectorBlendChildren = generateVectorBlendChildren; exports.generateWidthProfile = _chunk7MD7C6XQcjs.generateWidthProfile; exports.getAnchor = getAnchor; exports.getAnchorWorld = getAnchorWorld; exports.getEditablePathIds = getEditablePathIds; exports.getTransformHandlePositions = getTransformHandlePositions; exports.getVectorBlendControls = getVectorBlendControls; exports.getVectorCornerWidgets = getVectorCornerWidgets; exports.getVectorEffectsPanel = getVectorEffectsPanel; exports.getVectorEnteredGroups = getVectorEnteredGroups; exports.getVectorEnvelopePanel = getVectorEnvelopePanel; exports.getVectorEnvelopeTarget = getVectorEnvelopeTarget; exports.getVectorGradientAnnotator = getVectorGradientAnnotator; exports.getVectorGradientEditor = getVectorGradientEditor; exports.getVectorOverlayRenderData = getVectorOverlayRenderData; exports.getVectorSceneRenderData = getVectorSceneRenderData; exports.getVectorSelectionBoxGeometry = getVectorSelectionBoxGeometry; exports.getVectorSelectionFrame = getVectorSelectionFrame; exports.getVectorSelectionStyle = getVectorSelectionStyle; exports.getVectorWidthHandles = getVectorWidthHandles; exports.getVisibleAnchors = getVisibleAnchors; exports.getVisibleHandles = getVisibleHandles; exports.gradientMidpointRemap = _chunk7MD7C6XQcjs.gradientMidpointRemap; exports.hasExplicitGradientGeometry = _chunk7MD7C6XQcjs.hasExplicitGradientGeometry; exports.hasOwnVectorAppearance = _chunk7MD7C6XQcjs.hasOwnVectorAppearance; exports.hasPaint = _chunk7MD7C6XQcjs.hasPaint; exports.hasStrokeExtras = _chunk7MD7C6XQcjs.hasStrokeExtras; exports.hasVectorAppearance = _chunk7MD7C6XQcjs.hasVectorAppearance; exports.hasVectorCorners = _chunk7MD7C6XQcjs.hasVectorCorners; exports.hitTestVectorNode = _chunk7MD7C6XQcjs.hitTestVectorNode; exports.hitTestVectorNodes = _chunk7MD7C6XQcjs.hitTestVectorNodes; exports.hitTestVectorStroke = _chunk7MD7C6XQcjs.hitTestVectorStroke; exports.hitVectorGradientAnnotator = hitVectorGradientAnnotator; exports.inferAnchorType = _chunk7MD7C6XQcjs.inferAnchorType; exports.insertAnchor = _chunk7MD7C6XQcjs.insertAnchor; exports.insertVectorGradientStop = _chunk7MD7C6XQcjs.insertVectorGradientStop; exports.insertWidthPoint = _chunk7MD7C6XQcjs.insertWidthPoint; exports.interpolateMorphContours = _chunk7MD7C6XQcjs.interpolateMorphContours; exports.interpolateRigidMatrix = _chunk7MD7C6XQcjs.interpolateRigidMatrix; exports.interpolateVectorColor = _chunk7MD7C6XQcjs.interpolateVectorColor; exports.interpolateVectorPaint = _chunk7MD7C6XQcjs.interpolateVectorPaint; exports.interpolateVectorPaths = _chunk7MD7C6XQcjs.interpolateVectorPaths; exports.interpolateVectorStyle = _chunk7MD7C6XQcjs.interpolateVectorStyle; exports.interpolateWidthProfiles = _chunk7MD7C6XQcjs.interpolateWidthProfiles; exports.invertMatrix = _chunk7MD7C6XQcjs.invertMatrix; exports.isCentredVectorGradient = _chunk7MD7C6XQcjs.isCentredVectorGradient; exports.isClosedBezierShape = _chunk7MD7C6XQcjs.isClosedBezierShape; exports.isIdentityMatrix = _chunk7MD7C6XQcjs.isIdentityMatrix; exports.isUniformWidthProfile = _chunk7MD7C6XQcjs.isUniformWidthProfile; exports.isValidVectorMesh = _chunk7MD7C6XQcjs.isValidVectorMesh; exports.isVectorBlendGroup = isVectorBlendGroup; exports.isVectorGradient = _chunk7MD7C6XQcjs.isVectorGradient; exports.isVectorLiveBoolean = _chunk7MD7C6XQcjs.isVectorLiveBoolean; exports.isVectorTextTarget = isVectorTextTarget; exports.joinSubpaths = joinSubpaths; exports.knifePath = knifePath; exports.lineSubpath = _chunk7MD7C6XQcjs.lineSubpath; exports.locateVectorNode = _chunk7MD7C6XQcjs.locateVectorNode; exports.mapBezierPath = _chunk7MD7C6XQcjs.mapBezierPath; exports.mapVectorGradient = _chunk7MD7C6XQcjs.mapVectorGradient; exports.mapVectorMeshPoints = _chunk7MD7C6XQcjs.mapVectorMeshPoints; exports.mapVectorPaint = _chunk7MD7C6XQcjs.mapVectorPaint; exports.mapVectorPoints = _chunk7MD7C6XQcjs.mapVectorPoints; exports.mapVectorSubpaths = _chunk7MD7C6XQcjs.mapVectorSubpaths; exports.matrixRotation = _chunk7MD7C6XQcjs.matrixRotation; exports.mergePaths = _chunk7MD7C6XQcjs.mergePaths; exports.mirrorWidthProfile = _chunk7MD7C6XQcjs.mirrorWidthProfile; exports.morphContourToSubpath = _chunk7MD7C6XQcjs.morphContourToSubpath; exports.morphPathsCross = _chunk7MD7C6XQcjs.morphPathsCross; exports.moveAnchorHandle = _chunk7MD7C6XQcjs.moveAnchorHandle; exports.moveVectorGradientHandle = _chunk7MD7C6XQcjs.moveVectorGradientHandle; exports.moveVectorGradientStop = _chunk7MD7C6XQcjs.moveVectorGradientStop; exports.multiplyMatrices = _chunk7MD7C6XQcjs.multiplyMatrices; exports.nearestSegment = _chunk7MD7C6XQcjs.nearestSegment; exports.nearestStrokePosition = _chunk7MD7C6XQcjs.nearestStrokePosition; exports.nextVectorCornerKind = _chunk7MD7C6XQcjs.nextVectorCornerKind; exports.nodeMatrix = _chunk7MD7C6XQcjs.nodeMatrix; exports.normalizeVectorEffectParams = _chunk7MD7C6XQcjs.normalizeVectorEffectParams; exports.offsetPaths = _chunk7MD7C6XQcjs.offsetPaths; exports.orderVectorQuad = orderVectorQuad; exports.parseSvgTransform = _chunk7MD7C6XQcjs.parseSvgTransform; exports.parseVectorColor = _chunk7MD7C6XQcjs.parseVectorColor; exports.parseVectorSvg = _chunk7MD7C6XQcjs.parseVectorSvg; exports.pathsCenter = _chunk7MD7C6XQcjs.pathsCenter; exports.patternAttrs = _chunk7MD7C6XQcjs.patternAttrs; exports.periodicVectorGradientStops = _chunk7MD7C6XQcjs.periodicVectorGradientStops; exports.pinVectorGradient = _chunk7MD7C6XQcjs.pinVectorGradient; exports.planShapeBuilder = planShapeBuilder; exports.polygonSubpath = _chunk7MD7C6XQcjs.polygonSubpath; exports.polylineBounds = polylineBounds; exports.pressureWidthProfile = _chunk7MD7C6XQcjs.pressureWidthProfile; exports.puckerBloatPaths = _chunk7MD7C6XQcjs.puckerBloatPaths; exports.pullVectorMesh = _chunk7MD7C6XQcjs.pullVectorMesh; exports.recognizeInkShape = recognizeInkShape; exports.rectSubpath = _chunk7MD7C6XQcjs.rectSubpath; exports.refineMorphContour = _chunk7MD7C6XQcjs.refineMorphContour; exports.refreshVectorBlends = refreshVectorBlends; exports.releaseVectorBlend = releaseVectorBlend; exports.removeAnchorKeepingShape = removeAnchorKeepingShape; exports.removeAnchors = _chunk7MD7C6XQcjs.removeAnchors; exports.removeAnchorsKeepingShape = removeAnchorsKeepingShape; exports.removeRedundantPoints = removeRedundantPoints; exports.removeVectorGradientStop = _chunk7MD7C6XQcjs.removeVectorGradientStop; exports.removeVectorMeshSplitU = _chunk7MD7C6XQcjs.removeVectorMeshSplitU; exports.removeVectorMeshSplitV = _chunk7MD7C6XQcjs.removeVectorMeshSplitV; exports.removeWidthPoints = _chunk7MD7C6XQcjs.removeWidthPoints; exports.repeatPaths = _chunk7MD7C6XQcjs.repeatPaths; exports.resampleGradientStops = _chunk7MD7C6XQcjs.resampleGradientStops; exports.resizeVectorMesh = _chunk7MD7C6XQcjs.resizeVectorMesh; exports.resolveVectorBlendOptions = resolveVectorBlendOptions; exports.reverseMorphContour = _chunk7MD7C6XQcjs.reverseMorphContour; exports.reverseSubpath = _chunk7MD7C6XQcjs.reverseSubpath; exports.reverseVectorGradient = _chunk7MD7C6XQcjs.reverseVectorGradient; exports.reverseWidthProfile = _chunk7MD7C6XQcjs.reverseWidthProfile; exports.rotateMatrix = _chunk7MD7C6XQcjs.rotateMatrix; exports.roundCornerPaths = _chunk7MD7C6XQcjs.roundCornerPaths; exports.roundSubpaths = _chunk7MD7C6XQcjs.roundSubpaths; exports.samplePlainStops = _chunk7MD7C6XQcjs.samplePlainStops; exports.samplePolyline = samplePolyline; exports.sampleVectorGradient = _chunk7MD7C6XQcjs.sampleVectorGradient; exports.sampleVectorGradientAt = _chunk7MD7C6XQcjs.sampleVectorGradientAt; exports.sampleVectorPaintDefAt = _chunk7MD7C6XQcjs.sampleVectorPaintDefAt; exports.sanitizeVectorEffects = _chunk7MD7C6XQcjs.sanitizeVectorEffects; exports.sanitizeVectorGradient = _chunk7MD7C6XQcjs.sanitizeVectorGradient; exports.sanitizeWidthProfile = _chunk7MD7C6XQcjs.sanitizeWidthProfile; exports.scaleFor = scaleFor; exports.scaleMatrix = _chunk7MD7C6XQcjs.scaleMatrix; exports.setAnchorCorner = _chunk7MD7C6XQcjs.setAnchorCorner; exports.setSubpathCorners = _chunk7MD7C6XQcjs.setSubpathCorners; exports.setVectorGradientVector = _chunk7MD7C6XQcjs.setVectorGradientVector; exports.setWidthPoint = _chunk7MD7C6XQcjs.setWidthPoint; exports.simplifyPolyline = simplifyPolyline; exports.smoothSubpath = smoothSubpath; exports.solve8 = solve8; exports.sortedVectorGradientStops = _chunk7MD7C6XQcjs.sortedVectorGradientStops; exports.spanVectorGradientStops = _chunk7MD7C6XQcjs.spanVectorGradientStops; exports.splitIntoFaces = splitIntoFaces; exports.splitSubpathAt = splitSubpathAt; exports.splitVectorMeshU = _chunk7MD7C6XQcjs.splitVectorMeshU; exports.splitVectorMeshV = _chunk7MD7C6XQcjs.splitVectorMeshV; exports.starSubpath = _chunk7MD7C6XQcjs.starSubpath; exports.strokePositionPoint = _chunk7MD7C6XQcjs.strokePositionPoint; exports.strokeWidthProfileOf = _chunk7MD7C6XQcjs.strokeWidthProfileOf; exports.subpathEnclosesArea = subpathEnclosesArea; exports.subpathPointAt = subpathPointAt; exports.subpathSegment = _chunk7MD7C6XQcjs.subpathSegment; exports.subpathSegmentCount = _chunk7MD7C6XQcjs.subpathSegmentCount; exports.subpathToMorphContour = _chunk7MD7C6XQcjs.subpathToMorphContour; exports.subpathsToBezier = _chunk7MD7C6XQcjs.subpathsToBezier; exports.taperWaveFactor = _chunk7MD7C6XQcjs.taperWaveFactor; exports.toVectorKeyInput = toVectorKeyInput; exports.toVectorModifiers = toVectorModifiers; exports.toVectorPointerInput = toVectorPointerInput; exports.transformVectorEffects = _chunk7MD7C6XQcjs.transformVectorEffects; exports.transformVectorGradient = _chunk7MD7C6XQcjs.transformVectorGradient; exports.transformVectorNode = _chunk7MD7C6XQcjs.transformVectorNode; exports.transformVectorPaint = _chunk7MD7C6XQcjs.transformVectorPaint; exports.translateAnchor = _chunk7MD7C6XQcjs.translateAnchor; exports.translateMatrix = _chunk7MD7C6XQcjs.translateMatrix; exports.trimIntervals = _chunk7MD7C6XQcjs.trimIntervals; exports.trimPaths = _chunk7MD7C6XQcjs.trimPaths; exports.trimPathsIndividually = _chunk7MD7C6XQcjs.trimPathsIndividually; exports.turnMorphContour = _chunk7MD7C6XQcjs.turnMorphContour; exports.twistPaths = _chunk7MD7C6XQcjs.twistPaths; exports.unionBounds = _chunk7MD7C6XQcjs.unionBounds; exports.variableStrokeOutline = _chunk7MD7C6XQcjs.variableStrokeOutline; exports.variableStrokeRings = _chunk7MD7C6XQcjs.variableStrokeRings; exports.vectorAppearanceNodes = _chunk7MD7C6XQcjs.vectorAppearanceNodes; exports.vectorAppearanceOutline = _chunk7MD7C6XQcjs.vectorAppearanceOutline; exports.vectorAppearanceShapes = _chunk7MD7C6XQcjs.vectorAppearanceShapes; exports.vectorBlendColorDistance = vectorBlendColorDistance; exports.vectorBlendKeyTargets = vectorBlendKeyTargets; exports.vectorBlendKeys = vectorBlendKeys; exports.vectorBlendRail = vectorBlendRail; exports.vectorBlendRailAt = vectorBlendRailAt; exports.vectorBlendSpine = vectorBlendSpine; exports.vectorBlendStepCount = vectorBlendStepCount; exports.vectorBoxCorners = vectorBoxCorners; exports.vectorBoxMatrix = _chunk7MD7C6XQcjs.vectorBoxMatrix; exports.vectorBuilderErasedEdges = vectorBuilderErasedEdges; exports.vectorCornerAt = _chunk7MD7C6XQcjs.vectorCornerAt; exports.vectorCorners = _chunk7MD7C6XQcjs.vectorCorners; exports.vectorCornersAttribute = _chunk7MD7C6XQcjs.vectorCornersAttribute; exports.vectorDiamondPath = vectorDiamondPath; exports.vectorDistortQuad = vectorDistortQuad; exports.vectorDocumentToSvg = _chunk7MD7C6XQcjs.vectorDocumentToSvg; exports.vectorEffectInputBounds = _chunk7MD7C6XQcjs.vectorEffectInputBounds; exports.vectorEffectInputPaths = _chunk7MD7C6XQcjs.vectorEffectInputPaths; exports.vectorEnteredGroups = _chunk7MD7C6XQcjs.vectorEnteredGroups; exports.vectorEnvelopeFrame = _chunk7MD7C6XQcjs.vectorEnvelopeFrame; exports.vectorEnvelopeMap = _chunk7MD7C6XQcjs.vectorEnvelopeMap; exports.vectorEnvelopeMesh = _chunk7MD7C6XQcjs.vectorEnvelopeMesh; exports.vectorFillMap = vectorFillMap; exports.vectorGradientArea = _chunk7MD7C6XQcjs.vectorGradientArea; exports.vectorGradientAspect = _chunk7MD7C6XQcjs.vectorGradientAspect; exports.vectorGradientBarPosition = vectorGradientBarPosition; exports.vectorGradientFocalParam = _chunk7MD7C6XQcjs.vectorGradientFocalParam; exports.vectorGradientHandles = _chunk7MD7C6XQcjs.vectorGradientHandles; exports.vectorGradientMatrix = _chunk7MD7C6XQcjs.vectorGradientMatrix; exports.vectorGradientMidpointFromPosition = _chunk7MD7C6XQcjs.vectorGradientMidpointFromPosition; exports.vectorGradientMidpointPosition = _chunk7MD7C6XQcjs.vectorGradientMidpointPosition; exports.vectorGradientNeedsExpansion = _chunk7MD7C6XQcjs.vectorGradientNeedsExpansion; exports.vectorGradientParam = _chunk7MD7C6XQcjs.vectorGradientParam; exports.vectorGradientPoints = _chunk7MD7C6XQcjs.vectorGradientPoints; exports.vectorGradientRamp = _chunk7MD7C6XQcjs.vectorGradientRamp; exports.vectorGradientSvgDefs = _chunk7MD7C6XQcjs.vectorGradientSvgDefs; exports.vectorGradientTAt = _chunk7MD7C6XQcjs.vectorGradientTAt; exports.vectorGradientTargetPath = vectorGradientTargetPath; exports.vectorGradientUnitsMatrix = _chunk7MD7C6XQcjs.vectorGradientUnitsMatrix; exports.vectorHomography = vectorHomography; exports.vectorHomographyKeepsQuad = vectorHomographyKeepsQuad; exports.vectorIdentityMesh = _chunk7MD7C6XQcjs.vectorIdentityMesh; exports.vectorInkShapeName = vectorInkShapeName; exports.vectorLiveBooleanSteps = _chunk7MD7C6XQcjs.vectorLiveBooleanSteps; exports.vectorMeshColumns = _chunk7MD7C6XQcjs.vectorMeshColumns; exports.vectorMeshControlBounds = _chunk7MD7C6XQcjs.vectorMeshControlBounds; exports.vectorMeshEditPoints = _chunk7MD7C6XQcjs.vectorMeshEditPoints; exports.vectorMeshFromOutline = _chunk7MD7C6XQcjs.vectorMeshFromOutline; exports.vectorMeshGridCurves = _chunk7MD7C6XQcjs.vectorMeshGridCurves; exports.vectorMeshOutline = _chunk7MD7C6XQcjs.vectorMeshOutline; exports.vectorMeshParamAt = _chunk7MD7C6XQcjs.vectorMeshParamAt; exports.vectorMeshRows = _chunk7MD7C6XQcjs.vectorMeshRows; exports.vectorNodeBounds = _chunk7MD7C6XQcjs.vectorNodeBounds; exports.vectorNodeEnvelope = _chunk7MD7C6XQcjs.vectorNodeEnvelope; exports.vectorNodeRotation = _chunk7MD7C6XQcjs.vectorNodeRotation; exports.vectorNodeToBezier = _chunk7MD7C6XQcjs.vectorNodeToBezier; exports.vectorOperandOperation = _chunk7MD7C6XQcjs.vectorOperandOperation; exports.vectorPaintToHex = vectorPaintToHex; exports.vectorPaintToSvg = _chunk7MD7C6XQcjs.vectorPaintToSvg; exports.vectorParentMatrix = _chunk7MD7C6XQcjs.vectorParentMatrix; exports.vectorPathData = _chunk7MD7C6XQcjs.vectorPathData; exports.vectorPathEntries = vectorPathEntries; exports.vectorPathLocalBounds = _chunk7MD7C6XQcjs.vectorPathLocalBounds; exports.vectorPathWorldBezier = _chunk7MD7C6XQcjs.vectorPathWorldBezier; exports.vectorPathfinderShape = vectorPathfinderShape; exports.vectorRepeaterCopies = _chunk7MD7C6XQcjs.vectorRepeaterCopies; exports.vectorResizeCursor = vectorResizeCursor; exports.vectorResultStyle = vectorResultStyle; exports.vectorShapeBuilderHit = vectorShapeBuilderHit; exports.vectorShapeBuilderMap = vectorShapeBuilderMap; exports.vectorShearForSide = vectorShearForSide; exports.vectorSkewMatrix = vectorSkewMatrix; exports.vectorStrokeGradientDefs = _chunk7MD7C6XQcjs.vectorStrokeGradientDefs; exports.vectorStrokeLineArea = _chunk7MD7C6XQcjs.vectorStrokeLineArea; exports.vectorStrokeOutline = _chunk7MD7C6XQcjs.vectorStrokeOutline; exports.vectorStrokeOutlinePath = _chunk7MD7C6XQcjs.vectorStrokeOutlinePath; exports.vectorStrokeParts = _chunk7MD7C6XQcjs.vectorStrokeParts; exports.vectorStrokeReach = _chunk7MD7C6XQcjs.vectorStrokeReach; exports.vectorStrokeSvgParts = _chunk7MD7C6XQcjs.vectorStrokeSvgParts; exports.vectorStrokeWidthGeometry = vectorStrokeWidthGeometry; exports.vectorToolLabel = vectorToolLabel; exports.vectorWarpPresetGrid = _chunk7MD7C6XQcjs.vectorWarpPresetGrid; exports.vectorWarpPresetMesh = _chunk7MD7C6XQcjs.vectorWarpPresetMesh; exports.vectorWorldMatrix = _chunk7MD7C6XQcjs.vectorWorldMatrix; exports.walkVectorNodes = _chunk7MD7C6XQcjs.walkVectorNodes; exports.widthProfileAt = _chunk7MD7C6XQcjs.widthProfileAt; exports.widthProfileFromAttribute = _chunk7MD7C6XQcjs.widthProfileFromAttribute; exports.widthProfileMaxScale = _chunk7MD7C6XQcjs.widthProfileMaxScale; exports.widthProfilePreset = _chunk7MD7C6XQcjs.widthProfilePreset; exports.widthProfilePresetId = _chunk7MD7C6XQcjs.widthProfilePresetId; exports.widthProfileToAttribute = _chunk7MD7C6XQcjs.widthProfileToAttribute; exports.wigglePaths = _chunk7MD7C6XQcjs.wigglePaths; exports.zigzagPaths = _chunk7MD7C6XQcjs.zigzagPaths;
9332
+ exports.DEFAULT_VECTOR_BLEND_DISTANCE = DEFAULT_VECTOR_BLEND_DISTANCE; exports.DEFAULT_VECTOR_BLEND_STEPS = DEFAULT_VECTOR_BLEND_STEPS; exports.DEFAULT_VECTOR_PATH_EDIT = DEFAULT_VECTOR_PATH_EDIT; exports.DEFAULT_VECTOR_SNAP = DEFAULT_VECTOR_SNAP; exports.IDENTITY_MATRIX = _chunkDWGZUSEScjs.IDENTITY_MATRIX; exports.KAPPA = _chunkJF5PXN7Wcjs.KAPPA; exports.LazyMouse = LazyMouse; exports.VECTOR_ARROWHEADS = _chunkJF5PXN7Wcjs.VECTOR_ARROWHEADS; exports.VECTOR_ARROWHEAD_LABELS = VECTOR_ARROWHEAD_LABELS; exports.VECTOR_BLEND_MAX_SMOOTH_STEPS = VECTOR_BLEND_MAX_SMOOTH_STEPS; exports.VECTOR_BLEND_MAX_STEPS = VECTOR_BLEND_MAX_STEPS; exports.VECTOR_BLEND_SPACINGS = _chunkJF5PXN7Wcjs.VECTOR_BLEND_SPACINGS; exports.VECTOR_BLEND_SPACING_LABELS = VECTOR_BLEND_SPACING_LABELS; exports.VECTOR_BUILDER_HATCH_GAP = VECTOR_BUILDER_HATCH_GAP; exports.VECTOR_CLIPBOARD_TYPE = VECTOR_CLIPBOARD_TYPE; exports.VECTOR_CONSTRUCTION_ANGLES = VECTOR_CONSTRUCTION_ANGLES; exports.VECTOR_CORNER_KINDS = _chunkJF5PXN7Wcjs.VECTOR_CORNER_KINDS; exports.VECTOR_CORNER_KIND_LABELS = VECTOR_CORNER_KIND_LABELS; exports.VECTOR_CORNER_WIDGET_INSET = VECTOR_CORNER_WIDGET_INSET; exports.VECTOR_DISTORT_TOLERANCE = VECTOR_DISTORT_TOLERANCE; exports.VECTOR_EDIT_TOGGLES = VECTOR_EDIT_TOGGLES; exports.VECTOR_EFFECT_DEFAULTS = _chunkJF5PXN7Wcjs.VECTOR_EFFECT_DEFAULTS; exports.VECTOR_EFFECT_LABELS = _chunkJF5PXN7Wcjs.VECTOR_EFFECT_LABELS; exports.VECTOR_EFFECT_MENU = VECTOR_EFFECT_MENU; exports.VECTOR_EFFECT_PARAM_SPECS = _chunkJF5PXN7Wcjs.VECTOR_EFFECT_PARAM_SPECS; exports.VECTOR_EFFECT_TYPES = _chunkJF5PXN7Wcjs.VECTOR_EFFECT_TYPES; exports.VECTOR_ENVELOPE_STYLE_OPTIONS = VECTOR_ENVELOPE_STYLE_OPTIONS; exports.VECTOR_FILL_GAP = VECTOR_FILL_GAP; exports.VECTOR_GRADIENT_INTERPOLATIONS = _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_INTERPOLATIONS; exports.VECTOR_GRADIENT_INTERPOLATION_LABELS = VECTOR_GRADIENT_INTERPOLATION_LABELS; exports.VECTOR_GRADIENT_MAX_PERIODS = _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_MAX_PERIODS; exports.VECTOR_GRADIENT_MIDPOINT_GAP = VECTOR_GRADIENT_MIDPOINT_GAP; exports.VECTOR_GRADIENT_MIN_STOPS = _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_MIN_STOPS; exports.VECTOR_GRADIENT_OFF_BAR = VECTOR_GRADIENT_OFF_BAR; exports.VECTOR_GRADIENT_SPREADS = _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_SPREADS; exports.VECTOR_GRADIENT_SPREAD_LABELS = VECTOR_GRADIENT_SPREAD_LABELS; exports.VECTOR_GRADIENT_STOP_GAP = VECTOR_GRADIENT_STOP_GAP; exports.VECTOR_GRADIENT_TYPES = _chunkJF5PXN7Wcjs.VECTOR_GRADIENT_TYPES; exports.VECTOR_GRADIENT_TYPE_LABELS = VECTOR_GRADIENT_TYPE_LABELS; exports.VECTOR_INK_MAX_CORNERS = VECTOR_INK_MAX_CORNERS; exports.VECTOR_MERGE_MODES = _chunkJF5PXN7Wcjs.VECTOR_MERGE_MODES; exports.VECTOR_OVERLAY_THEME = VECTOR_OVERLAY_THEME; exports.VECTOR_PATHFINDER_ACTIONS = VECTOR_PATHFINDER_ACTIONS; exports.VECTOR_PATHFINDER_LABELS = VECTOR_PATHFINDER_LABELS; exports.VECTOR_PATHFINDER_OPERATIONS = _chunkJF5PXN7Wcjs.VECTOR_PATHFINDER_OPERATIONS; exports.VECTOR_PATH_ACTIONS = VECTOR_PATH_ACTIONS; exports.VECTOR_PENCIL_STRING_PX = VECTOR_PENCIL_STRING_PX; exports.VECTOR_PRESSURE_NOMINAL = _chunkJF5PXN7Wcjs.VECTOR_PRESSURE_NOMINAL; exports.VECTOR_ROTATE_HANDLE_OFFSET = VECTOR_ROTATE_HANDLE_OFFSET; exports.VECTOR_STROKE_ALIGN_LABELS = VECTOR_STROKE_ALIGN_LABELS; exports.VECTOR_STROKE_GRADIENT_MODES = _chunkJF5PXN7Wcjs.VECTOR_STROKE_GRADIENT_MODES; exports.VECTOR_STROKE_GRADIENT_MODE_LABELS = VECTOR_STROKE_GRADIENT_MODE_LABELS; exports.VECTOR_STYLE_KEYS = VECTOR_STYLE_KEYS; exports.VECTOR_TOOLS = _chunkJF5PXN7Wcjs.VECTOR_TOOLS; exports.VECTOR_TOOL_GLYPHS = VECTOR_TOOL_GLYPHS; exports.VECTOR_TOOL_SHORTCUTS = VECTOR_TOOL_SHORTCUTS; exports.VECTOR_TRANSFORM_HANDLES = _chunkJF5PXN7Wcjs.VECTOR_TRANSFORM_HANDLES; exports.VECTOR_WARP_STYLES = _chunkDWGZUSEScjs.WARP_STYLES; exports.VECTOR_WARP_STYLE_LABELS = _chunkDWGZUSEScjs.WARP_STYLE_LABELS; exports.VECTOR_WIDTH_PRESETS = _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PRESETS; exports.VECTOR_WIDTH_PRESET_IDS = _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PRESET_IDS; exports.VECTOR_WIDTH_PROFILE_MAX_POINTS = _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS; exports.VECTOR_WIDTH_PROFILE_MAX_SCALE = _chunkJF5PXN7Wcjs.VECTOR_WIDTH_PROFILE_MAX_SCALE; exports.VECTOR_WIDTH_SAME_T = _chunkJF5PXN7Wcjs.VECTOR_WIDTH_SAME_T; exports.VectorEditorController = VectorEditorController; exports.VectorSnapTargets = VectorSnapTargets; exports.activeVectorEffects = _chunkJF5PXN7Wcjs.activeVectorEffects; exports.addBuilderHit = addBuilderHit; exports.applyMatrix = _chunkDWGZUSEScjs.applyMatrix; exports.applyMatrixLinear = _chunkDWGZUSEScjs.applyMatrixLinear; exports.applyVectorBlendOptions = applyVectorBlendOptions; exports.applyVectorCornersAttribute = _chunkJF5PXN7Wcjs.applyVectorCornersAttribute; exports.applyVectorEffects = _chunkJF5PXN7Wcjs.applyVectorEffects; exports.applyVectorGradientPatch = _chunkJF5PXN7Wcjs.applyVectorGradientPatch; exports.applyVectorGradientSpread = _chunkJF5PXN7Wcjs.applyVectorGradientSpread; exports.applyVectorHomography = _chunkMUUXNRU4cjs.applyHomography; exports.arrowheadInset = _chunkJF5PXN7Wcjs.arrowheadInset; exports.arrowheadPath = _chunkJF5PXN7Wcjs.arrowheadPath; exports.arrowheadWeight = _chunkJF5PXN7Wcjs.arrowheadWeight; exports.bendSegment = bendSegment; exports.bezierToSubpaths = _chunkJF5PXN7Wcjs.bezierToSubpaths; exports.boundsFromPoints = _chunkJF5PXN7Wcjs.boundsFromPoints; exports.boundsIntersect = _chunkJF5PXN7Wcjs.boundsIntersect; exports.clearVectorLiveBooleanCache = _chunkJF5PXN7Wcjs.clearVectorLiveBooleanCache; exports.cloneAnchor = _chunkJF5PXN7Wcjs.cloneAnchor; exports.cloneSubpath = _chunkJF5PXN7Wcjs.cloneSubpath; exports.cloneVectorDocument = _chunkJF5PXN7Wcjs.cloneVectorDocument; exports.cloneVectorNode = _chunkJF5PXN7Wcjs.cloneVectorNode; exports.collectPathNodes = _chunkJF5PXN7Wcjs.collectPathNodes; exports.constrainToLeave = constrainToLeave; exports.convertAnchor = _chunkJF5PXN7Wcjs.convertAnchor; exports.convertVectorGradient = _chunkJF5PXN7Wcjs.convertVectorGradient; exports.cornerBisectorPoint = _chunkJF5PXN7Wcjs.cornerBisectorPoint; exports.cornerRadiusChange = _chunkJF5PXN7Wcjs.cornerRadiusChange; exports.cornerSetback = _chunkJF5PXN7Wcjs.cornerSetback; exports.correspondMorphContours = _chunkJF5PXN7Wcjs.correspondMorphContours; exports.createVectorCommands = createVectorCommands; exports.createVectorEffect = _chunkJF5PXN7Wcjs.createVectorEffect; exports.createVectorMorph = _chunkJF5PXN7Wcjs.createVectorMorph; exports.curvatureMoveAnchor = curvatureMoveAnchor; exports.cutSubpathAt = cutSubpathAt; exports.dashIntervals = _chunkJF5PXN7Wcjs.dashIntervals; exports.decomposeRigid = _chunkDWGZUSEScjs.decomposeRigid; exports.defaultVectorGradient = _chunkJF5PXN7Wcjs.defaultVectorGradient; exports.distortVectorNode = distortVectorNode; exports.dragVectorMeshPoint = _chunkDWGZUSEScjs.dragWarpMeshPoint; exports.effectPathLength = _chunkJF5PXN7Wcjs.effectPathLength; exports.effectPathVertexCount = _chunkJF5PXN7Wcjs.effectPathVertexCount; exports.effectiveStrokeAlign = _chunkJF5PXN7Wcjs.effectiveStrokeAlign; exports.ellipseSubpath = _chunkJF5PXN7Wcjs.ellipseSubpath; exports.eraseFromFill = eraseFromFill; exports.eraseFromOutline = eraseFromOutline; exports.eraserRegion = eraserRegion; exports.evalVectorMesh = _chunkDWGZUSEScjs.evalWarpMesh; exports.evaluateVectorPathKeyframes = _chunkJF5PXN7Wcjs.evaluateVectorPathKeyframes; exports.expandVectorAppearance = _chunkJF5PXN7Wcjs.expandVectorAppearance; exports.expandVectorAppearances = _chunkJF5PXN7Wcjs.expandVectorAppearances; exports.expandVectorBlend = expandVectorBlend; exports.expandVectorCorners = _chunkJF5PXN7Wcjs.expandVectorCorners; exports.expandVectorCornersOf = _chunkJF5PXN7Wcjs.expandVectorCornersOf; exports.expandVectorGradientSpread = _chunkJF5PXN7Wcjs.expandVectorGradientSpread; exports.expandVectorGradientStops = _chunkJF5PXN7Wcjs.expandVectorGradientStops; exports.explicitVectorGradient = _chunkJF5PXN7Wcjs.explicitVectorGradient; exports.findVectorNode = _chunkJF5PXN7Wcjs.findVectorNode; exports.fitCornerRadius = _chunkJF5PXN7Wcjs.fitCornerRadius; exports.fitVectorMesh = _chunkDWGZUSEScjs.fitWarpMesh; exports.foldVectorBooleanOperands = _chunkJF5PXN7Wcjs.foldVectorBooleanOperands; exports.generateVectorBlendChildren = generateVectorBlendChildren; exports.generateWidthProfile = _chunkJF5PXN7Wcjs.generateWidthProfile; exports.getAnchor = getAnchor; exports.getAnchorWorld = getAnchorWorld; exports.getEditablePathIds = getEditablePathIds; exports.getTransformHandlePositions = getTransformHandlePositions; exports.getVectorBlendControls = getVectorBlendControls; exports.getVectorCornerWidgets = getVectorCornerWidgets; exports.getVectorEffectsPanel = getVectorEffectsPanel; exports.getVectorEnteredGroups = getVectorEnteredGroups; exports.getVectorEnvelopePanel = getVectorEnvelopePanel; exports.getVectorEnvelopeTarget = getVectorEnvelopeTarget; exports.getVectorGradientAnnotator = getVectorGradientAnnotator; exports.getVectorGradientEditor = getVectorGradientEditor; exports.getVectorOverlayRenderData = getVectorOverlayRenderData; exports.getVectorSceneRenderData = getVectorSceneRenderData; exports.getVectorSelectionBoxGeometry = getVectorSelectionBoxGeometry; exports.getVectorSelectionFrame = getVectorSelectionFrame; exports.getVectorSelectionStyle = getVectorSelectionStyle; exports.getVectorWidthHandles = getVectorWidthHandles; exports.getVisibleAnchors = getVisibleAnchors; exports.getVisibleHandles = getVisibleHandles; exports.gradientMidpointRemap = _chunkJF5PXN7Wcjs.gradientMidpointRemap; exports.hasExplicitGradientGeometry = _chunkJF5PXN7Wcjs.hasExplicitGradientGeometry; exports.hasOwnVectorAppearance = _chunkJF5PXN7Wcjs.hasOwnVectorAppearance; exports.hasPaint = _chunkJF5PXN7Wcjs.hasPaint; exports.hasStrokeExtras = _chunkJF5PXN7Wcjs.hasStrokeExtras; exports.hasVectorAppearance = _chunkJF5PXN7Wcjs.hasVectorAppearance; exports.hasVectorCorners = _chunkJF5PXN7Wcjs.hasVectorCorners; exports.hitTestVectorNode = _chunkJF5PXN7Wcjs.hitTestVectorNode; exports.hitTestVectorNodes = _chunkJF5PXN7Wcjs.hitTestVectorNodes; exports.hitTestVectorStroke = _chunkJF5PXN7Wcjs.hitTestVectorStroke; exports.hitVectorGradientAnnotator = hitVectorGradientAnnotator; exports.inferAnchorType = _chunkJF5PXN7Wcjs.inferAnchorType; exports.insertAnchor = _chunkJF5PXN7Wcjs.insertAnchor; exports.insertVectorGradientStop = _chunkJF5PXN7Wcjs.insertVectorGradientStop; exports.insertWidthPoint = _chunkJF5PXN7Wcjs.insertWidthPoint; exports.interpolateMorphContours = _chunkJF5PXN7Wcjs.interpolateMorphContours; exports.interpolateRigidMatrix = _chunkJF5PXN7Wcjs.interpolateRigidMatrix; exports.interpolateVectorColor = _chunkJF5PXN7Wcjs.interpolateVectorColor; exports.interpolateVectorPaint = _chunkJF5PXN7Wcjs.interpolateVectorPaint; exports.interpolateVectorPaths = _chunkJF5PXN7Wcjs.interpolateVectorPaths; exports.interpolateVectorStyle = _chunkJF5PXN7Wcjs.interpolateVectorStyle; exports.interpolateWidthProfiles = _chunkJF5PXN7Wcjs.interpolateWidthProfiles; exports.invertMatrix = _chunkDWGZUSEScjs.invertMatrix; exports.isCentredVectorGradient = _chunkJF5PXN7Wcjs.isCentredVectorGradient; exports.isClosedBezierShape = _chunkJF5PXN7Wcjs.isClosedBezierShape; exports.isIdentityMatrix = _chunkDWGZUSEScjs.isIdentityMatrix; exports.isUniformWidthProfile = _chunkJF5PXN7Wcjs.isUniformWidthProfile; exports.isValidVectorMesh = _chunkDWGZUSEScjs.isValidWarpMesh; exports.isVectorBlendGroup = isVectorBlendGroup; exports.isVectorGradient = _chunkJF5PXN7Wcjs.isVectorGradient; exports.isVectorLiveBoolean = _chunkJF5PXN7Wcjs.isVectorLiveBoolean; exports.isVectorTextTarget = isVectorTextTarget; exports.joinSubpaths = joinSubpaths; exports.knifePath = knifePath; exports.lineSubpath = _chunkJF5PXN7Wcjs.lineSubpath; exports.locateVectorNode = _chunkJF5PXN7Wcjs.locateVectorNode; exports.mapBezierPath = _chunkJF5PXN7Wcjs.mapBezierPath; exports.mapVectorGradient = _chunkJF5PXN7Wcjs.mapVectorGradient; exports.mapVectorMeshPoints = _chunkDWGZUSEScjs.mapWarpMeshPoints; exports.mapVectorPaint = _chunkJF5PXN7Wcjs.mapVectorPaint; exports.mapVectorPoints = _chunkJF5PXN7Wcjs.mapVectorPoints; exports.mapVectorSubpaths = _chunkJF5PXN7Wcjs.mapVectorSubpaths; exports.matrixRotation = _chunkDWGZUSEScjs.matrixRotation; exports.mergePaths = _chunkJF5PXN7Wcjs.mergePaths; exports.mirrorWidthProfile = _chunkJF5PXN7Wcjs.mirrorWidthProfile; exports.morphContourToSubpath = _chunkJF5PXN7Wcjs.morphContourToSubpath; exports.morphPathsCross = _chunkJF5PXN7Wcjs.morphPathsCross; exports.moveAnchorHandle = _chunkJF5PXN7Wcjs.moveAnchorHandle; exports.moveVectorGradientHandle = _chunkJF5PXN7Wcjs.moveVectorGradientHandle; exports.moveVectorGradientStop = _chunkJF5PXN7Wcjs.moveVectorGradientStop; exports.multiplyMatrices = _chunkDWGZUSEScjs.multiplyMatrices; exports.nearestSegment = _chunkJF5PXN7Wcjs.nearestSegment; exports.nearestStrokePosition = _chunkJF5PXN7Wcjs.nearestStrokePosition; exports.nextVectorCornerKind = _chunkJF5PXN7Wcjs.nextVectorCornerKind; exports.nodeMatrix = _chunkJF5PXN7Wcjs.nodeMatrix; exports.normalizeVectorEffectParams = _chunkJF5PXN7Wcjs.normalizeVectorEffectParams; exports.offsetPaths = _chunkJF5PXN7Wcjs.offsetPaths; exports.orderVectorQuad = _chunkMUUXNRU4cjs.orderQuad; exports.parseSvgTransform = _chunkJF5PXN7Wcjs.parseSvgTransform; exports.parseVectorColor = _chunkJF5PXN7Wcjs.parseVectorColor; exports.parseVectorSvg = _chunkJF5PXN7Wcjs.parseVectorSvg; exports.pathsCenter = _chunkJF5PXN7Wcjs.pathsCenter; exports.patternAttrs = _chunkJF5PXN7Wcjs.patternAttrs; exports.periodicVectorGradientStops = _chunkJF5PXN7Wcjs.periodicVectorGradientStops; exports.pinVectorGradient = _chunkJF5PXN7Wcjs.pinVectorGradient; exports.planShapeBuilder = planShapeBuilder; exports.polygonSubpath = _chunkJF5PXN7Wcjs.polygonSubpath; exports.polylineBounds = polylineBounds; exports.pressureWidthProfile = _chunkJF5PXN7Wcjs.pressureWidthProfile; exports.puckerBloatPaths = _chunkJF5PXN7Wcjs.puckerBloatPaths; exports.pullVectorMesh = _chunkDWGZUSEScjs.pullWarpMesh; exports.recognizeInkShape = recognizeInkShape; exports.rectSubpath = _chunkJF5PXN7Wcjs.rectSubpath; exports.refineMorphContour = _chunkJF5PXN7Wcjs.refineMorphContour; exports.refreshVectorBlends = refreshVectorBlends; exports.releaseVectorBlend = releaseVectorBlend; exports.removeAnchorKeepingShape = removeAnchorKeepingShape; exports.removeAnchors = _chunkJF5PXN7Wcjs.removeAnchors; exports.removeAnchorsKeepingShape = removeAnchorsKeepingShape; exports.removeRedundantPoints = removeRedundantPoints; exports.removeVectorGradientStop = _chunkJF5PXN7Wcjs.removeVectorGradientStop; exports.removeVectorMeshSplitU = _chunkDWGZUSEScjs.removeWarpMeshSplitU; exports.removeVectorMeshSplitV = _chunkDWGZUSEScjs.removeWarpMeshSplitV; exports.removeWidthPoints = _chunkJF5PXN7Wcjs.removeWidthPoints; exports.repeatPaths = _chunkJF5PXN7Wcjs.repeatPaths; exports.resampleGradientStops = _chunkJF5PXN7Wcjs.resampleGradientStops; exports.resizeVectorMesh = _chunkDWGZUSEScjs.resizeWarpMesh; exports.resolveVectorBlendOptions = resolveVectorBlendOptions; exports.reverseMorphContour = _chunkJF5PXN7Wcjs.reverseMorphContour; exports.reverseSubpath = _chunkJF5PXN7Wcjs.reverseSubpath; exports.reverseVectorGradient = _chunkJF5PXN7Wcjs.reverseVectorGradient; exports.reverseWidthProfile = _chunkJF5PXN7Wcjs.reverseWidthProfile; exports.rotateMatrix = _chunkDWGZUSEScjs.rotateMatrix; exports.roundCornerPaths = _chunkJF5PXN7Wcjs.roundCornerPaths; exports.roundSubpaths = _chunkJF5PXN7Wcjs.roundSubpaths; exports.samplePlainStops = _chunkJF5PXN7Wcjs.samplePlainStops; exports.samplePolyline = samplePolyline; exports.sampleVectorGradient = _chunkJF5PXN7Wcjs.sampleVectorGradient; exports.sampleVectorGradientAt = _chunkJF5PXN7Wcjs.sampleVectorGradientAt; exports.sampleVectorPaintDefAt = _chunkJF5PXN7Wcjs.sampleVectorPaintDefAt; exports.sanitizeVectorEffects = _chunkJF5PXN7Wcjs.sanitizeVectorEffects; exports.sanitizeVectorGradient = _chunkJF5PXN7Wcjs.sanitizeVectorGradient; exports.sanitizeWidthProfile = _chunkJF5PXN7Wcjs.sanitizeWidthProfile; exports.scaleFor = scaleFor; exports.scaleMatrix = _chunkDWGZUSEScjs.scaleMatrix; exports.setAnchorCorner = _chunkJF5PXN7Wcjs.setAnchorCorner; exports.setSubpathCorners = _chunkJF5PXN7Wcjs.setSubpathCorners; exports.setVectorGradientVector = _chunkJF5PXN7Wcjs.setVectorGradientVector; exports.setWidthPoint = _chunkJF5PXN7Wcjs.setWidthPoint; exports.simplifyPolyline = simplifyPolyline; exports.smoothSubpath = smoothSubpath; exports.solve8 = _chunkMUUXNRU4cjs.solve8; exports.sortedVectorGradientStops = _chunkJF5PXN7Wcjs.sortedVectorGradientStops; exports.spanVectorGradientStops = _chunkJF5PXN7Wcjs.spanVectorGradientStops; exports.splitIntoFaces = splitIntoFaces; exports.splitSubpathAt = splitSubpathAt; exports.splitVectorMeshU = _chunkDWGZUSEScjs.splitWarpMeshU; exports.splitVectorMeshV = _chunkDWGZUSEScjs.splitWarpMeshV; exports.starSubpath = _chunkJF5PXN7Wcjs.starSubpath; exports.strokePositionPoint = _chunkJF5PXN7Wcjs.strokePositionPoint; exports.strokeWidthProfileOf = _chunkJF5PXN7Wcjs.strokeWidthProfileOf; exports.subpathEnclosesArea = subpathEnclosesArea; exports.subpathPointAt = subpathPointAt; exports.subpathSegment = _chunkJF5PXN7Wcjs.subpathSegment; exports.subpathSegmentCount = _chunkJF5PXN7Wcjs.subpathSegmentCount; exports.subpathToMorphContour = _chunkJF5PXN7Wcjs.subpathToMorphContour; exports.subpathsToBezier = _chunkJF5PXN7Wcjs.subpathsToBezier; exports.taperWaveFactor = _chunkJF5PXN7Wcjs.taperWaveFactor; exports.toVectorKeyInput = toVectorKeyInput; exports.toVectorModifiers = toVectorModifiers; exports.toVectorPointerInput = toVectorPointerInput; exports.transformVectorEffects = _chunkJF5PXN7Wcjs.transformVectorEffects; exports.transformVectorGradient = _chunkJF5PXN7Wcjs.transformVectorGradient; exports.transformVectorNode = _chunkJF5PXN7Wcjs.transformVectorNode; exports.transformVectorPaint = _chunkJF5PXN7Wcjs.transformVectorPaint; exports.translateAnchor = _chunkJF5PXN7Wcjs.translateAnchor; exports.translateMatrix = _chunkDWGZUSEScjs.translateMatrix; exports.trimIntervals = _chunkJF5PXN7Wcjs.trimIntervals; exports.trimPaths = _chunkJF5PXN7Wcjs.trimPaths; exports.trimPathsIndividually = _chunkJF5PXN7Wcjs.trimPathsIndividually; exports.turnMorphContour = _chunkJF5PXN7Wcjs.turnMorphContour; exports.twistPaths = _chunkJF5PXN7Wcjs.twistPaths; exports.unionBounds = _chunkJF5PXN7Wcjs.unionBounds; exports.variableStrokeOutline = _chunkJF5PXN7Wcjs.variableStrokeOutline; exports.variableStrokeRings = _chunkJF5PXN7Wcjs.variableStrokeRings; exports.vectorAppearanceNodes = _chunkJF5PXN7Wcjs.vectorAppearanceNodes; exports.vectorAppearanceOutline = _chunkJF5PXN7Wcjs.vectorAppearanceOutline; exports.vectorAppearanceShapes = _chunkJF5PXN7Wcjs.vectorAppearanceShapes; exports.vectorBlendColorDistance = vectorBlendColorDistance; exports.vectorBlendKeyTargets = vectorBlendKeyTargets; exports.vectorBlendKeys = vectorBlendKeys; exports.vectorBlendRail = vectorBlendRail; exports.vectorBlendRailAt = vectorBlendRailAt; exports.vectorBlendSpine = vectorBlendSpine; exports.vectorBlendStepCount = vectorBlendStepCount; exports.vectorBoxCorners = vectorBoxCorners; exports.vectorBoxMatrix = _chunkJF5PXN7Wcjs.vectorBoxMatrix; exports.vectorBuilderErasedEdges = vectorBuilderErasedEdges; exports.vectorCornerAt = _chunkJF5PXN7Wcjs.vectorCornerAt; exports.vectorCorners = _chunkJF5PXN7Wcjs.vectorCorners; exports.vectorCornersAttribute = _chunkJF5PXN7Wcjs.vectorCornersAttribute; exports.vectorDiamondPath = vectorDiamondPath; exports.vectorDistortQuad = vectorDistortQuad; exports.vectorDocumentToSvg = _chunkJF5PXN7Wcjs.vectorDocumentToSvg; exports.vectorEffectInputBounds = _chunkJF5PXN7Wcjs.vectorEffectInputBounds; exports.vectorEffectInputPaths = _chunkJF5PXN7Wcjs.vectorEffectInputPaths; exports.vectorEnteredGroups = _chunkJF5PXN7Wcjs.vectorEnteredGroups; exports.vectorEnvelopeFrame = _chunkJF5PXN7Wcjs.vectorEnvelopeFrame; exports.vectorEnvelopeMap = _chunkJF5PXN7Wcjs.vectorEnvelopeMap; exports.vectorEnvelopeMesh = _chunkJF5PXN7Wcjs.vectorEnvelopeMesh; exports.vectorFillMap = vectorFillMap; exports.vectorGradientArea = _chunkJF5PXN7Wcjs.vectorGradientArea; exports.vectorGradientAspect = _chunkJF5PXN7Wcjs.vectorGradientAspect; exports.vectorGradientBarPosition = vectorGradientBarPosition; exports.vectorGradientFocalParam = _chunkJF5PXN7Wcjs.vectorGradientFocalParam; exports.vectorGradientHandles = _chunkJF5PXN7Wcjs.vectorGradientHandles; exports.vectorGradientMatrix = _chunkJF5PXN7Wcjs.vectorGradientMatrix; exports.vectorGradientMidpointFromPosition = _chunkJF5PXN7Wcjs.vectorGradientMidpointFromPosition; exports.vectorGradientMidpointPosition = _chunkJF5PXN7Wcjs.vectorGradientMidpointPosition; exports.vectorGradientNeedsExpansion = _chunkJF5PXN7Wcjs.vectorGradientNeedsExpansion; exports.vectorGradientParam = _chunkJF5PXN7Wcjs.vectorGradientParam; exports.vectorGradientPoints = _chunkJF5PXN7Wcjs.vectorGradientPoints; exports.vectorGradientRamp = _chunkJF5PXN7Wcjs.vectorGradientRamp; exports.vectorGradientSvgDefs = _chunkJF5PXN7Wcjs.vectorGradientSvgDefs; exports.vectorGradientTAt = _chunkJF5PXN7Wcjs.vectorGradientTAt; exports.vectorGradientTargetPath = vectorGradientTargetPath; exports.vectorGradientUnitsMatrix = _chunkJF5PXN7Wcjs.vectorGradientUnitsMatrix; exports.vectorHomography = _chunkMUUXNRU4cjs.homographyFromPoints; exports.vectorHomographyKeepsQuad = _chunkMUUXNRU4cjs.homographyKeepsQuad; exports.vectorIdentityMesh = _chunkDWGZUSEScjs.identityWarpMesh; exports.vectorInkShapeName = vectorInkShapeName; exports.vectorLiveBooleanSteps = _chunkJF5PXN7Wcjs.vectorLiveBooleanSteps; exports.vectorMeshColumns = _chunkDWGZUSEScjs.warpMeshColumns; exports.vectorMeshControlBounds = _chunkDWGZUSEScjs.warpMeshControlBounds; exports.vectorMeshEditPoints = _chunkDWGZUSEScjs.warpMeshEditPoints; exports.vectorMeshFromOutline = _chunkJF5PXN7Wcjs.vectorMeshFromOutline; exports.vectorMeshGridCurves = _chunkDWGZUSEScjs.warpMeshGridCurves; exports.vectorMeshOutline = _chunkJF5PXN7Wcjs.vectorMeshOutline; exports.vectorMeshParamAt = _chunkDWGZUSEScjs.warpMeshParamAt; exports.vectorMeshRows = _chunkDWGZUSEScjs.warpMeshRows; exports.vectorNodeBounds = _chunkJF5PXN7Wcjs.vectorNodeBounds; exports.vectorNodeEnvelope = _chunkJF5PXN7Wcjs.vectorNodeEnvelope; exports.vectorNodeRotation = _chunkJF5PXN7Wcjs.vectorNodeRotation; exports.vectorNodeToBezier = _chunkJF5PXN7Wcjs.vectorNodeToBezier; exports.vectorOperandOperation = _chunkJF5PXN7Wcjs.vectorOperandOperation; exports.vectorPaintToHex = vectorPaintToHex; exports.vectorPaintToSvg = _chunkJF5PXN7Wcjs.vectorPaintToSvg; exports.vectorParentMatrix = _chunkJF5PXN7Wcjs.vectorParentMatrix; exports.vectorPathData = _chunkJF5PXN7Wcjs.vectorPathData; exports.vectorPathEntries = vectorPathEntries; exports.vectorPathLocalBounds = _chunkJF5PXN7Wcjs.vectorPathLocalBounds; exports.vectorPathWorldBezier = _chunkJF5PXN7Wcjs.vectorPathWorldBezier; exports.vectorPathfinderShape = vectorPathfinderShape; exports.vectorRepeaterCopies = _chunkJF5PXN7Wcjs.vectorRepeaterCopies; exports.vectorResizeCursor = vectorResizeCursor; exports.vectorResultStyle = vectorResultStyle; exports.vectorShapeBuilderHit = vectorShapeBuilderHit; exports.vectorShapeBuilderMap = vectorShapeBuilderMap; exports.vectorShearForSide = vectorShearForSide; exports.vectorSkewMatrix = vectorSkewMatrix; exports.vectorStrokeGradientDefs = _chunkJF5PXN7Wcjs.vectorStrokeGradientDefs; exports.vectorStrokeLineArea = _chunkJF5PXN7Wcjs.vectorStrokeLineArea; exports.vectorStrokeOutline = _chunkJF5PXN7Wcjs.vectorStrokeOutline; exports.vectorStrokeOutlinePath = _chunkJF5PXN7Wcjs.vectorStrokeOutlinePath; exports.vectorStrokeParts = _chunkJF5PXN7Wcjs.vectorStrokeParts; exports.vectorStrokeReach = _chunkJF5PXN7Wcjs.vectorStrokeReach; exports.vectorStrokeSvgParts = _chunkJF5PXN7Wcjs.vectorStrokeSvgParts; exports.vectorStrokeWidthGeometry = vectorStrokeWidthGeometry; exports.vectorToolLabel = vectorToolLabel; exports.vectorWarpPresetGrid = _chunkDWGZUSEScjs.warpPresetGrid; exports.vectorWarpPresetMesh = _chunkDWGZUSEScjs.warpPresetMesh; exports.vectorWorldMatrix = _chunkJF5PXN7Wcjs.vectorWorldMatrix; exports.walkVectorNodes = _chunkJF5PXN7Wcjs.walkVectorNodes; exports.widthProfileAt = _chunkJF5PXN7Wcjs.widthProfileAt; exports.widthProfileFromAttribute = _chunkJF5PXN7Wcjs.widthProfileFromAttribute; exports.widthProfileMaxScale = _chunkJF5PXN7Wcjs.widthProfileMaxScale; exports.widthProfilePreset = _chunkJF5PXN7Wcjs.widthProfilePreset; exports.widthProfilePresetId = _chunkJF5PXN7Wcjs.widthProfilePresetId; exports.widthProfileToAttribute = _chunkJF5PXN7Wcjs.widthProfileToAttribute; exports.wigglePaths = _chunkJF5PXN7Wcjs.wigglePaths; exports.zigzagPaths = _chunkJF5PXN7Wcjs.zigzagPaths;
9397
9333
  //# sourceMappingURL=index.cjs.map