@pixerate/editor 0.57.0 → 0.58.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.
@@ -267,7 +267,7 @@ var _chunkMLREO6J3cjs = require('../chunk-MLREO6J3.cjs');
267
267
 
268
268
 
269
269
 
270
- var _chunkXCXQDPIDcjs = require('../chunk-XCXQDPID.cjs');
270
+ var _chunkFKONE6AOcjs = require('../chunk-FKONE6AO.cjs');
271
271
 
272
272
 
273
273
 
@@ -313,9 +313,9 @@ var fmt = (n) => Math.round(n * 100) / 100;
313
313
  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
314
  function vectorGradientTargetPath(doc, selection, target) {
315
315
  for (const id of selection) {
316
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, id);
316
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, id);
317
317
  if (!node) continue;
318
- const path = _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node).find((p) => _chunkXCXQDPIDcjs.isVectorGradient.call(void 0, p[target]));
318
+ const path = _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node).find((p) => _chunkFKONE6AOcjs.isVectorGradient.call(void 0, p[target]));
319
319
  if (path) return path;
320
320
  }
321
321
  return null;
@@ -324,23 +324,23 @@ function getVectorGradientAnnotator(doc, selection, viewport, target) {
324
324
  const path = vectorGradientTargetPath(doc, selection, target);
325
325
  if (!path) return null;
326
326
  const gradient = path[target];
327
- const world = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, doc.nodes, path.id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
328
- const screen = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, world, [viewport.zoom, 0, 0, viewport.zoom, viewport.x, viewport.y]);
329
- const bounds = _chunkXCXQDPIDcjs.vectorPathLocalBounds.call(void 0, path);
330
- const h = _chunkXCXQDPIDcjs.vectorGradientHandles.call(void 0, gradient, bounds, screen);
327
+ const world = _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, doc.nodes, path.id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
328
+ const screen = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, world, [viewport.zoom, 0, 0, viewport.zoom, viewport.x, viewport.y]);
329
+ const bounds = _chunkFKONE6AOcjs.vectorPathLocalBounds.call(void 0, path);
330
+ const h = _chunkFKONE6AOcjs.vectorGradientHandles.call(void 0, gradient, bounds, screen);
331
331
  const v = { x: h.end.x - h.start.x, y: h.end.y - h.start.y };
332
332
  const len = Math.hypot(v.x, v.y);
333
333
  const normal = len > 1e-9 ? { x: -v.y / len, y: v.x / len } : { x: 0, y: 1 };
334
334
  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 = _chunkXCXQDPIDcjs.sortedVectorGradientStops.call(void 0, gradient);
335
+ const sorted = _chunkFKONE6AOcjs.sortedVectorGradientStops.call(void 0, gradient);
336
336
  const stops = sorted.map((s, index) => ({ ...s, index, ...at(s.offset, VECTOR_GRADIENT_STOP_GAP) }));
337
337
  const midpoints = sorted.slice(0, -1).flatMap((s, index) => {
338
- const pos = _chunkXCXQDPIDcjs.vectorGradientMidpointPosition.call(void 0, sorted, index);
338
+ const pos = _chunkFKONE6AOcjs.vectorGradientMidpointPosition.call(void 0, sorted, index);
339
339
  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
340
  });
341
341
  let extent = null;
342
- if (_chunkXCXQDPIDcjs.isCentredVectorGradient.call(void 0, gradient.type)) {
343
- const frame = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.vectorGradientMatrix.call(void 0, gradient, bounds), screen);
342
+ if (_chunkFKONE6AOcjs.isCentredVectorGradient.call(void 0, gradient.type)) {
343
+ const frame = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.vectorGradientMatrix.call(void 0, gradient, bounds), screen);
344
344
  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
345
  extent = `M${pts.map((p) => apply(frame, p)).map((p) => `${fmt(p.x)} ${fmt(p.y)}`).join("L")}Z`;
346
346
  }
@@ -357,7 +357,7 @@ function hitVectorGradientAnnotator(a, p) {
357
357
  const near2 = (q, r) => !!q && Math.hypot(q.x - p.x, q.y - p.y) <= r;
358
358
  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
359
  for (const m of a.midpoints) if (near2(m, MIDPOINT_HIT)) return { kind: "midpoint", index: m.index };
360
- const centred = _chunkXCXQDPIDcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
360
+ const centred = _chunkFKONE6AOcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
361
361
  if (near2(a.end, HANDLE_HIT)) return { kind: "handle", handle: centred ? "radius" : "end" };
362
362
  if (a.focal && near2(a.focal, HANDLE_HIT) && !near2(a.start, 1)) return { kind: "handle", handle: "focal" };
363
363
  if (near2(a.start, HANDLE_HIT)) return { kind: "handle", handle: "start" };
@@ -393,8 +393,8 @@ function paintColors(p) {
393
393
  return [];
394
394
  }
395
395
  function vectorBlendColorDistance(a, b) {
396
- const pa = _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, a)[0];
397
- const pb = _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, b)[0];
396
+ const pa = _chunkFKONE6AOcjs.collectPathNodes.call(void 0, a)[0];
397
+ const pb = _chunkFKONE6AOcjs.collectPathNodes.call(void 0, b)[0];
398
398
  if (!pa || !pb) return 0;
399
399
  let d = 0;
400
400
  for (const key of ["fill", "stroke"]) {
@@ -412,7 +412,7 @@ function vectorBlendColorDistance(a, b) {
412
412
  return d;
413
413
  }
414
414
  var centreOf = (n) => {
415
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n);
415
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n);
416
416
  return b ? [b.x + b.width / 2, b.y + b.height / 2] : [0, 0];
417
417
  };
418
418
  function vectorBlendStepCount(a, b, options, length) {
@@ -424,8 +424,8 @@ function vectorBlendStepCount(a, b, options, length) {
424
424
  if (o.spacing === "smoothColor") {
425
425
  const cd = vectorBlendColorDistance(a, b);
426
426
  if (cd > 1 / 255) return Math.min(VECTOR_BLEND_MAX_SMOOTH_STEPS, Math.max(1, Math.ceil(cd * 255 / 2)));
427
- const ba = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, a);
428
- const bb = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, b);
427
+ const ba = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, a);
428
+ const bb = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, b);
429
429
  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
430
  return Math.min(VECTOR_BLEND_MAX_SMOOTH_STEPS, Math.max(1, Math.ceil(dist3 / 2)));
431
431
  }
@@ -440,9 +440,9 @@ function vectorBlendRail(sp) {
440
440
  pts.push(p);
441
441
  angles.push(Math.atan2(tangent[1], tangent[0]));
442
442
  };
443
- const count = _chunkXCXQDPIDcjs.subpathSegmentCount.call(void 0, sp);
443
+ const count = _chunkFKONE6AOcjs.subpathSegmentCount.call(void 0, sp);
444
444
  for (let i = 0; i < count; i++) {
445
- const seg = _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, i);
445
+ const seg = _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, i);
446
446
  const samples = seg.length === 2 ? 1 : 32;
447
447
  if (i === 0) push(seg[0], _chunkO2UH7LZEcjs.segmentTangent.call(void 0, seg, 0));
448
448
  for (let k = 1; k <= samples; k++) push(_chunkO2UH7LZEcjs.segmentPoint.call(void 0, seg, k / samples), _chunkO2UH7LZEcjs.segmentTangent.call(void 0, seg, k / samples));
@@ -500,7 +500,7 @@ function morphFor(a, b, blend) {
500
500
  let byKey = inner.get(b);
501
501
  if (!byKey) inner.set(b, byKey = /* @__PURE__ */ new Map());
502
502
  let morph = byKey.get(key);
503
- if (!morph) byKey.set(key, morph = _chunkXCXQDPIDcjs.createVectorMorph.call(void 0, a, b, { linear: blend.linear, starts }));
503
+ if (!morph) byKey.set(key, morph = _chunkFKONE6AOcjs.createVectorMorph.call(void 0, a, b, { linear: blend.linear, starts }));
504
504
  return morph;
505
505
  }
506
506
  var wrapAngle = (a) => Math.atan2(Math.sin(a), Math.cos(a));
@@ -533,16 +533,16 @@ function generateVectorBlendChildren(group) {
533
533
  const p = vectorBlendRailAt(spine.rail, s0 + (s1 - s0) * t);
534
534
  const dx = p.point[0] - (p0.point[0] + (p1.point[0] - p0.point[0]) * t);
535
535
  const dy = p.point[1] - (p0.point[1] + (p1.point[1] - p0.point[1]) * t);
536
- let m = Math.hypot(dx, dy) > 1e-9 ? _chunkXCXQDPIDcjs.translateMatrix.call(void 0, dx, dy) : _chunkXCXQDPIDcjs.IDENTITY_MATRIX;
536
+ let m = Math.hypot(dx, dy) > 1e-9 ? _chunkFKONE6AOcjs.translateMatrix.call(void 0, dx, dy) : _chunkFKONE6AOcjs.IDENTITY_MATRIX;
537
537
  if (blend.orientToSpine) {
538
538
  const turn = wrapAngle(p.angle - (p0.angle + wrapAngle(p1.angle - p0.angle) * t));
539
539
  if (Math.abs(turn) > 1e-9) {
540
540
  const c = centreOf(step);
541
541
  const origin = { x: c[0] + m[4], y: c[1] + m[5] };
542
- m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, m, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, turn * 180 / Math.PI, origin));
542
+ m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, m, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, turn * 180 / Math.PI, origin));
543
543
  }
544
544
  }
545
- if (m !== _chunkXCXQDPIDcjs.IDENTITY_MATRIX) step = _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, step, m);
545
+ if (m !== _chunkFKONE6AOcjs.IDENTITY_MATRIX) step = _chunkFKONE6AOcjs.transformVectorNode.call(void 0, step, m);
546
546
  }
547
547
  out.push(asStep(step, `${group.id}~${++counter}`));
548
548
  }
@@ -589,13 +589,13 @@ function expandVectorBlend(group, newId) {
589
589
  return { ...rest, children: group.children.map((c) => c.blendStep ? plain(c, newId) : c) };
590
590
  }
591
591
  function releaseVectorBlend(group, newId) {
592
- const m = _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, group);
592
+ const m = _chunkFKONE6AOcjs.nodeMatrix.call(void 0, group);
593
593
  const opacity = group.opacity;
594
- const keys = vectorBlendKeys(group).map((c) => group.transform ? _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c);
594
+ const keys = vectorBlendKeys(group).map((c) => group.transform ? _chunkFKONE6AOcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c);
595
595
  const spine = _optionalChain([group, 'access', _13 => _13.blend, 'optionalAccess', _14 => _14.spine]);
596
596
  if (!spine || spine.anchors.length < 2) return keys;
597
597
  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 ? _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, path, m) : path];
598
+ return [...keys, group.transform ? _chunkFKONE6AOcjs.transformVectorNode.call(void 0, path, m) : path];
599
599
  }
600
600
 
601
601
  // src/vector/perspective.ts
@@ -705,7 +705,7 @@ function vectorDistortQuad(b, handle, d, mode = "distort") {
705
705
  if (side) for (const k of side) q[k] = { x: q[k].x + d.x, y: q[k].y + d.y };
706
706
  return q;
707
707
  }
708
- var about = (o, m) => _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, [1, 0, 0, 1, -o.x, -o.y], m), [1, 0, 0, 1, o.x, o.y]);
708
+ var about = (o, m) => _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, [1, 0, 0, 1, -o.x, -o.y], m), [1, 0, 0, 1, o.x, o.y]);
709
709
  function vectorShearForSide(b, handle, d, fromCenter = false) {
710
710
  const center = { x: b.x + b.width / 2, y: b.y + b.height / 2 };
711
711
  if (handle === "n" || handle === "s") {
@@ -729,16 +729,16 @@ function mapEffects(node, f) {
729
729
  if (!_optionalChain([node, 'access', _15 => _15.effects, 'optionalAccess', _16 => _16.length])) return void 0;
730
730
  return node.effects.map((e) => {
731
731
  if (e.type !== "envelope") return e;
732
- if (e.params.style === "mesh") return e.params.mesh ? { ...e, params: { ...e.params, mesh: _chunkXCXQDPIDcjs.mapVectorMeshPoints.call(void 0, e.params.mesh, f) } } : e;
733
- const bounds = _chunkXCXQDPIDcjs.vectorEffectInputBounds.call(void 0, node, e.id);
734
- if (!bounds || !_chunkXCXQDPIDcjs.vectorEnvelopeMap.call(void 0, e.params, bounds)) return e;
735
- return { ...e, params: { ...e.params, style: "mesh", mesh: _chunkXCXQDPIDcjs.mapVectorMeshPoints.call(void 0, _chunkXCXQDPIDcjs.vectorEnvelopeMesh.call(void 0, e.params, bounds), f) } };
732
+ if (e.params.style === "mesh") return e.params.mesh ? { ...e, params: { ...e.params, mesh: _chunkFKONE6AOcjs.mapVectorMeshPoints.call(void 0, e.params.mesh, f) } } : e;
733
+ const bounds = _chunkFKONE6AOcjs.vectorEffectInputBounds.call(void 0, node, e.id);
734
+ if (!bounds || !_chunkFKONE6AOcjs.vectorEnvelopeMap.call(void 0, e.params, bounds)) return e;
735
+ return { ...e, params: { ...e.params, style: "mesh", mesh: _chunkFKONE6AOcjs.mapVectorMeshPoints.call(void 0, _chunkFKONE6AOcjs.vectorEnvelopeMesh.call(void 0, e.params, bounds), f) } };
736
736
  });
737
737
  }
738
738
  function distortVectorNode(node, parentToDoc, f, tolerance = VECTOR_DISTORT_TOLERANCE) {
739
- const toDoc = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, node), parentToDoc);
740
- const inv = _chunkXCXQDPIDcjs.invertMatrix.call(void 0, toDoc);
741
- const local = (p) => _chunkXCXQDPIDcjs.applyMatrix.call(void 0, inv, f(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, p)));
739
+ const toDoc = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, node), parentToDoc);
740
+ const inv = _chunkFKONE6AOcjs.invertMatrix.call(void 0, toDoc);
741
+ const local = (p) => _chunkFKONE6AOcjs.applyMatrix.call(void 0, inv, f(_chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, p)));
742
742
  const effects = mapEffects(node, local);
743
743
  if (node.type === "group") {
744
744
  const group = node;
@@ -748,16 +748,16 @@ function distortVectorNode(node, parentToDoc, f, tolerance = VECTOR_DISTORT_TOLE
748
748
  ...group,
749
749
  children,
750
750
  ...effects ? { effects } : {},
751
- ...spine ? { blend: { ...group.blend, spine: _chunkXCXQDPIDcjs.mapVectorSubpaths.call(void 0, [spine], local, tolerance)[0] } } : {}
751
+ ...spine ? { blend: { ...group.blend, spine: _chunkFKONE6AOcjs.mapVectorSubpaths.call(void 0, [spine], local, tolerance)[0] } } : {}
752
752
  };
753
753
  }
754
754
  const path = node;
755
755
  return {
756
756
  ...path,
757
757
  ...effects ? { effects } : {},
758
- ...path.fill !== void 0 ? { fill: _chunkXCXQDPIDcjs.mapVectorPaint.call(void 0, path.fill, local) } : {},
759
- ...path.stroke !== void 0 ? { stroke: _chunkXCXQDPIDcjs.mapVectorPaint.call(void 0, path.stroke, local) } : {},
760
- subpaths: _chunkXCXQDPIDcjs.mapVectorSubpaths.call(void 0, path.subpaths, local, tolerance)
758
+ ...path.fill !== void 0 ? { fill: _chunkFKONE6AOcjs.mapVectorPaint.call(void 0, path.fill, local) } : {},
759
+ ...path.stroke !== void 0 ? { stroke: _chunkFKONE6AOcjs.mapVectorPaint.call(void 0, path.stroke, local) } : {},
760
+ subpaths: _chunkFKONE6AOcjs.mapVectorSubpaths.call(void 0, path.subpaths, local, tolerance)
761
761
  };
762
762
  }
763
763
 
@@ -818,11 +818,11 @@ var LABELS = {
818
818
  };
819
819
  var fmtLength = (n) => String(Math.round(n * 100) / 100);
820
820
  function nodeFrame(node, parent, aabb) {
821
- const angle = _chunkXCXQDPIDcjs.matrixRotation.call(void 0, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, node), parent));
822
- const b = angle ? _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, node, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, parent, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -angle))) : aabb !== void 0 ? aabb : _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, node, parent);
821
+ const angle = _chunkFKONE6AOcjs.matrixRotation.call(void 0, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, node), parent));
822
+ const b = angle ? _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, node, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, parent, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -angle))) : aabb !== void 0 ? aabb : _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, node, parent);
823
823
  if (!b) return null;
824
824
  const c = { x: b.x + b.width / 2, y: b.y + b.height / 2 };
825
- return { width: b.width, height: b.height, centre: angle ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, angle), c) : c };
825
+ return { width: b.width, height: b.height, centre: angle ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, angle), c) : c };
826
826
  }
827
827
  function contains(node, ids) {
828
828
  if (ids.has(node.id)) return true;
@@ -894,13 +894,13 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
894
894
  let segmentBudget = segments ? BUDGET : 0;
895
895
  const visit = (list, parent) => {
896
896
  for (const n of list) {
897
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent);
897
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent);
898
898
  if (n.type === "group") visit(n.children, m);
899
899
  else if (ids.has(n.id) && n.visible !== false) {
900
900
  n.subpaths.forEach((sp, s) => {
901
901
  sp.anchors.forEach((a, i) => {
902
902
  if (anchors <= 0 || moving(n.id, s, i)) return;
903
- this.pushAnchor(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, a));
903
+ this.pushAnchor(_chunkFKONE6AOcjs.applyMatrix.call(void 0, m, a));
904
904
  anchors--;
905
905
  });
906
906
  segmentBudget = this.pushSegments(sp, m, (i) => moving(n.id, s, i), segmentBudget);
@@ -908,7 +908,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
908
908
  }
909
909
  }
910
910
  };
911
- visit(doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
911
+ visit(doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
912
912
  }
913
913
  pushAnchor(p) {
914
914
  this.points.push({ p, kind: "anchor" });
@@ -918,10 +918,10 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
918
918
  /** The segments of `sp` (mapped by `m`) that stay put while the anchors `moving` accepts move. */
919
919
  pushSegments(sp, m, moving, budget) {
920
920
  const n = sp.anchors.length;
921
- const count = _chunkXCXQDPIDcjs.subpathSegmentCount.call(void 0, sp);
921
+ const count = _chunkFKONE6AOcjs.subpathSegmentCount.call(void 0, sp);
922
922
  for (let i = 0; i < count && budget > 0; i++) {
923
923
  if (moving(i) || moving((i + 1) % n)) continue;
924
- const seg = _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, i).map((q) => toPoint(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, toVec(q))));
924
+ const seg = _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, i).map((q) => toPoint(_chunkFKONE6AOcjs.applyMatrix.call(void 0, m, toVec(q))));
925
925
  let minX = Infinity;
926
926
  let minY = Infinity;
927
927
  let maxX = -Infinity;
@@ -976,8 +976,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
976
976
  const visit = (list, parent) => {
977
977
  for (const stored of list) {
978
978
  if (exclude.has(stored.id) || stored.visible === false) continue;
979
- const n = contains(stored, exclude) ? stored : _chunkXCXQDPIDcjs.expandVectorAppearance.call(void 0, stored);
980
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent);
979
+ const n = contains(stored, exclude) ? stored : _chunkFKONE6AOcjs.expandVectorAppearance.call(void 0, stored);
980
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent);
981
981
  if (n.type === "group") {
982
982
  visit(n.children, m);
983
983
  continue;
@@ -986,32 +986,32 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
986
986
  for (const sp of n.subpaths) {
987
987
  for (const a of sp.anchors) {
988
988
  if (anchors-- <= 0) break;
989
- const p = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, a);
989
+ const p = _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, a);
990
990
  if (gather === "drawing") self.pushAnchor(p);
991
991
  else self.points.push({ p, kind: "anchor" });
992
992
  }
993
993
  if (gather !== "bounds") segments = self.pushSegments(sp, m, () => false, segments);
994
994
  }
995
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n, parent);
995
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n, parent);
996
996
  const f = nodeFrame(n, parent, b);
997
997
  if (b) self.pushRect(b, "edge", _nullishCoalesce(_optionalChain([f, 'optionalAccess', _24 => _24.centre]), () => ( null)));
998
998
  }
999
999
  };
1000
- visit(doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
1000
+ visit(doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
1001
1001
  const objects = (list, parent) => {
1002
1002
  for (const n of list) {
1003
1003
  if (exclude.has(n.id) || n.visible === false || self.boxes.length >= BUDGET) continue;
1004
1004
  if (n.type === "group" && contains(n, exclude)) {
1005
- objects(n.children, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent));
1005
+ objects(n.children, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent));
1006
1006
  continue;
1007
1007
  }
1008
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n, parent);
1008
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n, parent);
1009
1009
  if (b) self.boxes.push(b);
1010
1010
  const f = nodeFrame(n, parent, b);
1011
1011
  if (f) self.sizes.push(f.width, f.height);
1012
1012
  }
1013
1013
  };
1014
- objects(doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
1014
+ objects(doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
1015
1015
  return sort ? self.index() : self;
1016
1016
  }
1017
1017
  // -------------------------------------------------------------------------
@@ -1292,8 +1292,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1292
1292
  * may match another object's width or height instead.
1293
1293
  */
1294
1294
  snapScale(frame, handle, sx, sy, mods, tol) {
1295
- const toDoc = frame.angle ? _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, frame.angle) : _chunkXCXQDPIDcjs.IDENTITY_MATRIX;
1296
- const toLocal = frame.angle ? _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -frame.angle) : _chunkXCXQDPIDcjs.IDENTITY_MATRIX;
1295
+ const toDoc = frame.angle ? _chunkFKONE6AOcjs.rotateMatrix.call(void 0, frame.angle) : _chunkFKONE6AOcjs.IDENTITY_MATRIX;
1296
+ const toLocal = frame.angle ? _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -frame.angle) : _chunkFKONE6AOcjs.IDENTITY_MATRIX;
1297
1297
  const corner = handle.length === 2;
1298
1298
  const proportional = !!mods.shift;
1299
1299
  const centre = { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 };
@@ -1310,7 +1310,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1310
1310
  let ny = sy;
1311
1311
  let snap = { hx: null, hy: null, on: null };
1312
1312
  if (corner && !proportional) {
1313
- const p = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * sx, y: origin.y + d0.y * sy });
1313
+ const p = _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * sx, y: origin.y + d0.y * sy });
1314
1314
  const hx = nearest(p.x, this.xs);
1315
1315
  const hy = nearest(p.y, this.ys);
1316
1316
  const on = this.nearestPoint(p, tol);
@@ -1321,7 +1321,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1321
1321
  tries.push({ tx: null, ty: _nullishCoalesce(_optionalChain([hy, 'optionalAccess', _37 => _37.v]), () => ( null)), s: { hx: null, hy, on: null } });
1322
1322
  for (const { tx, ty, s } of tries) {
1323
1323
  if (tx === null && ty === null) continue;
1324
- const q = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toLocal, { x: _nullishCoalesce(tx, () => ( p.x)), y: _nullishCoalesce(ty, () => ( p.y)) });
1324
+ const q = _chunkFKONE6AOcjs.applyMatrix.call(void 0, toLocal, { x: _nullishCoalesce(tx, () => ( p.x)), y: _nullishCoalesce(ty, () => ( p.y)) });
1325
1325
  let cx = (q.x - origin.x) / d0.x;
1326
1326
  let cy = (q.y - origin.y) / d0.y;
1327
1327
  if (!frame.angle) {
@@ -1355,8 +1355,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1355
1355
  for (const h of [handle, ...ends]) {
1356
1356
  const hv = handlePos(h, frame);
1357
1357
  const v = { x: hv.x - origin.x, y: hv.y - origin.y };
1358
- const base = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + c.x * v.x, y: origin.y + c.y * v.y });
1359
- const dir = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, { x: e.x * v.x, y: e.y * v.y });
1358
+ const base = _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + c.x * v.x, y: origin.y + c.y * v.y });
1359
+ const dir = _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, { x: e.x * v.x, y: e.y * v.y });
1360
1360
  const p = { x: base.x + dir.x * s0, y: base.y + dir.y * s0 };
1361
1361
  const l2 = dir.x * dir.x + dir.y * dir.y;
1362
1362
  const on = l2 > 1e-18 ? this.nearestPoint(p, tol) : null;
@@ -1378,7 +1378,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1378
1378
  }
1379
1379
  }
1380
1380
  const out = { sx: nx, sy: ny, snapped: false, lines: [], labels: [] };
1381
- const handleAt = () => _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * out.sx, y: origin.y + d0.y * out.sy });
1381
+ const handleAt = () => _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, { x: origin.x + d0.x * out.sx, y: origin.y + d0.y * out.sy });
1382
1382
  if (snap.on) {
1383
1383
  out.snapped = true;
1384
1384
  out.labels.push(this.label(snap.on.p, snap.on.kind));
@@ -1413,7 +1413,7 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1413
1413
  { x: box.x1, y: box.y0 },
1414
1414
  { x: box.x1, y: box.y1 },
1415
1415
  { x: box.x0, y: box.y1 }
1416
- ].map((q) => _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, q));
1416
+ ].map((q) => _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, q));
1417
1417
  const pminY = Math.min(...page.map((q) => q.y));
1418
1418
  const pmaxY = Math.max(...page.map((q) => q.y));
1419
1419
  const pminX = Math.min(...page.map((q) => q.x));
@@ -1428,8 +1428,8 @@ var VectorSnapTargets = (_class = class _VectorSnapTargets {
1428
1428
  out.snapped = true;
1429
1429
  const off = tol * 2;
1430
1430
  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 = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, a);
1432
- const pb = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toDoc, b);
1431
+ const pa = _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, a);
1432
+ const pb = _chunkFKONE6AOcjs.applyMatrix.call(void 0, toDoc, b);
1433
1433
  out.lines.push(line("size", pa, pb));
1434
1434
  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
1435
  }
@@ -1520,12 +1520,12 @@ var unit = (x, y) => {
1520
1520
  return l > 1e-12 && Number.isFinite(l) ? [x / l, y / l] : null;
1521
1521
  };
1522
1522
  function cubicOf(sp, i) {
1523
- const s = _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, i);
1523
+ const s = _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, i);
1524
1524
  if (s.length === 4) return s;
1525
1525
  const [a, b] = s;
1526
1526
  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
1527
  }
1528
- var isLine = (sp, i) => _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, i).length === 2;
1528
+ var isLine = (sp, i) => _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, i).length === 2;
1529
1529
  function startTangent(c) {
1530
1530
  for (let k = 1; k < 4; k++) {
1531
1531
  const u = unit(c[k][0] - c[0][0], c[k][1] - c[0][1]);
@@ -1545,10 +1545,10 @@ function sample(c, n, out, withStart) {
1545
1545
  }
1546
1546
  var onAnchor = (a, h) => !h || Math.abs(h.x - a.x) < EPS && Math.abs(h.y - a.y) < EPS;
1547
1547
  function tidy(a, keepType = true) {
1548
- const next = _chunkXCXQDPIDcjs.cloneAnchor.call(void 0, a);
1548
+ const next = _chunkFKONE6AOcjs.cloneAnchor.call(void 0, a);
1549
1549
  if (onAnchor(next, next.in)) delete next.in;
1550
1550
  if (onAnchor(next, next.out)) delete next.out;
1551
- const shown = _chunkXCXQDPIDcjs.inferAnchorType.call(void 0, next);
1551
+ const shown = _chunkFKONE6AOcjs.inferAnchorType.call(void 0, next);
1552
1552
  const type = keepType && a.type ? a.type === "symmetric" && shown !== "symmetric" ? shown === "corner" ? "corner" : "smooth" : a.type === "smooth" && shown === "corner" ? "corner" : a.type : shown;
1553
1553
  if (type === "corner") delete next.type;
1554
1554
  else next.type = type;
@@ -1592,7 +1592,7 @@ function fitAcross(pts, N, t0, t1) {
1592
1592
  return goldenMin(fit, 0, 1);
1593
1593
  }
1594
1594
  function removeAnchorKeepingShape(sp, index) {
1595
- const anchors = sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor);
1595
+ const anchors = sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor);
1596
1596
  const n = anchors.length;
1597
1597
  if (index < 0 || index >= n) return { anchors, closed: sp.closed };
1598
1598
  if ((sp.closed || index > 0 && index < n - 1) && n >= 3) {
@@ -1626,12 +1626,12 @@ function removeAnchorKeepingShape(sp, index) {
1626
1626
  }
1627
1627
  function removeAnchorsKeepingShape(sp, indices) {
1628
1628
  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(_chunkXCXQDPIDcjs.cloneAnchor), closed: sp.closed });
1629
+ return order.reduce((acc, i) => removeAnchorKeepingShape(acc, i), { anchors: sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor), closed: sp.closed });
1630
1630
  }
1631
1631
  function bendSegment(sp, segment, t, p) {
1632
- const anchors = sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor);
1632
+ const anchors = sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor);
1633
1633
  const n = anchors.length;
1634
- if (segment < 0 || segment >= _chunkXCXQDPIDcjs.subpathSegmentCount.call(void 0, sp) || !Number.isFinite(t) || !Number.isFinite(p.x) || !Number.isFinite(p.y)) return { anchors, closed: sp.closed };
1634
+ if (segment < 0 || segment >= _chunkFKONE6AOcjs.subpathSegmentCount.call(void 0, sp) || !Number.isFinite(t) || !Number.isFinite(p.x) || !Number.isFinite(p.y)) return { anchors, closed: sp.closed };
1635
1635
  const tc = Math.min(0.95, Math.max(0.05, t));
1636
1636
  const ia = segment;
1637
1637
  const ib = (segment + 1) % n;
@@ -1642,16 +1642,16 @@ function bendSegment(sp, segment, t, p) {
1642
1642
  const oy = (p.y - (a.y + (b.y - a.y) * tc)) / k;
1643
1643
  const c1 = { x: a.x + (b.x - a.x) / 3 + ox, y: a.y + (b.y - a.y) / 3 + oy };
1644
1644
  const c2 = { x: b.x + (a.x - b.x) / 3 + ox, y: b.y + (a.y - b.y) / 3 + oy };
1645
- anchors[ia] = _chunkXCXQDPIDcjs.moveAnchorHandle.call(void 0, a, "out", c1);
1646
- anchors[ib] = _chunkXCXQDPIDcjs.moveAnchorHandle.call(void 0, b, "in", c2);
1645
+ anchors[ia] = _chunkFKONE6AOcjs.moveAnchorHandle.call(void 0, a, "out", c1);
1646
+ anchors[ib] = _chunkFKONE6AOcjs.moveAnchorHandle.call(void 0, b, "in", c2);
1647
1647
  return { anchors, closed: sp.closed };
1648
1648
  }
1649
1649
  function subpathPointAt(sp, segment, t) {
1650
- const [x, y] = _chunkO2UH7LZEcjs.segmentPoint.call(void 0, _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, segment), t);
1650
+ const [x, y] = _chunkO2UH7LZEcjs.segmentPoint.call(void 0, _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, segment), t);
1651
1651
  return { x, y };
1652
1652
  }
1653
1653
  function curvatureMoveAnchor(sp, index, q) {
1654
- const anchors = sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor);
1654
+ const anchors = sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor);
1655
1655
  const a = sp.anchors[index];
1656
1656
  if (!a) return { anchors, closed: sp.closed };
1657
1657
  const own = [
@@ -1696,7 +1696,7 @@ function curvatureMoveAnchor(sp, index, q) {
1696
1696
  function cutSubpathAt(sp, at) {
1697
1697
  const n = sp.anchors.length;
1698
1698
  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(_chunkXCXQDPIDcjs.cloneAnchor), closed: sp.closed }];
1699
+ if (!cuts.length || n < 2) return [{ anchors: sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor), closed: sp.closed }];
1700
1700
  const first = cuts[0];
1701
1701
  const run = sp.closed ? Array.from({ length: n + 1 }, (_, i) => sp.anchors[(first + i) % n]) : sp.anchors;
1702
1702
  const cutSet = new Set(sp.closed ? [...cuts.map((c) => (c - first + n) % n), n] : cuts);
@@ -1704,7 +1704,7 @@ function cutSubpathAt(sp, at) {
1704
1704
  let cur = [];
1705
1705
  run.forEach((a, i) => {
1706
1706
  if (!cutSet.has(i)) {
1707
- cur.push(_chunkXCXQDPIDcjs.cloneAnchor.call(void 0, a));
1707
+ cur.push(_chunkFKONE6AOcjs.cloneAnchor.call(void 0, a));
1708
1708
  return;
1709
1709
  }
1710
1710
  if (cur.length) {
@@ -1719,10 +1719,10 @@ function cutSubpathAt(sp, at) {
1719
1719
  }
1720
1720
  function splitSubpathAt(sp, segment, t, endTolerance = 1e-6) {
1721
1721
  const n = sp.anchors.length;
1722
- if (segment < 0 || segment >= _chunkXCXQDPIDcjs.subpathSegmentCount.call(void 0, sp)) return [{ anchors: sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor), closed: sp.closed }];
1722
+ if (segment < 0 || segment >= _chunkFKONE6AOcjs.subpathSegmentCount.call(void 0, sp)) return [{ anchors: sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor), closed: sp.closed }];
1723
1723
  if (t <= endTolerance) return cutSubpathAt(sp, [segment]);
1724
1724
  if (t >= 1 - endTolerance) return cutSubpathAt(sp, [(segment + 1) % n]);
1725
- const { subpath, index } = _chunkXCXQDPIDcjs.insertAnchor.call(void 0, sp, segment, t);
1725
+ const { subpath, index } = _chunkFKONE6AOcjs.insertAnchor.call(void 0, sp, segment, t);
1726
1726
  return cutSubpathAt(subpath, [index]);
1727
1727
  }
1728
1728
  var endOf = (sp, last) => sp.anchors[last ? sp.anchors.length - 1 : 0];
@@ -1744,7 +1744,7 @@ function joinSubpaths(subpaths, tolerance) {
1744
1744
  const closed = [];
1745
1745
  let open = [];
1746
1746
  for (const sp of subpaths) {
1747
- const copy = { anchors: sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor), closed: sp.closed };
1747
+ const copy = { anchors: sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor), closed: sp.closed };
1748
1748
  if (sp.closed || sp.anchors.length < 2) {
1749
1749
  if (sp.anchors.length) closed.push(copy);
1750
1750
  } else open.push(copy);
@@ -1799,7 +1799,7 @@ function smoothSubpath(sp, amount = 1, only) {
1799
1799
  const t = Math.min(1, Math.max(0, amount));
1800
1800
  const orig = sp.anchors;
1801
1801
  const n = orig.length;
1802
- const anchors = orig.map(_chunkXCXQDPIDcjs.cloneAnchor);
1802
+ const anchors = orig.map(_chunkFKONE6AOcjs.cloneAnchor);
1803
1803
  if (n < 3 || t === 0) return { anchors, closed: sp.closed };
1804
1804
  for (let i = 0; i < n; i++) {
1805
1805
  if (!sp.closed && (i === 0 || i === n - 1)) continue;
@@ -1828,8 +1828,8 @@ function smoothSubpath(sp, amount = 1, only) {
1828
1828
  }
1829
1829
  function segsOf(sp) {
1830
1830
  const out = [];
1831
- for (let i = 0; i < _chunkXCXQDPIDcjs.subpathSegmentCount.call(void 0, sp); i++) {
1832
- const s = _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, i);
1831
+ for (let i = 0; i < _chunkFKONE6AOcjs.subpathSegmentCount.call(void 0, sp); i++) {
1832
+ const s = _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, i);
1833
1833
  out.push(s.length === 2 ? { c: s, line: true } : { c: s, line: false });
1834
1834
  }
1835
1835
  return out;
@@ -1886,7 +1886,7 @@ function removeRedundantPoints(sp, tolerance) {
1886
1886
  const tol = Math.max(tolerance, 1e-9);
1887
1887
  const types = new Map(sp.anchors.filter((a) => a.type).map((a) => [`${a.x},${a.y}`, a.type]));
1888
1888
  const segs = segsOf(sp).filter((s) => !isZeroSeg(s));
1889
- if (!segs.length) return { anchors: sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor), closed: sp.closed };
1889
+ if (!segs.length) return { anchors: sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor), closed: sp.closed };
1890
1890
  const minSegs = sp.closed ? 2 : 1;
1891
1891
  let changed = true;
1892
1892
  while (changed && segs.length > minSegs) {
@@ -1904,7 +1904,7 @@ function removeRedundantPoints(sp, tolerance) {
1904
1904
  break;
1905
1905
  }
1906
1906
  }
1907
- return _nullishCoalesce(segsToSubpath(segs, sp.closed, types), () => ( { anchors: sp.anchors.map(_chunkXCXQDPIDcjs.cloneAnchor), closed: sp.closed }));
1907
+ return _nullishCoalesce(segsToSubpath(segs, sp.closed, types), () => ( { anchors: sp.anchors.map(_chunkFKONE6AOcjs.cloneAnchor), closed: sp.closed }));
1908
1908
  }
1909
1909
 
1910
1910
  // src/vector/pathCut.ts
@@ -2143,14 +2143,14 @@ function eraseFromOutline(sp, region) {
2143
2143
  const regionSegs = _chunkO2UH7LZEcjs.pathToContours.call(void 0, region).flatMap((c) => _chunkO2UH7LZEcjs.closeContour.call(void 0, c, true));
2144
2144
  if (!regionSegs.length) return null;
2145
2145
  const rb = _chunkO2UH7LZEcjs.bezierPathBounds.call(void 0, region);
2146
- const count = _chunkXCXQDPIDcjs.subpathSegmentCount.call(void 0, sp);
2146
+ const count = _chunkFKONE6AOcjs.subpathSegmentCount.call(void 0, sp);
2147
2147
  if (!rb || count === 0) return null;
2148
2148
  const removed = (p) => _chunkO2UH7LZEcjs.pointInBezierPath.call(void 0, region, p, "nonzero");
2149
2149
  const runs = [];
2150
2150
  let cur = [];
2151
2151
  let any = false;
2152
2152
  for (let i = 0; i < count; i++) {
2153
- const seg = _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, i);
2153
+ const seg = _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, i);
2154
2154
  const sb = _chunkO2UH7LZEcjs.segmentBounds.call(void 0, seg);
2155
2155
  const ts = [0, 1];
2156
2156
  if (!(sb.maxX < rb.minX || sb.minX > rb.maxX || sb.maxY < rb.minY || sb.minY > rb.maxY)) {
@@ -2184,7 +2184,7 @@ function eraseFromOutline(sp, region) {
2184
2184
  for (const run of runs) {
2185
2185
  const anchors = [];
2186
2186
  for (const { seg, t0, t1 } of run) {
2187
- const c = _chunkO2UH7LZEcjs.subSegment.call(void 0, _chunkXCXQDPIDcjs.subpathSegment.call(void 0, sp, seg), t0, t1);
2187
+ const c = _chunkO2UH7LZEcjs.subSegment.call(void 0, _chunkFKONE6AOcjs.subpathSegment.call(void 0, sp, seg), t0, t1);
2188
2188
  const line2 = c.length === 2;
2189
2189
  const start = c[0];
2190
2190
  const end = c[c.length - 1];
@@ -2196,7 +2196,7 @@ function eraseFromOutline(sp, region) {
2196
2196
  }
2197
2197
  if (anchors.length < 2) continue;
2198
2198
  for (const a of anchors) {
2199
- const type = _chunkXCXQDPIDcjs.inferAnchorType.call(void 0, a);
2199
+ const type = _chunkFKONE6AOcjs.inferAnchorType.call(void 0, a);
2200
2200
  if (type !== "corner") a.type = type;
2201
2201
  }
2202
2202
  out.push({ anchors, closed: false });
@@ -2478,22 +2478,22 @@ function vectorPathEntries(doc, roots, options = {}) {
2478
2478
  const out = [];
2479
2479
  const visit = (stored, parent, inside) => {
2480
2480
  if (stored.visible === false || stored.locked && !options.locked) return;
2481
- const node = options.expand === false ? stored : _chunkXCXQDPIDcjs.expandVectorAppearance.call(void 0, stored);
2481
+ const node = options.expand === false ? stored : _chunkFKONE6AOcjs.expandVectorAppearance.call(void 0, stored);
2482
2482
  const picked = inside || roots === null || roots.includes(node.id);
2483
2483
  if (node.type === "group") {
2484
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, node), parent);
2484
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, node), parent);
2485
2485
  for (const c of node.children) visit(c, m, picked);
2486
2486
  } else if (picked) out.push({ node, parent });
2487
2487
  };
2488
- for (const n of doc.nodes) visit(n, _chunkXCXQDPIDcjs.IDENTITY_MATRIX, false);
2488
+ for (const n of doc.nodes) visit(n, _chunkFKONE6AOcjs.IDENTITY_MATRIX, false);
2489
2489
  return out;
2490
2490
  }
2491
2491
  var usable = (sp) => sp.anchors.length > 1;
2492
2492
  function worldOf(entry, subpaths) {
2493
- return _chunkXCXQDPIDcjs.vectorPathWorldBezier.call(void 0, { ...entry.node, subpaths }, entry.parent);
2493
+ return _chunkFKONE6AOcjs.vectorPathWorldBezier.call(void 0, { ...entry.node, subpaths }, entry.parent);
2494
2494
  }
2495
2495
  function subpathEnclosesArea(sp) {
2496
- const contour = _chunkO2UH7LZEcjs.pathToContours.call(void 0, _chunkXCXQDPIDcjs.subpathsToBezier.call(void 0, [{ ...sp, closed: true }]))[0];
2496
+ const contour = _chunkO2UH7LZEcjs.pathToContours.call(void 0, _chunkFKONE6AOcjs.subpathsToBezier.call(void 0, [{ ...sp, closed: true }]))[0];
2497
2497
  if (!contour) return false;
2498
2498
  const segs = _chunkO2UH7LZEcjs.closeContour.call(void 0, contour, true);
2499
2499
  const b = _chunkO2UH7LZEcjs.bezierPathBounds.call(void 0, _chunkO2UH7LZEcjs.contoursToPath.call(void 0, [{ segments: segs, closed: true }]));
@@ -2508,11 +2508,11 @@ function vectorPathfinderShape(entry, op) {
2508
2508
  const subpaths = node.subpaths.filter(usable);
2509
2509
  const closed = subpaths.map((s) => ({ ...s, closed: true }));
2510
2510
  const fillRule = _nullishCoalesce(node.fillRule, () => ( "nonzero"));
2511
- if (_chunkXCXQDPIDcjs.hasPaint.call(void 0, node.fill)) return { path: worldOf(entry, closed), fillRule, key: `fill:${paintKey(node.fill)}`, paint: "fill" };
2511
+ if (_chunkFKONE6AOcjs.hasPaint.call(void 0, node.fill)) return { path: worldOf(entry, closed), fillRule, key: `fill:${paintKey(node.fill)}`, paint: "fill" };
2512
2512
  const open = subpaths.length > 0 && subpaths.every((s) => !s.closed);
2513
2513
  if (op === "divide" && open) return { path: worldOf(entry, subpaths), line: true, paint: "line" };
2514
- if (_chunkXCXQDPIDcjs.hasPaint.call(void 0, node.stroke) && (_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0) {
2515
- const path = _chunkXCXQDPIDcjs.vectorStrokeOutline.call(void 0, { ...node, subpaths }, entry.parent);
2514
+ if (_chunkFKONE6AOcjs.hasPaint.call(void 0, node.stroke) && (_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0) {
2515
+ const path = _chunkFKONE6AOcjs.vectorStrokeOutline.call(void 0, { ...node, subpaths }, entry.parent);
2516
2516
  return { path, fillRule: "nonzero", key: `fill:${paintKey(node.stroke)}`, paint: "stroke" };
2517
2517
  }
2518
2518
  return { path: worldOf(entry, closed), fillRule, key: "none", paint: "outline" };
@@ -2536,7 +2536,7 @@ function vectorResultStyle(node, paint, edge = false) {
2536
2536
  const base = { ...rest, fillRule: "nonzero" };
2537
2537
  if (edge) {
2538
2538
  for (const k of STROKE_KEYS) delete base[k];
2539
- const stroke = paint === "stroke" || !_chunkXCXQDPIDcjs.hasPaint.call(void 0, node.fill) ? node.stroke : node.fill;
2539
+ const stroke = paint === "stroke" || !_chunkFKONE6AOcjs.hasPaint.call(void 0, node.fill) ? node.stroke : node.fill;
2540
2540
  return { ...base, fill: null, stroke: _nullishCoalesce(stroke, () => ( "#000000")), strokeWidth: _nullishCoalesce(node.strokeWidth, () => ( 1)) };
2541
2541
  }
2542
2542
  if (paint === "stroke") {
@@ -2548,7 +2548,7 @@ function vectorResultStyle(node, paint, edge = false) {
2548
2548
  function vectorShapeBuilderMap(entries) {
2549
2549
  const lines = [];
2550
2550
  const inputs = entries.map((entry) => {
2551
- const filled = _chunkXCXQDPIDcjs.hasPaint.call(void 0, entry.node.fill);
2551
+ const filled = _chunkFKONE6AOcjs.hasPaint.call(void 0, entry.node.fill);
2552
2552
  const subpaths = entry.node.subpaths.filter(usable).map((sp) => !sp.closed && filled && subpathEnclosesArea(sp) ? { ...sp, closed: true } : sp);
2553
2553
  lines.push(!subpaths.some((s) => s.closed));
2554
2554
  return { path: worldOf(entry, subpaths), fillRule: _nullishCoalesce(entry.node.fillRule, () => ( "nonzero")) };
@@ -2653,7 +2653,7 @@ function planShapeBuilder(m, touched, erase) {
2653
2653
  const kept = faces.flatMap((_, f) => sourcesOf[f].includes(i) && !picked.has(f) ? [f] : []);
2654
2654
  rest = kept.length ? m.map.merge(kept) : [];
2655
2655
  } else rest = worldOf(entry, entry.node.subpaths.filter(usable));
2656
- const fillCloses = _chunkXCXQDPIDcjs.hasPaint.call(void 0, entry.node.fill);
2656
+ const fillCloses = _chunkFKONE6AOcjs.hasPaint.call(void 0, entry.node.fill);
2657
2657
  let cut = false;
2658
2658
  for (const piece of cuts) {
2659
2659
  const r = rest.length ? _chunkMLREO6J3cjs.cutOutPiece.call(void 0, rest, piece, fillCloses, m.tolerance) : null;
@@ -2742,18 +2742,18 @@ function getEditablePathIds(state) {
2742
2742
  if (state.tool === "direct") {
2743
2743
  if (state.editingId) ids.add(state.editingId);
2744
2744
  for (const id of state.selection) {
2745
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
2745
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
2746
2746
  if (node && !node.locked) {
2747
- for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node)) if (!p.locked) ids.add(p.id);
2747
+ for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node)) if (!p.locked) ids.add(p.id);
2748
2748
  }
2749
2749
  }
2750
2750
  }
2751
- return [...ids].filter((id) => _optionalChain([_chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _38 => _38.type]) === "path");
2751
+ return [...ids].filter((id) => _optionalChain([_chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _38 => _38.type]) === "path");
2752
2752
  }
2753
2753
  function getVisibleAnchors(state) {
2754
2754
  const out = [];
2755
2755
  for (const id of getEditablePathIds(state)) {
2756
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
2756
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
2757
2757
  node.subpaths.forEach((sp, s) => sp.anchors.forEach((_, i) => out.push({ nodeId: id, subpath: s, index: i })));
2758
2758
  }
2759
2759
  return out;
@@ -2771,7 +2771,7 @@ function getVisibleHandles(state) {
2771
2771
  out.push({ nodeId: node.id, subpath: s, index: i, handle });
2772
2772
  };
2773
2773
  if (state.tool === "pen" && state.pen) {
2774
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, state.pen.nodeId);
2774
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, state.pen.nodeId);
2775
2775
  const sp = _optionalChain([node, 'optionalAccess', _41 => _41.type]) === "path" ? node.subpaths[state.pen.subpath] : void 0;
2776
2776
  if (_optionalChain([node, 'optionalAccess', _42 => _42.type]) === "path" && sp) {
2777
2777
  const last = sp.anchors.length - 1;
@@ -2784,7 +2784,7 @@ function getVisibleHandles(state) {
2784
2784
  const editable = new Set(getEditablePathIds(state));
2785
2785
  for (const ref of state.selectedAnchors) {
2786
2786
  if (!editable.has(ref.nodeId)) continue;
2787
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, ref.nodeId);
2787
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, ref.nodeId);
2788
2788
  const sp = node.subpaths[ref.subpath];
2789
2789
  if (!sp) continue;
2790
2790
  const n = sp.anchors.length;
@@ -2803,26 +2803,26 @@ function getVectorCornerWidgets(state) {
2803
2803
  const zoom = state.viewport.zoom;
2804
2804
  const out = [];
2805
2805
  for (const id of getEditablePathIds(state)) {
2806
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
2806
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
2807
2807
  const picked = state.selectedAnchors.filter((r) => r.nodeId === id);
2808
- const m = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
2809
- for (const c of _chunkXCXQDPIDcjs.vectorCorners.call(void 0, node.subpaths)) {
2808
+ const m = _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
2809
+ for (const c of _chunkFKONE6AOcjs.vectorCorners.call(void 0, node.subpaths)) {
2810
2810
  if (picked.length && !picked.some((r) => r.subpath === c.subpath && r.index === c.index)) continue;
2811
2811
  const side = Math.min(c.lu, c.lv);
2812
2812
  if (side * zoom < 3 * VECTOR_CORNER_WIDGET_INSET) continue;
2813
2813
  const a = node.subpaths[c.subpath].anchors[c.index];
2814
2814
  const radius = _nullishCoalesce(_optionalChain([a, 'access', _43 => _43.corner, 'optionalAccess', _44 => _44.radius]), () => ( 0));
2815
- const drawn = _chunkXCXQDPIDcjs.fitCornerRadius.call(void 0, c, radius);
2815
+ const drawn = _chunkFKONE6AOcjs.fitCornerRadius.call(void 0, c, radius);
2816
2816
  const k = Math.min(Math.max(drawn / c.sin, VECTOR_CORNER_WIDGET_INSET / (zoom * Math.sqrt(1 + c.cos))), side / 2);
2817
- const p = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, _chunkXCXQDPIDcjs.cornerBisectorPoint.call(void 0, c, k));
2817
+ const p = _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, _chunkFKONE6AOcjs.cornerBisectorPoint.call(void 0, c, k));
2818
2818
  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
2819
  }
2820
2820
  }
2821
2821
  return out;
2822
2822
  }
2823
2823
  function vectorStrokeWidthGeometry(node) {
2824
- if (!_chunkXCXQDPIDcjs.hasPaint.call(void 0, node.stroke) || !((_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0)) return null;
2825
- const parts = _chunkXCXQDPIDcjs.vectorStrokeParts.call(void 0, _chunkXCXQDPIDcjs.subpathsToBezier.call(void 0, node.subpaths), node);
2824
+ if (!_chunkFKONE6AOcjs.hasPaint.call(void 0, node.stroke) || !((_nullishCoalesce(node.strokeWidth, () => ( 1))) > 0)) return null;
2825
+ const parts = _chunkFKONE6AOcjs.vectorStrokeParts.call(void 0, _chunkFKONE6AOcjs.subpathsToBezier.call(void 0, node.subpaths), node);
2826
2826
  return parts.line.length ? { line: parts.line, unit: parts.drawWidth / 2 } : null;
2827
2827
  }
2828
2828
  function shiftWidthPoints(profile, indices, dt) {
@@ -2835,30 +2835,30 @@ function getVectorWidthHandles(state) {
2835
2835
  if (state.tool !== "width") return [];
2836
2836
  const ids = /* @__PURE__ */ new Set();
2837
2837
  for (const id of state.selection) {
2838
- const n = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
2839
- if (n) for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, n)) ids.add(p.id);
2838
+ const n = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
2839
+ if (n) for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, n)) ids.add(p.id);
2840
2840
  }
2841
2841
  if (_optionalChain([state, 'access', _47 => _47.hover, 'optionalAccess', _48 => _48.nodeId])) ids.add(state.hover.nodeId);
2842
2842
  if (_optionalChain([state, 'access', _49 => _49.interaction, 'optionalAccess', _50 => _50.type]) === "width") ids.add(state.interaction.ref.nodeId);
2843
2843
  for (const r of state.selectedWidthPoints) ids.add(r.nodeId);
2844
2844
  const out = [];
2845
2845
  for (const id of ids) {
2846
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
2846
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
2847
2847
  if (_optionalChain([node, 'optionalAccess', _51 => _51.type]) !== "path" || node.visible === false || !_optionalChain([node, 'access', _52 => _52.strokeWidthProfile, 'optionalAccess', _53 => _53.length])) continue;
2848
2848
  const g = vectorStrokeWidthGeometry(node);
2849
2849
  if (!g) continue;
2850
- const profile = _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
2851
- const m = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
2850
+ const profile = _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
2851
+ const m = _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, state.document.nodes, id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
2852
2852
  const contours = node.subpaths.length;
2853
2853
  for (let sp = 0; sp < contours; sp++) {
2854
2854
  profile.forEach((w, index) => {
2855
- const at = _chunkXCXQDPIDcjs.strokePositionPoint.call(void 0, g.line, sp, w.t);
2855
+ const at = _chunkFKONE6AOcjs.strokePositionPoint.call(void 0, g.line, sp, w.t);
2856
2856
  if (!at) return;
2857
2857
  const n = { x: at.tangent[1], y: -at.tangent[0] };
2858
2858
  const c = { x: at.point[0], y: at.point[1] };
2859
- const p = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, c);
2860
- const l = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, { x: c.x - n.x * w.right * g.unit, y: c.y - n.y * w.right * g.unit });
2859
+ const p = _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, c);
2860
+ const l = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, { x: c.x - n.x * w.right * g.unit, y: c.y - n.y * w.right * g.unit });
2862
2862
  out.push({
2863
2863
  ref: { nodeId: id, index, subpath: sp },
2864
2864
  x: p.x,
@@ -2876,24 +2876,24 @@ function getVectorWidthHandles(state) {
2876
2876
  return out;
2877
2877
  }
2878
2878
  function getAnchor(doc, ref) {
2879
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
2879
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
2880
2880
  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
2881
  }
2882
2882
  function getAnchorWorld(doc, ref) {
2883
2883
  const a = getAnchor(doc, ref);
2884
2884
  if (!a) return void 0;
2885
- const m = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, doc.nodes, ref.nodeId), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
2886
- const p = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, a);
2887
- return { x: p.x, y: p.y, ...a.in ? { in: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, a.in) } : {}, ...a.out ? { out: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, a.out) } : {}, ...a.type ? { type: a.type } : {} };
2885
+ const m = _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, doc.nodes, ref.nodeId), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
2886
+ const p = _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, a);
2887
+ return { x: p.x, y: p.y, ...a.in ? { in: _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, a.in) } : {}, ...a.out ? { out: _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, a.out) } : {}, ...a.type ? { type: a.type } : {} };
2888
2888
  }
2889
2889
  function getVectorSelectionFrame(doc, ids) {
2890
- const nodes = ids.map((id) => ({ node: _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, id), parent: _nullishCoalesce(_chunkXCXQDPIDcjs.vectorParentMatrix.call(void 0, doc.nodes, id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX)) })).filter((n) => n.node);
2890
+ const nodes = ids.map((id) => ({ node: _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, id), parent: _nullishCoalesce(_chunkFKONE6AOcjs.vectorParentMatrix.call(void 0, doc.nodes, id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX)) })).filter((n) => n.node);
2891
2891
  if (!nodes.length) return null;
2892
- const angles = nodes.map((n) => _chunkXCXQDPIDcjs.matrixRotation.call(void 0, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n.node), n.parent)));
2892
+ const angles = nodes.map((n) => _chunkFKONE6AOcjs.matrixRotation.call(void 0, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n.node), n.parent)));
2893
2893
  const same = angles.every((a) => Math.abs(normalizeAngle(a - angles[0])) < 1e-6);
2894
2894
  const angle = same ? angles[0] : 0;
2895
- const unrotate = _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -angle);
2896
- const b = _chunkXCXQDPIDcjs.unionBounds.call(void 0, nodes.map((n) => _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n.node, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, n.parent, unrotate))));
2895
+ const unrotate = _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -angle);
2896
+ const b = _chunkFKONE6AOcjs.unionBounds.call(void 0, nodes.map((n) => _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n.node, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, n.parent, unrotate))));
2897
2897
  return b ? { ...b, angle } : null;
2898
2898
  }
2899
2899
  var normalizeAngle = (a) => ((a + 180) % 360 + 360) % 360 - 180;
@@ -2914,8 +2914,8 @@ function getTransformHandlePositions(box) {
2914
2914
  function getVectorSelectionBoxGeometry(frame, viewport) {
2915
2915
  const z = viewport.zoom;
2916
2916
  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 = _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, frame.angle, { x: viewport.x, y: viewport.y });
2918
- const toScreen2 = (p) => frame.angle ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, rot, p) : { x: p.x, y: p.y };
2917
+ const rot = _chunkFKONE6AOcjs.rotateMatrix.call(void 0, frame.angle, { x: viewport.x, y: viewport.y });
2918
+ const toScreen2 = (p) => frame.angle ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, rot, p) : { x: p.x, y: p.y };
2919
2919
  const handles = getTransformHandlePositions(box).map((h) => ({ ...h, screen: toScreen2(h) }));
2920
2920
  const corners2 = [
2921
2921
  { x: box.x, y: box.y },
@@ -2928,10 +2928,10 @@ function getVectorSelectionBoxGeometry(frame, viewport) {
2928
2928
  }
2929
2929
  function getVectorEnvelopeTarget(doc, selection) {
2930
2930
  if (selection.length !== 1) return null;
2931
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, selection[0]);
2932
- if (!node || !_chunkXCXQDPIDcjs.vectorNodeEnvelope.call(void 0, node)) return null;
2933
- const frame = _chunkXCXQDPIDcjs.vectorEnvelopeFrame.call(void 0, node);
2934
- return frame ? { node, frame, world: _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, doc.nodes, node.id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX)) } : null;
2931
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, selection[0]);
2932
+ if (!node || !_chunkFKONE6AOcjs.vectorNodeEnvelope.call(void 0, node)) return null;
2933
+ const frame = _chunkFKONE6AOcjs.vectorEnvelopeFrame.call(void 0, node);
2934
+ return frame ? { node, frame, world: _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, doc.nodes, node.id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX)) } : null;
2935
2935
  }
2936
2936
  var RESIZE_CURSOR_ORDER = ["ew-resize", "nwse-resize", "ns-resize", "nesw-resize"];
2937
2937
  var HANDLE_ANGLES = { e: 0, se: 45, s: 90, sw: 135, w: 180, nw: 225, n: 270, ne: 315 };
@@ -3081,7 +3081,7 @@ var placementOf = (n) => ({
3081
3081
  ...n.locked ? { locked: true } : {},
3082
3082
  ...n.booleanOperation ? { booleanOperation: n.booleanOperation } : {}
3083
3083
  });
3084
- var isRoot = (m) => m === _chunkXCXQDPIDcjs.IDENTITY_MATRIX || m[0] === 1 && m[1] === 0 && m[2] === 0 && m[3] === 1 && m[4] === 0 && m[5] === 0;
3084
+ var isRoot = (m) => m === _chunkFKONE6AOcjs.IDENTITY_MATRIX || m[0] === 1 && m[1] === 0 && m[2] === 0 && m[3] === 1 && m[4] === 0 && m[5] === 0;
3085
3085
  var idCounter = 0;
3086
3086
  var defaultCreateId = () => `vn-${Date.now().toString(36)}${(++idCounter).toString(36)}`;
3087
3087
  var VectorEditorController = (_class3 = class {
@@ -3133,7 +3133,7 @@ var VectorEditorController = (_class3 = class {
3133
3133
 
3134
3134
  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
3135
  this.history = _nullishCoalesce(options.history, () => ( new (0, _chunkQKLRAA4Tcjs.HistoryManager)()));
3136
- this.doc = options.document ? _chunkXCXQDPIDcjs.cloneVectorDocument.call(void 0, options.document) : { width: 800, height: 600, nodes: [] };
3136
+ this.doc = options.document ? _chunkFKONE6AOcjs.cloneVectorDocument.call(void 0, options.document) : { width: 800, height: 600, nodes: [] };
3137
3137
  this.doc = this.refreshed(this.doc);
3138
3138
  this.tool = _nullishCoalesce(options.tool, () => ( "select"));
3139
3139
  this.defaults = { ...DEFAULT_DEFAULTS, ..._nullishCoalesce(options.defaults, () => ( {})) };
@@ -3186,7 +3186,7 @@ var VectorEditorController = (_class3 = class {
3186
3186
  return this.doc;
3187
3187
  }
3188
3188
  getNode(id) {
3189
- return _chunkXCXQDPIDcjs.findVectorNode.call(void 0, this.doc.nodes, id);
3189
+ return _chunkFKONE6AOcjs.findVectorNode.call(void 0, this.doc.nodes, id);
3190
3190
  }
3191
3191
  computeState() {
3192
3192
  const h = this.history.getState();
@@ -3245,10 +3245,10 @@ var VectorEditorController = (_class3 = class {
3245
3245
  });
3246
3246
  }
3247
3247
  boundsOf(ids) {
3248
- return _chunkXCXQDPIDcjs.unionBounds.call(void 0,
3248
+ return _chunkFKONE6AOcjs.unionBounds.call(void 0,
3249
3249
  ids.map((id) => {
3250
3250
  const n = this.getNode(id);
3251
- return n ? _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunkXCXQDPIDcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX))) : null;
3251
+ return n ? _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunkFKONE6AOcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX))) : null;
3252
3252
  })
3253
3253
  );
3254
3254
  }
@@ -3257,11 +3257,11 @@ var VectorEditorController = (_class3 = class {
3257
3257
  }
3258
3258
  /** Local → document matrix of a node in `doc` (default: the current document). */
3259
3259
  worldOf(id, doc = this.doc) {
3260
- return _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, doc.nodes, id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
3260
+ return _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, doc.nodes, id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
3261
3261
  }
3262
3262
  /** A document point in node `id`'s own space. */
3263
3263
  toLocal(id, p, doc = this.doc) {
3264
- return _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(id, doc)), p);
3264
+ return _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(id, doc)), p);
3265
3265
  }
3266
3266
  cursorFor() {
3267
3267
  if (_optionalChain([this, 'access', _61 => _61.drag, 'optionalAccess', _62 => _62.kind]) === "pan" || this.spaceHeld) return this.drag ? "grabbing" : "grab";
@@ -3374,9 +3374,9 @@ var VectorEditorController = (_class3 = class {
3374
3374
  this.setDoc(mapTree(this.doc.nodes, (n) => n.id === id ? next : n));
3375
3375
  }
3376
3376
  freshIds(node) {
3377
- const copy = _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, node);
3377
+ const copy = _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, node);
3378
3378
  const used = /* @__PURE__ */ new Set();
3379
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
3379
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
3380
3380
  const next = () => {
3381
3381
  let id = this.createId();
3382
3382
  while (used.has(id)) id = this.createId();
@@ -3544,7 +3544,7 @@ var VectorEditorController = (_class3 = class {
3544
3544
  /** Replaces the document. Undoable unless `{ history: false }` (then history is cleared). */
3545
3545
  setDocument(doc, options = {}) {
3546
3546
  this.cancelDrag();
3547
- const next = _chunkXCXQDPIDcjs.cloneVectorDocument.call(void 0, doc);
3547
+ const next = _chunkFKONE6AOcjs.cloneVectorDocument.call(void 0, doc);
3548
3548
  if (options.history === false) {
3549
3549
  this.doc = next;
3550
3550
  this.selection = [];
@@ -3572,7 +3572,7 @@ var VectorEditorController = (_class3 = class {
3572
3572
  /** Replaces the document with parsed SVG markup (one undo step). */
3573
3573
  loadSvg(svg, options = {}) {
3574
3574
  try {
3575
- const doc = _chunkXCXQDPIDcjs.parseVectorSvg.call(void 0, svg, { createId: () => this.createId() });
3575
+ const doc = _chunkFKONE6AOcjs.parseVectorSvg.call(void 0, svg, { createId: () => this.createId() });
3576
3576
  this.setDocument(doc, { history: options.history, label: "Import SVG" });
3577
3577
  return { ok: true };
3578
3578
  } catch (error) {
@@ -3582,7 +3582,7 @@ var VectorEditorController = (_class3 = class {
3582
3582
  /** Adds the nodes of SVG markup on top of the document, selected. */
3583
3583
  importSvg(svg) {
3584
3584
  try {
3585
- const parsed = _chunkXCXQDPIDcjs.parseVectorSvg.call(void 0, svg);
3585
+ const parsed = _chunkFKONE6AOcjs.parseVectorSvg.call(void 0, svg);
3586
3586
  const nodes = parsed.nodes.map((n) => this.freshIds(n));
3587
3587
  if (!nodes.length) return { ok: false, message: "The SVG has no shapes the editor can read." };
3588
3588
  this.change("Import SVG", () => {
@@ -3596,21 +3596,21 @@ var VectorEditorController = (_class3 = class {
3596
3596
  }
3597
3597
  }
3598
3598
  toSvg(options) {
3599
- return _chunkXCXQDPIDcjs.vectorDocumentToSvg.call(void 0, this.doc, options);
3599
+ return _chunkFKONE6AOcjs.vectorDocumentToSvg.call(void 0, this.doc, options);
3600
3600
  }
3601
3601
  toJSON() {
3602
- return _chunkXCXQDPIDcjs.cloneVectorDocument.call(void 0, this.doc);
3602
+ return _chunkFKONE6AOcjs.cloneVectorDocument.call(void 0, this.doc);
3603
3603
  }
3604
3604
  /** Adds a node (ids are kept unless taken). Returns its id. */
3605
3605
  addNode(node, options = {}) {
3606
3606
  const taken = (() => {
3607
3607
  let clash = false;
3608
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, [node], (n) => {
3608
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, [node], (n) => {
3609
3609
  if (this.getNode(n.id)) clash = true;
3610
3610
  });
3611
3611
  return clash;
3612
3612
  })();
3613
- const next = taken ? this.freshIds(node) : _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, node);
3613
+ const next = taken ? this.freshIds(node) : _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, node);
3614
3614
  this.change(_nullishCoalesce(options.label, () => ( `Add ${next.type === "group" ? "Group" : _nullishCoalesce(next.name, () => ( "Path"))}`)), () => {
3615
3615
  const insert = (list) => {
3616
3616
  const copy = list.slice();
@@ -3634,24 +3634,24 @@ var VectorEditorController = (_class3 = class {
3634
3634
  let subpath;
3635
3635
  switch (input.kind) {
3636
3636
  case "rect":
3637
- subpath = _chunkXCXQDPIDcjs.rectSubpath.call(void 0, b);
3637
+ subpath = _chunkFKONE6AOcjs.rectSubpath.call(void 0, b);
3638
3638
  break;
3639
3639
  case "ellipse":
3640
- subpath = _chunkXCXQDPIDcjs.ellipseSubpath.call(void 0, b);
3640
+ subpath = _chunkFKONE6AOcjs.ellipseSubpath.call(void 0, b);
3641
3641
  break;
3642
3642
  case "polygon":
3643
- subpath = _chunkXCXQDPIDcjs.polygonSubpath.call(void 0, b, _nullishCoalesce(input.sides, () => ( d.polygonSides)));
3643
+ subpath = _chunkFKONE6AOcjs.polygonSubpath.call(void 0, b, _nullishCoalesce(input.sides, () => ( d.polygonSides)));
3644
3644
  break;
3645
3645
  case "star":
3646
- subpath = _chunkXCXQDPIDcjs.starSubpath.call(void 0, b, _nullishCoalesce(input.points, () => ( d.starPoints)), _nullishCoalesce(input.innerRatio, () => ( d.starInnerRatio)));
3646
+ subpath = _chunkFKONE6AOcjs.starSubpath.call(void 0, b, _nullishCoalesce(input.points, () => ( d.starPoints)), _nullishCoalesce(input.innerRatio, () => ( d.starInnerRatio)));
3647
3647
  break;
3648
3648
  case "line":
3649
- subpath = _chunkXCXQDPIDcjs.lineSubpath.call(void 0, { x: b.x, y: b.y }, { x: b.x + b.width, y: b.y + b.height });
3649
+ subpath = _chunkFKONE6AOcjs.lineSubpath.call(void 0, { x: b.x, y: b.y }, { x: b.x + b.width, y: b.y + b.height });
3650
3650
  break;
3651
3651
  }
3652
3652
  const radius = _nullishCoalesce(input.cornerRadius, () => ( d.cornerRadius));
3653
3653
  const kind = _nullishCoalesce(input.cornerKind, () => ( d.cornerKind));
3654
- if ((input.kind === "rect" || input.kind === "polygon" || input.kind === "star") && radius > 0) subpath = _chunkXCXQDPIDcjs.setSubpathCorners.call(void 0, subpath, radius, kind);
3654
+ if ((input.kind === "rect" || input.kind === "polygon" || input.kind === "star") && radius > 0) subpath = _chunkFKONE6AOcjs.setSubpathCorners.call(void 0, subpath, radius, kind);
3655
3655
  const names = { rect: "Rectangle", ellipse: "Ellipse", polygon: "Polygon", star: "Star", line: "Line" };
3656
3656
  const style = this.styleFor(input.kind === "line");
3657
3657
  const own = {};
@@ -3667,7 +3667,7 @@ var VectorEditorController = (_class3 = class {
3667
3667
  }
3668
3668
  /** Adds a path from SVG path data. Returns its id. */
3669
3669
  addPath(d, style = {}, options = {}) {
3670
- const subpaths = _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, d);
3670
+ const subpaths = _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, d);
3671
3671
  const node = { id: this.newId(), type: "path", name: _nullishCoalesce(style.name, () => ( "Path")), ...this.styleFor(false), ...style, subpaths };
3672
3672
  return this.addNode(node, { label: "Add Path", ...options });
3673
3673
  }
@@ -3697,7 +3697,7 @@ var VectorEditorController = (_class3 = class {
3697
3697
  for (const id of ids) {
3698
3698
  const node = this.getNode(id);
3699
3699
  if (!node) return { ok: false, message: `There is no node "${id}".` };
3700
- for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node)) targets.add(p.id);
3700
+ for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node)) targets.add(p.id);
3701
3701
  }
3702
3702
  if (!targets.size) return { ok: false, message: "Nothing is selected." };
3703
3703
  this.change(_nullishCoalesce(options.label, () => ( "Change Style")), () => {
@@ -3714,13 +3714,13 @@ var VectorEditorController = (_class3 = class {
3714
3714
  let points;
3715
3715
  if (profile === null) points = [];
3716
3716
  else if (typeof profile === "string") {
3717
- const preset = _chunkXCXQDPIDcjs.widthProfilePreset.call(void 0, profile);
3717
+ const preset = _chunkFKONE6AOcjs.widthProfilePreset.call(void 0, profile);
3718
3718
  if (!preset) return { ok: false, message: `There is no width profile "${profile}".` };
3719
3719
  points = preset;
3720
- } else if (Array.isArray(profile)) points = _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, profile);
3720
+ } else if (Array.isArray(profile)) points = _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, profile);
3721
3721
  else {
3722
3722
  const p = profile;
3723
- points = p.taper || p.wave ? _chunkXCXQDPIDcjs.generateWidthProfile.call(void 0, p) : [];
3723
+ points = p.taper || p.wave ? _chunkFKONE6AOcjs.generateWidthProfile.call(void 0, p) : [];
3724
3724
  }
3725
3725
  this.widthPoints = [];
3726
3726
  this.widthEdit = null;
@@ -3751,7 +3751,7 @@ var VectorEditorController = (_class3 = class {
3751
3751
  for (const id of ids) {
3752
3752
  const node = this.getNode(id);
3753
3753
  if (node && !node.locked) {
3754
- for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
3754
+ for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
3755
3755
  }
3756
3756
  }
3757
3757
  return [...out.values()];
@@ -3768,8 +3768,8 @@ var VectorEditorController = (_class3 = class {
3768
3768
  const next = /* @__PURE__ */ new Map();
3769
3769
  for (const path of paths) {
3770
3770
  const paint = path[target];
3771
- const base = _chunkXCXQDPIDcjs.isVectorGradient.call(void 0, paint) ? paint : _chunkXCXQDPIDcjs.defaultVectorGradient.call(void 0, _nullishCoalesce(patch.type, () => ( "linear")), paint);
3772
- const g = _chunkXCXQDPIDcjs.applyVectorGradientPatch.call(void 0, base, patch);
3771
+ const base = _chunkFKONE6AOcjs.isVectorGradient.call(void 0, paint) ? paint : _chunkFKONE6AOcjs.defaultVectorGradient.call(void 0, _nullishCoalesce(patch.type, () => ( "linear")), paint);
3772
+ const g = _chunkFKONE6AOcjs.applyVectorGradientPatch.call(void 0, base, patch);
3773
3773
  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
3774
  next.set(path.id, { ...path, [target]: g });
3775
3775
  }
@@ -3781,12 +3781,12 @@ var VectorEditorController = (_class3 = class {
3781
3781
  /** Applies `fn` to every target gradient of the selection (paths whose paint is not a gradient are skipped). */
3782
3782
  editGradients(label, fn, merge) {
3783
3783
  const target = this.gradientEdit.target;
3784
- const paths = this.gradientPaths().filter((p) => _chunkXCXQDPIDcjs.isVectorGradient.call(void 0, p[target]));
3784
+ const paths = this.gradientPaths().filter((p) => _chunkFKONE6AOcjs.isVectorGradient.call(void 0, p[target]));
3785
3785
  if (!paths.length) return { ok: false, message: "The selection has no gradient." };
3786
3786
  const next = /* @__PURE__ */ new Map();
3787
3787
  for (const path of paths) {
3788
3788
  const g = path[target];
3789
- const stops = fn(_chunkXCXQDPIDcjs.sortedVectorGradientStops.call(void 0, g));
3789
+ const stops = fn(_chunkFKONE6AOcjs.sortedVectorGradientStops.call(void 0, g));
3790
3790
  if (!stops) return { ok: false, message: "A gradient keeps at least two stops." };
3791
3791
  next.set(path.id, { ...path, [target]: { ...g, stops } });
3792
3792
  }
@@ -3816,7 +3816,7 @@ var VectorEditorController = (_class3 = class {
3816
3816
  }
3817
3817
  return out;
3818
3818
  });
3819
- if (patch.offset !== void 0 && Number.isFinite(patch.offset)) ({ stops: next, index: moved } = _chunkXCXQDPIDcjs.moveVectorGradientStop.call(void 0, next, index, patch.offset));
3819
+ if (patch.offset !== void 0 && Number.isFinite(patch.offset)) ({ stops: next, index: moved } = _chunkFKONE6AOcjs.moveVectorGradientStop.call(void 0, next, index, patch.offset));
3820
3820
  return next;
3821
3821
  },
3822
3822
  options.merge
@@ -3829,8 +3829,8 @@ var VectorEditorController = (_class3 = class {
3829
3829
  let index = 0;
3830
3830
  const target = this.gradientEdit.target;
3831
3831
  const result = this.editGradients("Add Gradient Stop", (stops) => {
3832
- const path = this.gradientPaths().find((p) => _chunkXCXQDPIDcjs.isVectorGradient.call(void 0, p[target]));
3833
- const r = _chunkXCXQDPIDcjs.insertVectorGradientStop.call(void 0, { ...path[target], stops }, offset);
3832
+ const path = this.gradientPaths().find((p) => _chunkFKONE6AOcjs.isVectorGradient.call(void 0, p[target]));
3833
+ const r = _chunkFKONE6AOcjs.insertVectorGradientStop.call(void 0, { ...path[target], stops }, offset);
3834
3834
  index = r.index;
3835
3835
  return r.stops;
3836
3836
  });
@@ -3839,7 +3839,7 @@ var VectorEditorController = (_class3 = class {
3839
3839
  }
3840
3840
  /** Removes stop `index` of the selection's gradients (never below two stops). */
3841
3841
  removeGradientStop(index) {
3842
- const result = this.editGradients("Delete Gradient Stop", (stops) => _chunkXCXQDPIDcjs.removeVectorGradientStop.call(void 0, stops, index));
3842
+ const result = this.editGradients("Delete Gradient Stop", (stops) => _chunkFKONE6AOcjs.removeVectorGradientStop.call(void 0, stops, index));
3843
3843
  if (result.ok) this.selectGradientStop(null);
3844
3844
  return result;
3845
3845
  }
@@ -3892,48 +3892,48 @@ var VectorEditorController = (_class3 = class {
3892
3892
  const end = constrained(drag.startDoc, p);
3893
3893
  let doc = base;
3894
3894
  for (const id2 of drag.targets) {
3895
- const node2 = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, base.nodes, id2);
3895
+ const node2 = _chunkFKONE6AOcjs.findVectorNode.call(void 0, base.nodes, id2);
3896
3896
  if (!node2) continue;
3897
3897
  const paint = node2[target];
3898
- const g2 = _chunkXCXQDPIDcjs.isVectorGradient.call(void 0, paint) ? paint : _chunkXCXQDPIDcjs.defaultVectorGradient.call(void 0, "linear", paint);
3899
- doc = this.withGradient(doc, id2, target, _chunkXCXQDPIDcjs.setVectorGradientVector.call(void 0, g2, _chunkXCXQDPIDcjs.vectorPathLocalBounds.call(void 0, node2), this.toLocal(id2, drag.startDoc, base), this.toLocal(id2, end, base)));
3898
+ const g2 = _chunkFKONE6AOcjs.isVectorGradient.call(void 0, paint) ? paint : _chunkFKONE6AOcjs.defaultVectorGradient.call(void 0, "linear", paint);
3899
+ doc = this.withGradient(doc, id2, target, _chunkFKONE6AOcjs.setVectorGradientVector.call(void 0, g2, _chunkFKONE6AOcjs.vectorPathLocalBounds.call(void 0, node2), this.toLocal(id2, drag.startDoc, base), this.toLocal(id2, end, base)));
3900
3900
  }
3901
3901
  this.doc = doc;
3902
3902
  this.notify(true);
3903
3903
  return;
3904
3904
  }
3905
3905
  const id = drag.nodeId;
3906
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, base.nodes, id);
3906
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, base.nodes, id);
3907
3907
  const g = node[target];
3908
- const bounds = _chunkXCXQDPIDcjs.vectorPathLocalBounds.call(void 0, node);
3908
+ const bounds = _chunkFKONE6AOcjs.vectorPathLocalBounds.call(void 0, node);
3909
3909
  const local = (q) => this.toLocal(id, q, base);
3910
3910
  const part = drag.part;
3911
3911
  let next = g;
3912
3912
  if (part.kind === "handle") {
3913
3913
  let to = p;
3914
3914
  if (part.handle === "end" || part.handle === "radius") to = constrained(this.screenToDocument(drag.annotator.start), p);
3915
- next = _chunkXCXQDPIDcjs.moveVectorGradientHandle.call(void 0, g, bounds, part.handle, local(to), local(drag.startDoc));
3915
+ next = _chunkFKONE6AOcjs.moveVectorGradientHandle.call(void 0, g, bounds, part.handle, local(to), local(drag.startDoc));
3916
3916
  } else if (part.kind === "bar") {
3917
- next = _chunkXCXQDPIDcjs.moveVectorGradientHandle.call(void 0, g, bounds, "start", local(p), local(drag.startDoc));
3917
+ next = _chunkFKONE6AOcjs.moveVectorGradientHandle.call(void 0, g, bounds, "start", local(p), local(drag.startDoc));
3918
3918
  } else {
3919
3919
  const a = drag.annotator;
3920
3920
  const pos = vectorGradientBarPosition(a, screen);
3921
- const stops = _chunkXCXQDPIDcjs.sortedVectorGradientStops.call(void 0, g);
3921
+ const stops = _chunkFKONE6AOcjs.sortedVectorGradientStops.call(void 0, g);
3922
3922
  if (part.kind === "stop") {
3923
3923
  const off = Math.abs(pos.across - VECTOR_GRADIENT_STOP_GAP) > VECTOR_GRADIENT_OFF_BAR;
3924
- const removed = off ? _chunkXCXQDPIDcjs.removeVectorGradientStop.call(void 0, stops, part.index) : null;
3924
+ const removed = off ? _chunkFKONE6AOcjs.removeVectorGradientStop.call(void 0, stops, part.index) : null;
3925
3925
  if (removed) {
3926
3926
  next = { ...g, stops: removed };
3927
3927
  drag.stop = null;
3928
3928
  } else {
3929
- const r = _chunkXCXQDPIDcjs.moveVectorGradientStop.call(void 0, stops, part.index, Math.min(1, Math.max(0, pos.offset)));
3929
+ const r = _chunkFKONE6AOcjs.moveVectorGradientStop.call(void 0, stops, part.index, Math.min(1, Math.max(0, pos.offset)));
3930
3930
  next = { ...g, stops: r.stops };
3931
3931
  drag.stop = r.index;
3932
3932
  }
3933
3933
  this.interaction = { type: "gradient", part: "stop", ...removed ? { removing: true } : {} };
3934
3934
  this.gradientEdit = { ...this.gradientEdit, stop: drag.stop };
3935
3935
  } else {
3936
- const m = _chunkXCXQDPIDcjs.vectorGradientMidpointFromPosition.call(void 0, stops, part.index, pos.offset);
3936
+ const m = _chunkFKONE6AOcjs.vectorGradientMidpointFromPosition.call(void 0, stops, part.index, pos.offset);
3937
3937
  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
3938
  }
3939
3939
  }
@@ -3972,7 +3972,7 @@ var VectorEditorController = (_class3 = class {
3972
3972
  this.change(count > 1 ? "Delete Width Points" : "Delete Width Point", () => {
3973
3973
  for (const [id, indices] of byNode) {
3974
3974
  const node = this.getNode(id);
3975
- const rest = _chunkXCXQDPIDcjs.removeWidthPoints.call(void 0, _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile), indices);
3975
+ const rest = _chunkFKONE6AOcjs.removeWidthPoints.call(void 0, _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile), indices);
3976
3976
  this.replaceNode(id, withStyle(node, { strokeWidthProfile: rest.length ? rest : null }));
3977
3977
  }
3978
3978
  });
@@ -4008,25 +4008,25 @@ var VectorEditorController = (_class3 = class {
4008
4008
  const left = num(values.left);
4009
4009
  const right = num(values.right);
4010
4010
  const scale = (w) => w === void 0 ? void 0 : Math.max(0, w) / g.unit;
4011
- const profile = _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4011
+ const profile = _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4012
4012
  let points;
4013
4013
  let index;
4014
4014
  const existing = _nullishCoalesce(target.index, () => ( null));
4015
4015
  if (existing === null) {
4016
4016
  if (t === void 0) return { ok: false, message: "A new width point needs a position t." };
4017
- if (profile.length >= _chunkXCXQDPIDcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS) return { ok: false, message: "The profile has too many width points." };
4018
- ({ points, index } = _chunkXCXQDPIDcjs.insertWidthPoint.call(void 0, profile.length ? profile : null, t, { left: scale(left), right: scale(right) }, { step: true }));
4017
+ if (profile.length >= _chunkFKONE6AOcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS) return { ok: false, message: "The profile has too many width points." };
4018
+ ({ points, index } = _chunkFKONE6AOcjs.insertWidthPoint.call(void 0, profile.length ? profile : null, t, { left: scale(left), right: scale(right) }, { step: true }));
4019
4019
  } else {
4020
4020
  const p = profile[existing];
4021
4021
  if (!p) return { ok: false, message: "There is no such width point." };
4022
4022
  const sides2 = { left: _nullishCoalesce(scale(left), () => ( p.left)), right: _nullishCoalesce(scale(right), () => ( p.right)) };
4023
4023
  const tt = t === void 0 ? p.t : Math.min(Math.max(t, 0), 1);
4024
- if (Math.abs(tt - p.t) <= _chunkXCXQDPIDcjs.VECTOR_WIDTH_SAME_T) {
4025
- points = _chunkXCXQDPIDcjs.setWidthPoint.call(void 0, profile, existing, sides2);
4024
+ if (Math.abs(tt - p.t) <= _chunkFKONE6AOcjs.VECTOR_WIDTH_SAME_T) {
4025
+ points = _chunkFKONE6AOcjs.setWidthPoint.call(void 0, profile, existing, sides2);
4026
4026
  index = existing;
4027
4027
  } else {
4028
- const rest = _chunkXCXQDPIDcjs.removeWidthPoints.call(void 0, profile, [existing]);
4029
- if (rest.length) ({ points, index } = _chunkXCXQDPIDcjs.insertWidthPoint.call(void 0, rest, tt, sides2, { step: true }));
4028
+ const rest = _chunkFKONE6AOcjs.removeWidthPoints.call(void 0, profile, [existing]);
4029
+ if (rest.length) ({ points, index } = _chunkFKONE6AOcjs.insertWidthPoint.call(void 0, rest, tt, sides2, { step: true }));
4030
4030
  else {
4031
4031
  points = [{ t: tt, ...sides2 }];
4032
4032
  index = 0;
@@ -4074,15 +4074,15 @@ var VectorEditorController = (_class3 = class {
4074
4074
  if (_optionalChain([node, 'optionalAccess', _140 => _140.type]) !== "path") return null;
4075
4075
  const g = vectorStrokeWidthGeometry(node);
4076
4076
  if (!g) return null;
4077
- const profile = _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4077
+ const profile = _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
4078
4078
  const p = index === null ? null : profile[index];
4079
4079
  if (index !== null && !p) return null;
4080
4080
  const tt = p ? p.t : Math.min(Math.max(_nullishCoalesce(t, () => ( 0)), 0), 1);
4081
- const sides2 = _nullishCoalesce(p, () => ( _chunkXCXQDPIDcjs.widthProfileAt.call(void 0, profile.length ? profile : null, tt)));
4081
+ const sides2 = _nullishCoalesce(p, () => ( _chunkFKONE6AOcjs.widthProfileAt.call(void 0, profile.length ? profile : null, tt)));
4082
4082
  const sp = Math.min(Math.max(0, subpath), Math.max(0, node.subpaths.length - 1));
4083
- const at = _chunkXCXQDPIDcjs.strokePositionPoint.call(void 0, g.line, sp, tt);
4083
+ const at = _chunkFKONE6AOcjs.strokePositionPoint.call(void 0, g.line, sp, tt);
4084
4084
  const round = (v) => Math.round(v * 1e6) / 1e6;
4085
- const q = at ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, this.worldOf(nodeId), { x: at.point[0], y: at.point[1] }) : { x: 0, y: 0 };
4085
+ const q = at ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, this.worldOf(nodeId), { x: at.point[0], y: at.point[1] }) : { x: 0, y: 0 };
4086
4086
  const point = { x: round(q.x), y: round(q.y) };
4087
4087
  return { nodeId, subpath: sp, index, t: round(tt), left: round(sides2.left * g.unit), right: round(sides2.right * g.unit), point };
4088
4088
  }
@@ -4096,7 +4096,7 @@ var VectorEditorController = (_class3 = class {
4096
4096
  const refs = this.cornerTargets(options);
4097
4097
  if (!refs.length) return { ok: false, message: "Nothing is selected." };
4098
4098
  this.change(radius > 0 ? "Corner Radius" : "Sharpen Corners", () => {
4099
- this.doc = this.updateAnchors(this.doc, refs, (a) => _chunkXCXQDPIDcjs.setAnchorCorner.call(void 0, a, radius, options.kind));
4099
+ this.doc = this.updateAnchors(this.doc, refs, (a) => _chunkFKONE6AOcjs.setAnchorCorner.call(void 0, a, radius, options.kind));
4100
4100
  });
4101
4101
  return { ok: true };
4102
4102
  }
@@ -4105,7 +4105,7 @@ var VectorEditorController = (_class3 = class {
4105
4105
  const refs = this.cornerTargets(options);
4106
4106
  if (!refs.length) return { ok: false, message: "Nothing is selected." };
4107
4107
  this.change("Corner Kind", () => {
4108
- this.doc = this.updateAnchors(this.doc, refs, (a) => _chunkXCXQDPIDcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _141 => _141.corner, 'optionalAccess', _142 => _142.radius]), () => ( 0)), kind));
4108
+ this.doc = this.updateAnchors(this.doc, refs, (a) => _chunkFKONE6AOcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _141 => _141.corner, 'optionalAccess', _142 => _142.radius]), () => ( 0)), kind));
4109
4109
  });
4110
4110
  return { ok: true };
4111
4111
  }
@@ -4117,7 +4117,7 @@ var VectorEditorController = (_class3 = class {
4117
4117
  for (const id of _nullishCoalesce(options.ids, () => ( this.selection))) {
4118
4118
  const node = this.getNode(id);
4119
4119
  if (!node) continue;
4120
- for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node)) {
4120
+ for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node)) {
4121
4121
  if (p.locked) continue;
4122
4122
  p.subpaths.forEach((sp, s) => sp.anchors.forEach((_, i) => out.push({ nodeId: p.id, subpath: s, index: i })));
4123
4123
  }
@@ -4135,14 +4135,14 @@ var VectorEditorController = (_class3 = class {
4135
4135
  for (const id of roots) {
4136
4136
  const node = this.getNode(id);
4137
4137
  if (node) {
4138
- for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node)) if (!p.locked && _chunkXCXQDPIDcjs.hasPaint.call(void 0, p.stroke) && (_nullishCoalesce(p.strokeWidth, () => ( 1))) > 0) paths.push(p);
4138
+ for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node)) if (!p.locked && _chunkFKONE6AOcjs.hasPaint.call(void 0, p.stroke) && (_nullishCoalesce(p.strokeWidth, () => ( 1))) > 0) paths.push(p);
4139
4139
  }
4140
4140
  }
4141
4141
  if (!paths.length) return [];
4142
4142
  const created = [];
4143
4143
  const replace = /* @__PURE__ */ new Map();
4144
4144
  for (const p of paths) {
4145
- const outline = _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, _chunkXCXQDPIDcjs.vectorStrokeOutlinePath.call(void 0, _chunkXCXQDPIDcjs.vectorAppearanceOutline.call(void 0, p), p));
4145
+ const outline = _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, _chunkFKONE6AOcjs.vectorStrokeOutlinePath.call(void 0, _chunkFKONE6AOcjs.vectorAppearanceOutline.call(void 0, p), p));
4146
4146
  if (!outline.length) continue;
4147
4147
  const {
4148
4148
  stroke,
@@ -4159,10 +4159,10 @@ var VectorEditorController = (_class3 = class {
4159
4159
  strokeWidthProfile: _wp,
4160
4160
  effects,
4161
4161
  ...rest
4162
- } = _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, p);
4162
+ } = _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, p);
4163
4163
  const id = this.newId();
4164
4164
  const strokeNode = { ...rest, id, name: `${_nullishCoalesce(p.name, () => ( "Path"))} Stroke`, subpaths: outline, fill: _nullishCoalesce(stroke, () => ( null)), stroke: null, fillRule: "nonzero" };
4165
- const list = _chunkXCXQDPIDcjs.hasPaint.call(void 0, p.fill) ? [{ ...rest, ...effects ? { effects } : {}, stroke: null }, strokeNode] : [strokeNode];
4165
+ const list = _chunkFKONE6AOcjs.hasPaint.call(void 0, p.fill) ? [{ ...rest, ...effects ? { effects } : {}, stroke: null }, strokeNode] : [strokeNode];
4166
4166
  created.push(id);
4167
4167
  replace.set(p.id, list);
4168
4168
  }
@@ -4191,7 +4191,7 @@ var VectorEditorController = (_class3 = class {
4191
4191
  */
4192
4192
  addEffect(type, options = {}) {
4193
4193
  const targets = this.effectTargets(options.ids);
4194
- if (!targets.length || !_chunkXCXQDPIDcjs.createVectorEffect.call(void 0, type, "")) return [];
4194
+ if (!targets.length || !_chunkFKONE6AOcjs.createVectorEffect.call(void 0, type, "")) return [];
4195
4195
  const created = [];
4196
4196
  const next = /* @__PURE__ */ new Map();
4197
4197
  for (const node of targets) {
@@ -4200,15 +4200,15 @@ var VectorEditorController = (_class3 = class {
4200
4200
  while (list.some((e) => e.id === `fx${k}`)) k++;
4201
4201
  const params = { ..._nullishCoalesce(options.params, () => ( {})) };
4202
4202
  if (type === "repeater" && params.position === void 0) {
4203
- const b = _chunkO2UH7LZEcjs.bezierPathBounds.call(void 0, _chunkXCXQDPIDcjs.vectorAppearanceOutline.call(void 0, node));
4203
+ const b = _chunkO2UH7LZEcjs.bezierPathBounds.call(void 0, _chunkFKONE6AOcjs.vectorAppearanceOutline.call(void 0, node));
4204
4204
  if (b && b.maxX - b.minX > 0) params.position = { x: Math.round((b.maxX - b.minX) * 1.25 * 100) / 100, y: 0 };
4205
4205
  }
4206
- const effect = _chunkXCXQDPIDcjs.createVectorEffect.call(void 0, type, `fx${k}`, params);
4206
+ const effect = _chunkFKONE6AOcjs.createVectorEffect.call(void 0, type, `fx${k}`, params);
4207
4207
  const at = options.index === void 0 ? list.length : Math.min(list.length, Math.max(0, Math.round(options.index)));
4208
4208
  next.set(node.id, { ...node, effects: [...list.slice(0, at), effect, ...list.slice(at)] });
4209
4209
  created.push(effect.id);
4210
4210
  }
4211
- this.change(`Add ${_chunkXCXQDPIDcjs.VECTOR_EFFECT_LABELS[type]}`, () => this.setDoc(mapTree(this.doc.nodes, (n) => _nullishCoalesce(next.get(n.id), () => ( n)))));
4211
+ this.change(`Add ${_chunkFKONE6AOcjs.VECTOR_EFFECT_LABELS[type]}`, () => this.setDoc(mapTree(this.doc.nodes, (n) => _nullishCoalesce(next.get(n.id), () => ( n)))));
4212
4212
  return created;
4213
4213
  }
4214
4214
  editEffects(nodeId, label, fn, merge) {
@@ -4228,7 +4228,7 @@ var VectorEditorController = (_class3 = class {
4228
4228
  const merge = options.merge === true ? `effect:${nodeId}:${effectId}` : options.merge || void 0;
4229
4229
  const node = this.getNode(nodeId);
4230
4230
  const current = _optionalChain([node, 'optionalAccess', _143 => _143.effects, 'optionalAccess', _144 => _144.find, 'call', _145 => _145((e) => e.id === effectId)]);
4231
- const label = current ? _nullishCoalesce(_chunkXCXQDPIDcjs.VECTOR_EFFECT_LABELS[current.type], () => ( "Effect")) : "Effect";
4231
+ const label = current ? _nullishCoalesce(_chunkFKONE6AOcjs.VECTOR_EFFECT_LABELS[current.type], () => ( "Effect")) : "Effect";
4232
4232
  return this.editEffects(
4233
4233
  nodeId,
4234
4234
  `Edit ${label}`,
@@ -4237,7 +4237,7 @@ var VectorEditorController = (_class3 = class {
4237
4237
  if (i < 0) return `Node "${nodeId}" has no effect "${effectId}".`;
4238
4238
  const e = list[i];
4239
4239
  const raw = patch.params && e.type === "envelope" && node ? this.envelopeParams(node, e, patch.params) : patch.params;
4240
- const params = raw ? _chunkXCXQDPIDcjs.normalizeVectorEffectParams.call(void 0, e.type, raw, e.params) : e.params;
4240
+ const params = raw ? _chunkFKONE6AOcjs.normalizeVectorEffectParams.call(void 0, e.type, raw, e.params) : e.params;
4241
4241
  const next = { ...e, params, ...patch.enabled !== void 0 ? { enabled: patch.enabled } : {} };
4242
4242
  if (next.enabled !== false) delete next.enabled;
4243
4243
  return list.map((x, j) => j === i ? next : x);
@@ -4268,16 +4268,16 @@ var VectorEditorController = (_class3 = class {
4268
4268
  * nodes (empty when none was live).
4269
4269
  */
4270
4270
  expandAppearance(options = {}) {
4271
- const roots = (_nullishCoalesce(options.ids, () => ( this.selectedRoots()))).map((id) => this.getNode(id)).filter((n) => !!n && _chunkXCXQDPIDcjs.hasVectorAppearance.call(void 0, n));
4271
+ const roots = (_nullishCoalesce(options.ids, () => ( this.selectedRoots()))).map((id) => this.getNode(id)).filter((n) => !!n && _chunkFKONE6AOcjs.hasVectorAppearance.call(void 0, n));
4272
4272
  if (!roots.length) return [];
4273
4273
  const fresh = (n) => {
4274
4274
  const id = n.id.includes("~fx") ? this.newId() : n.id;
4275
4275
  return n.type === "group" ? { ...n, id, children: n.children.map(fresh) } : { ...n, id };
4276
4276
  };
4277
4277
  const bake = (n) => {
4278
- if (!_chunkXCXQDPIDcjs.hasVectorAppearance.call(void 0, n)) return n;
4279
- if (!_chunkXCXQDPIDcjs.hasOwnVectorAppearance.call(void 0, n)) return { ...n, children: n.children.map(bake) };
4280
- let e = _chunkXCXQDPIDcjs.expandVectorAppearance.call(void 0, n);
4278
+ if (!_chunkFKONE6AOcjs.hasVectorAppearance.call(void 0, n)) return n;
4279
+ if (!_chunkFKONE6AOcjs.hasOwnVectorAppearance.call(void 0, n)) return { ...n, children: n.children.map(bake) };
4280
+ let e = _chunkFKONE6AOcjs.expandVectorAppearance.call(void 0, n);
4281
4281
  if (e.type === "group" && e.children.length === 1 && e.children[0].type === "path") {
4282
4282
  const { id: _id, opacity, name, ...child } = e.children[0];
4283
4283
  const k = (_nullishCoalesce(e.opacity, () => ( 1))) * (_nullishCoalesce(opacity, () => ( 1)));
@@ -4360,11 +4360,11 @@ var VectorEditorController = (_class3 = class {
4360
4360
  selectedRoots() {
4361
4361
  return this.selection.filter((id) => {
4362
4362
  let covered = false;
4363
- const loc = _chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, id);
4363
+ const loc = _chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, id);
4364
4364
  let parent = _nullishCoalesce(_optionalChain([loc, 'optionalAccess', _146 => _146.parent]), () => ( null));
4365
4365
  while (parent) {
4366
4366
  if (this.selection.includes(parent.id)) covered = true;
4367
- parent = _nullishCoalesce(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, parent.id), 'optionalAccess', _147 => _147.parent]), () => ( null));
4367
+ parent = _nullishCoalesce(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, parent.id), 'optionalAccess', _147 => _147.parent]), () => ( null));
4368
4368
  }
4369
4369
  return !covered;
4370
4370
  });
@@ -4375,12 +4375,12 @@ var VectorEditorController = (_class3 = class {
4375
4375
  /** `m`, given in a frame rotated by `angle`, as a document-space matrix. */
4376
4376
  inFrame(angle, m) {
4377
4377
  if (!angle) return m;
4378
- return _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -angle), m), _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, angle));
4378
+ return _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -angle), m), _chunkFKONE6AOcjs.rotateMatrix.call(void 0, angle));
4379
4379
  }
4380
4380
  /** The selection frame's corners in document space, clockwise from the top left. */
4381
4381
  frameCorners(frame) {
4382
- const rot = _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, frame.angle);
4383
- return vectorBoxCorners(frame).map((c) => frame.angle ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, rot, c) : c);
4382
+ const rot = _chunkFKONE6AOcjs.rotateMatrix.call(void 0, frame.angle);
4383
+ return vectorBoxCorners(frame).map((c) => frame.angle ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, rot, c) : c);
4384
4384
  }
4385
4385
  /** `doc` with nodes `ids` sent through `f` (a map of document space), each in its own space (see `distortVectorNode`). */
4386
4386
  distorted(doc, ids, f, tolerance = VECTOR_DISTORT_TOLERANCE) {
@@ -4390,7 +4390,7 @@ var VectorEditorController = (_class3 = class {
4390
4390
  let next = n;
4391
4391
  if (ids.has(n.id) && !n.locked) next = distortVectorNode(n, parent, f, tolerance);
4392
4392
  else if (n.type === "group") {
4393
- const children = visit(n.children, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent));
4393
+ const children = visit(n.children, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent));
4394
4394
  if (children !== n.children) next = { ...n, children };
4395
4395
  }
4396
4396
  if (next !== n) changed = true;
@@ -4398,7 +4398,7 @@ var VectorEditorController = (_class3 = class {
4398
4398
  });
4399
4399
  return changed ? out : list;
4400
4400
  };
4401
- const nodes = visit(doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
4401
+ const nodes = visit(doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
4402
4402
  return nodes === doc.nodes ? doc : { ...doc, nodes };
4403
4403
  }
4404
4404
  /**
@@ -4440,13 +4440,13 @@ var VectorEditorController = (_class3 = class {
4440
4440
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4441
4441
  if (!frame) return { ok: false, message: "Nothing is selected." };
4442
4442
  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 = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4443
+ const origin = _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4444
4444
  return this.transform(this.inFrame(frame.angle, vectorSkewMatrix(ax, ay, origin)), { ids: options.ids, label: "Skew" });
4445
4445
  }
4446
4446
  /** A selection box handle dragged in Free Distort mode. */
4447
4447
  moveDistort(drag, p, input) {
4448
4448
  const angle = drag.frame.angle;
4449
- const unrotate = (v) => angle ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -angle), v) : v;
4449
+ const unrotate = (v) => angle ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -angle), v) : v;
4450
4450
  const q = unrotate(p);
4451
4451
  const q0 = unrotate(drag.start);
4452
4452
  const d = { x: q.x - q0.x, y: q.y - q0.y };
@@ -4458,13 +4458,13 @@ var VectorEditorController = (_class3 = class {
4458
4458
  const m = this.inFrame(angle, vectorShearForSide(drag.frame, drag.handle, d, !!input.alt));
4459
4459
  drag.op = "Skew";
4460
4460
  this.doc = this.transformed(drag.base, ids, m);
4461
- this.interaction = { type: "distort", mode: "skew", corners: from.map((c) => _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, c)) };
4461
+ this.interaction = { type: "distort", mode: "skew", corners: from.map((c) => _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, c)) };
4462
4462
  this.notify(true);
4463
4463
  return;
4464
4464
  }
4465
4465
  const mode = corner && input.mod && input.alt && input.shift ? "perspective" : "distort";
4466
- const rot = _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, angle);
4467
- const quad = vectorDistortQuad(drag.frame, drag.handle, d, mode).map((c) => angle ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, rot, c) : c);
4466
+ const rot = _chunkFKONE6AOcjs.rotateMatrix.call(void 0, angle);
4467
+ const quad = vectorDistortQuad(drag.frame, drag.handle, d, mode).map((c) => angle ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, rot, c) : c);
4468
4468
  const h = vectorHomography(from, quad);
4469
4469
  if (!h || !vectorHomographyKeepsQuad(h, from)) return;
4470
4470
  drag.op = mode === "perspective" ? "Perspective" : "Distort";
@@ -4482,11 +4482,11 @@ var VectorEditorController = (_class3 = class {
4482
4482
  /** Envelope parameters for `node` after `patch`: a preset switched to a mesh becomes the mesh it stood for. */
4483
4483
  envelopeParams(node, current, patch) {
4484
4484
  if (patch.style !== "mesh" || patch.mesh !== void 0 || !current || current.params.style === "mesh") return patch;
4485
- const frame = _chunkXCXQDPIDcjs.vectorEnvelopeFrame.call(void 0, node, current.id);
4485
+ const frame = _chunkFKONE6AOcjs.vectorEnvelopeFrame.call(void 0, node, current.id);
4486
4486
  if (!frame) return patch;
4487
4487
  const rows = typeof patch.rows === "number" ? patch.rows : current.params.rows;
4488
4488
  const columns = typeof patch.columns === "number" ? patch.columns : current.params.columns;
4489
- return { ...patch, mesh: _chunkXCXQDPIDcjs.resizeVectorMesh.call(void 0, frame.mesh, columns, rows) };
4489
+ return { ...patch, mesh: _chunkFKONE6AOcjs.resizeVectorMesh.call(void 0, frame.mesh, columns, rows) };
4490
4490
  }
4491
4491
  /**
4492
4492
  * Gives the selected (or given) nodes an envelope distortion, or changes the one they have: a
@@ -4506,14 +4506,14 @@ var VectorEditorController = (_class3 = class {
4506
4506
  const list = _nullishCoalesce(node.effects, () => ( []));
4507
4507
  const current = _nullishCoalesce(list.find((e) => e.type === "envelope"), () => ( null));
4508
4508
  if (current) {
4509
- const p = _chunkXCXQDPIDcjs.normalizeVectorEffectParams.call(void 0, "envelope", this.envelopeParams(node, current, raw), current.params);
4509
+ const p = _chunkFKONE6AOcjs.normalizeVectorEffectParams.call(void 0, "envelope", this.envelopeParams(node, current, raw), current.params);
4510
4510
  const { enabled: _e, ...rest } = current;
4511
4511
  next.set(node.id, { ...node, effects: list.map((e) => e === current ? { ...rest, params: p } : e) });
4512
4512
  out.push({ nodeId: node.id, effectId: current.id });
4513
4513
  } else {
4514
4514
  let k = list.length + 1;
4515
4515
  while (list.some((e) => e.id === `fx${k}`)) k++;
4516
- const effect = _chunkXCXQDPIDcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, raw);
4516
+ const effect = _chunkFKONE6AOcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, raw);
4517
4517
  next.set(node.id, { ...node, effects: [...list, effect] });
4518
4518
  out.push({ nodeId: node.id, effectId: effect.id });
4519
4519
  }
@@ -4533,7 +4533,7 @@ var VectorEditorController = (_class3 = class {
4533
4533
  const ids = _nullishCoalesce(options.ids, () => ( this.selectedRoots()));
4534
4534
  if (ids.length < 2) return { ok: false, message: "Select the objects and, on top of them, the shape to use as the envelope." };
4535
4535
  const order = /* @__PURE__ */ new Map();
4536
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => order.set(n.id, order.size));
4536
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => order.set(n.id, order.size));
4537
4537
  const sorted = ids.filter((id) => order.has(id)).sort((a, b) => order.get(a) - order.get(b));
4538
4538
  const topId = sorted[sorted.length - 1];
4539
4539
  const top = this.getNode(topId);
@@ -4541,26 +4541,26 @@ var VectorEditorController = (_class3 = class {
4541
4541
  if (!top || !outline) return { ok: false, message: "The top object must be a path with a closed outline." };
4542
4542
  const contents = sorted.slice(0, -1).map((id) => this.getNode(id));
4543
4543
  if (contents.some((n) => n.locked)) return { ok: false, message: "Locked objects cannot be enveloped." };
4544
- const parents = contents.map((n) => _nullishCoalesce(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _154 => _154.parent, 'optionalAccess', _155 => _155.id]), () => ( null)));
4544
+ const parents = contents.map((n) => _nullishCoalesce(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _154 => _154.parent, 'optionalAccess', _155 => _155.id]), () => ( null)));
4545
4545
  if (parents.some((p) => p !== parents[0])) return { ok: false, message: "The objects to envelope must be in the same group." };
4546
4546
  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]) : _chunkXCXQDPIDcjs.IDENTITY_MATRIX;
4548
- const targetToDoc = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, target), parentToDoc);
4549
- const toLocal = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, this.worldOf(topId), _chunkXCXQDPIDcjs.invertMatrix.call(void 0, targetToDoc));
4547
+ const parentToDoc = parents[0] ? this.worldOf(parents[0]) : _chunkFKONE6AOcjs.IDENTITY_MATRIX;
4548
+ const targetToDoc = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, target), parentToDoc);
4549
+ const toLocal = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, this.worldOf(topId), _chunkFKONE6AOcjs.invertMatrix.call(void 0, targetToDoc));
4550
4550
  const local = {
4551
4551
  closed: true,
4552
4552
  anchors: outline.anchors.map((a) => ({
4553
- ..._chunkXCXQDPIDcjs.applyMatrix.call(void 0, toLocal, a),
4554
- ...a.in ? { in: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toLocal, a.in) } : {},
4555
- ...a.out ? { out: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, toLocal, a.out) } : {}
4553
+ ..._chunkFKONE6AOcjs.applyMatrix.call(void 0, toLocal, a),
4554
+ ...a.in ? { in: _chunkFKONE6AOcjs.applyMatrix.call(void 0, toLocal, a.in) } : {},
4555
+ ...a.out ? { out: _chunkFKONE6AOcjs.applyMatrix.call(void 0, toLocal, a.out) } : {}
4556
4556
  }))
4557
4557
  };
4558
- const mesh = _chunkXCXQDPIDcjs.vectorMeshFromOutline.call(void 0, local, _nullishCoalesce(options.columns, () => ( 4)), _nullishCoalesce(options.rows, () => ( 4)));
4558
+ const mesh = _chunkFKONE6AOcjs.vectorMeshFromOutline.call(void 0, local, _nullishCoalesce(options.columns, () => ( 4)), _nullishCoalesce(options.rows, () => ( 4)));
4559
4559
  if (!mesh) return { ok: false, message: "The top object\u2019s outline is too small to use as an envelope." };
4560
4560
  const list = _nullishCoalesce(target.effects, () => ( []));
4561
4561
  let k = list.length + 1;
4562
4562
  while (list.some((e) => e.id === `fx${k}`)) k++;
4563
- const effect = _chunkXCXQDPIDcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, { style: "mesh", mesh });
4563
+ const effect = _chunkFKONE6AOcjs.createVectorEffect.call(void 0, "envelope", `fx${k}`, { style: "mesh", mesh });
4564
4564
  const enveloped = { ...target, effects: [...list, effect] };
4565
4565
  this.change("Make Envelope with Top Object", () => {
4566
4566
  let nodes = spliceTree(this.doc.nodes, topId, []);
@@ -4588,7 +4588,7 @@ var VectorEditorController = (_class3 = class {
4588
4588
  const replace = /* @__PURE__ */ new Map();
4589
4589
  for (const node of targets) {
4590
4590
  const effect = node.effects.find((e) => e.type === "envelope");
4591
- const frame = _chunkXCXQDPIDcjs.vectorEnvelopeFrame.call(void 0, node, effect.id);
4591
+ const frame = _chunkFKONE6AOcjs.vectorEnvelopeFrame.call(void 0, node, effect.id);
4592
4592
  const rest = node.effects.filter((e) => e !== effect);
4593
4593
  const { effects: _e, ...plain2 } = node;
4594
4594
  const kept = rest.length ? { ...plain2, effects: rest } : plain2;
@@ -4603,7 +4603,7 @@ var VectorEditorController = (_class3 = class {
4603
4603
  type: "path",
4604
4604
  name: "Envelope",
4605
4605
  ...node.transform ? { transform: node.transform } : {},
4606
- subpaths: [_chunkXCXQDPIDcjs.vectorMeshOutline.call(void 0, frame.mesh)],
4606
+ subpaths: [_chunkFKONE6AOcjs.vectorMeshOutline.call(void 0, frame.mesh)],
4607
4607
  fill: null,
4608
4608
  stroke: "#808080",
4609
4609
  strokeWidth: 1
@@ -4629,11 +4629,11 @@ var VectorEditorController = (_class3 = class {
4629
4629
  const target = this.envelopeTarget();
4630
4630
  if (!target) return null;
4631
4631
  const { mesh } = target.frame;
4632
- const pts = _chunkXCXQDPIDcjs.vectorMeshEditPoints.call(void 0, mesh);
4632
+ const pts = _chunkFKONE6AOcjs.vectorMeshEditPoints.call(void 0, mesh);
4633
4633
  let best = null;
4634
4634
  let bestD = Infinity;
4635
4635
  for (const index of [...pts.handles.map((h) => h.index), ...pts.anchors]) {
4636
- const s = this.documentToScreen(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, target.world, mesh.points[index]));
4636
+ const s = this.documentToScreen(_chunkFKONE6AOcjs.applyMatrix.call(void 0, target.world, mesh.points[index]));
4637
4637
  const d = Math.hypot(s.x - screen.x, s.y - screen.y);
4638
4638
  if (d <= this.hitRadius && d < bestD - 0.5) {
4639
4639
  best = index;
@@ -4641,8 +4641,8 @@ var VectorEditorController = (_class3 = class {
4641
4641
  }
4642
4642
  }
4643
4643
  if (best !== null) return { target, index: best, s: 0, t: 0 };
4644
- const local = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, target.world), p);
4645
- const at = _chunkXCXQDPIDcjs.vectorMeshParamAt.call(void 0, mesh, local);
4644
+ const local = _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.invertMatrix.call(void 0, target.world), p);
4645
+ const at = _chunkFKONE6AOcjs.vectorMeshParamAt.call(void 0, mesh, local);
4646
4646
  if (at.distance > this.tolerance()) return null;
4647
4647
  return { target, index: null, s: at.s, t: at.t };
4648
4648
  }
@@ -4667,7 +4667,7 @@ var VectorEditorController = (_class3 = class {
4667
4667
  this.notify();
4668
4668
  return;
4669
4669
  }
4670
- const node = _chunkXCXQDPIDcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
4670
+ const node = _chunkFKONE6AOcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
4671
4671
  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
4672
  else if (!input.shift) this.selection = [];
4673
4673
  this.anchors = [];
@@ -4678,7 +4678,7 @@ var VectorEditorController = (_class3 = class {
4678
4678
  const d = { x: local.x - drag.start.x, y: local.y - drag.start.y };
4679
4679
  if (!drag.moved && Math.hypot(d.x, d.y) * this.viewport.zoom < 1) return;
4680
4680
  drag.moved = true;
4681
- const mesh = drag.index !== null ? _chunkXCXQDPIDcjs.dragVectorMeshPoint.call(void 0, drag.base, drag.index, d) : _chunkXCXQDPIDcjs.pullVectorMesh.call(void 0, drag.base, drag.s, drag.t, d);
4681
+ const mesh = drag.index !== null ? _chunkFKONE6AOcjs.dragVectorMeshPoint.call(void 0, drag.base, drag.index, d) : _chunkFKONE6AOcjs.pullVectorMesh.call(void 0, drag.base, drag.s, drag.t, d);
4682
4682
  const nodes = mapTree(drag.baseDoc.nodes, (n) => {
4683
4683
  if (n.id !== drag.nodeId) return n;
4684
4684
  const effects = (_nullishCoalesce(n.effects, () => ( []))).map(
@@ -4705,10 +4705,10 @@ var VectorEditorController = (_class3 = class {
4705
4705
  const out = list.map((n) => {
4706
4706
  let next = n;
4707
4707
  if (ids.has(n.id) && !n.locked) {
4708
- const local = isRoot(parent) ? m : _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, parent, m), _chunkXCXQDPIDcjs.invertMatrix.call(void 0, parent));
4709
- next = _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, n, local);
4708
+ const local = isRoot(parent) ? m : _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, parent, m), _chunkFKONE6AOcjs.invertMatrix.call(void 0, parent));
4709
+ next = _chunkFKONE6AOcjs.transformVectorNode.call(void 0, n, local);
4710
4710
  } else if (n.type === "group") {
4711
- const children = visit(n.children, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent));
4711
+ const children = visit(n.children, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent));
4712
4712
  if (children !== n.children) next = { ...n, children };
4713
4713
  }
4714
4714
  if (next !== n) changed = true;
@@ -4716,7 +4716,7 @@ var VectorEditorController = (_class3 = class {
4716
4716
  });
4717
4717
  return changed ? out : list;
4718
4718
  };
4719
- const nodes = visit(doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
4719
+ const nodes = visit(doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
4720
4720
  return nodes === doc.nodes ? doc : { ...doc, nodes };
4721
4721
  }
4722
4722
  translate(dx, dy, options = {}) {
@@ -4726,11 +4726,11 @@ var VectorEditorController = (_class3 = class {
4726
4726
  });
4727
4727
  return { ok: true };
4728
4728
  }
4729
- return this.transform(_chunkXCXQDPIDcjs.translateMatrix.call(void 0, dx, dy), { ids: options.ids, label: "Move" });
4729
+ return this.transform(_chunkFKONE6AOcjs.translateMatrix.call(void 0, dx, dy), { ids: options.ids, label: "Move" });
4730
4730
  }
4731
4731
  /** The selection frame's centre in document space. */
4732
4732
  frameCenter(frame) {
4733
- return _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
4733
+ return _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
4734
4734
  }
4735
4735
  /**
4736
4736
  * Scales along the selection box's own axes (rotated with the selection when its nodes
@@ -4739,15 +4739,15 @@ var VectorEditorController = (_class3 = class {
4739
4739
  scale(sx, sy = sx, options = {}) {
4740
4740
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4741
4741
  if (!frame) return { ok: false, message: "Nothing is selected." };
4742
- const origin = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4743
- return this.transform(this.inFrame(frame.angle, _chunkXCXQDPIDcjs.scaleMatrix.call(void 0, sx, sy, origin)), { ids: options.ids, label: "Scale" });
4742
+ const origin = _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -frame.angle), _nullishCoalesce(options.origin, () => ( this.frameCenter(frame))));
4743
+ return this.transform(this.inFrame(frame.angle, _chunkFKONE6AOcjs.scaleMatrix.call(void 0, sx, sy, origin)), { ids: options.ids, label: "Scale" });
4744
4744
  }
4745
4745
  /** Rotates clockwise by `degrees` around `origin` (default: the selection centre). */
4746
4746
  rotate(degrees, options = {}) {
4747
4747
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4748
4748
  if (!frame) return { ok: false, message: "Nothing is selected." };
4749
4749
  const origin = _nullishCoalesce(options.origin, () => ( this.frameCenter(frame)));
4750
- return this.transform(_chunkXCXQDPIDcjs.rotateMatrix.call(void 0, degrees, origin), { ids: options.ids, label: "Rotate" });
4750
+ return this.transform(_chunkFKONE6AOcjs.rotateMatrix.call(void 0, degrees, origin), { ids: options.ids, label: "Rotate" });
4751
4751
  }
4752
4752
  /** Sets each selected (or given) node's rotation to `degrees`, turning it around its own centre. */
4753
4753
  setRotation(degrees, options = {}) {
@@ -4758,7 +4758,7 @@ var VectorEditorController = (_class3 = class {
4758
4758
  const frame = this.frameOf([id]);
4759
4759
  if (!frame) continue;
4760
4760
  const delta = normalizeAngle(degrees - frame.angle);
4761
- if (Math.abs(delta) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, delta, this.frameCenter(frame)));
4761
+ if (Math.abs(delta) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunkFKONE6AOcjs.rotateMatrix.call(void 0, delta, this.frameCenter(frame)));
4762
4762
  }
4763
4763
  });
4764
4764
  return { ok: true };
@@ -4768,7 +4768,7 @@ var VectorEditorController = (_class3 = class {
4768
4768
  const frame = this.frameOf(_nullishCoalesce(options.ids, () => ( this.selectedRoots())));
4769
4769
  if (!frame) return { ok: false, message: "Nothing is selected." };
4770
4770
  const c = { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 };
4771
- const m = axis === "horizontal" ? _chunkXCXQDPIDcjs.scaleMatrix.call(void 0, -1, 1, c) : _chunkXCXQDPIDcjs.scaleMatrix.call(void 0, 1, -1, c);
4771
+ const m = axis === "horizontal" ? _chunkFKONE6AOcjs.scaleMatrix.call(void 0, -1, 1, c) : _chunkFKONE6AOcjs.scaleMatrix.call(void 0, 1, -1, c);
4772
4772
  return this.transform(this.inFrame(frame.angle, m), { ids: options.ids, label: axis === "horizontal" ? "Flip Horizontal" : "Flip Vertical" });
4773
4773
  }
4774
4774
  /**
@@ -4791,7 +4791,7 @@ var VectorEditorController = (_class3 = class {
4791
4791
  if (edge === "top") dy = target.y - b.y;
4792
4792
  if (edge === "middle") dy = target.y + target.height / 2 - (b.y + b.height / 2);
4793
4793
  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]), _chunkXCXQDPIDcjs.translateMatrix.call(void 0, dx, dy));
4794
+ if (dx || dy) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([id]), _chunkFKONE6AOcjs.translateMatrix.call(void 0, dx, dy));
4795
4795
  }
4796
4796
  });
4797
4797
  return { ok: true };
@@ -4813,7 +4813,7 @@ var VectorEditorController = (_class3 = class {
4813
4813
  let cursor = pos(first);
4814
4814
  for (const item of items) {
4815
4815
  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 ? _chunkXCXQDPIDcjs.translateMatrix.call(void 0, d, 0) : _chunkXCXQDPIDcjs.translateMatrix.call(void 0, 0, d));
4816
+ if (Math.abs(d) > 1e-9) this.doc = this.transformed(this.doc, /* @__PURE__ */ new Set([item.id]), horizontal ? _chunkFKONE6AOcjs.translateMatrix.call(void 0, d, 0) : _chunkFKONE6AOcjs.translateMatrix.call(void 0, 0, d));
4817
4817
  cursor += size(item.b) + gap;
4818
4818
  }
4819
4819
  });
@@ -4837,14 +4837,14 @@ var VectorEditorController = (_class3 = class {
4837
4837
  }
4838
4838
  withDuplicates(doc, ids, offset, created) {
4839
4839
  const set = new Set(ids);
4840
- const m = _chunkXCXQDPIDcjs.translateMatrix.call(void 0, offset.x, offset.y);
4840
+ const m = _chunkFKONE6AOcjs.translateMatrix.call(void 0, offset.x, offset.y);
4841
4841
  const insert = (list) => {
4842
4842
  const out = [];
4843
4843
  for (const node of list) {
4844
4844
  const n = node.type === "group" ? { ...node, children: insert(node.children) } : node;
4845
4845
  out.push(n);
4846
4846
  if (set.has(node.id)) {
4847
- const copy = _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, this.freshIds(node), m);
4847
+ const copy = _chunkFKONE6AOcjs.transformVectorNode.call(void 0, this.freshIds(node), m);
4848
4848
  created.push(copy.id);
4849
4849
  out.push(copy);
4850
4850
  }
@@ -4857,7 +4857,7 @@ var VectorEditorController = (_class3 = class {
4857
4857
  group(options = {}) {
4858
4858
  const ids = _nullishCoalesce(options.ids, () => ( this.selectedRoots()));
4859
4859
  if (!ids.length) return null;
4860
- const locs = ids.map((id2) => _chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
4860
+ const locs = ids.map((id2) => _chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
4861
4861
  if (locs.some((l) => !l)) return null;
4862
4862
  const parent = _nullishCoalesce(_optionalChain([locs, 'access', _159 => _159[0], 'access', _160 => _160.parent, 'optionalAccess', _161 => _161.id]), () => ( null));
4863
4863
  if (locs.some((l) => (_nullishCoalesce(_optionalChain([l, 'access', _162 => _162.parent, 'optionalAccess', _163 => _163.id]), () => ( null))) !== parent)) return null;
@@ -4894,9 +4894,9 @@ var VectorEditorController = (_class3 = class {
4894
4894
  if (set.has(n.id) && n.type === "group") {
4895
4895
  changed = true;
4896
4896
  const opacity = n.opacity;
4897
- const m = _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n);
4897
+ const m = _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n);
4898
4898
  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 ? _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c)
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 ? _chunkFKONE6AOcjs.transformVectorNode.call(void 0, c, m) : c).map((c) => opacity !== void 0 && opacity < 1 ? { ...c, opacity: (_nullishCoalesce(c.opacity, () => ( 1))) * opacity } : c)
4900
4900
  );
4901
4901
  } else if (n.type === "group") {
4902
4902
  const children = flatten(n.children);
@@ -4948,16 +4948,16 @@ var VectorEditorController = (_class3 = class {
4948
4948
  const result = _chunkO2UH7LZEcjs.pathBoolean.call(void 0,
4949
4949
  BOOLEAN_OPS[op],
4950
4950
  entries.map((e) => ({
4951
- path: _chunkXCXQDPIDcjs.vectorPathWorldBezier.call(void 0, { ...e.node, subpaths: e.node.subpaths.filter((s) => s.anchors.length > 1).map((s) => ({ ...s, closed: true })) }, e.parent),
4951
+ path: _chunkFKONE6AOcjs.vectorPathWorldBezier.call(void 0, { ...e.node, subpaths: e.node.subpaths.filter((s) => s.anchors.length > 1).map((s) => ({ ...s, closed: true })) }, e.parent),
4952
4952
  fillRule: _nullishCoalesce(e.node.fillRule, () => ( "nonzero"))
4953
4953
  }))
4954
4954
  );
4955
4955
  const base = entries[0].node;
4956
4956
  const anchorRoot = _nullishCoalesce(roots.find((r) => this.holds(r, base.id)), () => ( base.id));
4957
- const subpaths = _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(anchorRoot, result.path));
4957
+ const subpaths = _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(anchorRoot, result.path));
4958
4958
  if (result.error || !subpaths.length) return null;
4959
4959
  const id = this.newId();
4960
- const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, base);
4960
+ const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, base);
4961
4961
  const node = { ...baseRest, id, name: BOOLEAN_LABELS[op], subpaths };
4962
4962
  const drop = /* @__PURE__ */ new Set([...entries.map((e) => e.node.id), ...roots]);
4963
4963
  this.change(BOOLEAN_LABELS[op], () => {
@@ -4971,20 +4971,20 @@ var VectorEditorController = (_class3 = class {
4971
4971
  /** Whether stored node `rootId` holds `id` as drawn (`id` may be an expanded path inside it). */
4972
4972
  holds(rootId, id) {
4973
4973
  const n = this.getNode(rootId);
4974
- return !!n && (!!_chunkXCXQDPIDcjs.findVectorNode.call(void 0, [n], id) || !!_chunkXCXQDPIDcjs.findVectorNode.call(void 0, [_chunkXCXQDPIDcjs.expandVectorAppearance.call(void 0, n)], id));
4974
+ return !!n && (!!_chunkFKONE6AOcjs.findVectorNode.call(void 0, [n], id) || !!_chunkFKONE6AOcjs.findVectorNode.call(void 0, [_chunkFKONE6AOcjs.expandVectorAppearance.call(void 0, n)], id));
4975
4975
  }
4976
4976
  liveBooleanOp(op, roots) {
4977
4977
  const nodes = roots.map((id2) => this.getNode(id2));
4978
4978
  if (!nodes.length || nodes.some((n) => !n)) return null;
4979
4979
  const label = `Live ${BOOLEAN_LABELS[op]}`;
4980
4980
  const lone = nodes.length === 1 ? nodes[0] : null;
4981
- if (_chunkXCXQDPIDcjs.isVectorLiveBoolean.call(void 0, lone)) {
4981
+ if (_chunkFKONE6AOcjs.isVectorLiveBoolean.call(void 0, lone)) {
4982
4982
  const children = lone.children.map((c) => c.booleanOperation ? (({ booleanOperation: _b, ...rest }) => rest)(c) : c);
4983
4983
  this.change(label, () => this.replaceNode(lone.id, { ...lone, liveBoolean: op, children }));
4984
4984
  return lone.id;
4985
4985
  }
4986
- const parents = roots.map((id2) => _nullishCoalesce(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, id2), 'optionalAccess', _165 => _165.parent]), () => ( null)));
4987
- if (parents.every((g) => _chunkXCXQDPIDcjs.isVectorLiveBoolean.call(void 0, g))) {
4986
+ const parents = roots.map((id2) => _nullishCoalesce(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, id2), 'optionalAccess', _165 => _165.parent]), () => ( null)));
4987
+ if (parents.every((g) => _chunkFKONE6AOcjs.isVectorLiveBoolean.call(void 0, g))) {
4988
4988
  const set = new Set(roots);
4989
4989
  this.change(
4990
4990
  label,
@@ -5035,8 +5035,8 @@ var VectorEditorController = (_class3 = class {
5035
5035
  const paths = entries.map((e) => e.node);
5036
5036
  const id = this.newId();
5037
5037
  const first = _nullishCoalesce(roots.find((r) => this.holds(r, paths[0].id)), () => ( paths[0].id));
5038
- const subpaths = entries.flatMap((e) => _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(first, _chunkXCXQDPIDcjs.vectorPathWorldBezier.call(void 0, e.node, e.parent))));
5039
- const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, paths[0]);
5038
+ const subpaths = entries.flatMap((e) => _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(first, _chunkFKONE6AOcjs.vectorPathWorldBezier.call(void 0, e.node, e.parent))));
5039
+ const { transform: _t, effects: _e, booleanOperation: _b, ...baseRest } = _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, paths[0]);
5040
5040
  const node = { ...baseRest, id, name: "Compound Path", subpaths };
5041
5041
  const drop = /* @__PURE__ */ new Set([...paths.map((p) => p.id), ...roots]);
5042
5042
  this.change("Combine", () => {
@@ -5048,8 +5048,8 @@ var VectorEditorController = (_class3 = class {
5048
5048
  }
5049
5049
  /** A document-space path mapped into the parent space of node `id`. */
5050
5050
  intoParentSpace(id, path) {
5051
- const parent = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
5052
- return isRoot(parent) ? path : _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, path, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, parent));
5051
+ const parent = _nullishCoalesce(_chunkFKONE6AOcjs.vectorParentMatrix.call(void 0, this.doc.nodes, id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
5052
+ return isRoot(parent) ? path : _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, path, _chunkFKONE6AOcjs.invertMatrix.call(void 0, parent));
5053
5053
  }
5054
5054
  /** Splits selected compound paths into one path per subpath. */
5055
5055
  breakApart(options = {}) {
@@ -5094,7 +5094,7 @@ var VectorEditorController = (_class3 = class {
5094
5094
  const topRoot = _nullishCoalesce([...roots].reverse().find((r) => this.holds(r, last)), () => ( last));
5095
5095
  const nodes = [];
5096
5096
  for (const piece of result.pieces) {
5097
- const subpaths = _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(topRoot, piece.path)).map((sp) => piece.open ? { ...sp, closed: false } : sp);
5097
+ const subpaths = _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, this.intoParentSpace(topRoot, piece.path)).map((sp) => piece.open ? { ...sp, closed: false } : sp);
5098
5098
  if (!subpaths.length) continue;
5099
5099
  const source = entries[piece.source].node;
5100
5100
  const style = vectorResultStyle(source, shapes[piece.source].paint, op === "outline");
@@ -5121,7 +5121,7 @@ var VectorEditorController = (_class3 = class {
5121
5121
  const out = /* @__PURE__ */ new Map();
5122
5122
  for (const id of _nullishCoalesce(ids, () => ( this.selection))) {
5123
5123
  const node = this.getNode(id);
5124
- const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _170 => _170.parent]);
5124
+ const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _170 => _170.parent]);
5125
5125
  if (isVectorBlendGroup(group)) out.set(group.id, group);
5126
5126
  }
5127
5127
  return [...out.values()];
@@ -5138,7 +5138,7 @@ var VectorEditorController = (_class3 = class {
5138
5138
  return !!n && !n.blendStep && !n.locked;
5139
5139
  });
5140
5140
  if (ids.length < 2) return null;
5141
- const locs = ids.map((id2) => _chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
5141
+ const locs = ids.map((id2) => _chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, id2));
5142
5142
  const parent = _nullishCoalesce(_optionalChain([locs, 'access', _171 => _171[0], 'access', _172 => _172.parent, 'optionalAccess', _173 => _173.id]), () => ( null));
5143
5143
  if (locs.some((l) => (_nullishCoalesce(_optionalChain([l, 'access', _174 => _174.parent, 'optionalAccess', _175 => _175.id]), () => ( null))) !== parent)) return null;
5144
5144
  const order = input.keepOrder ? ids : ids.slice().sort((a, b) => locs[ids.indexOf(a)].index - locs[ids.indexOf(b)].index);
@@ -5182,13 +5182,13 @@ var VectorEditorController = (_class3 = class {
5182
5182
  const node = this.getNode(nodeId);
5183
5183
  if (!isVectorBlendGroup(group)) return { ok: false, message: `"${blendId}" is not a blend.` };
5184
5184
  if (!node || node.blendStep || node.locked || node.id === blendId) return { ok: false, message: `"${nodeId}" cannot be a key.` };
5185
- const parentOf = (id) => _nullishCoalesce(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _176 => _176.parent, 'optionalAccess', _177 => _177.id]), () => ( null));
5185
+ const parentOf = (id) => _nullishCoalesce(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, id), 'optionalAccess', _176 => _176.parent, 'optionalAccess', _177 => _177.id]), () => ( null));
5186
5186
  if (parentOf(blendId) !== parentOf(nodeId)) return { ok: false, message: "The new key must sit beside the blend (same parent)." };
5187
5187
  const start = options.start;
5188
5188
  this.change("Blend", () => {
5189
5189
  const blend = start !== null && start !== void 0 ? { ...group.blend, starts: { ...group.blend.starts, [nodeId]: start } } : group.blend;
5190
- const m = _chunkXCXQDPIDcjs.invertMatrix.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, group));
5191
- const key = group.transform ? _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, node, m) : node;
5190
+ const m = _chunkFKONE6AOcjs.invertMatrix.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, group));
5191
+ const key = group.transform ? _chunkFKONE6AOcjs.transformVectorNode.call(void 0, node, m) : node;
5192
5192
  const without = mapTree(this.doc.nodes, (n) => n.id === nodeId ? null : n);
5193
5193
  this.setDoc(spliceTree(without, blendId, [{ ...group, blend, children: [...group.children, key] }]));
5194
5194
  this.selection = [blendId];
@@ -5214,7 +5214,7 @@ var VectorEditorController = (_class3 = class {
5214
5214
  if (!groups.length) return [];
5215
5215
  const set = new Set(groups.map((g) => g.id));
5216
5216
  const used = /* @__PURE__ */ new Set();
5217
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
5217
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => used.add(n.id));
5218
5218
  const fresh = () => {
5219
5219
  let id = this.createId();
5220
5220
  while (used.has(id)) id = this.createId();
@@ -5252,14 +5252,14 @@ var VectorEditorController = (_class3 = class {
5252
5252
  replaceBlendSpine(options = {}) {
5253
5253
  const roots = _nullishCoalesce(options.ids, () => ( this.selectedRoots()));
5254
5254
  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([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _179 => _179.parent])));
5255
+ const paths = roots.map((id) => this.getNode(id)).filter((n) => _optionalChain([n, 'optionalAccess', _178 => _178.type]) === "path" && !n.blendStep && !isVectorBlendGroup(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, this.doc.nodes, n.id), 'optionalAccess', _179 => _179.parent])));
5256
5256
  if (groups.length !== 1 || paths.length !== 1) return { ok: false, message: "Select one blend and one path to be its spine." };
5257
5257
  const group = groups[0];
5258
5258
  const path = paths[0];
5259
5259
  const first = path.subpaths.find((sp) => sp.anchors.length >= 2);
5260
5260
  if (!first) return { ok: false, message: "The spine needs a path with at least two points." };
5261
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, this.worldOf(path.id), _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(group.id)));
5262
- const spine = _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, { id: "", type: "path", subpaths: [first] }, m).subpaths[0];
5261
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, this.worldOf(path.id), _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(group.id)));
5262
+ const spine = _chunkFKONE6AOcjs.transformVectorNode.call(void 0, { id: "", type: "path", subpaths: [first] }, m).subpaths[0];
5263
5263
  this.change("Replace Spine", () => {
5264
5264
  const withSpine = { ...group, blend: { ...group.blend, spine } };
5265
5265
  const targets = vectorBlendKeyTargets(withSpine);
@@ -5267,11 +5267,11 @@ var VectorEditorController = (_class3 = class {
5267
5267
  const children = withSpine.children.map((c) => {
5268
5268
  if (c.blendStep) return c;
5269
5269
  const target = targets[k++];
5270
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, c);
5270
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, c);
5271
5271
  if (!target || !b) return c;
5272
5272
  const dx = target[0] - (b.x + b.width / 2);
5273
5273
  const dy = target[1] - (b.y + b.height / 2);
5274
- return Math.hypot(dx, dy) > 1e-9 ? _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, c, _chunkXCXQDPIDcjs.translateMatrix.call(void 0, dx, dy)) : c;
5274
+ return Math.hypot(dx, dy) > 1e-9 ? _chunkFKONE6AOcjs.transformVectorNode.call(void 0, c, _chunkFKONE6AOcjs.translateMatrix.call(void 0, dx, dy)) : c;
5275
5275
  });
5276
5276
  this.setDoc(mapTree(this.doc.nodes, (n) => n.id === path.id ? null : n.id === group.id ? { ...withSpine, children } : n));
5277
5277
  this.selection = [group.id];
@@ -5339,15 +5339,15 @@ var VectorEditorController = (_class3 = class {
5339
5339
  let nodes = this.doc.nodes;
5340
5340
  m.entries.forEach((entry, i) => {
5341
5341
  const node = entry.node;
5342
- const toLocal = (path) => _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, path, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, node), entry.parent)));
5342
+ const toLocal = (path) => _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, path, _chunkFKONE6AOcjs.invertMatrix.call(void 0, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, node), entry.parent)));
5343
5343
  const list = [];
5344
5344
  const r = plan.replace.get(i);
5345
5345
  if (r === void 0) list.push(node);
5346
- else if (_optionalChain([r, 'optionalAccess', _182 => _182.kind]) === "fill") list.push({ ...node, fillRule: "nonzero", subpaths: _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5347
- else if (_optionalChain([r, 'optionalAccess', _183 => _183.kind]) === "outline") list.push({ ...node, subpaths: _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5346
+ else if (_optionalChain([r, 'optionalAccess', _182 => _182.kind]) === "fill") list.push({ ...node, fillRule: "nonzero", subpaths: _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5347
+ else if (_optionalChain([r, 'optionalAccess', _183 => _183.kind]) === "outline") list.push({ ...node, subpaths: _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, toLocal(r.path)) });
5348
5348
  else if (_optionalChain([r, 'optionalAccess', _184 => _184.kind]) === "pieces") {
5349
5349
  r.paths.forEach(
5350
- (path, k) => list.push({ ...node, id: k === 0 ? node.id : this.newId(), subpaths: _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, toLocal(path)).map((sp) => ({ ...sp, closed: false })) })
5350
+ (path, k) => list.push({ ...node, id: k === 0 ? node.id : this.newId(), subpaths: _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, toLocal(path)).map((sp) => ({ ...sp, closed: false })) })
5351
5351
  );
5352
5352
  }
5353
5353
  if (plan.merged && plan.merged.style === i) {
@@ -5358,9 +5358,9 @@ var VectorEditorController = (_class3 = class {
5358
5358
  id: mergedId,
5359
5359
  name: "Shape",
5360
5360
  ...node.transform ? { transform: node.transform } : {},
5361
- subpaths: _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, toLocal(plan.merged.path))
5361
+ subpaths: _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, toLocal(plan.merged.path))
5362
5362
  };
5363
- if (plan.merged.currentFill || !_chunkXCXQDPIDcjs.hasPaint.call(void 0, merged.fill)) merged.fill = _chunkXCXQDPIDcjs.hasPaint.call(void 0, this.defaults.fill) ? this.defaults.fill : "#808080";
5363
+ if (plan.merged.currentFill || !_chunkFKONE6AOcjs.hasPaint.call(void 0, merged.fill)) merged.fill = _chunkFKONE6AOcjs.hasPaint.call(void 0, this.defaults.fill) ? this.defaults.fill : "#808080";
5364
5364
  list.push(merged);
5365
5365
  }
5366
5366
  if (r === void 0 && list.length === 1) return;
@@ -5397,14 +5397,14 @@ var VectorEditorController = (_class3 = class {
5397
5397
  if (!_optionalChain([region, 'optionalAccess', _191 => _191.length])) return null;
5398
5398
  let below = null;
5399
5399
  const roots = new Set(this.selectedRoots());
5400
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5400
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5401
5401
  if (!below && roots.has(n.id)) below = n.id;
5402
5402
  });
5403
- const subpaths = _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, below ? this.intoParentSpace(below, region) : region);
5403
+ const subpaths = _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, below ? this.intoParentSpace(below, region) : region);
5404
5404
  if (!subpaths.length) return null;
5405
5405
  const id = this.newId();
5406
5406
  const node = { id, type: "path", name: "Fill", ...this.styleFor(false), stroke: null, fillRule: "nonzero", subpaths };
5407
- if (!_chunkXCXQDPIDcjs.hasPaint.call(void 0, node.fill)) node.fill = "#808080";
5407
+ if (!_chunkFKONE6AOcjs.hasPaint.call(void 0, node.fill)) node.fill = "#808080";
5408
5408
  const target = below;
5409
5409
  this.change("Fill Region", () => {
5410
5410
  if (target) {
@@ -5506,10 +5506,10 @@ var VectorEditorController = (_class3 = class {
5506
5506
  /** Moves anchors by a document-space offset (converted into each node's own space). */
5507
5507
  movedAnchors(doc, refs, dx, dy) {
5508
5508
  const local = /* @__PURE__ */ new Map();
5509
- for (const r of refs) if (!local.has(r.nodeId)) local.set(r.nodeId, _chunkXCXQDPIDcjs.applyMatrixLinear.call(void 0, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(r.nodeId, doc)), { x: dx, y: dy }));
5509
+ for (const r of refs) if (!local.has(r.nodeId)) local.set(r.nodeId, _chunkFKONE6AOcjs.applyMatrixLinear.call(void 0, _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(r.nodeId, doc)), { x: dx, y: dy }));
5510
5510
  return this.updateAnchors(doc, refs, (a, ref) => {
5511
5511
  const d = local.get(ref.nodeId);
5512
- return _chunkXCXQDPIDcjs.translateAnchor.call(void 0, a, d.x, d.y);
5512
+ return _chunkFKONE6AOcjs.translateAnchor.call(void 0, a, d.x, d.y);
5513
5513
  });
5514
5514
  }
5515
5515
  /**
@@ -5527,7 +5527,7 @@ var VectorEditorController = (_class3 = class {
5527
5527
  }
5528
5528
  /** `doc` with anchor `ref` moved to document point `to` by a Curvature-tool move. */
5529
5529
  curvatureMoved(doc, ref, to) {
5530
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5530
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5531
5531
  if (_optionalChain([node, 'optionalAccess', _196 => _196.type]) !== "path" || node.locked || !node.subpaths[ref.subpath]) return doc;
5532
5532
  const q = this.toLocal(ref.nodeId, to, doc);
5533
5533
  const subpaths = node.subpaths.map((sp, i) => i === ref.subpath ? curvatureMoveAnchor(sp, ref.index, q) : sp);
@@ -5536,7 +5536,7 @@ var VectorEditorController = (_class3 = class {
5536
5536
  }
5537
5537
  /** `doc` with segment `ref` bent through document point `p` at parameter `t`. */
5538
5538
  bent(doc, ref, t, p) {
5539
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5539
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, ref.nodeId);
5540
5540
  if (_optionalChain([node, 'optionalAccess', _197 => _197.type]) !== "path" || node.locked || !node.subpaths[ref.subpath]) return doc;
5541
5541
  const q = this.toLocal(ref.nodeId, p, doc);
5542
5542
  const subpaths = node.subpaths.map((sp, i) => i === ref.subpath ? bendSegment(sp, ref.segment, t, q) : sp);
@@ -5561,7 +5561,7 @@ var VectorEditorController = (_class3 = class {
5561
5561
  if (!getAnchor(this.doc, ref)) return { ok: false, message: "There is no such anchor." };
5562
5562
  const local = this.toLocal(ref.nodeId, to);
5563
5563
  this.change("Move Handle", () => {
5564
- this.doc = this.updateAnchors(this.doc, [ref], (a) => _chunkXCXQDPIDcjs.moveAnchorHandle.call(void 0, a, ref.handle, local, options.breakHandles));
5564
+ this.doc = this.updateAnchors(this.doc, [ref], (a) => _chunkFKONE6AOcjs.moveAnchorHandle.call(void 0, a, ref.handle, local, options.breakHandles));
5565
5565
  });
5566
5566
  return { ok: true };
5567
5567
  }
@@ -5573,7 +5573,7 @@ var VectorEditorController = (_class3 = class {
5573
5573
  if (n.type !== "path") return n;
5574
5574
  const mine = refs.filter((r) => r.nodeId === n.id);
5575
5575
  if (!mine.length) return n;
5576
- const subpaths = n.subpaths.map((sp, s) => mine.filter((r) => r.subpath === s).reduce((acc, r) => _chunkXCXQDPIDcjs.convertAnchor.call(void 0, acc, r.index, type), sp));
5576
+ const subpaths = n.subpaths.map((sp, s) => mine.filter((r) => r.subpath === s).reduce((acc, r) => _chunkFKONE6AOcjs.convertAnchor.call(void 0, acc, r.index, type), sp));
5577
5577
  return { ...n, subpaths };
5578
5578
  });
5579
5579
  this.setDoc(nodes);
@@ -5584,9 +5584,9 @@ var VectorEditorController = (_class3 = class {
5584
5584
  insertAnchorAt(nodeId, point) {
5585
5585
  const node = this.getNode(nodeId);
5586
5586
  if (_optionalChain([node, 'optionalAccess', _199 => _199.type]) !== "path") return null;
5587
- const hit = _chunkXCXQDPIDcjs.nearestSegment.call(void 0, node, this.toLocal(nodeId, point));
5587
+ const hit = _chunkFKONE6AOcjs.nearestSegment.call(void 0, node, this.toLocal(nodeId, point));
5588
5588
  if (!hit) return null;
5589
- const { subpath, index } = _chunkXCXQDPIDcjs.insertAnchor.call(void 0, node.subpaths[hit.subpath], hit.segment, hit.t);
5589
+ const { subpath, index } = _chunkFKONE6AOcjs.insertAnchor.call(void 0, node.subpaths[hit.subpath], hit.segment, hit.t);
5590
5590
  const ref = { nodeId, subpath: hit.subpath, index };
5591
5591
  this.change("Add Point", () => {
5592
5592
  this.replaceNode(nodeId, { ...node, subpaths: node.subpaths.map((sp, i) => i === hit.subpath ? subpath : sp) });
@@ -5611,7 +5611,7 @@ var VectorEditorController = (_class3 = class {
5611
5611
  const subpaths = n.subpaths.map((sp, s) => {
5612
5612
  const indices = mine.filter((r) => r.subpath === s).map((r) => r.index);
5613
5613
  if (!indices.length) return sp;
5614
- return keepShape ? removeAnchorsKeepingShape(sp, indices) : _chunkXCXQDPIDcjs.removeAnchors.call(void 0, sp, indices);
5614
+ return keepShape ? removeAnchorsKeepingShape(sp, indices) : _chunkFKONE6AOcjs.removeAnchors.call(void 0, sp, indices);
5615
5615
  }).filter((sp) => sp.anchors.length > 1);
5616
5616
  return subpaths.length ? { ...n, subpaths } : null;
5617
5617
  });
@@ -5642,13 +5642,13 @@ var VectorEditorController = (_class3 = class {
5642
5642
  }
5643
5643
  /** Reverses the direction of every subpath of the selected paths. */
5644
5644
  reversePaths(ids = this.selection) {
5645
- const set = new Set(ids.flatMap((id) => this.getNode(id) ? _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, this.getNode(id)) : []).map((p) => p.id));
5645
+ const set = new Set(ids.flatMap((id) => this.getNode(id) ? _chunkFKONE6AOcjs.collectPathNodes.call(void 0, this.getNode(id)) : []).map((p) => p.id));
5646
5646
  if (!set.size) return { ok: false, message: "Select a path." };
5647
5647
  this.change("Reverse Path", () => {
5648
5648
  this.setDoc(
5649
5649
  mapTree(
5650
5650
  this.doc.nodes,
5651
- (n) => n.type === "path" && set.has(n.id) ? { ...n, subpaths: n.subpaths.map(_chunkXCXQDPIDcjs.reverseSubpath), ..._optionalChain([n, 'access', _201 => _201.strokeWidthProfile, 'optionalAccess', _202 => _202.length]) ? { strokeWidthProfile: _chunkXCXQDPIDcjs.reverseWidthProfile.call(void 0, n.strokeWidthProfile) } : {} } : n
5651
+ (n) => n.type === "path" && set.has(n.id) ? { ...n, subpaths: n.subpaths.map(_chunkFKONE6AOcjs.reverseSubpath), ..._optionalChain([n, 'access', _201 => _201.strokeWidthProfile, 'optionalAccess', _202 => _202.length]) ? { strokeWidthProfile: _chunkFKONE6AOcjs.reverseWidthProfile.call(void 0, n.strokeWidthProfile) } : {} } : n
5652
5652
  )
5653
5653
  );
5654
5654
  this.anchors = [];
@@ -5665,20 +5665,20 @@ var VectorEditorController = (_class3 = class {
5665
5665
  for (const id of roots) {
5666
5666
  const node = this.getNode(id);
5667
5667
  if (node && !node.locked) {
5668
- for (const p of _chunkXCXQDPIDcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
5668
+ for (const p of _chunkFKONE6AOcjs.collectPathNodes.call(void 0, node)) if (!p.locked) out.set(p.id, p);
5669
5669
  }
5670
5670
  }
5671
5671
  const order = [];
5672
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5672
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5673
5673
  if (out.has(n.id)) order.push(n.id);
5674
5674
  });
5675
5675
  return order.map((id) => out.get(id));
5676
5676
  }
5677
5677
  /** Subpaths of node `from` mapped into node `to`'s own space. */
5678
5678
  subpathsIn(from, to) {
5679
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, this.worldOf(from.id), _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(to)));
5679
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, this.worldOf(from.id), _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(to)));
5680
5680
  if (isRoot(m)) return from.subpaths;
5681
- const map = (p) => _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, p);
5681
+ const map = (p) => _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, p);
5682
5682
  return from.subpaths.map((sp) => ({
5683
5683
  closed: sp.closed,
5684
5684
  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 +5788,7 @@ var VectorEditorController = (_class3 = class {
5788
5788
  const node = this.getNode(nodeId);
5789
5789
  if (_optionalChain([node, 'optionalAccess', _203 => _203.type]) !== "path" || node.locked) return null;
5790
5790
  const local = this.toLocal(nodeId, point);
5791
- const hit = _chunkXCXQDPIDcjs.nearestSegment.call(void 0, node, local);
5791
+ const hit = _chunkFKONE6AOcjs.nearestSegment.call(void 0, node, local);
5792
5792
  if (!hit) return null;
5793
5793
  const sp = node.subpaths[hit.subpath];
5794
5794
  const n = sp.anchors.length;
@@ -5832,7 +5832,7 @@ var VectorEditorController = (_class3 = class {
5832
5832
  /** Visible, unlocked paths a stroke over `points` can reach: in `ids`, the selection, or (with neither) any whose bounds it crosses. */
5833
5833
  strokeTargets(points, ids, pad) {
5834
5834
  const blocked = /* @__PURE__ */ new Set();
5835
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n, parent) => {
5835
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n, parent) => {
5836
5836
  if (n.visible === false || n.locked || parent && blocked.has(parent.id)) blocked.add(n.id);
5837
5837
  });
5838
5838
  const visible = (p) => !blocked.has(p.id);
@@ -5840,17 +5840,17 @@ var VectorEditorController = (_class3 = class {
5840
5840
  const box = polylineBounds(points.map(toPoint2), pad);
5841
5841
  if (!box) return [];
5842
5842
  const out = [];
5843
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5843
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
5844
5844
  if (n.type !== "path" || !visible(n)) return;
5845
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunkXCXQDPIDcjs.vectorParentMatrix.call(void 0, this.doc.nodes, n.id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX)));
5846
- if (b && _chunkXCXQDPIDcjs.boundsIntersect.call(void 0, b, box)) out.push(n);
5845
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n, _nullishCoalesce(_chunkFKONE6AOcjs.vectorParentMatrix.call(void 0, this.doc.nodes, n.id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX)));
5846
+ if (b && _chunkFKONE6AOcjs.boundsIntersect.call(void 0, b, box)) out.push(n);
5847
5847
  });
5848
5848
  return out;
5849
5849
  }
5850
5850
  /** A stroke's points in node `id`'s own space. */
5851
5851
  localPoints(id, points) {
5852
- const inv = _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(id));
5853
- return points.map((p) => toPoint2(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, inv, p)));
5852
+ const inv = _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(id));
5853
+ return points.map((p) => toPoint2(_chunkFKONE6AOcjs.applyMatrix.call(void 0, inv, p)));
5854
5854
  }
5855
5855
  /**
5856
5856
  * Knife: cuts closed paths along the polyline `points` (document space) wherever it crosses
@@ -5865,8 +5865,8 @@ var VectorEditorController = (_class3 = class {
5865
5865
  for (const node of this.strokeTargets(pts, options.ids, 0)) {
5866
5866
  const closed = node.subpaths.filter((sp) => sp.anchors.length > 1);
5867
5867
  if (!closed.length || closed.some((sp) => !sp.closed)) continue;
5868
- const result = knifePath(_chunkXCXQDPIDcjs.subpathsToBezier.call(void 0, closed), _nullishCoalesce(node.fillRule, () => ( "nonzero")), this.localPoints(node.id, pts));
5869
- if (result) plan.push({ node, pieces: result.map((path) => _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, path)) });
5868
+ const result = knifePath(_chunkFKONE6AOcjs.subpathsToBezier.call(void 0, closed), _nullishCoalesce(node.fillRule, () => ( "nonzero")), this.localPoints(node.id, pts));
5869
+ if (result) plan.push({ node, pieces: result.map((path) => _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, path)) });
5870
5870
  }
5871
5871
  if (!plan.length) return [];
5872
5872
  const created = [];
@@ -5895,12 +5895,12 @@ var VectorEditorController = (_class3 = class {
5895
5895
  const rb = _chunkO2UH7LZEcjs.bezierPathBounds.call(void 0, region);
5896
5896
  const reach = rb ? [{ x: rb.minX, y: rb.minY }, { x: rb.maxX, y: rb.maxY }] : points;
5897
5897
  for (const node of this.strokeTargets(reach, options.ids, 0)) {
5898
- const local = _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, region, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(node.id)));
5898
+ const local = _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, region, _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(node.id)));
5899
5899
  const live = node.subpaths.filter((sp) => sp.anchors.length > 1);
5900
5900
  if (!live.length) continue;
5901
- if (_chunkXCXQDPIDcjs.hasPaint.call(void 0, node.fill) && live.every((sp) => sp.closed)) {
5902
- const faces = eraseFromFill(_chunkXCXQDPIDcjs.subpathsToBezier.call(void 0, live), _nullishCoalesce(node.fillRule, () => ( "nonzero")), local);
5903
- if (faces) plan.push({ node, pieces: faces.map((f) => _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, f)) });
5901
+ if (_chunkFKONE6AOcjs.hasPaint.call(void 0, node.fill) && live.every((sp) => sp.closed)) {
5902
+ const faces = eraseFromFill(_chunkFKONE6AOcjs.subpathsToBezier.call(void 0, live), _nullishCoalesce(node.fillRule, () => ( "nonzero")), local);
5903
+ if (faces) plan.push({ node, pieces: faces.map((f) => _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, f)) });
5904
5904
  continue;
5905
5905
  }
5906
5906
  const results = live.map((sp) => eraseFromOutline(sp, local));
@@ -5945,7 +5945,7 @@ var VectorEditorController = (_class3 = class {
5945
5945
  // -------------------------------------------------------------------------
5946
5946
  /** Copies the selection. Returns JSON text for the system clipboard (or null). */
5947
5947
  copy() {
5948
- const nodes = this.selectedRoots().map((id) => this.getNode(id)).filter((n) => !!n).map((n) => _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, n));
5948
+ const nodes = this.selectedRoots().map((id) => this.getNode(id)).filter((n) => !!n).map((n) => _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, n));
5949
5949
  if (!nodes.length) return null;
5950
5950
  this.clipboard = nodes;
5951
5951
  return JSON.stringify({ type: VECTOR_CLIPBOARD_TYPE, nodes });
@@ -5972,7 +5972,7 @@ var VectorEditorController = (_class3 = class {
5972
5972
  }
5973
5973
  } else if (/<svg[\s>]/i.test(trimmed)) {
5974
5974
  try {
5975
- nodes = _chunkXCXQDPIDcjs.parseVectorSvg.call(void 0, trimmed).nodes;
5975
+ nodes = _chunkFKONE6AOcjs.parseVectorSvg.call(void 0, trimmed).nodes;
5976
5976
  } catch (e4) {
5977
5977
  nodes = null;
5978
5978
  }
@@ -5980,13 +5980,13 @@ var VectorEditorController = (_class3 = class {
5980
5980
  } else nodes = this.clipboard;
5981
5981
  if (!_optionalChain([nodes, 'optionalAccess', _208 => _208.length])) return [];
5982
5982
  const offset = _nullishCoalesce(options.offset, () => ( (text && !text.trim().startsWith("{") ? { x: 0, y: 0 } : { x: 10, y: 10 })));
5983
- const copies = nodes.map((n) => _chunkXCXQDPIDcjs.transformVectorNode.call(void 0, this.freshIds(n), _chunkXCXQDPIDcjs.translateMatrix.call(void 0, offset.x, offset.y)));
5983
+ const copies = nodes.map((n) => _chunkFKONE6AOcjs.transformVectorNode.call(void 0, this.freshIds(n), _chunkFKONE6AOcjs.translateMatrix.call(void 0, offset.x, offset.y)));
5984
5984
  this.change("Paste", () => {
5985
5985
  this.setDoc([...this.doc.nodes, ...copies]);
5986
5986
  this.selection = copies.map((n) => n.id);
5987
5987
  this.anchors = [];
5988
5988
  });
5989
- if (!text) this.clipboard = copies.map((n) => _chunkXCXQDPIDcjs.cloneVectorNode.call(void 0, n));
5989
+ if (!text) this.clipboard = copies.map((n) => _chunkFKONE6AOcjs.cloneVectorNode.call(void 0, n));
5990
5990
  return copies.map((n) => n.id);
5991
5991
  }
5992
5992
  // -------------------------------------------------------------------------
@@ -6070,7 +6070,7 @@ var VectorEditorController = (_class3 = class {
6070
6070
  /** Deepest unlocked visible path under `p`. */
6071
6071
  /** Live groups being edited (selected, or holding the selection or the edited path): their children are hit as stored. */
6072
6072
  enteredGroups() {
6073
- return _chunkXCXQDPIDcjs.vectorEnteredGroups.call(void 0, this.doc.nodes, this.editingId ? [...this.selection, this.editingId] : this.selection);
6073
+ return _chunkFKONE6AOcjs.vectorEnteredGroups.call(void 0, this.doc.nodes, this.editingId ? [...this.selection, this.editingId] : this.selection);
6074
6074
  }
6075
6075
  hitPath(p) {
6076
6076
  const tol = this.tolerance();
@@ -6080,19 +6080,19 @@ var VectorEditorController = (_class3 = class {
6080
6080
  const n = list[i];
6081
6081
  if (n.visible === false || n.locked) continue;
6082
6082
  if (n.type === "group") {
6083
- if (_chunkXCXQDPIDcjs.hasOwnVectorAppearance.call(void 0, n) && !entered.has(n.id) && !_chunkXCXQDPIDcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) continue;
6084
- const found = search(n.children, _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent));
6083
+ if (_chunkFKONE6AOcjs.hasOwnVectorAppearance.call(void 0, n) && !entered.has(n.id) && !_chunkFKONE6AOcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) continue;
6084
+ const found = search(n.children, _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent));
6085
6085
  if (found) return found;
6086
- } else if (_chunkXCXQDPIDcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) return n;
6086
+ } else if (_chunkFKONE6AOcjs.hitTestVectorNode.call(void 0, n, p, tol, parent, { entered })) return n;
6087
6087
  }
6088
6088
  return null;
6089
6089
  };
6090
- return search(this.doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
6090
+ return search(this.doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
6091
6091
  }
6092
6092
  /** Endpoints of open subpaths of unlocked visible paths (pen tool resumes from them). */
6093
6093
  openEndpoints() {
6094
6094
  const out = [];
6095
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6095
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6096
6096
  if (n.type !== "path" || n.locked || n.visible === false) return;
6097
6097
  n.subpaths.forEach((sp, s) => {
6098
6098
  if (sp.closed || sp.anchors.length < 1) return;
@@ -6108,7 +6108,7 @@ var VectorEditorController = (_class3 = class {
6108
6108
  case "select": {
6109
6109
  const handle = this.hitTransformHandle(screen);
6110
6110
  if (handle) return { nodeId: null, transformHandle: handle };
6111
- const node = _chunkXCXQDPIDcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6111
+ const node = _chunkFKONE6AOcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6112
6112
  return node ? { nodeId: node.id } : null;
6113
6113
  }
6114
6114
  case "direct": {
@@ -6120,9 +6120,9 @@ var VectorEditorController = (_class3 = class {
6120
6120
  if (widget) return { nodeId: widget.ref.nodeId, corner: widget.ref };
6121
6121
  for (const id of getEditablePathIds(this.view())) {
6122
6122
  const node = this.getNode(id);
6123
- const seg = _chunkXCXQDPIDcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6123
+ const seg = _chunkFKONE6AOcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6124
6124
  if (seg && seg.distance <= this.tolerance()) {
6125
- const point = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, this.worldOf(id), seg.point);
6125
+ const point = _chunkFKONE6AOcjs.applyMatrix.call(void 0, this.worldOf(id), seg.point);
6126
6126
  return { nodeId: id, segment: { nodeId: id, subpath: seg.subpath, segment: seg.segment, t: seg.t, point } };
6127
6127
  }
6128
6128
  }
@@ -6159,7 +6159,7 @@ var VectorEditorController = (_class3 = class {
6159
6159
  case "envelope": {
6160
6160
  const hit = this.hitEnvelope(screen, p);
6161
6161
  if (hit) return { nodeId: hit.target.node.id, envelope: { nodeId: hit.target.node.id, index: hit.index } };
6162
- const node = _chunkXCXQDPIDcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6162
+ const node = _chunkFKONE6AOcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6163
6163
  return node ? { nodeId: node.id } : null;
6164
6164
  }
6165
6165
  default:
@@ -6195,19 +6195,19 @@ var VectorEditorController = (_class3 = class {
6195
6195
  strokeSpotAt(p) {
6196
6196
  let best = null;
6197
6197
  const tol = this.tolerance();
6198
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6198
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, this.doc.nodes, (n) => {
6199
6199
  if (n.type !== "path" || n.visible === false || n.locked) return;
6200
6200
  if (hiddenOrLocked(this.doc.nodes, n.id)) return;
6201
6201
  const g = vectorStrokeWidthGeometry(n);
6202
6202
  if (!g) return;
6203
6203
  const m = this.worldOf(n.id);
6204
- const local = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, m), p);
6205
- const near2 = _chunkXCXQDPIDcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6204
+ const local = _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.invertMatrix.call(void 0, m), p);
6205
+ const near2 = _chunkFKONE6AOcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6206
6206
  if (!near2) return;
6207
- const profile = _chunkXCXQDPIDcjs.strokeWidthProfileOf.call(void 0, n);
6208
- const w = _chunkXCXQDPIDcjs.widthProfileAt.call(void 0, profile, near2.t);
6207
+ const profile = _chunkFKONE6AOcjs.strokeWidthProfileOf.call(void 0, n);
6208
+ const w = _chunkFKONE6AOcjs.widthProfileAt.call(void 0, profile, near2.t);
6209
6209
  const reach = Math.max(near2.side === "left" ? w.left : w.right, 0) * g.unit + tol;
6210
- if (near2.distance > reach || near2.distance > _chunkXCXQDPIDcjs.widthProfileMaxScale.call(void 0, profile) * g.unit + tol) return;
6210
+ if (near2.distance > reach || near2.distance > _chunkFKONE6AOcjs.widthProfileMaxScale.call(void 0, profile) * g.unit + tol) return;
6211
6211
  if (best && near2.distance >= best.distance) return;
6212
6212
  const nx = near2.tangent[1];
6213
6213
  const ny = -near2.tangent[0];
@@ -6216,9 +6216,9 @@ var VectorEditorController = (_class3 = class {
6216
6216
  nodeId: n.id,
6217
6217
  subpath: near2.contour,
6218
6218
  t: near2.t,
6219
- point: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, { x: cx, y: cy }),
6220
- left: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, { x: cx + nx * w.left * g.unit, y: cy + ny * w.left * g.unit }),
6221
- right: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, { x: cx - nx * w.right * g.unit, y: cy - ny * w.right * g.unit }),
6219
+ point: _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, { x: cx, y: cy }),
6220
+ left: _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, { x: cx + nx * w.left * g.unit, y: cy + ny * w.left * g.unit }),
6221
+ right: _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, { x: cx - nx * w.right * g.unit, y: cy - ny * w.right * g.unit }),
6222
6222
  distance: near2.distance
6223
6223
  };
6224
6224
  });
@@ -6249,11 +6249,11 @@ var VectorEditorController = (_class3 = class {
6249
6249
  let t;
6250
6250
  let subpath;
6251
6251
  if (hit) {
6252
- profile = _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
6252
+ profile = _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, node.strokeWidthProfile);
6253
6253
  ref = { nodeId: node.id, index: hit.ref.index, subpath: hit.ref.subpath };
6254
6254
  t = _nullishCoalesce(_optionalChain([profile, 'access', _216 => _216[ref.index], 'optionalAccess', _217 => _217.t]), () => ( 0));
6255
6255
  subpath = hit.ref.subpath;
6256
- if (hit.ref.part === "center") mode = input.alt && profile.length < _chunkXCXQDPIDcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS ? "copy" : "move";
6256
+ if (hit.ref.part === "center") mode = input.alt && profile.length < _chunkFKONE6AOcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS ? "copy" : "move";
6257
6257
  else if (input.alt) side = hit.ref.part;
6258
6258
  const same = this.widthPoints.length > 0 && this.widthPoints[0].nodeId === node.id;
6259
6259
  const selected = same && this.widthPoints.some((r) => r.index === ref.index);
@@ -6268,8 +6268,8 @@ var VectorEditorController = (_class3 = class {
6268
6268
  } else if (mode === "copy" || !selected) this.widthPoints = [ref];
6269
6269
  if (mode !== "copy") group = this.widthPoints.filter((r) => r.index !== ref.index).map((r) => r.index);
6270
6270
  } else {
6271
- const near2 = _chunkXCXQDPIDcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6272
- const inserted = _chunkXCXQDPIDcjs.insertWidthPoint.call(void 0, _chunkXCXQDPIDcjs.strokeWidthProfileOf.call(void 0, node), near2.t);
6271
+ const near2 = _chunkFKONE6AOcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y]);
6272
+ const inserted = _chunkFKONE6AOcjs.insertWidthPoint.call(void 0, _chunkFKONE6AOcjs.strokeWidthProfileOf.call(void 0, node), near2.t);
6273
6273
  profile = inserted.points;
6274
6274
  subpath = near2.contour;
6275
6275
  t = near2.t;
@@ -6277,7 +6277,7 @@ var VectorEditorController = (_class3 = class {
6277
6277
  if (input.alt) side = near2.side;
6278
6278
  this.widthPoints = [ref];
6279
6279
  }
6280
- const at = _chunkXCXQDPIDcjs.strokePositionPoint.call(void 0, g.line, subpath, t);
6280
+ const at = _chunkFKONE6AOcjs.strokePositionPoint.call(void 0, g.line, subpath, t);
6281
6281
  if (!at) return;
6282
6282
  const base = { ...this.doc, nodes: mapTree(this.doc.nodes, (n) => n.id === node.id ? { ...n, strokeWidthProfile: profile } : n) };
6283
6283
  this.doc = base;
@@ -6311,16 +6311,16 @@ var VectorEditorController = (_class3 = class {
6311
6311
  */
6312
6312
  snapWidthT(drag, node, line2, t, skip) {
6313
6313
  const m = this.worldOf(node.id, drag.base);
6314
- const at = _chunkXCXQDPIDcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, t);
6314
+ const at = _chunkFKONE6AOcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, t);
6315
6315
  if (!at) return t;
6316
- const here = this.documentToScreen(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, { x: at.point[0], y: at.point[1] }));
6316
+ const here = this.documentToScreen(_chunkFKONE6AOcjs.applyMatrix.call(void 0, m, { x: at.point[0], y: at.point[1] }));
6317
6317
  let best = t;
6318
6318
  let bestD = this.hitRadius;
6319
6319
  drag.profile.forEach((w, i) => {
6320
6320
  if (i === skip || drag.group.includes(i)) return;
6321
- const q = _chunkXCXQDPIDcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, w.t);
6321
+ const q = _chunkFKONE6AOcjs.strokePositionPoint.call(void 0, line2, drag.ref.subpath, w.t);
6322
6322
  if (!q) return;
6323
- const s = this.documentToScreen(_chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, { x: q.point[0], y: q.point[1] }));
6323
+ const s = this.documentToScreen(_chunkFKONE6AOcjs.applyMatrix.call(void 0, m, { x: q.point[0], y: q.point[1] }));
6324
6324
  const d = Math.hypot(s.x - here.x, s.y - here.y);
6325
6325
  if (d <= bestD) {
6326
6326
  best = w.t;
@@ -6337,18 +6337,18 @@ var VectorEditorController = (_class3 = class {
6337
6337
  for (let i = list.length - 1; i >= 0; i--) {
6338
6338
  const n = list[i];
6339
6339
  if (n.visible === false || n.locked) continue;
6340
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, n), parent);
6340
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, n), parent);
6341
6341
  if (n.type === "group") {
6342
6342
  visit(n.children, m);
6343
6343
  continue;
6344
6344
  }
6345
- const hit = _chunkXCXQDPIDcjs.nearestSegment.call(void 0, n, _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.invertMatrix.call(void 0, m), p));
6345
+ const hit = _chunkFKONE6AOcjs.nearestSegment.call(void 0, n, _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.invertMatrix.call(void 0, m), p));
6346
6346
  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: _chunkXCXQDPIDcjs.applyMatrix.call(void 0, m, hit.point), distance: hit.distance };
6347
+ best = { nodeId: n.id, subpath: hit.subpath, segment: hit.segment, t: hit.t, point: _chunkFKONE6AOcjs.applyMatrix.call(void 0, m, hit.point), distance: hit.distance };
6348
6348
  }
6349
6349
  }
6350
6350
  };
6351
- visit(this.doc.nodes, _chunkXCXQDPIDcjs.IDENTITY_MATRIX);
6351
+ visit(this.doc.nodes, _chunkFKONE6AOcjs.IDENTITY_MATRIX);
6352
6352
  if (!best) return null;
6353
6353
  const { distance: _d, ...seg } = best;
6354
6354
  return seg;
@@ -6405,7 +6405,7 @@ var VectorEditorController = (_class3 = class {
6405
6405
  }
6406
6406
  /** The shape under the pointer for the Blend tool, and the anchor of its first subpath under it. */
6407
6407
  blendHit(screen, p) {
6408
- const node = _chunkXCXQDPIDcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance());
6408
+ const node = _chunkFKONE6AOcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance());
6409
6409
  if (!node) return null;
6410
6410
  let anchor = null;
6411
6411
  if (node.type === "path" && node.subpaths[0]) {
@@ -6448,13 +6448,13 @@ var VectorEditorController = (_class3 = class {
6448
6448
  if (handle) {
6449
6449
  const frame = this.frameOf(this.selectedRoots());
6450
6450
  const before = this.snapshot();
6451
- const center = _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
6451
+ const center = _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, frame.angle), { x: frame.x + frame.width / 2, y: frame.y + frame.height / 2 });
6452
6452
  this.drag = handle === "rotate" ? { kind: "rotate", start: p, center, before, base: this.doc } : { kind: "scale", handle, start: p, frame, before, base: this.doc };
6453
6453
  this.interaction = handle === "rotate" ? { type: "rotate", angle: 0 } : { type: "scale", handle, sx: 1, sy: 1 };
6454
6454
  this.notify();
6455
6455
  return;
6456
6456
  }
6457
- const node = _chunkXCXQDPIDcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6457
+ const node = _chunkFKONE6AOcjs.hitTestVectorNodes.call(void 0, this.doc.nodes, p, this.tolerance(), { entered: this.enteredGroups() });
6458
6458
  if (node) {
6459
6459
  const selected = this.selection.includes(node.id);
6460
6460
  if (input.shift) {
@@ -6522,12 +6522,12 @@ var VectorEditorController = (_class3 = class {
6522
6522
  }
6523
6523
  for (const id of getEditablePathIds(this.view())) {
6524
6524
  const node = this.getNode(id);
6525
- const seg = _chunkXCXQDPIDcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6525
+ const seg = _chunkFKONE6AOcjs.nearestSegment.call(void 0, node, this.toLocal(id, p));
6526
6526
  if (!seg || seg.distance > this.tolerance()) continue;
6527
6527
  const sp = node.subpaths[seg.subpath];
6528
6528
  if (input.alt) {
6529
6529
  const before = this.snapshot();
6530
- const { subpath, index } = _chunkXCXQDPIDcjs.insertAnchor.call(void 0, sp, seg.segment, seg.t);
6530
+ const { subpath, index } = _chunkFKONE6AOcjs.insertAnchor.call(void 0, sp, seg.segment, seg.t);
6531
6531
  this.replaceNode(id, { ...node, subpaths: node.subpaths.map((s, i) => i === seg.subpath ? subpath : s) });
6532
6532
  const ref = { nodeId: id, subpath: seg.subpath, index };
6533
6533
  this.anchors = [ref];
@@ -6594,7 +6594,7 @@ var VectorEditorController = (_class3 = class {
6594
6594
  let node2 = this.getNode(endpoint.nodeId);
6595
6595
  let index = endpoint.index;
6596
6596
  if (index === 0 && node2.subpaths[endpoint.subpath].anchors.length > 1) {
6597
- node2 = { ...node2, subpaths: node2.subpaths.map((s, i) => i === endpoint.subpath ? _chunkXCXQDPIDcjs.reverseSubpath.call(void 0, s) : s) };
6597
+ node2 = { ...node2, subpaths: node2.subpaths.map((s, i) => i === endpoint.subpath ? _chunkFKONE6AOcjs.reverseSubpath.call(void 0, s) : s) };
6598
6598
  this.replaceNode(node2.id, node2);
6599
6599
  index = node2.subpaths[endpoint.subpath].anchors.length - 1;
6600
6600
  }
@@ -6697,7 +6697,7 @@ var VectorEditorController = (_class3 = class {
6697
6697
  drag.targets = void 0;
6698
6698
  }
6699
6699
  ({ dx, dy } = this.snapMove(drag, dx, dy, input));
6700
- this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunkXCXQDPIDcjs.translateMatrix.call(void 0, dx, dy));
6700
+ this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunkFKONE6AOcjs.translateMatrix.call(void 0, dx, dy));
6701
6701
  this.interaction = { type: "move", dx, dy };
6702
6702
  this.notify(true);
6703
6703
  return;
@@ -6705,7 +6705,7 @@ var VectorEditorController = (_class3 = class {
6705
6705
  case "scale": {
6706
6706
  if (this.freeDistort && drag.handle !== "rotate") return this.moveDistort(drag, p, input);
6707
6707
  const angle = drag.frame.angle;
6708
- const q = angle ? _chunkXCXQDPIDcjs.applyMatrix.call(void 0, _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, -angle), p) : p;
6708
+ const q = angle ? _chunkFKONE6AOcjs.applyMatrix.call(void 0, _chunkFKONE6AOcjs.rotateMatrix.call(void 0, -angle), p) : p;
6709
6709
  let { sx, sy, origin } = scaleFor(drag.handle, drag.frame, q, input);
6710
6710
  if (this.snap.objects && !input.mod && drag.handle !== "rotate") {
6711
6711
  drag.targets ??= VectorSnapTargets.forResize(drag.base, this.selectedRoots());
@@ -6714,7 +6714,7 @@ var VectorEditorController = (_class3 = class {
6714
6714
  this.setGuides(res);
6715
6715
  } else this.setGuides(null);
6716
6716
  const ids = new Set(this.selectedRoots());
6717
- this.doc = this.transformed(drag.base, ids, this.inFrame(angle, _chunkXCXQDPIDcjs.scaleMatrix.call(void 0, sx, sy, origin)));
6717
+ this.doc = this.transformed(drag.base, ids, this.inFrame(angle, _chunkFKONE6AOcjs.scaleMatrix.call(void 0, sx, sy, origin)));
6718
6718
  this.interaction = { type: "scale", handle: drag.handle, sx, sy };
6719
6719
  this.notify(true);
6720
6720
  return;
@@ -6724,13 +6724,13 @@ var VectorEditorController = (_class3 = class {
6724
6724
  const a1 = Math.atan2(p.y - drag.center.y, p.x - drag.center.x);
6725
6725
  let angle = (a1 - a0) * 180 / Math.PI;
6726
6726
  if (input.shift) angle = Math.round(angle / 15) * 15;
6727
- this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunkXCXQDPIDcjs.rotateMatrix.call(void 0, angle, drag.center));
6727
+ this.doc = this.transformed(drag.base, new Set(this.selectedRoots()), _chunkFKONE6AOcjs.rotateMatrix.call(void 0, angle, drag.center));
6728
6728
  this.interaction = { type: "rotate", angle };
6729
6729
  this.notify(true);
6730
6730
  return;
6731
6731
  }
6732
6732
  case "marquee": {
6733
- const bounds = _chunkXCXQDPIDcjs.boundsFromPoints.call(void 0, drag.start, p);
6733
+ const bounds = _chunkFKONE6AOcjs.boundsFromPoints.call(void 0, drag.start, p);
6734
6734
  this.interaction = { type: "marquee", bounds };
6735
6735
  if (drag.anchorsMode) {
6736
6736
  const inside = getVisibleAnchors(this.view()).filter((r) => {
@@ -6740,8 +6740,8 @@ var VectorEditorController = (_class3 = class {
6740
6740
  this.anchors = [...drag.baseAnchors, ...inside.filter((r) => !drag.baseAnchors.some((b) => sameRef(b, r)))];
6741
6741
  } else {
6742
6742
  const hits = this.doc.nodes.filter((n) => !n.locked && n.visible !== false).filter((n) => {
6743
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n);
6744
- return b && _chunkXCXQDPIDcjs.boundsIntersect.call(void 0, b, bounds);
6743
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n);
6744
+ return b && _chunkFKONE6AOcjs.boundsIntersect.call(void 0, b, bounds);
6745
6745
  }).map((n) => n.id);
6746
6746
  this.selection = [.../* @__PURE__ */ new Set([...drag.base, ...hits])];
6747
6747
  }
@@ -6773,7 +6773,7 @@ var VectorEditorController = (_class3 = class {
6773
6773
  const leave = anchor ? { at: { x: anchor.x, y: anchor.y }, constrain: input.shift ? "angle" : null } : null;
6774
6774
  const pt = this.snapDrawn(p, leave, input, () => drag.targets ??= VectorSnapTargets.forHandle(drag.base, drag.ref.nodeId));
6775
6775
  const local = this.toLocal(drag.ref.nodeId, pt, drag.base);
6776
- this.doc = this.updateAnchors(drag.base, [drag.ref], (a) => _chunkXCXQDPIDcjs.moveAnchorHandle.call(void 0, a, drag.ref.handle, local, input.alt));
6776
+ this.doc = this.updateAnchors(drag.base, [drag.ref], (a) => _chunkFKONE6AOcjs.moveAnchorHandle.call(void 0, a, drag.ref.handle, local, input.alt));
6777
6777
  this.interaction = { type: "handle", ref: drag.ref };
6778
6778
  this.notify(true);
6779
6779
  return;
@@ -6782,10 +6782,10 @@ var VectorEditorController = (_class3 = class {
6782
6782
  if (!drag.moved && Math.hypot(p.x - drag.start.x, p.y - drag.start.y) * this.viewport.zoom < 3) return;
6783
6783
  drag.moved = true;
6784
6784
  const c = drag.widget.corner;
6785
- const inv = _chunkXCXQDPIDcjs.invertMatrix.call(void 0, this.worldOf(drag.widget.ref.nodeId, drag.base));
6786
- const d = _chunkXCXQDPIDcjs.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 + _chunkXCXQDPIDcjs.cornerRadiusChange.call(void 0, c, d)));
6788
- this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunkXCXQDPIDcjs.setAnchorCorner.call(void 0, a, radius));
6785
+ const inv = _chunkFKONE6AOcjs.invertMatrix.call(void 0, this.worldOf(drag.widget.ref.nodeId, drag.base));
6786
+ const d = _chunkFKONE6AOcjs.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 + _chunkFKONE6AOcjs.cornerRadiusChange.call(void 0, c, d)));
6788
+ this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunkFKONE6AOcjs.setAnchorCorner.call(void 0, a, radius));
6789
6789
  this.interaction = { type: "corner", ref: drag.widget.ref, radius };
6790
6790
  this.notify(true);
6791
6791
  return;
@@ -6822,8 +6822,8 @@ var VectorEditorController = (_class3 = class {
6822
6822
  const side = drag.closing ? "in" : "out";
6823
6823
  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
6824
  this.doc = this.updateAnchors(drag.base, [drag.ref], (a) => {
6825
- if (drag.outOnly || drag.altBreaks && input.alt) return _chunkXCXQDPIDcjs.moveAnchorHandle.call(void 0, a, side, pos, true);
6826
- return _chunkXCXQDPIDcjs.moveAnchorHandle.call(void 0, { ...a, type: "symmetric" }, side, pos);
6825
+ if (drag.outOnly || drag.altBreaks && input.alt) return _chunkFKONE6AOcjs.moveAnchorHandle.call(void 0, a, side, pos, true);
6826
+ return _chunkFKONE6AOcjs.moveAnchorHandle.call(void 0, { ...a, type: "symmetric" }, side, pos);
6827
6827
  });
6828
6828
  this.notify(true);
6829
6829
  return;
@@ -6851,7 +6851,7 @@ var VectorEditorController = (_class3 = class {
6851
6851
  if (input.alt) start = { x: start.x - w, y: start.y - h };
6852
6852
  const x2 = drag.start.x + w;
6853
6853
  const y2 = drag.start.y + h;
6854
- bounds = _chunkXCXQDPIDcjs.boundsFromPoints.call(void 0, start, { x: x2, y: y2 });
6854
+ bounds = _chunkFKONE6AOcjs.boundsFromPoints.call(void 0, start, { x: x2, y: y2 });
6855
6855
  }
6856
6856
  const shaped = this.createShapeNode({ kind: drag.tool, ...bounds });
6857
6857
  this.replaceNode(drag.nodeId, { ...node, subpaths: shaped.subpaths });
@@ -6862,32 +6862,32 @@ var VectorEditorController = (_class3 = class {
6862
6862
  case "width": {
6863
6863
  if (!drag.moved && Math.hypot(p.x - drag.start.x, p.y - drag.start.y) * this.viewport.zoom < 2) return;
6864
6864
  drag.moved = true;
6865
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, drag.base.nodes, drag.ref.nodeId);
6865
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, drag.base.nodes, drag.ref.nodeId);
6866
6866
  const local = this.toLocal(node.id, p, drag.base);
6867
6867
  const src = drag.profile[drag.source];
6868
6868
  let profile;
6869
6869
  let index = drag.source;
6870
6870
  if (drag.mode !== "width") {
6871
6871
  const g = vectorStrokeWidthGeometry(node);
6872
- const near2 = g ? _chunkXCXQDPIDcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y], drag.ref.subpath) : null;
6872
+ const near2 = g ? _chunkFKONE6AOcjs.nearestStrokePosition.call(void 0, g.line, [local.x, local.y], drag.ref.subpath) : null;
6873
6873
  if (!g || !near2) return;
6874
6874
  const t = drag.group.length ? near2.t : this.snapWidthT(drag, node, g.line, near2.t, drag.source);
6875
6875
  if (drag.mode === "copy") {
6876
- ({ points: profile, index } = _chunkXCXQDPIDcjs.insertWidthPoint.call(void 0, drag.profile, t, { left: src.left, right: src.right }, { step: true }));
6876
+ ({ points: profile, index } = _chunkFKONE6AOcjs.insertWidthPoint.call(void 0, drag.profile, t, { left: src.left, right: src.right }, { step: true }));
6877
6877
  } else if (drag.group.length) {
6878
6878
  const shifted = shiftWidthPoints(drag.profile, [drag.source, ...drag.group], t - src.t);
6879
6879
  profile = shifted.points;
6880
6880
  drag.renumber = shifted.renumber;
6881
6881
  index = _nullishCoalesce(shifted.renumber.get(drag.source), () => ( drag.source));
6882
- } else profile = _chunkXCXQDPIDcjs.setWidthPoint.call(void 0, drag.profile, drag.source, { t });
6882
+ } else profile = _chunkFKONE6AOcjs.setWidthPoint.call(void 0, drag.profile, drag.source, { t });
6883
6883
  } else {
6884
6884
  const off = ((local.x - drag.origin.x) * drag.normal.x + (local.y - drag.origin.y) * drag.normal.y) / drag.unit;
6885
6885
  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 = _chunkXCXQDPIDcjs.setWidthPoint.call(void 0, drag.profile, drag.source, patch);
6886
+ profile = _chunkFKONE6AOcjs.setWidthPoint.call(void 0, drag.profile, drag.source, patch);
6887
6887
  if (drag.group.length) {
6888
6888
  const dl = profile[drag.source].left - src.left;
6889
6889
  const dr = profile[drag.source].right - src.right;
6890
- for (const i of drag.group) profile = _chunkXCXQDPIDcjs.setWidthPoint.call(void 0, profile, i, { left: Math.max(0, drag.profile[i].left + dl), right: Math.max(0, drag.profile[i].right + dr) });
6890
+ for (const i of drag.group) profile = _chunkFKONE6AOcjs.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
6891
  }
6892
6892
  }
6893
6893
  this.doc = { ...drag.base, nodes: mapTree(drag.base.nodes, (n) => n.id === node.id ? { ...n, strokeWidthProfile: profile } : n) };
@@ -7032,8 +7032,8 @@ var VectorEditorController = (_class3 = class {
7032
7032
  case "corner": {
7033
7033
  if (drag.moved) return this.commit("Corner Radius", drag.before);
7034
7034
  if (drag.alt) {
7035
- const kind = _chunkXCXQDPIDcjs.nextVectorCornerKind.call(void 0, drag.widget.kind);
7036
- this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunkXCXQDPIDcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _234 => _234.corner, 'optionalAccess', _235 => _235.radius]), () => ( 0)), kind));
7035
+ const kind = _chunkFKONE6AOcjs.nextVectorCornerKind.call(void 0, drag.widget.kind);
7036
+ this.doc = this.updateAnchors(drag.base, drag.refs, (a) => _chunkFKONE6AOcjs.setAnchorCorner.call(void 0, a, _nullishCoalesce(_optionalChain([a, 'access', _234 => _234.corner, 'optionalAccess', _235 => _235.radius]), () => ( 0)), kind));
7037
7037
  return this.commit("Corner Kind", drag.before);
7038
7038
  }
7039
7039
  const ref = drag.widget.ref;
@@ -7078,7 +7078,7 @@ var VectorEditorController = (_class3 = class {
7078
7078
  return this.commit(drag.label, drag.before);
7079
7079
  case "shape": {
7080
7080
  const node = this.getNode(drag.nodeId);
7081
- const b = node ? _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, node) : null;
7081
+ const b = node ? _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, node) : null;
7082
7082
  const min = 2 / this.viewport.zoom;
7083
7083
  if (!b || b.width < min && b.height < min) {
7084
7084
  this.doc = drag.before.doc;
@@ -7114,7 +7114,7 @@ var VectorEditorController = (_class3 = class {
7114
7114
  anchors[anchors.length - 1].out = { x: c.p1[0], y: c.p1[1] };
7115
7115
  anchors.push({ x: c.p3[0], y: c.p3[1], in: { x: c.p2[0], y: c.p2[1] } });
7116
7116
  }
7117
- const subpaths = anchors.length > 1 ? _chunkXCXQDPIDcjs.bezierToSubpaths.call(void 0, _chunkXCXQDPIDcjs.subpathsToBezier.call(void 0, [{ anchors, closed: false }])) : node.subpaths;
7117
+ const subpaths = anchors.length > 1 ? _chunkFKONE6AOcjs.bezierToSubpaths.call(void 0, _chunkFKONE6AOcjs.subpathsToBezier.call(void 0, [{ anchors, closed: false }])) : node.subpaths;
7118
7118
  const profile = drag.pressures ? pencilPressureProfile(drag.points, drag.pressures) : [];
7119
7119
  this.replaceNode(drag.nodeId, { ...node, subpaths, ...profile.length ? { strokeWidthProfile: profile } : {} });
7120
7120
  this.selection = [drag.nodeId];
@@ -7177,7 +7177,7 @@ var VectorEditorController = (_class3 = class {
7177
7177
  const id = _nullishCoalesce(_optionalChain([this, 'access', _243 => _243.hover, 'optionalAccess', _244 => _244.segment, 'optionalAccess', _245 => _245.nodeId]), () => ( this.editingId));
7178
7178
  if (id) {
7179
7179
  const node = this.getNode(id);
7180
- const seg = node ? _chunkXCXQDPIDcjs.nearestSegment.call(void 0, node, this.toLocal(id, p)) : null;
7180
+ const seg = node ? _chunkFKONE6AOcjs.nearestSegment.call(void 0, node, this.toLocal(id, p)) : null;
7181
7181
  if (seg && seg.distance <= this.tolerance()) this.insertAnchorAt(id, p);
7182
7182
  }
7183
7183
  return;
@@ -7326,11 +7326,11 @@ function inkShapeLabel(shape) {
7326
7326
  function inkShapeSubpath(shape) {
7327
7327
  switch (shape.kind) {
7328
7328
  case "line":
7329
- return _chunkXCXQDPIDcjs.lineSubpath.call(void 0, { x: shape.a[0], y: shape.a[1] }, { x: shape.b[0], y: shape.b[1] });
7329
+ return _chunkFKONE6AOcjs.lineSubpath.call(void 0, { x: shape.a[0], y: shape.a[1] }, { x: shape.b[0], y: shape.b[1] });
7330
7330
  case "rect":
7331
- return _chunkXCXQDPIDcjs.rectSubpath.call(void 0, shape);
7331
+ return _chunkFKONE6AOcjs.rectSubpath.call(void 0, shape);
7332
7332
  case "ellipse":
7333
- return _chunkXCXQDPIDcjs.ellipseSubpath.call(void 0, shape);
7333
+ return _chunkFKONE6AOcjs.ellipseSubpath.call(void 0, shape);
7334
7334
  case "polygon":
7335
7335
  return { anchors: shape.points.map(([x, y]) => ({ x, y })), closed: true };
7336
7336
  }
@@ -7366,14 +7366,14 @@ function scaleFor(handle, b, p, mods = {}) {
7366
7366
  function withStyle(node, style) {
7367
7367
  const next = { ...node, ...style };
7368
7368
  if ("strokeWidthProfile" in style) {
7369
- const p = style.strokeWidthProfile ? _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, style.strokeWidthProfile) : [];
7369
+ const p = style.strokeWidthProfile ? _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, style.strokeWidthProfile) : [];
7370
7370
  if (p.length) next.strokeWidthProfile = p;
7371
7371
  else delete next.strokeWidthProfile;
7372
7372
  }
7373
7373
  return next;
7374
7374
  }
7375
7375
  function hiddenOrLocked(nodes, id) {
7376
- const loc = _chunkXCXQDPIDcjs.locateVectorNode.call(void 0, nodes, id);
7376
+ const loc = _chunkFKONE6AOcjs.locateVectorNode.call(void 0, nodes, id);
7377
7377
  if (!loc) return false;
7378
7378
  const n = loc.list[loc.index];
7379
7379
  if (n.locked || n.visible === false) return true;
@@ -7386,7 +7386,7 @@ function pencilPressureProfile(points, pressures) {
7386
7386
  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
7387
  const total = s[n - 1];
7388
7388
  if (!(total > 0)) return [];
7389
- return _chunkXCXQDPIDcjs.pressureWidthProfile.call(void 0, s.map((d, i) => ({ t: d / total, pressure: pressures[i] })));
7389
+ return _chunkFKONE6AOcjs.pressureWidthProfile.call(void 0, s.map((d, i) => ({ t: d / total, pressure: pressures[i] })));
7390
7390
  }
7391
7391
 
7392
7392
  // src/vector/render.ts
@@ -7395,21 +7395,21 @@ var fmtMatrix = (m) => `matrix(${m.map((n) => Math.round(n * 1e6) / 1e6).join("
7395
7395
  var VECTOR_BUILDER_HATCH_GAP = 6;
7396
7396
  function renderNode(stored, defs, idPrefix) {
7397
7397
  if (stored.visible === false) return null;
7398
- const node = _chunkXCXQDPIDcjs.expandVectorAppearance.call(void 0, stored);
7398
+ const node = _chunkFKONE6AOcjs.expandVectorAppearance.call(void 0, stored);
7399
7399
  if (node.type === "group") {
7400
7400
  const children = node.children.map((c) => renderNode(c, defs, idPrefix)).filter((c) => !!c);
7401
7401
  return { kind: "group", id: node.id, ...node.transform ? { transform: fmtMatrix(node.transform) } : {}, opacity: _nullishCoalesce(node.opacity, () => ( 1)), children };
7402
7402
  }
7403
- const fill = _chunkXCXQDPIDcjs.vectorPaintToSvg.call(void 0, node.fill, `${idPrefix}fill-${node.id}`, { node });
7404
- const stroke = _chunkXCXQDPIDcjs.vectorPaintToSvg.call(void 0, node.stroke, `${idPrefix}stroke-${node.id}`, { node, role: "stroke" });
7403
+ const fill = _chunkFKONE6AOcjs.vectorPaintToSvg.call(void 0, node.fill, `${idPrefix}fill-${node.id}`, { node });
7404
+ const stroke = _chunkFKONE6AOcjs.vectorPaintToSvg.call(void 0, node.stroke, `${idPrefix}stroke-${node.id}`, { node, role: "stroke" });
7405
7405
  defs.push(...fill.defs, ...stroke.defs);
7406
- const strokeParts = stroke.value !== "none" ? _chunkXCXQDPIDcjs.vectorStrokeSvgParts.call(void 0, node, `${idPrefix}clip-${node.id}`) : void 0;
7406
+ const strokeParts = stroke.value !== "none" ? _chunkFKONE6AOcjs.vectorStrokeSvgParts.call(void 0, node, `${idPrefix}clip-${node.id}`) : void 0;
7407
7407
  return {
7408
7408
  kind: "path",
7409
7409
  id: node.id,
7410
7410
  ...node.transform ? { transform: fmtMatrix(node.transform) } : {},
7411
7411
  ...strokeParts ? { strokeParts } : {},
7412
- d: _chunkXCXQDPIDcjs.vectorPathData.call(void 0, node),
7412
+ d: _chunkFKONE6AOcjs.vectorPathData.call(void 0, node),
7413
7413
  fill: fill.value,
7414
7414
  stroke: stroke.value,
7415
7415
  strokeWidth: _nullishCoalesce(node.strokeWidth, () => ( 1)),
@@ -7438,17 +7438,17 @@ var toScreen = (state, p) => ({ x: p.x * state.viewport.zoom + state.viewport.x,
7438
7438
  function screenOutline(state, node, entered) {
7439
7439
  const v = state.viewport;
7440
7440
  const view = [v.zoom, 0, 0, v.zoom, v.x, v.y];
7441
- const parent = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorParentMatrix.call(void 0, state.document.nodes, node.id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
7441
+ const parent = _nullishCoalesce(_chunkFKONE6AOcjs.vectorParentMatrix.call(void 0, state.document.nodes, node.id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
7442
7442
  return outlinePaths(node, parent, entered).map((path) => _chunkO2UH7LZEcjs.bezierPathToSvg.call(void 0, _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, path, view), { precision: 2 })).join(" ");
7443
7443
  }
7444
7444
  function outlinePaths(node, parent, entered) {
7445
- if (node.type === "path") return [_chunkXCXQDPIDcjs.vectorPathWorldBezier.call(void 0, node, parent, { effects: false })];
7446
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _chunkXCXQDPIDcjs.nodeMatrix.call(void 0, node), parent);
7447
- if (_chunkXCXQDPIDcjs.hasOwnVectorAppearance.call(void 0, node) && !entered.has(node.id)) return [_chunkO2UH7LZEcjs.transformBezierPath.call(void 0, _chunkXCXQDPIDcjs.vectorAppearanceOutline.call(void 0, node), m)];
7445
+ if (node.type === "path") return [_chunkFKONE6AOcjs.vectorPathWorldBezier.call(void 0, node, parent, { effects: false })];
7446
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _chunkFKONE6AOcjs.nodeMatrix.call(void 0, node), parent);
7447
+ if (_chunkFKONE6AOcjs.hasOwnVectorAppearance.call(void 0, node) && !entered.has(node.id)) return [_chunkO2UH7LZEcjs.transformBezierPath.call(void 0, _chunkFKONE6AOcjs.vectorAppearanceOutline.call(void 0, node), m)];
7448
7448
  return node.children.filter((c) => c.visible !== false).flatMap((c) => outlinePaths(c, m, entered));
7449
7449
  }
7450
7450
  function getVectorEnteredGroups(state) {
7451
- return _chunkXCXQDPIDcjs.vectorEnteredGroups.call(void 0, state.document.nodes, state.editingId ? [...state.selection, state.editingId] : state.selection);
7451
+ return _chunkFKONE6AOcjs.vectorEnteredGroups.call(void 0, state.document.nodes, state.editingId ? [...state.selection, state.editingId] : state.selection);
7452
7452
  }
7453
7453
  function collect(node) {
7454
7454
  if (node.type === "path") return [node];
@@ -7462,7 +7462,7 @@ function getVectorOverlayRenderData(state) {
7462
7462
  const seen = /* @__PURE__ */ new Set();
7463
7463
  const outline = (id, selected2) => {
7464
7464
  if (seen.has(id)) return;
7465
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, id);
7465
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, id);
7466
7466
  if (!node || node.visible === false) return;
7467
7467
  seen.add(id);
7468
7468
  outlines.push({ id, d: screenOutline(state, node, entered), selected: selected2 });
@@ -7481,7 +7481,7 @@ function getVectorOverlayRenderData(state) {
7481
7481
  const a = getAnchorWorld(doc, ref);
7482
7482
  const s = toScreen(state, a);
7483
7483
  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, () => ( _chunkXCXQDPIDcjs.inferAnchorType.call(void 0, a))), selected: selected(ref), hovered: sameAnchor(_optionalChain([state, 'access', _257 => _257.hover, 'optionalAccess', _258 => _258.anchor]), ref), closes };
7484
+ return { ref, x: s.x, y: s.y, type: _nullishCoalesce(a.type, () => ( _chunkFKONE6AOcjs.inferAnchorType.call(void 0, a))), selected: selected(ref), hovered: sameAnchor(_optionalChain([state, 'access', _257 => _257.hover, 'optionalAccess', _258 => _258.anchor]), ref), closes };
7485
7485
  });
7486
7486
  if (state.tool === "pen" && !state.pen && _optionalChain([state, 'access', _259 => _259.hover, 'optionalAccess', _260 => _260.anchor])) {
7487
7487
  const a = getAnchorWorld(doc, state.hover.anchor);
@@ -7507,7 +7507,7 @@ function getVectorOverlayRenderData(state) {
7507
7507
  }
7508
7508
  let penPreview = null;
7509
7509
  if (state.tool === "pen" && state.pen && state.pointer && !state.interaction) {
7510
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, state.pen.nodeId);
7510
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, state.pen.nodeId);
7511
7511
  const sp = _optionalChain([node, 'optionalAccess', _266 => _266.type]) === "path" ? node.subpaths[state.pen.subpath] : void 0;
7512
7512
  const last = sp ? getAnchorWorld(doc, { nodeId: state.pen.nodeId, subpath: state.pen.subpath, index: sp.anchors.length - 1 }) : void 0;
7513
7513
  if (last) {
@@ -7524,7 +7524,7 @@ function getVectorOverlayRenderData(state) {
7524
7524
  if (_optionalChain([it, 'optionalAccess', _267 => _267.type]) === "rotate") status = `${Math.round(it.angle)}\xB0`;
7525
7525
  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
7526
  else if (_optionalChain([it, 'optionalAccess', _270 => _270.type]) === "scale" || _optionalChain([it, 'optionalAccess', _271 => _271.type]) === "draw") {
7527
- const b = it.type === "draw" ? _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId) ? _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId)) : null : state.selectionFrame;
7527
+ const b = it.type === "draw" ? _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId) ? _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, it.nodeId)) : null : state.selectionFrame;
7528
7528
  if (b) status = `W ${fmt2(b.width)} \xD7 H ${fmt2(b.height)}`;
7529
7529
  }
7530
7530
  const guides = { lines: [], labels: [] };
@@ -7614,17 +7614,17 @@ function envelopeOverlay(state) {
7614
7614
  const target = getVectorEnvelopeTarget(state.document, state.selection);
7615
7615
  if (!target) return null;
7616
7616
  const v = state.viewport;
7617
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, target.world, [v.zoom, 0, 0, v.zoom, v.x, v.y]);
7617
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, target.world, [v.zoom, 0, 0, v.zoom, v.x, v.y]);
7618
7618
  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
7619
  const { mesh } = target.frame;
7620
- const grid = _chunkXCXQDPIDcjs.vectorMeshGridCurves.call(void 0, mesh).map((c) => {
7620
+ const grid = _chunkFKONE6AOcjs.vectorMeshGridCurves.call(void 0, mesh).map((c) => {
7621
7621
  const [a, b, cc, d] = c.map(sc);
7622
7622
  return `M${a.x} ${a.y}C${b.x} ${b.y} ${cc.x} ${cc.y} ${d.x} ${d.y}`;
7623
7623
  }).join("");
7624
7624
  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
7625
  const it = state.interaction;
7626
7626
  const active = _optionalChain([it, 'optionalAccess', _292 => _292.type]) === "envelope" && it.nodeId === target.node.id ? it.index : void 0;
7627
- const pts = _chunkXCXQDPIDcjs.vectorMeshEditPoints.call(void 0, mesh);
7627
+ const pts = _chunkFKONE6AOcjs.vectorMeshEditPoints.call(void 0, mesh);
7628
7628
  return {
7629
7629
  nodeId: target.node.id,
7630
7630
  grid,
@@ -7636,16 +7636,16 @@ function envelopeOverlay(state) {
7636
7636
  };
7637
7637
  }
7638
7638
  var VECTOR_ENVELOPE_STYLE_OPTIONS = [
7639
- ..._chunkXCXQDPIDcjs.VECTOR_WARP_STYLES.map((value) => ({ value, label: _chunkXCXQDPIDcjs.VECTOR_WARP_STYLE_LABELS[value] })),
7639
+ ..._chunkFKONE6AOcjs.VECTOR_WARP_STYLES.map((value) => ({ value, label: _chunkFKONE6AOcjs.VECTOR_WARP_STYLE_LABELS[value] })),
7640
7640
  { value: "mesh", label: "Mesh" }
7641
7641
  ];
7642
7642
  function getVectorEnvelopePanel(state) {
7643
- const nodes = state.selection.map((id) => _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7643
+ const nodes = state.selection.map((id) => _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7644
7644
  if (!nodes.length) return null;
7645
7645
  const one = nodes.length === 1 ? nodes[0] : null;
7646
7646
  const first = _optionalChain([one, 'optionalAccess', _293 => _293.effects, 'optionalAccess', _294 => _294.find, 'call', _295 => _295((e) => e.type === "envelope")]);
7647
7647
  const order = /* @__PURE__ */ new Map();
7648
- _chunkXCXQDPIDcjs.walkVectorNodes.call(void 0, state.document.nodes, (n) => order.set(n.id, order.size));
7648
+ _chunkFKONE6AOcjs.walkVectorNodes.call(void 0, state.document.nodes, (n) => order.set(n.id, order.size));
7649
7649
  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
7650
  return {
7651
7651
  nodeId: _nullishCoalesce(_optionalChain([one, 'optionalAccess', _296 => _296.id]), () => ( null)),
@@ -7662,7 +7662,7 @@ function gradientOverlay(state) {
7662
7662
  const hover = state.interaction ? null : _optionalChain([state, 'access', _302 => _302.hover, 'optionalAccess', _303 => _303.gradient]);
7663
7663
  const handleHovered = (h) => _optionalChain([hover, 'optionalAccess', _304 => _304.kind]) === "handle" && hover.handle === h;
7664
7664
  const pt = (p) => ({ x: fmt2(p.x), y: fmt2(p.y) });
7665
- const centred = _chunkXCXQDPIDcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
7665
+ const centred = _chunkFKONE6AOcjs.isCentredVectorGradient.call(void 0, a.gradient.type);
7666
7666
  const removing = _optionalChain([state, 'access', _305 => _305.interaction, 'optionalAccess', _306 => _306.type]) === "gradient" && !!state.interaction.removing;
7667
7667
  return {
7668
7668
  nodeId: a.nodeId,
@@ -7689,8 +7689,8 @@ function gradientOverlay(state) {
7689
7689
  function selectedBlends(state) {
7690
7690
  const out = /* @__PURE__ */ new Map();
7691
7691
  for (const id of state.selection) {
7692
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
7693
- const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _309 => _309.parent]);
7692
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
7693
+ const group = isVectorBlendGroup(node) ? node : _optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, state.document.nodes, id), 'optionalAccess', _309 => _309.parent]);
7694
7694
  if (isVectorBlendGroup(group)) out.set(group.id, group);
7695
7695
  }
7696
7696
  return [...out.values()];
@@ -7706,8 +7706,8 @@ function blendOverlay(state) {
7706
7706
  const spines = selectedBlends(state).flatMap((g) => {
7707
7707
  const s = vectorBlendSpine(g);
7708
7708
  if (!s) return [];
7709
- const m = _chunkXCXQDPIDcjs.multiplyMatrices.call(void 0, _nullishCoalesce(_chunkXCXQDPIDcjs.vectorWorldMatrix.call(void 0, doc.nodes, g.id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX)), view);
7710
- const d = _chunkO2UH7LZEcjs.bezierPathToSvg.call(void 0, _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, _chunkXCXQDPIDcjs.subpathsToBezier.call(void 0, [s.spine], { corners: false }), m), { precision: 2 });
7709
+ const m = _chunkFKONE6AOcjs.multiplyMatrices.call(void 0, _nullishCoalesce(_chunkFKONE6AOcjs.vectorWorldMatrix.call(void 0, doc.nodes, g.id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX)), view);
7710
+ const d = _chunkO2UH7LZEcjs.bezierPathToSvg.call(void 0, _chunkO2UH7LZEcjs.transformBezierPath.call(void 0, _chunkFKONE6AOcjs.subpathsToBezier.call(void 0, [s.spine], { corners: false }), m), { precision: 2 });
7711
7711
  const keys = s.stops.map((stop) => {
7712
7712
  const p = vectorBlendRailAt(s.rail, stop).point;
7713
7713
  return sc({ x: p[0], y: p[1] }, m);
@@ -7717,12 +7717,12 @@ function blendOverlay(state) {
7717
7717
  let start = null;
7718
7718
  const anchors = [];
7719
7719
  if (state.tool === "blend") {
7720
- const from = state.blendStart ? _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, state.blendStart.nodeId) : void 0;
7720
+ const from = state.blendStart ? _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, state.blendStart.nodeId) : void 0;
7721
7721
  if (from && state.blendStart) {
7722
7722
  const a = state.blendStart.anchor === null ? void 0 : getAnchorWorld(doc, { nodeId: from.id, subpath: 0, index: state.blendStart.anchor });
7723
7723
  start = { d: screenOutline(state, from, /* @__PURE__ */ new Set()), anchor: a ? sc(a, view) : null };
7724
7724
  }
7725
- const hovered = _optionalChain([state, 'access', _310 => _310.hover, 'optionalAccess', _311 => _311.nodeId]) ? _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, state.hover.nodeId) : void 0;
7725
+ const hovered = _optionalChain([state, 'access', _310 => _310.hover, 'optionalAccess', _311 => _311.nodeId]) ? _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, state.hover.nodeId) : void 0;
7726
7726
  if (_optionalChain([hovered, 'optionalAccess', _312 => _312.type]) === "path" && hovered.subpaths[0]) {
7727
7727
  hovered.subpaths[0].anchors.forEach((_, index) => {
7728
7728
  const a = getAnchorWorld(doc, { nodeId: hovered.id, subpath: 0, index });
@@ -7736,11 +7736,11 @@ function getVectorBlendControls(state) {
7736
7736
  const blends = selectedBlends(state);
7737
7737
  const doc = state.document;
7738
7738
  const roots = state.selection.filter((id) => {
7739
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, id);
7740
- return !!node && !node.blendStep && !node.locked && !state.selection.includes(_nullishCoalesce(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _316 => _316.parent, 'optionalAccess', _317 => _317.id]), () => ( "")));
7739
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, id);
7740
+ return !!node && !node.blendStep && !node.locked && !state.selection.includes(_nullishCoalesce(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _316 => _316.parent, 'optionalAccess', _317 => _317.id]), () => ( "")));
7741
7741
  });
7742
- const parents = new Set(roots.map((id) => _nullishCoalesce(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _318 => _318.parent, 'optionalAccess', _319 => _319.id]), () => ( null))));
7743
- const paths = roots.filter((id) => _optionalChain([_chunkXCXQDPIDcjs.findVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _320 => _320.type]) === "path" && !isVectorBlendGroup(_optionalChain([_chunkXCXQDPIDcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _321 => _321.parent])));
7742
+ const parents = new Set(roots.map((id) => _nullishCoalesce(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _318 => _318.parent, 'optionalAccess', _319 => _319.id]), () => ( null))));
7743
+ const paths = roots.filter((id) => _optionalChain([_chunkFKONE6AOcjs.findVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _320 => _320.type]) === "path" && !isVectorBlendGroup(_optionalChain([_chunkFKONE6AOcjs.locateVectorNode.call(void 0, doc.nodes, id), 'optionalAccess', _321 => _321.parent])));
7744
7744
  const first = blends[0];
7745
7745
  return {
7746
7746
  ids: blends.map((g) => g.id),
@@ -7805,14 +7805,14 @@ function isVectorTextTarget(target) {
7805
7805
  function getVectorSelectionStyle(state) {
7806
7806
  const paths = [];
7807
7807
  for (const id of state.selection) {
7808
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
7808
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
7809
7809
  if (node) paths.push(...collect(node));
7810
7810
  }
7811
7811
  const anchorMode = state.tool === "direct" && !!_optionalChain([state, 'access', _326 => _326.selectedAnchors, 'optionalAccess', _327 => _327.length]);
7812
7812
  if (anchorMode) {
7813
7813
  for (const r of state.selectedAnchors) {
7814
7814
  if (paths.some((p) => p.id === r.nodeId)) continue;
7815
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, r.nodeId);
7815
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, r.nodeId);
7816
7816
  if (_optionalChain([node, 'optionalAccess', _328 => _328.type]) === "path") paths.push(node);
7817
7817
  }
7818
7818
  }
@@ -7821,7 +7821,7 @@ function getVectorSelectionStyle(state) {
7821
7821
  const same = (get) => paths.every((p) => JSON.stringify(_nullishCoalesce(get(p), () => ( null))) === JSON.stringify(_nullishCoalesce(get(first), () => ( null))));
7822
7822
  const corners2 = [];
7823
7823
  for (const p of paths) {
7824
- for (const c of _chunkXCXQDPIDcjs.vectorCorners.call(void 0, p.subpaths)) {
7824
+ for (const c of _chunkFKONE6AOcjs.vectorCorners.call(void 0, p.subpaths)) {
7825
7825
  if (anchorMode && !state.selectedAnchors.some((r) => r.nodeId === p.id && r.subpath === c.subpath && r.index === c.index)) continue;
7826
7826
  const corner = p.subpaths[c.subpath].anchors[c.index].corner;
7827
7827
  corners2.push({ radius: _nullishCoalesce(_optionalChain([corner, 'optionalAccess', _329 => _329.radius]), () => ( 0)), kind: _nullishCoalesce(_optionalChain([corner, 'optionalAccess', _330 => _330.kind]), () => ( "round")) });
@@ -7840,7 +7840,7 @@ function getVectorSelectionStyle(state) {
7840
7840
  startArrowScale: _nullishCoalesce(first.startArrowScale, () => ( 1)),
7841
7841
  endArrowScale: _nullishCoalesce(first.endArrowScale, () => ( 1)),
7842
7842
  strokeWidthProfile: profileOf(first),
7843
- widthProfile: _chunkXCXQDPIDcjs.widthProfilePresetId.call(void 0, profileOf(first)),
7843
+ widthProfile: _chunkFKONE6AOcjs.widthProfilePresetId.call(void 0, profileOf(first)),
7844
7844
  cornerRadius: c0.radius,
7845
7845
  cornerKind: c0.kind,
7846
7846
  corners: corners2.length,
@@ -7864,8 +7864,8 @@ function getVectorSelectionStyle(state) {
7864
7864
  };
7865
7865
  }
7866
7866
  function profileOf(p) {
7867
- const points = _chunkXCXQDPIDcjs.sanitizeWidthProfile.call(void 0, p.strokeWidthProfile);
7868
- return points.length && _chunkXCXQDPIDcjs.widthProfilePresetId.call(void 0, points) !== "uniform" ? points : null;
7867
+ const points = _chunkFKONE6AOcjs.sanitizeWidthProfile.call(void 0, p.strokeWidthProfile);
7868
+ return points.length && _chunkFKONE6AOcjs.widthProfilePresetId.call(void 0, points) !== "uniform" ? points : null;
7869
7869
  }
7870
7870
  var VECTOR_STROKE_ALIGN_LABELS = { center: "Center", inside: "Inside", outside: "Outside" };
7871
7871
  var VECTOR_CORNER_KIND_LABELS = { round: "Round", inverted: "Inverted", chamfer: "Chamfer" };
@@ -7891,19 +7891,19 @@ var VECTOR_STROKE_GRADIENT_MODE_LABELS = { within: "Within stroke", along: "Alon
7891
7891
  function getVectorGradientEditor(state) {
7892
7892
  const paths = [];
7893
7893
  for (const id of state.selection) {
7894
- const node = _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id);
7894
+ const node = _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id);
7895
7895
  if (node) paths.push(...collect(node));
7896
7896
  }
7897
7897
  if (!paths.length) return null;
7898
7898
  const target = state.gradientEdit.target;
7899
7899
  const paint = paths[0][target];
7900
- const gradient = _chunkXCXQDPIDcjs.isVectorGradient.call(void 0, paint) ? paint : null;
7901
- const sorted = gradient ? _chunkXCXQDPIDcjs.sortedVectorGradientStops.call(void 0, gradient) : [];
7900
+ const gradient = _chunkFKONE6AOcjs.isVectorGradient.call(void 0, paint) ? paint : null;
7901
+ const sorted = gradient ? _chunkFKONE6AOcjs.sortedVectorGradientStops.call(void 0, gradient) : [];
7902
7902
  const stopIndex = state.gradientEdit.stop;
7903
7903
  const stops = sorted.map((s, index) => ({ ...s, index, selected: index === stopIndex }));
7904
7904
  const sel = stopIndex !== null && sorted[stopIndex] ? { ...sorted[stopIndex], index: stopIndex, last: stopIndex === sorted.length - 1 } : null;
7905
- const preview = gradient ? `linear-gradient(to right, ${_chunkXCXQDPIDcjs.expandVectorGradientStops.call(void 0, gradient).map((s) => {
7906
- const c = _chunkXCXQDPIDcjs.parseVectorColor.call(void 0, s.color);
7905
+ const preview = gradient ? `linear-gradient(to right, ${_chunkFKONE6AOcjs.expandVectorGradientStops.call(void 0, gradient).map((s) => {
7906
+ const c = _chunkFKONE6AOcjs.parseVectorColor.call(void 0, s.color);
7907
7907
  const a = (_nullishCoalesce(_optionalChain([c, 'optionalAccess', _331 => _331[3]]), () => ( 1))) * (_nullishCoalesce(s.opacity, () => ( 1)));
7908
7908
  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
7909
  return `${color} ${Math.round(s.offset * 1e4) / 100}%`;
@@ -7944,9 +7944,9 @@ var VECTOR_EDIT_TOGGLES = [
7944
7944
  { key: "curvatureMoves", label: "Curv", title: "Curvature point moves (Alt flips while dragging)" },
7945
7945
  { key: "recognizeShapes", label: "Shapes", title: "Turn pencil scribbles into shapes" }
7946
7946
  ];
7947
- var VECTOR_EFFECT_MENU = _chunkXCXQDPIDcjs.VECTOR_EFFECT_TYPES.map((type) => ({ type, label: _chunkXCXQDPIDcjs.VECTOR_EFFECT_LABELS[type] }));
7947
+ var VECTOR_EFFECT_MENU = _chunkFKONE6AOcjs.VECTOR_EFFECT_TYPES.map((type) => ({ type, label: _chunkFKONE6AOcjs.VECTOR_EFFECT_LABELS[type] }));
7948
7948
  function getVectorEffectsPanel(state) {
7949
- const nodes = state.selection.map((id) => _chunkXCXQDPIDcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7949
+ const nodes = state.selection.map((id) => _chunkFKONE6AOcjs.findVectorNode.call(void 0, state.document.nodes, id)).filter((n) => !!n && !n.blendStep);
7950
7950
  if (!nodes.length) return null;
7951
7951
  const one = nodes.length === 1 ? nodes[0] : null;
7952
7952
  return {
@@ -7955,13 +7955,13 @@ function getVectorEffectsPanel(state) {
7955
7955
  effects: (_nullishCoalesce(_optionalChain([one, 'optionalAccess', _338 => _338.effects]), () => ( []))).map((e) => ({
7956
7956
  id: e.id,
7957
7957
  type: e.type,
7958
- label: _nullishCoalesce(_chunkXCXQDPIDcjs.VECTOR_EFFECT_LABELS[e.type], () => ( e.type)),
7958
+ label: _nullishCoalesce(_chunkFKONE6AOcjs.VECTOR_EFFECT_LABELS[e.type], () => ( e.type)),
7959
7959
  enabled: e.enabled !== false,
7960
7960
  params: e.params,
7961
7961
  // The Envelope panel (`getVectorEnvelopePanel`) edits an envelope's warp and mesh.
7962
- specs: e.type === "envelope" ? [] : _nullishCoalesce(_chunkXCXQDPIDcjs.VECTOR_EFFECT_PARAM_SPECS[e.type], () => ( []))
7962
+ specs: e.type === "envelope" ? [] : _nullishCoalesce(_chunkFKONE6AOcjs.VECTOR_EFFECT_PARAM_SPECS[e.type], () => ( []))
7963
7963
  })),
7964
- expandable: nodes.some(_chunkXCXQDPIDcjs.hasVectorAppearance)
7964
+ expandable: nodes.some(_chunkFKONE6AOcjs.hasVectorAppearance)
7965
7965
  };
7966
7966
  }
7967
7967
 
@@ -8007,13 +8007,13 @@ var BLEND_PROPS = {
8007
8007
  linear: { type: "boolean", description: "Move anchors in straight lines instead of the rotation-aware morph." }
8008
8008
  };
8009
8009
  var checkBlendOptions = (params) => {
8010
- if (_optionalChain([params, 'optionalAccess', _339 => _339.spacing]) !== void 0 && !_chunkXCXQDPIDcjs.VECTOR_BLEND_SPACINGS.includes(params.spacing)) fail(`Unknown blend spacing "${params.spacing}".`);
8010
+ if (_optionalChain([params, 'optionalAccess', _339 => _339.spacing]) !== void 0 && !_chunkFKONE6AOcjs.VECTOR_BLEND_SPACINGS.includes(params.spacing)) fail(`Unknown blend spacing "${params.spacing}".`);
8011
8011
  if (_optionalChain([params, 'optionalAccess', _340 => _340.steps]) !== void 0 && !(Number.isFinite(params.steps) && params.steps >= 1)) fail("steps must be at least 1.");
8012
8012
  if (_optionalChain([params, 'optionalAccess', _341 => _341.distance]) !== void 0 && !(Number.isFinite(params.distance) && params.distance > 0)) fail("distance must be positive.");
8013
8013
  };
8014
8014
  var POINT = { type: "object", properties: { x: { type: "number" }, y: { type: "number" } }, required: ["x", "y"] };
8015
8015
  var GRADIENT_PROPS = {
8016
- type: { type: "string", enum: _chunkXCXQDPIDcjs.VECTOR_GRADIENT_TYPES, description: "linear, radial, conic (an angle sweep), reflected (linear mirrored about the start) or diamond." },
8016
+ type: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_GRADIENT_TYPES, description: "linear, radial, conic (an angle sweep), reflected (linear mirrored about the start) or diamond." },
8017
8017
  stops: {
8018
8018
  type: "array",
8019
8019
  minItems: 1,
@@ -8038,10 +8038,10 @@ var GRADIENT_PROPS = {
8038
8038
  focal: { ...POINT, description: "Radial focal point (where t = 0), in `units`." },
8039
8039
  focalRadius: { type: "number", minimum: 0, maximum: 0.99, description: "Radial focal circle radius as a fraction of the radius (SVG fr)." },
8040
8040
  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: _chunkXCXQDPIDcjs.VECTOR_GRADIENT_SPREADS, description: "What paints past the ends: pad (default), reflect or repeat." },
8042
- interpolation: { type: "string", enum: _chunkXCXQDPIDcjs.VECTOR_GRADIENT_INTERPOLATIONS, description: "Colour mixing space: srgb (default), linear (light) or oklab." },
8041
+ spread: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_GRADIENT_SPREADS, description: "What paints past the ends: pad (default), reflect or repeat." },
8042
+ interpolation: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_GRADIENT_INTERPOLATIONS, description: "Colour mixing space: srgb (default), linear (light) or oklab." },
8043
8043
  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: _chunkXCXQDPIDcjs.VECTOR_STROKE_GRADIENT_MODES, description: "On strokes: within (default, like a fill), along the path or across it." }
8044
+ strokeMode: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_STROKE_GRADIENT_MODES, description: "On strokes: within (default, like a fill), along the path or across it." }
8045
8045
  };
8046
8046
  var PAINT = {
8047
8047
  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 +8056,8 @@ var STYLE_PROPS = {
8056
8056
  strokeDasharray: { type: "array", items: { type: "number" } },
8057
8057
  fillRule: { type: "string", enum: ["nonzero", "evenodd"] },
8058
8058
  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: [..._chunkXCXQDPIDcjs.VECTOR_ARROWHEADS, null], description: "Head at the start of an open path, or null for none." },
8060
- endArrow: { type: ["string", "null"], enum: [..._chunkXCXQDPIDcjs.VECTOR_ARROWHEADS, null], description: "Head at the end of an open path, or null for none." },
8059
+ startArrow: { type: ["string", "null"], enum: [..._chunkFKONE6AOcjs.VECTOR_ARROWHEADS, null], description: "Head at the start of an open path, or null for none." },
8060
+ endArrow: { type: ["string", "null"], enum: [..._chunkFKONE6AOcjs.VECTOR_ARROWHEADS, null], description: "Head at the end of an open path, or null for none." },
8061
8061
  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
8062
  startArrowScale: { type: "number", exclusiveMinimum: 0, description: "Start head size as a multiple of the stroke width (default 1)." },
8063
8063
  endArrowScale: { type: "number", exclusiveMinimum: 0, description: "End head size as a multiple of the stroke width (default 1)." },
@@ -8068,7 +8068,7 @@ var pickStyle = (params) => {
8068
8068
  for (const key of Object.keys(STYLE_PROPS)) if (params[key] !== void 0) out[key] = params[key];
8069
8069
  for (const key of ["fill", "stroke"]) {
8070
8070
  const paint = out[key];
8071
- if (paint && typeof paint === "object") out[key] = _nullishCoalesce(_chunkXCXQDPIDcjs.sanitizeVectorGradient.call(void 0, paint), () => ( fail(`${key} is not a valid gradient: give a type and at least one stop { offset, color }.`)));
8071
+ if (paint && typeof paint === "object") out[key] = _nullishCoalesce(_chunkFKONE6AOcjs.sanitizeVectorGradient.call(void 0, paint), () => ( fail(`${key} is not a valid gradient: give a type and at least one stop { offset, color }.`)));
8072
8072
  }
8073
8073
  return out;
8074
8074
  };
@@ -8100,19 +8100,19 @@ function createVectorCommands(controller, options = {}) {
8100
8100
  const out = [];
8101
8101
  const visit = (nodes, depth) => {
8102
8102
  for (const n of nodes) {
8103
- const parent = _nullishCoalesce(_chunkXCXQDPIDcjs.vectorParentMatrix.call(void 0, state.document.nodes, n.id), () => ( _chunkXCXQDPIDcjs.IDENTITY_MATRIX));
8104
- const b = _chunkXCXQDPIDcjs.vectorNodeBounds.call(void 0, n, parent);
8103
+ const parent = _nullishCoalesce(_chunkFKONE6AOcjs.vectorParentMatrix.call(void 0, state.document.nodes, n.id), () => ( _chunkFKONE6AOcjs.IDENTITY_MATRIX));
8104
+ const b = _chunkFKONE6AOcjs.vectorNodeBounds.call(void 0, n, parent);
8105
8105
  out.push({
8106
8106
  id: n.id,
8107
8107
  type: n.type,
8108
8108
  ...n.name ? { name: n.name } : {},
8109
8109
  depth,
8110
- rotation: Math.round(_chunkXCXQDPIDcjs.vectorNodeRotation.call(void 0, n, parent) * 100) / 100,
8110
+ rotation: Math.round(_chunkFKONE6AOcjs.vectorNodeRotation.call(void 0, n, parent) * 100) / 100,
8111
8111
  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
8112
  visible: n.visible !== false,
8113
8113
  locked: !!n.locked,
8114
8114
  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: _chunkXCXQDPIDcjs.vectorPathData.call(void 0, n, 2) } : { children: n.children.length },
8115
+ ...n.type === "path" ? { fill: _nullishCoalesce(n.fill, () => ( null)), stroke: _nullishCoalesce(n.stroke, () => ( null)), strokeWidth: _nullishCoalesce(n.strokeWidth, () => ( 1)), d: _chunkFKONE6AOcjs.vectorPathData.call(void 0, n, 2) } : { children: n.children.length },
8116
8116
  ...n.type === "group" && n.blend ? { blend: { ...resolveVectorBlendOptions(n.blend), spine: !!n.blend.spine, keys: vectorBlendKeys(n).map((k) => k.id) } } : {},
8117
8117
  ...n.blendStep ? { blendStep: true } : {},
8118
8118
  ..._optionalChain([n, 'access', _350 => _350.effects, 'optionalAccess', _351 => _351.length]) ? { effects: n.effects } : {},
@@ -8164,7 +8164,7 @@ function createVectorCommands(controller, options = {}) {
8164
8164
  width: { type: "number", description: "For a line: the x offset of its end." },
8165
8165
  height: { type: "number", description: "For a line: the y offset of its end." },
8166
8166
  cornerRadius: { type: "number", minimum: 0, description: "Live corner radius of a rect, polygon or star." },
8167
- cornerKind: { type: "string", enum: _chunkXCXQDPIDcjs.VECTOR_CORNER_KINDS },
8167
+ cornerKind: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_CORNER_KINDS },
8168
8168
  sides: { type: "integer", minimum: 3 },
8169
8169
  points: { type: "integer", minimum: 3 },
8170
8170
  innerRatio: { type: "number", minimum: 0, maximum: 1 },
@@ -8221,7 +8221,7 @@ function createVectorCommands(controller, options = {}) {
8221
8221
  undoable: true,
8222
8222
  run: (_ctx, params) => {
8223
8223
  const { ids: _i, target, ...patch } = _nullishCoalesce(params, () => ( {}));
8224
- if (patch.type !== void 0 && !_chunkXCXQDPIDcjs.VECTOR_GRADIENT_TYPES.includes(patch.type)) fail(`Unknown gradient type "${patch.type}".`);
8224
+ if (patch.type !== void 0 && !_chunkFKONE6AOcjs.VECTOR_GRADIENT_TYPES.includes(patch.type)) fail(`Unknown gradient type "${patch.type}".`);
8225
8225
  if (patch.stops !== void 0 && !(Array.isArray(patch.stops) && patch.stops.length)) fail("stops needs at least one { offset, color }.");
8226
8226
  check(controller.setGradient(patch, { ids: ids(params), target: _nullishCoalesce(target, () => ( "fill")) }));
8227
8227
  const id = ids(params)[0];
@@ -8236,7 +8236,7 @@ function createVectorCommands(controller, options = {}) {
8236
8236
  label: "Corner Radius\u2026",
8237
8237
  keywords: ["round", "rounded", "corners", "radius", "fillet", "chamfer", "live corners"],
8238
8238
  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: _chunkXCXQDPIDcjs.VECTOR_CORNER_KINDS }, ids: IDS, anchors: ANCHORS } },
8239
+ params: { type: "object", properties: { radius: { type: "number", minimum: 0 }, kind: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_CORNER_KINDS }, ids: IDS, anchors: ANCHORS } },
8240
8240
  undoable: true,
8241
8241
  run: (_ctx, params) => {
8242
8242
  const refs = _optionalChain([params, 'optionalAccess', _354 => _354.anchors]) ? anchorsOf(params.anchors) : void 0;
@@ -8257,7 +8257,7 @@ function createVectorCommands(controller, options = {}) {
8257
8257
  type: "object",
8258
8258
  properties: {
8259
8259
  ids: IDS,
8260
- preset: { type: "string", enum: _chunkXCXQDPIDcjs.VECTOR_WIDTH_PRESET_IDS },
8260
+ preset: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_WIDTH_PRESET_IDS },
8261
8261
  points: WIDTH_POINTS,
8262
8262
  taper: {
8263
8263
  type: "object",
@@ -8380,7 +8380,7 @@ function createVectorCommands(controller, options = {}) {
8380
8380
  type: "object",
8381
8381
  properties: {
8382
8382
  ids: IDS,
8383
- preset: { type: "string", enum: _chunkXCXQDPIDcjs.VECTOR_WARP_STYLES },
8383
+ preset: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_WARP_STYLES },
8384
8384
  bend: { type: "number", minimum: -100, maximum: 100 },
8385
8385
  horizontal: { type: "number", minimum: -100, maximum: 100 },
8386
8386
  vertical: { type: "number", minimum: -100, maximum: 100 },
@@ -8409,7 +8409,7 @@ function createVectorCommands(controller, options = {}) {
8409
8409
  check(r);
8410
8410
  return { nodeId: r.nodeId };
8411
8411
  }
8412
- if (params.preset !== void 0 && !_chunkXCXQDPIDcjs.VECTOR_WARP_STYLES.includes(params.preset)) fail(`Unknown warp preset "${params.preset}".`);
8412
+ if (params.preset !== void 0 && !_chunkFKONE6AOcjs.VECTOR_WARP_STYLES.includes(params.preset)) fail(`Unknown warp preset "${params.preset}".`);
8413
8413
  const patch = {};
8414
8414
  if (params.preset) patch.style = params.preset;
8415
8415
  for (const k of ["bend", "horizontal", "vertical"]) if (params[k] !== void 0) patch[k] = params[k];
@@ -8424,7 +8424,7 @@ function createVectorCommands(controller, options = {}) {
8424
8424
  if (params.mesh.points) {
8425
8425
  const even = (n) => Array.from({ length: n + 1 }, (_, i) => i / n);
8426
8426
  const mesh = { us: even(columns), vs: even(rows), points: params.mesh.points.map((p) => ({ x: p.x, y: p.y })) };
8427
- if (!_chunkXCXQDPIDcjs.isValidVectorMesh.call(void 0, mesh)) fail(`A ${columns} \xD7 ${rows} mesh needs ${(3 * columns + 1) * (3 * rows + 1)} finite points.`);
8427
+ if (!_chunkFKONE6AOcjs.isValidVectorMesh.call(void 0, mesh)) fail(`A ${columns} \xD7 ${rows} mesh needs ${(3 * columns + 1) * (3 * rows + 1)} finite points.`);
8428
8428
  patch.mesh = mesh;
8429
8429
  }
8430
8430
  }
@@ -8507,7 +8507,7 @@ function createVectorCommands(controller, options = {}) {
8507
8507
  params: {
8508
8508
  type: "object",
8509
8509
  properties: {
8510
- type: { type: "string", enum: _chunkXCXQDPIDcjs.VECTOR_EFFECT_TYPES },
8510
+ type: { type: "string", enum: _chunkFKONE6AOcjs.VECTOR_EFFECT_TYPES },
8511
8511
  params: { type: "object", description: EFFECT_PARAMS_DESCRIPTION },
8512
8512
  index: { type: "integer", minimum: 0, description: "Position in the stack (default: last)." },
8513
8513
  ids: IDS
@@ -8517,7 +8517,7 @@ function createVectorCommands(controller, options = {}) {
8517
8517
  undoable: true,
8518
8518
  enabled: enabledFor,
8519
8519
  run: (_ctx, params) => {
8520
- if (!_chunkXCXQDPIDcjs.VECTOR_EFFECT_TYPES.includes(params.type)) fail(`Unknown effect type "${params.type}".`);
8520
+ if (!_chunkFKONE6AOcjs.VECTOR_EFFECT_TYPES.includes(params.type)) fail(`Unknown effect type "${params.type}".`);
8521
8521
  const targets = ids(params);
8522
8522
  const created = controller.addEffect(params.type, { ids: targets, params: params.params, index: params.index });
8523
8523
  if (!created.length) fail("Nothing to add the effect to.");
@@ -8662,10 +8662,10 @@ function createVectorCommands(controller, options = {}) {
8662
8662
  label: "Pathfinder\u2026",
8663
8663
  keywords: ["divide", "trim", "merge", "crop", "outline", "minus back", "split", "faces"],
8664
8664
  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: [..._chunkXCXQDPIDcjs.VECTOR_PATHFINDER_OPERATIONS] }, ids: IDS }, required: ["operation"] },
8665
+ params: { type: "object", properties: { operation: { type: "string", enum: [..._chunkFKONE6AOcjs.VECTOR_PATHFINDER_OPERATIONS] }, ids: IDS }, required: ["operation"] },
8666
8666
  undoable: true,
8667
8667
  run: (_ctx, params) => {
8668
- if (!_chunkXCXQDPIDcjs.VECTOR_PATHFINDER_OPERATIONS.includes(params.operation)) fail(`Unknown Pathfinder operation "${params.operation}".`);
8668
+ if (!_chunkFKONE6AOcjs.VECTOR_PATHFINDER_OPERATIONS.includes(params.operation)) fail(`Unknown Pathfinder operation "${params.operation}".`);
8669
8669
  const created = controller.pathfinder(params.operation, { ids: ids(params) });
8670
8670
  if (!created.length) fail("Nothing came out: select paths that overlap (two or more, except for divide and outline).");
8671
8671
  return { ids: created, selection: [...controller.getState().selection] };
@@ -8971,7 +8971,7 @@ function createVectorCommands(controller, options = {}) {
8971
8971
  label: "Choose Tool\u2026",
8972
8972
  keywords: ["pen", "pencil", "select", "rectangle", "ellipse"],
8973
8973
  description: "Switches the canvas tool.",
8974
- params: { type: "object", properties: { tool: { type: "string", enum: [..._chunkXCXQDPIDcjs.VECTOR_TOOLS] } }, required: ["tool"] },
8974
+ params: { type: "object", properties: { tool: { type: "string", enum: [..._chunkFKONE6AOcjs.VECTOR_TOOLS] } }, required: ["tool"] },
8975
8975
  run: (_ctx, params) => {
8976
8976
  controller.setTool(params.tool);
8977
8977
  return { tool: params.tool };
@@ -9393,5 +9393,5 @@ function createVectorCommands(controller, options = {}) {
9393
9393
 
9394
9394
 
9395
9395
 
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 = _chunkXCXQDPIDcjs.IDENTITY_MATRIX; exports.KAPPA = _chunkXCXQDPIDcjs.KAPPA; exports.LazyMouse = LazyMouse; exports.VECTOR_ARROWHEADS = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.VECTOR_EFFECT_DEFAULTS; exports.VECTOR_EFFECT_LABELS = _chunkXCXQDPIDcjs.VECTOR_EFFECT_LABELS; exports.VECTOR_EFFECT_MENU = VECTOR_EFFECT_MENU; exports.VECTOR_EFFECT_PARAM_SPECS = _chunkXCXQDPIDcjs.VECTOR_EFFECT_PARAM_SPECS; exports.VECTOR_EFFECT_TYPES = _chunkXCXQDPIDcjs.VECTOR_EFFECT_TYPES; exports.VECTOR_ENVELOPE_STYLE_OPTIONS = VECTOR_ENVELOPE_STYLE_OPTIONS; exports.VECTOR_FILL_GAP = VECTOR_FILL_GAP; exports.VECTOR_GRADIENT_INTERPOLATIONS = _chunkXCXQDPIDcjs.VECTOR_GRADIENT_INTERPOLATIONS; exports.VECTOR_GRADIENT_INTERPOLATION_LABELS = VECTOR_GRADIENT_INTERPOLATION_LABELS; exports.VECTOR_GRADIENT_MAX_PERIODS = _chunkXCXQDPIDcjs.VECTOR_GRADIENT_MAX_PERIODS; exports.VECTOR_GRADIENT_MIDPOINT_GAP = VECTOR_GRADIENT_MIDPOINT_GAP; exports.VECTOR_GRADIENT_MIN_STOPS = _chunkXCXQDPIDcjs.VECTOR_GRADIENT_MIN_STOPS; exports.VECTOR_GRADIENT_OFF_BAR = VECTOR_GRADIENT_OFF_BAR; exports.VECTOR_GRADIENT_SPREADS = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.VECTOR_PATHFINDER_OPERATIONS; exports.VECTOR_PATH_ACTIONS = VECTOR_PATH_ACTIONS; exports.VECTOR_PENCIL_STRING_PX = VECTOR_PENCIL_STRING_PX; exports.VECTOR_PRESSURE_NOMINAL = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.VECTOR_TOOLS; exports.VECTOR_TOOL_GLYPHS = VECTOR_TOOL_GLYPHS; exports.VECTOR_TOOL_SHORTCUTS = VECTOR_TOOL_SHORTCUTS; exports.VECTOR_TRANSFORM_HANDLES = _chunkXCXQDPIDcjs.VECTOR_TRANSFORM_HANDLES; exports.VECTOR_WARP_STYLES = _chunkXCXQDPIDcjs.VECTOR_WARP_STYLES; exports.VECTOR_WARP_STYLE_LABELS = _chunkXCXQDPIDcjs.VECTOR_WARP_STYLE_LABELS; exports.VECTOR_WIDTH_PRESETS = _chunkXCXQDPIDcjs.VECTOR_WIDTH_PRESETS; exports.VECTOR_WIDTH_PRESET_IDS = _chunkXCXQDPIDcjs.VECTOR_WIDTH_PRESET_IDS; exports.VECTOR_WIDTH_PROFILE_MAX_POINTS = _chunkXCXQDPIDcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS; exports.VECTOR_WIDTH_PROFILE_MAX_SCALE = _chunkXCXQDPIDcjs.VECTOR_WIDTH_PROFILE_MAX_SCALE; exports.VECTOR_WIDTH_SAME_T = _chunkXCXQDPIDcjs.VECTOR_WIDTH_SAME_T; exports.VectorEditorController = VectorEditorController; exports.VectorSnapTargets = VectorSnapTargets; exports.activeVectorEffects = _chunkXCXQDPIDcjs.activeVectorEffects; exports.addBuilderHit = addBuilderHit; exports.applyMatrix = _chunkXCXQDPIDcjs.applyMatrix; exports.applyMatrixLinear = _chunkXCXQDPIDcjs.applyMatrixLinear; exports.applyVectorBlendOptions = applyVectorBlendOptions; exports.applyVectorCornersAttribute = _chunkXCXQDPIDcjs.applyVectorCornersAttribute; exports.applyVectorEffects = _chunkXCXQDPIDcjs.applyVectorEffects; exports.applyVectorGradientPatch = _chunkXCXQDPIDcjs.applyVectorGradientPatch; exports.applyVectorGradientSpread = _chunkXCXQDPIDcjs.applyVectorGradientSpread; exports.applyVectorHomography = applyVectorHomography; exports.arrowheadInset = _chunkXCXQDPIDcjs.arrowheadInset; exports.arrowheadPath = _chunkXCXQDPIDcjs.arrowheadPath; exports.arrowheadWeight = _chunkXCXQDPIDcjs.arrowheadWeight; exports.bendSegment = bendSegment; exports.bezierToSubpaths = _chunkXCXQDPIDcjs.bezierToSubpaths; exports.boundsFromPoints = _chunkXCXQDPIDcjs.boundsFromPoints; exports.boundsIntersect = _chunkXCXQDPIDcjs.boundsIntersect; exports.clearVectorLiveBooleanCache = _chunkXCXQDPIDcjs.clearVectorLiveBooleanCache; exports.cloneAnchor = _chunkXCXQDPIDcjs.cloneAnchor; exports.cloneSubpath = _chunkXCXQDPIDcjs.cloneSubpath; exports.cloneVectorDocument = _chunkXCXQDPIDcjs.cloneVectorDocument; exports.cloneVectorNode = _chunkXCXQDPIDcjs.cloneVectorNode; exports.collectPathNodes = _chunkXCXQDPIDcjs.collectPathNodes; exports.constrainToLeave = constrainToLeave; exports.convertAnchor = _chunkXCXQDPIDcjs.convertAnchor; exports.convertVectorGradient = _chunkXCXQDPIDcjs.convertVectorGradient; exports.cornerBisectorPoint = _chunkXCXQDPIDcjs.cornerBisectorPoint; exports.cornerRadiusChange = _chunkXCXQDPIDcjs.cornerRadiusChange; exports.cornerSetback = _chunkXCXQDPIDcjs.cornerSetback; exports.correspondMorphContours = _chunkXCXQDPIDcjs.correspondMorphContours; exports.createVectorCommands = createVectorCommands; exports.createVectorEffect = _chunkXCXQDPIDcjs.createVectorEffect; exports.createVectorMorph = _chunkXCXQDPIDcjs.createVectorMorph; exports.curvatureMoveAnchor = curvatureMoveAnchor; exports.cutSubpathAt = cutSubpathAt; exports.dashIntervals = _chunkXCXQDPIDcjs.dashIntervals; exports.decomposeRigid = _chunkXCXQDPIDcjs.decomposeRigid; exports.defaultVectorGradient = _chunkXCXQDPIDcjs.defaultVectorGradient; exports.distortVectorNode = distortVectorNode; exports.dragVectorMeshPoint = _chunkXCXQDPIDcjs.dragVectorMeshPoint; exports.effectPathLength = _chunkXCXQDPIDcjs.effectPathLength; exports.effectPathVertexCount = _chunkXCXQDPIDcjs.effectPathVertexCount; exports.effectiveStrokeAlign = _chunkXCXQDPIDcjs.effectiveStrokeAlign; exports.ellipseSubpath = _chunkXCXQDPIDcjs.ellipseSubpath; exports.eraseFromFill = eraseFromFill; exports.eraseFromOutline = eraseFromOutline; exports.eraserRegion = eraserRegion; exports.evalVectorMesh = _chunkXCXQDPIDcjs.evalVectorMesh; exports.evaluateVectorPathKeyframes = _chunkXCXQDPIDcjs.evaluateVectorPathKeyframes; exports.expandVectorAppearance = _chunkXCXQDPIDcjs.expandVectorAppearance; exports.expandVectorAppearances = _chunkXCXQDPIDcjs.expandVectorAppearances; exports.expandVectorBlend = expandVectorBlend; exports.expandVectorCorners = _chunkXCXQDPIDcjs.expandVectorCorners; exports.expandVectorCornersOf = _chunkXCXQDPIDcjs.expandVectorCornersOf; exports.expandVectorGradientSpread = _chunkXCXQDPIDcjs.expandVectorGradientSpread; exports.expandVectorGradientStops = _chunkXCXQDPIDcjs.expandVectorGradientStops; exports.explicitVectorGradient = _chunkXCXQDPIDcjs.explicitVectorGradient; exports.findVectorNode = _chunkXCXQDPIDcjs.findVectorNode; exports.fitCornerRadius = _chunkXCXQDPIDcjs.fitCornerRadius; exports.fitVectorMesh = _chunkXCXQDPIDcjs.fitVectorMesh; exports.foldVectorBooleanOperands = _chunkXCXQDPIDcjs.foldVectorBooleanOperands; exports.generateVectorBlendChildren = generateVectorBlendChildren; exports.generateWidthProfile = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.gradientMidpointRemap; exports.hasExplicitGradientGeometry = _chunkXCXQDPIDcjs.hasExplicitGradientGeometry; exports.hasOwnVectorAppearance = _chunkXCXQDPIDcjs.hasOwnVectorAppearance; exports.hasPaint = _chunkXCXQDPIDcjs.hasPaint; exports.hasStrokeExtras = _chunkXCXQDPIDcjs.hasStrokeExtras; exports.hasVectorAppearance = _chunkXCXQDPIDcjs.hasVectorAppearance; exports.hasVectorCorners = _chunkXCXQDPIDcjs.hasVectorCorners; exports.hitTestVectorNode = _chunkXCXQDPIDcjs.hitTestVectorNode; exports.hitTestVectorNodes = _chunkXCXQDPIDcjs.hitTestVectorNodes; exports.hitTestVectorStroke = _chunkXCXQDPIDcjs.hitTestVectorStroke; exports.hitVectorGradientAnnotator = hitVectorGradientAnnotator; exports.inferAnchorType = _chunkXCXQDPIDcjs.inferAnchorType; exports.insertAnchor = _chunkXCXQDPIDcjs.insertAnchor; exports.insertVectorGradientStop = _chunkXCXQDPIDcjs.insertVectorGradientStop; exports.insertWidthPoint = _chunkXCXQDPIDcjs.insertWidthPoint; exports.interpolateMorphContours = _chunkXCXQDPIDcjs.interpolateMorphContours; exports.interpolateRigidMatrix = _chunkXCXQDPIDcjs.interpolateRigidMatrix; exports.interpolateVectorColor = _chunkXCXQDPIDcjs.interpolateVectorColor; exports.interpolateVectorPaint = _chunkXCXQDPIDcjs.interpolateVectorPaint; exports.interpolateVectorPaths = _chunkXCXQDPIDcjs.interpolateVectorPaths; exports.interpolateVectorStyle = _chunkXCXQDPIDcjs.interpolateVectorStyle; exports.interpolateWidthProfiles = _chunkXCXQDPIDcjs.interpolateWidthProfiles; exports.invertMatrix = _chunkXCXQDPIDcjs.invertMatrix; exports.isCentredVectorGradient = _chunkXCXQDPIDcjs.isCentredVectorGradient; exports.isClosedBezierShape = _chunkXCXQDPIDcjs.isClosedBezierShape; exports.isIdentityMatrix = _chunkXCXQDPIDcjs.isIdentityMatrix; exports.isUniformWidthProfile = _chunkXCXQDPIDcjs.isUniformWidthProfile; exports.isValidVectorMesh = _chunkXCXQDPIDcjs.isValidVectorMesh; exports.isVectorBlendGroup = isVectorBlendGroup; exports.isVectorGradient = _chunkXCXQDPIDcjs.isVectorGradient; exports.isVectorLiveBoolean = _chunkXCXQDPIDcjs.isVectorLiveBoolean; exports.isVectorTextTarget = isVectorTextTarget; exports.joinSubpaths = joinSubpaths; exports.knifePath = knifePath; exports.lineSubpath = _chunkXCXQDPIDcjs.lineSubpath; exports.locateVectorNode = _chunkXCXQDPIDcjs.locateVectorNode; exports.mapBezierPath = _chunkXCXQDPIDcjs.mapBezierPath; exports.mapVectorGradient = _chunkXCXQDPIDcjs.mapVectorGradient; exports.mapVectorMeshPoints = _chunkXCXQDPIDcjs.mapVectorMeshPoints; exports.mapVectorPaint = _chunkXCXQDPIDcjs.mapVectorPaint; exports.mapVectorPoints = _chunkXCXQDPIDcjs.mapVectorPoints; exports.mapVectorSubpaths = _chunkXCXQDPIDcjs.mapVectorSubpaths; exports.matrixRotation = _chunkXCXQDPIDcjs.matrixRotation; exports.mergePaths = _chunkXCXQDPIDcjs.mergePaths; exports.mirrorWidthProfile = _chunkXCXQDPIDcjs.mirrorWidthProfile; exports.morphContourToSubpath = _chunkXCXQDPIDcjs.morphContourToSubpath; exports.morphPathsCross = _chunkXCXQDPIDcjs.morphPathsCross; exports.moveAnchorHandle = _chunkXCXQDPIDcjs.moveAnchorHandle; exports.moveVectorGradientHandle = _chunkXCXQDPIDcjs.moveVectorGradientHandle; exports.moveVectorGradientStop = _chunkXCXQDPIDcjs.moveVectorGradientStop; exports.multiplyMatrices = _chunkXCXQDPIDcjs.multiplyMatrices; exports.nearestSegment = _chunkXCXQDPIDcjs.nearestSegment; exports.nearestStrokePosition = _chunkXCXQDPIDcjs.nearestStrokePosition; exports.nextVectorCornerKind = _chunkXCXQDPIDcjs.nextVectorCornerKind; exports.nodeMatrix = _chunkXCXQDPIDcjs.nodeMatrix; exports.normalizeVectorEffectParams = _chunkXCXQDPIDcjs.normalizeVectorEffectParams; exports.offsetPaths = _chunkXCXQDPIDcjs.offsetPaths; exports.orderVectorQuad = orderVectorQuad; exports.parseSvgTransform = _chunkXCXQDPIDcjs.parseSvgTransform; exports.parseVectorColor = _chunkXCXQDPIDcjs.parseVectorColor; exports.parseVectorSvg = _chunkXCXQDPIDcjs.parseVectorSvg; exports.pathsCenter = _chunkXCXQDPIDcjs.pathsCenter; exports.patternAttrs = _chunkXCXQDPIDcjs.patternAttrs; exports.periodicVectorGradientStops = _chunkXCXQDPIDcjs.periodicVectorGradientStops; exports.pinVectorGradient = _chunkXCXQDPIDcjs.pinVectorGradient; exports.planShapeBuilder = planShapeBuilder; exports.polygonSubpath = _chunkXCXQDPIDcjs.polygonSubpath; exports.polylineBounds = polylineBounds; exports.pressureWidthProfile = _chunkXCXQDPIDcjs.pressureWidthProfile; exports.puckerBloatPaths = _chunkXCXQDPIDcjs.puckerBloatPaths; exports.pullVectorMesh = _chunkXCXQDPIDcjs.pullVectorMesh; exports.recognizeInkShape = recognizeInkShape; exports.rectSubpath = _chunkXCXQDPIDcjs.rectSubpath; exports.refineMorphContour = _chunkXCXQDPIDcjs.refineMorphContour; exports.refreshVectorBlends = refreshVectorBlends; exports.releaseVectorBlend = releaseVectorBlend; exports.removeAnchorKeepingShape = removeAnchorKeepingShape; exports.removeAnchors = _chunkXCXQDPIDcjs.removeAnchors; exports.removeAnchorsKeepingShape = removeAnchorsKeepingShape; exports.removeRedundantPoints = removeRedundantPoints; exports.removeVectorGradientStop = _chunkXCXQDPIDcjs.removeVectorGradientStop; exports.removeVectorMeshSplitU = _chunkXCXQDPIDcjs.removeVectorMeshSplitU; exports.removeVectorMeshSplitV = _chunkXCXQDPIDcjs.removeVectorMeshSplitV; exports.removeWidthPoints = _chunkXCXQDPIDcjs.removeWidthPoints; exports.repeatPaths = _chunkXCXQDPIDcjs.repeatPaths; exports.resampleGradientStops = _chunkXCXQDPIDcjs.resampleGradientStops; exports.resizeVectorMesh = _chunkXCXQDPIDcjs.resizeVectorMesh; exports.resolveVectorBlendOptions = resolveVectorBlendOptions; exports.reverseMorphContour = _chunkXCXQDPIDcjs.reverseMorphContour; exports.reverseSubpath = _chunkXCXQDPIDcjs.reverseSubpath; exports.reverseVectorGradient = _chunkXCXQDPIDcjs.reverseVectorGradient; exports.reverseWidthProfile = _chunkXCXQDPIDcjs.reverseWidthProfile; exports.rotateMatrix = _chunkXCXQDPIDcjs.rotateMatrix; exports.roundCornerPaths = _chunkXCXQDPIDcjs.roundCornerPaths; exports.roundSubpaths = _chunkXCXQDPIDcjs.roundSubpaths; exports.samplePlainStops = _chunkXCXQDPIDcjs.samplePlainStops; exports.samplePolyline = samplePolyline; exports.sampleVectorGradient = _chunkXCXQDPIDcjs.sampleVectorGradient; exports.sampleVectorGradientAt = _chunkXCXQDPIDcjs.sampleVectorGradientAt; exports.sampleVectorPaintDefAt = _chunkXCXQDPIDcjs.sampleVectorPaintDefAt; exports.sanitizeVectorEffects = _chunkXCXQDPIDcjs.sanitizeVectorEffects; exports.sanitizeVectorGradient = _chunkXCXQDPIDcjs.sanitizeVectorGradient; exports.sanitizeWidthProfile = _chunkXCXQDPIDcjs.sanitizeWidthProfile; exports.scaleFor = scaleFor; exports.scaleMatrix = _chunkXCXQDPIDcjs.scaleMatrix; exports.setAnchorCorner = _chunkXCXQDPIDcjs.setAnchorCorner; exports.setSubpathCorners = _chunkXCXQDPIDcjs.setSubpathCorners; exports.setVectorGradientVector = _chunkXCXQDPIDcjs.setVectorGradientVector; exports.setWidthPoint = _chunkXCXQDPIDcjs.setWidthPoint; exports.simplifyPolyline = simplifyPolyline; exports.smoothSubpath = smoothSubpath; exports.solve8 = solve8; exports.sortedVectorGradientStops = _chunkXCXQDPIDcjs.sortedVectorGradientStops; exports.spanVectorGradientStops = _chunkXCXQDPIDcjs.spanVectorGradientStops; exports.splitIntoFaces = splitIntoFaces; exports.splitSubpathAt = splitSubpathAt; exports.splitVectorMeshU = _chunkXCXQDPIDcjs.splitVectorMeshU; exports.splitVectorMeshV = _chunkXCXQDPIDcjs.splitVectorMeshV; exports.starSubpath = _chunkXCXQDPIDcjs.starSubpath; exports.strokePositionPoint = _chunkXCXQDPIDcjs.strokePositionPoint; exports.strokeWidthProfileOf = _chunkXCXQDPIDcjs.strokeWidthProfileOf; exports.subpathEnclosesArea = subpathEnclosesArea; exports.subpathPointAt = subpathPointAt; exports.subpathSegment = _chunkXCXQDPIDcjs.subpathSegment; exports.subpathSegmentCount = _chunkXCXQDPIDcjs.subpathSegmentCount; exports.subpathToMorphContour = _chunkXCXQDPIDcjs.subpathToMorphContour; exports.subpathsToBezier = _chunkXCXQDPIDcjs.subpathsToBezier; exports.taperWaveFactor = _chunkXCXQDPIDcjs.taperWaveFactor; exports.toVectorKeyInput = toVectorKeyInput; exports.toVectorModifiers = toVectorModifiers; exports.toVectorPointerInput = toVectorPointerInput; exports.transformVectorEffects = _chunkXCXQDPIDcjs.transformVectorEffects; exports.transformVectorGradient = _chunkXCXQDPIDcjs.transformVectorGradient; exports.transformVectorNode = _chunkXCXQDPIDcjs.transformVectorNode; exports.transformVectorPaint = _chunkXCXQDPIDcjs.transformVectorPaint; exports.translateAnchor = _chunkXCXQDPIDcjs.translateAnchor; exports.translateMatrix = _chunkXCXQDPIDcjs.translateMatrix; exports.trimIntervals = _chunkXCXQDPIDcjs.trimIntervals; exports.trimPaths = _chunkXCXQDPIDcjs.trimPaths; exports.trimPathsIndividually = _chunkXCXQDPIDcjs.trimPathsIndividually; exports.turnMorphContour = _chunkXCXQDPIDcjs.turnMorphContour; exports.twistPaths = _chunkXCXQDPIDcjs.twistPaths; exports.unionBounds = _chunkXCXQDPIDcjs.unionBounds; exports.variableStrokeOutline = _chunkXCXQDPIDcjs.variableStrokeOutline; exports.variableStrokeRings = _chunkXCXQDPIDcjs.variableStrokeRings; exports.vectorAppearanceNodes = _chunkXCXQDPIDcjs.vectorAppearanceNodes; exports.vectorAppearanceOutline = _chunkXCXQDPIDcjs.vectorAppearanceOutline; exports.vectorAppearanceShapes = _chunkXCXQDPIDcjs.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 = _chunkXCXQDPIDcjs.vectorBoxMatrix; exports.vectorBuilderErasedEdges = vectorBuilderErasedEdges; exports.vectorCornerAt = _chunkXCXQDPIDcjs.vectorCornerAt; exports.vectorCorners = _chunkXCXQDPIDcjs.vectorCorners; exports.vectorCornersAttribute = _chunkXCXQDPIDcjs.vectorCornersAttribute; exports.vectorDiamondPath = vectorDiamondPath; exports.vectorDistortQuad = vectorDistortQuad; exports.vectorDocumentToSvg = _chunkXCXQDPIDcjs.vectorDocumentToSvg; exports.vectorEffectInputBounds = _chunkXCXQDPIDcjs.vectorEffectInputBounds; exports.vectorEffectInputPaths = _chunkXCXQDPIDcjs.vectorEffectInputPaths; exports.vectorEnteredGroups = _chunkXCXQDPIDcjs.vectorEnteredGroups; exports.vectorEnvelopeFrame = _chunkXCXQDPIDcjs.vectorEnvelopeFrame; exports.vectorEnvelopeMap = _chunkXCXQDPIDcjs.vectorEnvelopeMap; exports.vectorEnvelopeMesh = _chunkXCXQDPIDcjs.vectorEnvelopeMesh; exports.vectorFillMap = vectorFillMap; exports.vectorGradientArea = _chunkXCXQDPIDcjs.vectorGradientArea; exports.vectorGradientAspect = _chunkXCXQDPIDcjs.vectorGradientAspect; exports.vectorGradientBarPosition = vectorGradientBarPosition; exports.vectorGradientFocalParam = _chunkXCXQDPIDcjs.vectorGradientFocalParam; exports.vectorGradientHandles = _chunkXCXQDPIDcjs.vectorGradientHandles; exports.vectorGradientMatrix = _chunkXCXQDPIDcjs.vectorGradientMatrix; exports.vectorGradientMidpointFromPosition = _chunkXCXQDPIDcjs.vectorGradientMidpointFromPosition; exports.vectorGradientMidpointPosition = _chunkXCXQDPIDcjs.vectorGradientMidpointPosition; exports.vectorGradientNeedsExpansion = _chunkXCXQDPIDcjs.vectorGradientNeedsExpansion; exports.vectorGradientParam = _chunkXCXQDPIDcjs.vectorGradientParam; exports.vectorGradientPoints = _chunkXCXQDPIDcjs.vectorGradientPoints; exports.vectorGradientRamp = _chunkXCXQDPIDcjs.vectorGradientRamp; exports.vectorGradientSvgDefs = _chunkXCXQDPIDcjs.vectorGradientSvgDefs; exports.vectorGradientTAt = _chunkXCXQDPIDcjs.vectorGradientTAt; exports.vectorGradientTargetPath = vectorGradientTargetPath; exports.vectorGradientUnitsMatrix = _chunkXCXQDPIDcjs.vectorGradientUnitsMatrix; exports.vectorHomography = vectorHomography; exports.vectorHomographyKeepsQuad = vectorHomographyKeepsQuad; exports.vectorIdentityMesh = _chunkXCXQDPIDcjs.vectorIdentityMesh; exports.vectorInkShapeName = vectorInkShapeName; exports.vectorLiveBooleanSteps = _chunkXCXQDPIDcjs.vectorLiveBooleanSteps; exports.vectorMeshColumns = _chunkXCXQDPIDcjs.vectorMeshColumns; exports.vectorMeshControlBounds = _chunkXCXQDPIDcjs.vectorMeshControlBounds; exports.vectorMeshEditPoints = _chunkXCXQDPIDcjs.vectorMeshEditPoints; exports.vectorMeshFromOutline = _chunkXCXQDPIDcjs.vectorMeshFromOutline; exports.vectorMeshGridCurves = _chunkXCXQDPIDcjs.vectorMeshGridCurves; exports.vectorMeshOutline = _chunkXCXQDPIDcjs.vectorMeshOutline; exports.vectorMeshParamAt = _chunkXCXQDPIDcjs.vectorMeshParamAt; exports.vectorMeshRows = _chunkXCXQDPIDcjs.vectorMeshRows; exports.vectorNodeBounds = _chunkXCXQDPIDcjs.vectorNodeBounds; exports.vectorNodeEnvelope = _chunkXCXQDPIDcjs.vectorNodeEnvelope; exports.vectorNodeRotation = _chunkXCXQDPIDcjs.vectorNodeRotation; exports.vectorNodeToBezier = _chunkXCXQDPIDcjs.vectorNodeToBezier; exports.vectorOperandOperation = _chunkXCXQDPIDcjs.vectorOperandOperation; exports.vectorPaintToHex = vectorPaintToHex; exports.vectorPaintToSvg = _chunkXCXQDPIDcjs.vectorPaintToSvg; exports.vectorParentMatrix = _chunkXCXQDPIDcjs.vectorParentMatrix; exports.vectorPathData = _chunkXCXQDPIDcjs.vectorPathData; exports.vectorPathEntries = vectorPathEntries; exports.vectorPathLocalBounds = _chunkXCXQDPIDcjs.vectorPathLocalBounds; exports.vectorPathWorldBezier = _chunkXCXQDPIDcjs.vectorPathWorldBezier; exports.vectorPathfinderShape = vectorPathfinderShape; exports.vectorRepeaterCopies = _chunkXCXQDPIDcjs.vectorRepeaterCopies; exports.vectorResizeCursor = vectorResizeCursor; exports.vectorResultStyle = vectorResultStyle; exports.vectorShapeBuilderHit = vectorShapeBuilderHit; exports.vectorShapeBuilderMap = vectorShapeBuilderMap; exports.vectorShearForSide = vectorShearForSide; exports.vectorSkewMatrix = vectorSkewMatrix; exports.vectorStrokeGradientDefs = _chunkXCXQDPIDcjs.vectorStrokeGradientDefs; exports.vectorStrokeLineArea = _chunkXCXQDPIDcjs.vectorStrokeLineArea; exports.vectorStrokeOutline = _chunkXCXQDPIDcjs.vectorStrokeOutline; exports.vectorStrokeOutlinePath = _chunkXCXQDPIDcjs.vectorStrokeOutlinePath; exports.vectorStrokeParts = _chunkXCXQDPIDcjs.vectorStrokeParts; exports.vectorStrokeReach = _chunkXCXQDPIDcjs.vectorStrokeReach; exports.vectorStrokeSvgParts = _chunkXCXQDPIDcjs.vectorStrokeSvgParts; exports.vectorStrokeWidthGeometry = vectorStrokeWidthGeometry; exports.vectorToolLabel = vectorToolLabel; exports.vectorWarpPresetGrid = _chunkXCXQDPIDcjs.vectorWarpPresetGrid; exports.vectorWarpPresetMesh = _chunkXCXQDPIDcjs.vectorWarpPresetMesh; exports.vectorWorldMatrix = _chunkXCXQDPIDcjs.vectorWorldMatrix; exports.walkVectorNodes = _chunkXCXQDPIDcjs.walkVectorNodes; exports.widthProfileAt = _chunkXCXQDPIDcjs.widthProfileAt; exports.widthProfileFromAttribute = _chunkXCXQDPIDcjs.widthProfileFromAttribute; exports.widthProfileMaxScale = _chunkXCXQDPIDcjs.widthProfileMaxScale; exports.widthProfilePreset = _chunkXCXQDPIDcjs.widthProfilePreset; exports.widthProfilePresetId = _chunkXCXQDPIDcjs.widthProfilePresetId; exports.widthProfileToAttribute = _chunkXCXQDPIDcjs.widthProfileToAttribute; exports.wigglePaths = _chunkXCXQDPIDcjs.wigglePaths; exports.zigzagPaths = _chunkXCXQDPIDcjs.zigzagPaths;
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 = _chunkFKONE6AOcjs.IDENTITY_MATRIX; exports.KAPPA = _chunkFKONE6AOcjs.KAPPA; exports.LazyMouse = LazyMouse; exports.VECTOR_ARROWHEADS = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.VECTOR_EFFECT_DEFAULTS; exports.VECTOR_EFFECT_LABELS = _chunkFKONE6AOcjs.VECTOR_EFFECT_LABELS; exports.VECTOR_EFFECT_MENU = VECTOR_EFFECT_MENU; exports.VECTOR_EFFECT_PARAM_SPECS = _chunkFKONE6AOcjs.VECTOR_EFFECT_PARAM_SPECS; exports.VECTOR_EFFECT_TYPES = _chunkFKONE6AOcjs.VECTOR_EFFECT_TYPES; exports.VECTOR_ENVELOPE_STYLE_OPTIONS = VECTOR_ENVELOPE_STYLE_OPTIONS; exports.VECTOR_FILL_GAP = VECTOR_FILL_GAP; exports.VECTOR_GRADIENT_INTERPOLATIONS = _chunkFKONE6AOcjs.VECTOR_GRADIENT_INTERPOLATIONS; exports.VECTOR_GRADIENT_INTERPOLATION_LABELS = VECTOR_GRADIENT_INTERPOLATION_LABELS; exports.VECTOR_GRADIENT_MAX_PERIODS = _chunkFKONE6AOcjs.VECTOR_GRADIENT_MAX_PERIODS; exports.VECTOR_GRADIENT_MIDPOINT_GAP = VECTOR_GRADIENT_MIDPOINT_GAP; exports.VECTOR_GRADIENT_MIN_STOPS = _chunkFKONE6AOcjs.VECTOR_GRADIENT_MIN_STOPS; exports.VECTOR_GRADIENT_OFF_BAR = VECTOR_GRADIENT_OFF_BAR; exports.VECTOR_GRADIENT_SPREADS = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.VECTOR_PATHFINDER_OPERATIONS; exports.VECTOR_PATH_ACTIONS = VECTOR_PATH_ACTIONS; exports.VECTOR_PENCIL_STRING_PX = VECTOR_PENCIL_STRING_PX; exports.VECTOR_PRESSURE_NOMINAL = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.VECTOR_TOOLS; exports.VECTOR_TOOL_GLYPHS = VECTOR_TOOL_GLYPHS; exports.VECTOR_TOOL_SHORTCUTS = VECTOR_TOOL_SHORTCUTS; exports.VECTOR_TRANSFORM_HANDLES = _chunkFKONE6AOcjs.VECTOR_TRANSFORM_HANDLES; exports.VECTOR_WARP_STYLES = _chunkFKONE6AOcjs.VECTOR_WARP_STYLES; exports.VECTOR_WARP_STYLE_LABELS = _chunkFKONE6AOcjs.VECTOR_WARP_STYLE_LABELS; exports.VECTOR_WIDTH_PRESETS = _chunkFKONE6AOcjs.VECTOR_WIDTH_PRESETS; exports.VECTOR_WIDTH_PRESET_IDS = _chunkFKONE6AOcjs.VECTOR_WIDTH_PRESET_IDS; exports.VECTOR_WIDTH_PROFILE_MAX_POINTS = _chunkFKONE6AOcjs.VECTOR_WIDTH_PROFILE_MAX_POINTS; exports.VECTOR_WIDTH_PROFILE_MAX_SCALE = _chunkFKONE6AOcjs.VECTOR_WIDTH_PROFILE_MAX_SCALE; exports.VECTOR_WIDTH_SAME_T = _chunkFKONE6AOcjs.VECTOR_WIDTH_SAME_T; exports.VectorEditorController = VectorEditorController; exports.VectorSnapTargets = VectorSnapTargets; exports.activeVectorEffects = _chunkFKONE6AOcjs.activeVectorEffects; exports.addBuilderHit = addBuilderHit; exports.applyMatrix = _chunkFKONE6AOcjs.applyMatrix; exports.applyMatrixLinear = _chunkFKONE6AOcjs.applyMatrixLinear; exports.applyVectorBlendOptions = applyVectorBlendOptions; exports.applyVectorCornersAttribute = _chunkFKONE6AOcjs.applyVectorCornersAttribute; exports.applyVectorEffects = _chunkFKONE6AOcjs.applyVectorEffects; exports.applyVectorGradientPatch = _chunkFKONE6AOcjs.applyVectorGradientPatch; exports.applyVectorGradientSpread = _chunkFKONE6AOcjs.applyVectorGradientSpread; exports.applyVectorHomography = applyVectorHomography; exports.arrowheadInset = _chunkFKONE6AOcjs.arrowheadInset; exports.arrowheadPath = _chunkFKONE6AOcjs.arrowheadPath; exports.arrowheadWeight = _chunkFKONE6AOcjs.arrowheadWeight; exports.bendSegment = bendSegment; exports.bezierToSubpaths = _chunkFKONE6AOcjs.bezierToSubpaths; exports.boundsFromPoints = _chunkFKONE6AOcjs.boundsFromPoints; exports.boundsIntersect = _chunkFKONE6AOcjs.boundsIntersect; exports.clearVectorLiveBooleanCache = _chunkFKONE6AOcjs.clearVectorLiveBooleanCache; exports.cloneAnchor = _chunkFKONE6AOcjs.cloneAnchor; exports.cloneSubpath = _chunkFKONE6AOcjs.cloneSubpath; exports.cloneVectorDocument = _chunkFKONE6AOcjs.cloneVectorDocument; exports.cloneVectorNode = _chunkFKONE6AOcjs.cloneVectorNode; exports.collectPathNodes = _chunkFKONE6AOcjs.collectPathNodes; exports.constrainToLeave = constrainToLeave; exports.convertAnchor = _chunkFKONE6AOcjs.convertAnchor; exports.convertVectorGradient = _chunkFKONE6AOcjs.convertVectorGradient; exports.cornerBisectorPoint = _chunkFKONE6AOcjs.cornerBisectorPoint; exports.cornerRadiusChange = _chunkFKONE6AOcjs.cornerRadiusChange; exports.cornerSetback = _chunkFKONE6AOcjs.cornerSetback; exports.correspondMorphContours = _chunkFKONE6AOcjs.correspondMorphContours; exports.createVectorCommands = createVectorCommands; exports.createVectorEffect = _chunkFKONE6AOcjs.createVectorEffect; exports.createVectorMorph = _chunkFKONE6AOcjs.createVectorMorph; exports.curvatureMoveAnchor = curvatureMoveAnchor; exports.cutSubpathAt = cutSubpathAt; exports.dashIntervals = _chunkFKONE6AOcjs.dashIntervals; exports.decomposeRigid = _chunkFKONE6AOcjs.decomposeRigid; exports.defaultVectorGradient = _chunkFKONE6AOcjs.defaultVectorGradient; exports.distortVectorNode = distortVectorNode; exports.dragVectorMeshPoint = _chunkFKONE6AOcjs.dragVectorMeshPoint; exports.effectPathLength = _chunkFKONE6AOcjs.effectPathLength; exports.effectPathVertexCount = _chunkFKONE6AOcjs.effectPathVertexCount; exports.effectiveStrokeAlign = _chunkFKONE6AOcjs.effectiveStrokeAlign; exports.ellipseSubpath = _chunkFKONE6AOcjs.ellipseSubpath; exports.eraseFromFill = eraseFromFill; exports.eraseFromOutline = eraseFromOutline; exports.eraserRegion = eraserRegion; exports.evalVectorMesh = _chunkFKONE6AOcjs.evalVectorMesh; exports.evaluateVectorPathKeyframes = _chunkFKONE6AOcjs.evaluateVectorPathKeyframes; exports.expandVectorAppearance = _chunkFKONE6AOcjs.expandVectorAppearance; exports.expandVectorAppearances = _chunkFKONE6AOcjs.expandVectorAppearances; exports.expandVectorBlend = expandVectorBlend; exports.expandVectorCorners = _chunkFKONE6AOcjs.expandVectorCorners; exports.expandVectorCornersOf = _chunkFKONE6AOcjs.expandVectorCornersOf; exports.expandVectorGradientSpread = _chunkFKONE6AOcjs.expandVectorGradientSpread; exports.expandVectorGradientStops = _chunkFKONE6AOcjs.expandVectorGradientStops; exports.explicitVectorGradient = _chunkFKONE6AOcjs.explicitVectorGradient; exports.findVectorNode = _chunkFKONE6AOcjs.findVectorNode; exports.fitCornerRadius = _chunkFKONE6AOcjs.fitCornerRadius; exports.fitVectorMesh = _chunkFKONE6AOcjs.fitVectorMesh; exports.foldVectorBooleanOperands = _chunkFKONE6AOcjs.foldVectorBooleanOperands; exports.generateVectorBlendChildren = generateVectorBlendChildren; exports.generateWidthProfile = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.gradientMidpointRemap; exports.hasExplicitGradientGeometry = _chunkFKONE6AOcjs.hasExplicitGradientGeometry; exports.hasOwnVectorAppearance = _chunkFKONE6AOcjs.hasOwnVectorAppearance; exports.hasPaint = _chunkFKONE6AOcjs.hasPaint; exports.hasStrokeExtras = _chunkFKONE6AOcjs.hasStrokeExtras; exports.hasVectorAppearance = _chunkFKONE6AOcjs.hasVectorAppearance; exports.hasVectorCorners = _chunkFKONE6AOcjs.hasVectorCorners; exports.hitTestVectorNode = _chunkFKONE6AOcjs.hitTestVectorNode; exports.hitTestVectorNodes = _chunkFKONE6AOcjs.hitTestVectorNodes; exports.hitTestVectorStroke = _chunkFKONE6AOcjs.hitTestVectorStroke; exports.hitVectorGradientAnnotator = hitVectorGradientAnnotator; exports.inferAnchorType = _chunkFKONE6AOcjs.inferAnchorType; exports.insertAnchor = _chunkFKONE6AOcjs.insertAnchor; exports.insertVectorGradientStop = _chunkFKONE6AOcjs.insertVectorGradientStop; exports.insertWidthPoint = _chunkFKONE6AOcjs.insertWidthPoint; exports.interpolateMorphContours = _chunkFKONE6AOcjs.interpolateMorphContours; exports.interpolateRigidMatrix = _chunkFKONE6AOcjs.interpolateRigidMatrix; exports.interpolateVectorColor = _chunkFKONE6AOcjs.interpolateVectorColor; exports.interpolateVectorPaint = _chunkFKONE6AOcjs.interpolateVectorPaint; exports.interpolateVectorPaths = _chunkFKONE6AOcjs.interpolateVectorPaths; exports.interpolateVectorStyle = _chunkFKONE6AOcjs.interpolateVectorStyle; exports.interpolateWidthProfiles = _chunkFKONE6AOcjs.interpolateWidthProfiles; exports.invertMatrix = _chunkFKONE6AOcjs.invertMatrix; exports.isCentredVectorGradient = _chunkFKONE6AOcjs.isCentredVectorGradient; exports.isClosedBezierShape = _chunkFKONE6AOcjs.isClosedBezierShape; exports.isIdentityMatrix = _chunkFKONE6AOcjs.isIdentityMatrix; exports.isUniformWidthProfile = _chunkFKONE6AOcjs.isUniformWidthProfile; exports.isValidVectorMesh = _chunkFKONE6AOcjs.isValidVectorMesh; exports.isVectorBlendGroup = isVectorBlendGroup; exports.isVectorGradient = _chunkFKONE6AOcjs.isVectorGradient; exports.isVectorLiveBoolean = _chunkFKONE6AOcjs.isVectorLiveBoolean; exports.isVectorTextTarget = isVectorTextTarget; exports.joinSubpaths = joinSubpaths; exports.knifePath = knifePath; exports.lineSubpath = _chunkFKONE6AOcjs.lineSubpath; exports.locateVectorNode = _chunkFKONE6AOcjs.locateVectorNode; exports.mapBezierPath = _chunkFKONE6AOcjs.mapBezierPath; exports.mapVectorGradient = _chunkFKONE6AOcjs.mapVectorGradient; exports.mapVectorMeshPoints = _chunkFKONE6AOcjs.mapVectorMeshPoints; exports.mapVectorPaint = _chunkFKONE6AOcjs.mapVectorPaint; exports.mapVectorPoints = _chunkFKONE6AOcjs.mapVectorPoints; exports.mapVectorSubpaths = _chunkFKONE6AOcjs.mapVectorSubpaths; exports.matrixRotation = _chunkFKONE6AOcjs.matrixRotation; exports.mergePaths = _chunkFKONE6AOcjs.mergePaths; exports.mirrorWidthProfile = _chunkFKONE6AOcjs.mirrorWidthProfile; exports.morphContourToSubpath = _chunkFKONE6AOcjs.morphContourToSubpath; exports.morphPathsCross = _chunkFKONE6AOcjs.morphPathsCross; exports.moveAnchorHandle = _chunkFKONE6AOcjs.moveAnchorHandle; exports.moveVectorGradientHandle = _chunkFKONE6AOcjs.moveVectorGradientHandle; exports.moveVectorGradientStop = _chunkFKONE6AOcjs.moveVectorGradientStop; exports.multiplyMatrices = _chunkFKONE6AOcjs.multiplyMatrices; exports.nearestSegment = _chunkFKONE6AOcjs.nearestSegment; exports.nearestStrokePosition = _chunkFKONE6AOcjs.nearestStrokePosition; exports.nextVectorCornerKind = _chunkFKONE6AOcjs.nextVectorCornerKind; exports.nodeMatrix = _chunkFKONE6AOcjs.nodeMatrix; exports.normalizeVectorEffectParams = _chunkFKONE6AOcjs.normalizeVectorEffectParams; exports.offsetPaths = _chunkFKONE6AOcjs.offsetPaths; exports.orderVectorQuad = orderVectorQuad; exports.parseSvgTransform = _chunkFKONE6AOcjs.parseSvgTransform; exports.parseVectorColor = _chunkFKONE6AOcjs.parseVectorColor; exports.parseVectorSvg = _chunkFKONE6AOcjs.parseVectorSvg; exports.pathsCenter = _chunkFKONE6AOcjs.pathsCenter; exports.patternAttrs = _chunkFKONE6AOcjs.patternAttrs; exports.periodicVectorGradientStops = _chunkFKONE6AOcjs.periodicVectorGradientStops; exports.pinVectorGradient = _chunkFKONE6AOcjs.pinVectorGradient; exports.planShapeBuilder = planShapeBuilder; exports.polygonSubpath = _chunkFKONE6AOcjs.polygonSubpath; exports.polylineBounds = polylineBounds; exports.pressureWidthProfile = _chunkFKONE6AOcjs.pressureWidthProfile; exports.puckerBloatPaths = _chunkFKONE6AOcjs.puckerBloatPaths; exports.pullVectorMesh = _chunkFKONE6AOcjs.pullVectorMesh; exports.recognizeInkShape = recognizeInkShape; exports.rectSubpath = _chunkFKONE6AOcjs.rectSubpath; exports.refineMorphContour = _chunkFKONE6AOcjs.refineMorphContour; exports.refreshVectorBlends = refreshVectorBlends; exports.releaseVectorBlend = releaseVectorBlend; exports.removeAnchorKeepingShape = removeAnchorKeepingShape; exports.removeAnchors = _chunkFKONE6AOcjs.removeAnchors; exports.removeAnchorsKeepingShape = removeAnchorsKeepingShape; exports.removeRedundantPoints = removeRedundantPoints; exports.removeVectorGradientStop = _chunkFKONE6AOcjs.removeVectorGradientStop; exports.removeVectorMeshSplitU = _chunkFKONE6AOcjs.removeVectorMeshSplitU; exports.removeVectorMeshSplitV = _chunkFKONE6AOcjs.removeVectorMeshSplitV; exports.removeWidthPoints = _chunkFKONE6AOcjs.removeWidthPoints; exports.repeatPaths = _chunkFKONE6AOcjs.repeatPaths; exports.resampleGradientStops = _chunkFKONE6AOcjs.resampleGradientStops; exports.resizeVectorMesh = _chunkFKONE6AOcjs.resizeVectorMesh; exports.resolveVectorBlendOptions = resolveVectorBlendOptions; exports.reverseMorphContour = _chunkFKONE6AOcjs.reverseMorphContour; exports.reverseSubpath = _chunkFKONE6AOcjs.reverseSubpath; exports.reverseVectorGradient = _chunkFKONE6AOcjs.reverseVectorGradient; exports.reverseWidthProfile = _chunkFKONE6AOcjs.reverseWidthProfile; exports.rotateMatrix = _chunkFKONE6AOcjs.rotateMatrix; exports.roundCornerPaths = _chunkFKONE6AOcjs.roundCornerPaths; exports.roundSubpaths = _chunkFKONE6AOcjs.roundSubpaths; exports.samplePlainStops = _chunkFKONE6AOcjs.samplePlainStops; exports.samplePolyline = samplePolyline; exports.sampleVectorGradient = _chunkFKONE6AOcjs.sampleVectorGradient; exports.sampleVectorGradientAt = _chunkFKONE6AOcjs.sampleVectorGradientAt; exports.sampleVectorPaintDefAt = _chunkFKONE6AOcjs.sampleVectorPaintDefAt; exports.sanitizeVectorEffects = _chunkFKONE6AOcjs.sanitizeVectorEffects; exports.sanitizeVectorGradient = _chunkFKONE6AOcjs.sanitizeVectorGradient; exports.sanitizeWidthProfile = _chunkFKONE6AOcjs.sanitizeWidthProfile; exports.scaleFor = scaleFor; exports.scaleMatrix = _chunkFKONE6AOcjs.scaleMatrix; exports.setAnchorCorner = _chunkFKONE6AOcjs.setAnchorCorner; exports.setSubpathCorners = _chunkFKONE6AOcjs.setSubpathCorners; exports.setVectorGradientVector = _chunkFKONE6AOcjs.setVectorGradientVector; exports.setWidthPoint = _chunkFKONE6AOcjs.setWidthPoint; exports.simplifyPolyline = simplifyPolyline; exports.smoothSubpath = smoothSubpath; exports.solve8 = solve8; exports.sortedVectorGradientStops = _chunkFKONE6AOcjs.sortedVectorGradientStops; exports.spanVectorGradientStops = _chunkFKONE6AOcjs.spanVectorGradientStops; exports.splitIntoFaces = splitIntoFaces; exports.splitSubpathAt = splitSubpathAt; exports.splitVectorMeshU = _chunkFKONE6AOcjs.splitVectorMeshU; exports.splitVectorMeshV = _chunkFKONE6AOcjs.splitVectorMeshV; exports.starSubpath = _chunkFKONE6AOcjs.starSubpath; exports.strokePositionPoint = _chunkFKONE6AOcjs.strokePositionPoint; exports.strokeWidthProfileOf = _chunkFKONE6AOcjs.strokeWidthProfileOf; exports.subpathEnclosesArea = subpathEnclosesArea; exports.subpathPointAt = subpathPointAt; exports.subpathSegment = _chunkFKONE6AOcjs.subpathSegment; exports.subpathSegmentCount = _chunkFKONE6AOcjs.subpathSegmentCount; exports.subpathToMorphContour = _chunkFKONE6AOcjs.subpathToMorphContour; exports.subpathsToBezier = _chunkFKONE6AOcjs.subpathsToBezier; exports.taperWaveFactor = _chunkFKONE6AOcjs.taperWaveFactor; exports.toVectorKeyInput = toVectorKeyInput; exports.toVectorModifiers = toVectorModifiers; exports.toVectorPointerInput = toVectorPointerInput; exports.transformVectorEffects = _chunkFKONE6AOcjs.transformVectorEffects; exports.transformVectorGradient = _chunkFKONE6AOcjs.transformVectorGradient; exports.transformVectorNode = _chunkFKONE6AOcjs.transformVectorNode; exports.transformVectorPaint = _chunkFKONE6AOcjs.transformVectorPaint; exports.translateAnchor = _chunkFKONE6AOcjs.translateAnchor; exports.translateMatrix = _chunkFKONE6AOcjs.translateMatrix; exports.trimIntervals = _chunkFKONE6AOcjs.trimIntervals; exports.trimPaths = _chunkFKONE6AOcjs.trimPaths; exports.trimPathsIndividually = _chunkFKONE6AOcjs.trimPathsIndividually; exports.turnMorphContour = _chunkFKONE6AOcjs.turnMorphContour; exports.twistPaths = _chunkFKONE6AOcjs.twistPaths; exports.unionBounds = _chunkFKONE6AOcjs.unionBounds; exports.variableStrokeOutline = _chunkFKONE6AOcjs.variableStrokeOutline; exports.variableStrokeRings = _chunkFKONE6AOcjs.variableStrokeRings; exports.vectorAppearanceNodes = _chunkFKONE6AOcjs.vectorAppearanceNodes; exports.vectorAppearanceOutline = _chunkFKONE6AOcjs.vectorAppearanceOutline; exports.vectorAppearanceShapes = _chunkFKONE6AOcjs.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 = _chunkFKONE6AOcjs.vectorBoxMatrix; exports.vectorBuilderErasedEdges = vectorBuilderErasedEdges; exports.vectorCornerAt = _chunkFKONE6AOcjs.vectorCornerAt; exports.vectorCorners = _chunkFKONE6AOcjs.vectorCorners; exports.vectorCornersAttribute = _chunkFKONE6AOcjs.vectorCornersAttribute; exports.vectorDiamondPath = vectorDiamondPath; exports.vectorDistortQuad = vectorDistortQuad; exports.vectorDocumentToSvg = _chunkFKONE6AOcjs.vectorDocumentToSvg; exports.vectorEffectInputBounds = _chunkFKONE6AOcjs.vectorEffectInputBounds; exports.vectorEffectInputPaths = _chunkFKONE6AOcjs.vectorEffectInputPaths; exports.vectorEnteredGroups = _chunkFKONE6AOcjs.vectorEnteredGroups; exports.vectorEnvelopeFrame = _chunkFKONE6AOcjs.vectorEnvelopeFrame; exports.vectorEnvelopeMap = _chunkFKONE6AOcjs.vectorEnvelopeMap; exports.vectorEnvelopeMesh = _chunkFKONE6AOcjs.vectorEnvelopeMesh; exports.vectorFillMap = vectorFillMap; exports.vectorGradientArea = _chunkFKONE6AOcjs.vectorGradientArea; exports.vectorGradientAspect = _chunkFKONE6AOcjs.vectorGradientAspect; exports.vectorGradientBarPosition = vectorGradientBarPosition; exports.vectorGradientFocalParam = _chunkFKONE6AOcjs.vectorGradientFocalParam; exports.vectorGradientHandles = _chunkFKONE6AOcjs.vectorGradientHandles; exports.vectorGradientMatrix = _chunkFKONE6AOcjs.vectorGradientMatrix; exports.vectorGradientMidpointFromPosition = _chunkFKONE6AOcjs.vectorGradientMidpointFromPosition; exports.vectorGradientMidpointPosition = _chunkFKONE6AOcjs.vectorGradientMidpointPosition; exports.vectorGradientNeedsExpansion = _chunkFKONE6AOcjs.vectorGradientNeedsExpansion; exports.vectorGradientParam = _chunkFKONE6AOcjs.vectorGradientParam; exports.vectorGradientPoints = _chunkFKONE6AOcjs.vectorGradientPoints; exports.vectorGradientRamp = _chunkFKONE6AOcjs.vectorGradientRamp; exports.vectorGradientSvgDefs = _chunkFKONE6AOcjs.vectorGradientSvgDefs; exports.vectorGradientTAt = _chunkFKONE6AOcjs.vectorGradientTAt; exports.vectorGradientTargetPath = vectorGradientTargetPath; exports.vectorGradientUnitsMatrix = _chunkFKONE6AOcjs.vectorGradientUnitsMatrix; exports.vectorHomography = vectorHomography; exports.vectorHomographyKeepsQuad = vectorHomographyKeepsQuad; exports.vectorIdentityMesh = _chunkFKONE6AOcjs.vectorIdentityMesh; exports.vectorInkShapeName = vectorInkShapeName; exports.vectorLiveBooleanSteps = _chunkFKONE6AOcjs.vectorLiveBooleanSteps; exports.vectorMeshColumns = _chunkFKONE6AOcjs.vectorMeshColumns; exports.vectorMeshControlBounds = _chunkFKONE6AOcjs.vectorMeshControlBounds; exports.vectorMeshEditPoints = _chunkFKONE6AOcjs.vectorMeshEditPoints; exports.vectorMeshFromOutline = _chunkFKONE6AOcjs.vectorMeshFromOutline; exports.vectorMeshGridCurves = _chunkFKONE6AOcjs.vectorMeshGridCurves; exports.vectorMeshOutline = _chunkFKONE6AOcjs.vectorMeshOutline; exports.vectorMeshParamAt = _chunkFKONE6AOcjs.vectorMeshParamAt; exports.vectorMeshRows = _chunkFKONE6AOcjs.vectorMeshRows; exports.vectorNodeBounds = _chunkFKONE6AOcjs.vectorNodeBounds; exports.vectorNodeEnvelope = _chunkFKONE6AOcjs.vectorNodeEnvelope; exports.vectorNodeRotation = _chunkFKONE6AOcjs.vectorNodeRotation; exports.vectorNodeToBezier = _chunkFKONE6AOcjs.vectorNodeToBezier; exports.vectorOperandOperation = _chunkFKONE6AOcjs.vectorOperandOperation; exports.vectorPaintToHex = vectorPaintToHex; exports.vectorPaintToSvg = _chunkFKONE6AOcjs.vectorPaintToSvg; exports.vectorParentMatrix = _chunkFKONE6AOcjs.vectorParentMatrix; exports.vectorPathData = _chunkFKONE6AOcjs.vectorPathData; exports.vectorPathEntries = vectorPathEntries; exports.vectorPathLocalBounds = _chunkFKONE6AOcjs.vectorPathLocalBounds; exports.vectorPathWorldBezier = _chunkFKONE6AOcjs.vectorPathWorldBezier; exports.vectorPathfinderShape = vectorPathfinderShape; exports.vectorRepeaterCopies = _chunkFKONE6AOcjs.vectorRepeaterCopies; exports.vectorResizeCursor = vectorResizeCursor; exports.vectorResultStyle = vectorResultStyle; exports.vectorShapeBuilderHit = vectorShapeBuilderHit; exports.vectorShapeBuilderMap = vectorShapeBuilderMap; exports.vectorShearForSide = vectorShearForSide; exports.vectorSkewMatrix = vectorSkewMatrix; exports.vectorStrokeGradientDefs = _chunkFKONE6AOcjs.vectorStrokeGradientDefs; exports.vectorStrokeLineArea = _chunkFKONE6AOcjs.vectorStrokeLineArea; exports.vectorStrokeOutline = _chunkFKONE6AOcjs.vectorStrokeOutline; exports.vectorStrokeOutlinePath = _chunkFKONE6AOcjs.vectorStrokeOutlinePath; exports.vectorStrokeParts = _chunkFKONE6AOcjs.vectorStrokeParts; exports.vectorStrokeReach = _chunkFKONE6AOcjs.vectorStrokeReach; exports.vectorStrokeSvgParts = _chunkFKONE6AOcjs.vectorStrokeSvgParts; exports.vectorStrokeWidthGeometry = vectorStrokeWidthGeometry; exports.vectorToolLabel = vectorToolLabel; exports.vectorWarpPresetGrid = _chunkFKONE6AOcjs.vectorWarpPresetGrid; exports.vectorWarpPresetMesh = _chunkFKONE6AOcjs.vectorWarpPresetMesh; exports.vectorWorldMatrix = _chunkFKONE6AOcjs.vectorWorldMatrix; exports.walkVectorNodes = _chunkFKONE6AOcjs.walkVectorNodes; exports.widthProfileAt = _chunkFKONE6AOcjs.widthProfileAt; exports.widthProfileFromAttribute = _chunkFKONE6AOcjs.widthProfileFromAttribute; exports.widthProfileMaxScale = _chunkFKONE6AOcjs.widthProfileMaxScale; exports.widthProfilePreset = _chunkFKONE6AOcjs.widthProfilePreset; exports.widthProfilePresetId = _chunkFKONE6AOcjs.widthProfilePresetId; exports.widthProfileToAttribute = _chunkFKONE6AOcjs.widthProfileToAttribute; exports.wigglePaths = _chunkFKONE6AOcjs.wigglePaths; exports.zigzagPaths = _chunkFKONE6AOcjs.zigzagPaths;
9397
9397
  //# sourceMappingURL=index.cjs.map