@pixerate/editor 0.114.0 → 0.116.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (122) hide show
  1. package/THIRD_PARTY_NOTICES.md +6 -0
  2. package/dist/animation-editor/index.cjs +54 -54
  3. package/dist/animation-editor/index.d.cts +2 -2
  4. package/dist/animation-editor/index.d.ts +2 -2
  5. package/dist/animation-editor/index.js +2 -2
  6. package/dist/{chunk-DFQEX3AM.cjs → chunk-2UT4GXYA.cjs} +133 -8
  7. package/dist/chunk-2UT4GXYA.cjs.map +1 -0
  8. package/dist/{chunk-VXR7XWMF.js → chunk-7LNZAWSJ.js} +437 -41
  9. package/dist/chunk-7LNZAWSJ.js.map +1 -0
  10. package/dist/{chunk-LKCYANMW.js → chunk-ARQ7PQ6Q.js} +129 -4
  11. package/dist/chunk-ARQ7PQ6Q.js.map +1 -0
  12. package/dist/chunk-COAMRKVI.cjs +159 -0
  13. package/dist/chunk-COAMRKVI.cjs.map +1 -0
  14. package/dist/{chunk-C6C5PDKU.js → chunk-D53KSJUV.js} +3 -322
  15. package/dist/chunk-D53KSJUV.js.map +1 -0
  16. package/dist/chunk-D53VQGEJ.js +3262 -0
  17. package/dist/chunk-D53VQGEJ.js.map +1 -0
  18. package/dist/chunk-EJVDBITD.cjs +501 -0
  19. package/dist/chunk-EJVDBITD.cjs.map +1 -0
  20. package/dist/{chunk-LPLCWZTM.cjs → chunk-FODKPD44.cjs} +555 -159
  21. package/dist/chunk-FODKPD44.cjs.map +1 -0
  22. package/dist/chunk-HOCPSFGA.cjs +3262 -0
  23. package/dist/chunk-HOCPSFGA.cjs.map +1 -0
  24. package/dist/chunk-IPFRWILU.js +1908 -0
  25. package/dist/chunk-IPFRWILU.js.map +1 -0
  26. package/dist/{chunk-FV5AXTSF.cjs → chunk-JSSBHMMU.cjs} +36 -188
  27. package/dist/chunk-JSSBHMMU.cjs.map +1 -0
  28. package/dist/chunk-LF4WOZXZ.js +159 -0
  29. package/dist/chunk-LF4WOZXZ.js.map +1 -0
  30. package/dist/{chunk-26PGXHY7.cjs → chunk-M7O4BJRH.cjs} +36 -36
  31. package/dist/{chunk-26PGXHY7.cjs.map → chunk-M7O4BJRH.cjs.map} +1 -1
  32. package/dist/chunk-N3467VD6.js +501 -0
  33. package/dist/chunk-N3467VD6.js.map +1 -0
  34. package/dist/{chunk-ST7E3NEE.cjs → chunk-PAOWHJ5O.cjs} +18 -337
  35. package/dist/chunk-PAOWHJ5O.cjs.map +1 -0
  36. package/dist/{chunk-EUVSQ25B.js → chunk-SEBYNBHW.js} +85 -46
  37. package/dist/chunk-SEBYNBHW.js.map +1 -0
  38. package/dist/chunk-SMJGE7HM.cjs +1908 -0
  39. package/dist/chunk-SMJGE7HM.cjs.map +1 -0
  40. package/dist/{chunk-MMVHBKMM.js → chunk-T2P5TIZ6.js} +2 -2
  41. package/dist/{chunk-FGW5OWJ4.js → chunk-VJUML33I.js} +4 -156
  42. package/dist/chunk-VJUML33I.js.map +1 -0
  43. package/dist/{chunk-5OVJHMZQ.cjs → chunk-ZYZGEILO.cjs} +332 -293
  44. package/dist/chunk-ZYZGEILO.cjs.map +1 -0
  45. package/dist/export/index.cjs +4 -2
  46. package/dist/export/index.cjs.map +1 -1
  47. package/dist/export/index.js +5 -3
  48. package/dist/{export-b6NjCZ5-.d.cts → export-BXxSGBCq.d.cts} +67 -5
  49. package/dist/{export-_1dUKwpF.d.ts → export-Dm44YUvS.d.ts} +67 -5
  50. package/dist/export-Dv0-ZVrV.d.cts +501 -0
  51. package/dist/export-Dv0-ZVrV.d.ts +501 -0
  52. package/dist/{retouch-Do6tBs2H.d.ts → flow-BMtHAmg4.d.ts} +561 -2
  53. package/dist/{retouch-Bxkuc0KH.d.cts → flow-COCB42TP.d.cts} +561 -2
  54. package/dist/image-editor/index.cjs +1227 -934
  55. package/dist/image-editor/index.cjs.map +1 -1
  56. package/dist/image-editor/index.d.cts +18 -10
  57. package/dist/image-editor/index.d.ts +18 -10
  58. package/dist/image-editor/index.js +324 -31
  59. package/dist/image-editor/index.js.map +1 -1
  60. package/dist/index.cjs +4 -2
  61. package/dist/index.cjs.map +1 -1
  62. package/dist/index.js +5 -3
  63. package/dist/index.js.map +1 -1
  64. package/dist/kernel-wasm-WYCGNZR4.js +10 -0
  65. package/dist/kernel-wasm-WYCGNZR4.js.map +1 -0
  66. package/dist/kernel-wasm-YPVAEMVN.cjs +10 -0
  67. package/dist/kernel-wasm-YPVAEMVN.cjs.map +1 -0
  68. package/dist/paint/index.cjs +165 -3
  69. package/dist/paint/index.cjs.map +1 -1
  70. package/dist/paint/index.d.cts +225 -3
  71. package/dist/paint/index.d.ts +225 -3
  72. package/dist/paint/index.js +166 -4
  73. package/dist/paint-editor/index.cjs +4691 -845
  74. package/dist/paint-editor/index.cjs.map +1 -1
  75. package/dist/paint-editor/index.d.cts +1525 -277
  76. package/dist/paint-editor/index.d.ts +1525 -277
  77. package/dist/paint-editor/index.js +4561 -715
  78. package/dist/paint-editor/index.js.map +1 -1
  79. package/dist/raster/index.cjs +4 -3
  80. package/dist/raster/index.cjs.map +1 -1
  81. package/dist/raster/index.js +10 -9
  82. package/dist/{svg-BnRj0q8i.d.cts → svg-CVdFc80-.d.cts} +2 -2
  83. package/dist/{svg-CmmBFfGT.d.ts → svg-DlEuhwoX.d.ts} +2 -2
  84. package/dist/{types-1SUQKDAw.d.ts → types-CDLGhAZp.d.ts} +40 -2
  85. package/dist/{types-yINF17Ta.d.cts → types-Tfly4Aya.d.cts} +40 -2
  86. package/dist/vector/index.cjs +1897 -975
  87. package/dist/vector/index.cjs.map +1 -1
  88. package/dist/vector/index.d.cts +292 -32
  89. package/dist/vector/index.d.ts +292 -32
  90. package/dist/vector/index.js +928 -6
  91. package/dist/vector/index.js.map +1 -1
  92. package/dist/video-editor/index.cjs +502 -2165
  93. package/dist/video-editor/index.cjs.map +1 -1
  94. package/dist/video-editor/index.d.cts +3 -501
  95. package/dist/video-editor/index.d.ts +3 -501
  96. package/dist/video-editor/index.js +151 -1814
  97. package/dist/video-editor/index.js.map +1 -1
  98. package/package.json +4 -2
  99. package/skills/pixerate-image-editor/SKILL.md +1 -0
  100. package/skills/pixerate-image-editor/references/color-management.md +8 -3
  101. package/skills/pixerate-image-editor/references/photoshop-files.md +15 -9
  102. package/skills/pixerate-paint-editor/SKILL.md +136 -4
  103. package/skills/pixerate-vector/SKILL.md +22 -1
  104. package/dist/chunk-5OVJHMZQ.cjs.map +0 -1
  105. package/dist/chunk-C6C5PDKU.js.map +0 -1
  106. package/dist/chunk-DFQEX3AM.cjs.map +0 -1
  107. package/dist/chunk-EUVSQ25B.js.map +0 -1
  108. package/dist/chunk-FGW5OWJ4.js.map +0 -1
  109. package/dist/chunk-FV5AXTSF.cjs.map +0 -1
  110. package/dist/chunk-GX332W2C.js +0 -181
  111. package/dist/chunk-GX332W2C.js.map +0 -1
  112. package/dist/chunk-LKCYANMW.js.map +0 -1
  113. package/dist/chunk-LPLCWZTM.cjs.map +0 -1
  114. package/dist/chunk-MUUXNRU4.cjs +0 -181
  115. package/dist/chunk-MUUXNRU4.cjs.map +0 -1
  116. package/dist/chunk-ST7E3NEE.cjs.map +0 -1
  117. package/dist/chunk-TCKIXI46.cjs +0 -1136
  118. package/dist/chunk-TCKIXI46.cjs.map +0 -1
  119. package/dist/chunk-UBIXVXPR.js +0 -1136
  120. package/dist/chunk-UBIXVXPR.js.map +0 -1
  121. package/dist/chunk-VXR7XWMF.js.map +0 -1
  122. /package/dist/{chunk-MMVHBKMM.js.map → chunk-T2P5TIZ6.js.map} +0 -0
@@ -159,8 +159,8 @@ var fmtMatrix = (m) => `matrix(${m.map((n) => fmt(n, 6)).join(" ")})`;
159
159
  function isVectorGradient(paint) {
160
160
  return !!paint && typeof paint === "object" && VECTOR_GRADIENT_TYPES.includes(paint.type) && Array.isArray(paint.stops);
161
161
  }
162
- function parseVectorColor(color) {
163
- const hex = _chunkA6PHCAGXcjs.normalizeTokenColor.call(void 0, color);
162
+ function parseVectorColor(color2) {
163
+ const hex = _chunkA6PHCAGXcjs.normalizeTokenColor.call(void 0, color2);
164
164
  if (hex === null) return null;
165
165
  const c = _chunkA6PHCAGXcjs.hexToRgba.call(void 0, hex);
166
166
  return [c.r, c.g, c.b, c.a];
@@ -262,15 +262,15 @@ function sampleVectorGradient(g, t) {
262
262
  return s ? { color: s.color, opacity: _nullishCoalesce(s.opacity, () => ( 1)) } : { color: "#000000", opacity: 0 };
263
263
  }
264
264
  var stopOf = (offset, c) => {
265
- const color = _chunkA6PHCAGXcjs.rgbaToHex.call(void 0, c[0], c[1], c[2]);
265
+ const color2 = _chunkA6PHCAGXcjs.rgbaToHex.call(void 0, c[0], c[1], c[2]);
266
266
  const opacity = Math.round(c[3] * 1e4) / 1e4;
267
- return opacity < 1 ? { offset, color, opacity } : { offset, color };
267
+ return opacity < 1 ? { offset, color: color2, opacity } : { offset, color: color2 };
268
268
  };
269
269
  var maxDiff = (a, b) => Math.max(Math.abs(a[0] - b[0]), Math.abs(a[1] - b[1]), Math.abs(a[2] - b[2]), Math.abs(a[3] - b[3]));
270
270
  var lerpRgba = (a, b, u) => [0, 1, 2, 3].map((c) => a[c] + (b[c] - a[c]) * u);
271
271
  function expandVectorGradientStops(g, options = {}) {
272
272
  const stops = sortedVectorGradientStops(g);
273
- const plain2 = () => stops.map(({ offset, color, opacity }) => opacity !== void 0 && opacity !== 1 ? { offset, color, opacity } : { offset, color });
273
+ const plain2 = () => stops.map(({ offset, color: color2, opacity }) => opacity !== void 0 && opacity !== 1 ? { offset, color: color2, opacity } : { offset, color: color2 });
274
274
  if (!vectorGradientNeedsExpansion(g)) return plain2();
275
275
  const ramp = vectorGradientRamp(g);
276
276
  if (!ramp || stops.length < 2) return plain2();
@@ -342,9 +342,9 @@ function placeStop(stops, stop) {
342
342
  }
343
343
  function insertVectorGradientStop(g, offset) {
344
344
  const at2 = clamp(offset, 0, 1);
345
- const { color, opacity } = sampleVectorGradient(g, at2);
345
+ const { color: color2, opacity } = sampleVectorGradient(g, at2);
346
346
  const stops = sortedVectorGradientStops(g);
347
- const index = placeStop(stops, opacity < 1 ? { offset: at2, color, opacity } : { offset: at2, color });
347
+ const index = placeStop(stops, opacity < 1 ? { offset: at2, color: color2, opacity } : { offset: at2, color: color2 });
348
348
  return { stops, index };
349
349
  }
350
350
  function moveVectorGradientStop(stops, index, offset) {
@@ -527,9 +527,11 @@ function mapVectorGradient(g, f) {
527
527
  return { ...g, start: f(p.start), end: f(p.end), width: f(p.width), ...p.focal ? { focal: f(p.focal) } : {} };
528
528
  }
529
529
  function mapVectorPaint(paint, f) {
530
+ if (isVectorShadedPaint(paint)) return mapVectorShadedPaint(paint, f);
530
531
  return isVectorGradient(paint) ? mapVectorGradient(paint, f) : paint;
531
532
  }
532
533
  function transformVectorPaint(paint, m) {
534
+ if (isVectorShadedPaint(paint)) return transformVectorShadedPaint(paint, m);
533
535
  return isVectorGradient(paint) ? transformVectorGradient(paint, m) : paint;
534
536
  }
535
537
  var isCentredVectorGradient = (type) => type === "radial" || type === "conic" || type === "diamond";
@@ -936,6 +938,365 @@ function applyVectorGradientPatch(g, patch) {
936
938
  return clean2;
937
939
  }
938
940
 
941
+ // src/vector/shading.ts
942
+ function isVectorMeshGradient(paint) {
943
+ return !!paint && typeof paint === "object" && paint.type === "mesh" && Array.isArray(paint.points);
944
+ }
945
+ function isVectorFreeformGradient(paint) {
946
+ return !!paint && typeof paint === "object" && paint.type === "freeform" && Array.isArray(paint.points);
947
+ }
948
+ function isVectorShadedPaint(paint) {
949
+ return isVectorMeshGradient(paint) || isVectorFreeformGradient(paint);
950
+ }
951
+ var lerp = (a, b, t) => a + (b - a) * t;
952
+ var rgbaOf = (color2, opacity = 1) => {
953
+ const c = _nullishCoalesce(parseVectorColor(color2), () => ( [0, 0, 0, 1]));
954
+ return [c[0], c[1], c[2], c[3] * opacity];
955
+ };
956
+ var hex2 = (v2) => Math.round(Math.min(1, Math.max(0, v2)) * 255).toString(16).padStart(2, "0");
957
+ function vectorRgbaToCss([r, g, b, a]) {
958
+ if (a >= 0.9995) return `#${hex2(r)}${hex2(g)}${hex2(b)}`;
959
+ const c = (v2) => Math.round(Math.min(1, Math.max(0, v2)) * 255);
960
+ return `rgba(${c(r)},${c(g)},${c(b)},${Math.round(Math.max(0, a) * 1e3) / 1e3})`;
961
+ }
962
+ var VECTOR_MESH_MAX = 32;
963
+ function createVectorMeshGradient(bounds, rows, columns, colors = {}) {
964
+ const r = Math.min(VECTOR_MESH_MAX, Math.max(1, Math.round(rows)));
965
+ const c = Math.min(VECTOR_MESH_MAX, Math.max(1, Math.round(columns)));
966
+ const points = [];
967
+ const out = [];
968
+ const corners = _optionalChain([colors, 'access', _12 => _12.corners, 'optionalAccess', _13 => _13.map, 'call', _14 => _14((k) => rgbaOf(k))]);
969
+ for (let i = 0; i <= r; i++) {
970
+ for (let j = 0; j <= c; j++) {
971
+ points.push({ x: bounds.x + bounds.width * j / c, y: bounds.y + bounds.height * i / r });
972
+ const k = i * (c + 1) + j;
973
+ if (_optionalChain([colors, 'access', _15 => _15.colors, 'optionalAccess', _16 => _16[k]])) out.push(colors.colors[k]);
974
+ else if (corners) {
975
+ const u = j / c;
976
+ const v2 = i / r;
977
+ const top = corners[0].map((x, n) => lerp(x, corners[1][n], u));
978
+ const bottom = corners[3].map((x, n) => lerp(x, corners[2][n], u));
979
+ out.push(vectorRgbaToCss(top.map((x, n) => lerp(x, bottom[n], v2))));
980
+ } else out.push("#ffffff");
981
+ }
982
+ }
983
+ return { type: "mesh", rows: r, columns: c, points, colors: out };
984
+ }
985
+ function catmull(p0, p1, p2, p3) {
986
+ return [p1, { x: p1.x + (p2.x - p0.x) / 6, y: p1.y + (p2.y - p0.y) / 6 }, { x: p2.x - (p3.x - p1.x) / 6, y: p2.y - (p3.y - p1.y) / 6 }, p2];
987
+ }
988
+ function cubicAt(c, t) {
989
+ const s = 1 - t;
990
+ const a = s * s * s;
991
+ const b = 3 * s * s * t;
992
+ const d = 3 * s * t * t;
993
+ const e = t * t * t;
994
+ return { x: a * c[0].x + b * c[1].x + d * c[2].x + e * c[3].x, y: a * c[0].y + b * c[1].y + d * c[2].y + e * c[3].y };
995
+ }
996
+ function meshOk(m) {
997
+ const n = (m.rows + 1) * (m.columns + 1);
998
+ return m.rows >= 1 && m.columns >= 1 && m.points.length === n && m.colors.length === n;
999
+ }
1000
+ function meshLattice(m) {
1001
+ const cols = m.columns + 1;
1002
+ const at2 = (r, c) => m.points[r * cols + c];
1003
+ const ext = (a, b) => ({ x: 2 * a.x - b.x, y: 2 * a.y - b.y });
1004
+ const P = (r, c) => {
1005
+ if (r < 0) return ext(P(0, c), P(1, c));
1006
+ if (r > m.rows) return ext(P(m.rows, c), P(m.rows - 1, c));
1007
+ if (c < 0) return ext(at2(r, 0), at2(r, 1));
1008
+ if (c > m.columns) return ext(at2(r, m.columns), at2(r, m.columns - 1));
1009
+ return at2(r, c);
1010
+ };
1011
+ return P;
1012
+ }
1013
+ function vectorMeshPointAt(m, i, j, u, v2) {
1014
+ const P = meshLattice(m);
1015
+ const top = catmull(P(i, j - 1), P(i, j), P(i, j + 1), P(i, j + 2));
1016
+ const bottom = catmull(P(i + 1, j - 1), P(i + 1, j), P(i + 1, j + 1), P(i + 1, j + 2));
1017
+ const left2 = catmull(P(i - 1, j), P(i, j), P(i + 1, j), P(i + 2, j));
1018
+ const right = catmull(P(i - 1, j + 1), P(i, j + 1), P(i + 1, j + 1), P(i + 2, j + 1));
1019
+ const t = cubicAt(top, u);
1020
+ const b = cubicAt(bottom, u);
1021
+ const l = cubicAt(left2, v2);
1022
+ const r = cubicAt(right, v2);
1023
+ const [p00, p01, p11, p10] = [P(i, j), P(i, j + 1), P(i + 1, j + 1), P(i + 1, j)];
1024
+ const bl = (k) => (1 - u) * (1 - v2) * p00[k] + u * (1 - v2) * p01[k] + u * v2 * p11[k] + (1 - u) * v2 * p10[k];
1025
+ return { x: (1 - v2) * t.x + v2 * b.x + (1 - u) * l.x + u * r.x - bl("x"), y: (1 - v2) * t.y + v2 * b.y + (1 - u) * l.y + u * r.y - bl("y") };
1026
+ }
1027
+ function vectorMeshColorAt(m, i, j, u, v2) {
1028
+ const cols = m.columns + 1;
1029
+ const C = (r, c2) => rgbaOf(m.colors[r * cols + c2], _nullishCoalesce(_optionalChain([m, 'access', _17 => _17.opacities, 'optionalAccess', _18 => _18[r * cols + c2]]), () => ( 1)));
1030
+ const a = C(i, j);
1031
+ const b = C(i, j + 1);
1032
+ const c = C(i + 1, j + 1);
1033
+ const d = C(i + 1, j);
1034
+ return [0, 1, 2, 3].map((k) => (1 - u) * (1 - v2) * a[k] + u * (1 - v2) * b[k] + u * v2 * c[k] + (1 - u) * v2 * d[k]);
1035
+ }
1036
+ function vectorMeshLines(m) {
1037
+ const P = meshLattice(m);
1038
+ const rows = [];
1039
+ for (let i = 0; i <= m.rows; i++) rows.push(Array.from({ length: m.columns }, (_, j) => catmull(P(i, j - 1), P(i, j), P(i, j + 1), P(i, j + 2))));
1040
+ const columns = [];
1041
+ for (let j = 0; j <= m.columns; j++) columns.push(Array.from({ length: m.rows }, (_, i) => catmull(P(i - 1, j), P(i, j), P(i + 1, j), P(i + 2, j))));
1042
+ return { rows, columns };
1043
+ }
1044
+ var LINE_STEPS = 16;
1045
+ var lerpSource = (a, b, t) => ({ x: lerp(a.x, b.x, t), y: lerp(a.y, b.y, t), c: a.c.map((v2, k) => lerp(v2, b.c[k], t)), radius: lerp(a.radius, b.radius, t) });
1046
+ function vectorFreeformSpreadScale(bounds) {
1047
+ return Math.max(Math.abs(bounds.width), Math.abs(bounds.height)) / 2;
1048
+ }
1049
+ function vectorFreeformLineSegments(f, line) {
1050
+ const ix = _optionalChain([f, 'access', _19 => _19.lines, 'optionalAccess', _20 => _20[line]]);
1051
+ if (!ix) return [];
1052
+ const pts = ix.map((i) => f.points[i]);
1053
+ if (pts.some((p) => !p)) return [];
1054
+ const n = pts.length;
1055
+ const out = [];
1056
+ for (let i = 0; i + 1 < n; i++) out.push(catmull(pts[Math.max(0, i - 1)], pts[i], pts[i + 1], pts[Math.min(n - 1, i + 2)]));
1057
+ return out;
1058
+ }
1059
+ function vectorFreeformField(f, scale3) {
1060
+ const src = (p) => ({ x: p.x, y: p.y, c: rgbaOf(p.color, _nullishCoalesce(p.opacity, () => ( 1))), radius: Math.min(1, Math.max(0, _nullishCoalesce(p.spread, () => ( 0)))) * scale3 });
1061
+ const points = f.points.map(src);
1062
+ const pieces = [];
1063
+ (_nullishCoalesce(f.lines, () => ( []))).forEach((ix, l) => {
1064
+ const v2 = [];
1065
+ vectorFreeformLineSegments(f, l).forEach((c, s) => {
1066
+ const a = points[ix[s]];
1067
+ const b = points[ix[s + 1]];
1068
+ for (let k = s === 0 ? 0 : 1; k <= LINE_STEPS; k++) {
1069
+ const t = k / LINE_STEPS;
1070
+ const at2 = cubicAt(c, t);
1071
+ v2.push({ ...lerpSource(a, b, t), x: at2.x, y: at2.y });
1072
+ }
1073
+ });
1074
+ let len2 = 0;
1075
+ for (let k = 1; k < v2.length; k++) len2 += Math.hypot(v2[k].x - v2[k - 1].x, v2[k].y - v2[k - 1].y);
1076
+ const n = Math.max(1, v2.length - 1);
1077
+ for (let k = 1; k < v2.length; k++) {
1078
+ const d = Math.hypot(v2[k].x - v2[k - 1].x, v2[k].y - v2[k - 1].y);
1079
+ pieces.push({ a: v2[k - 1], b: v2[k], share: len2 > 0 ? d / len2 : 1 / n });
1080
+ }
1081
+ });
1082
+ return { points, pieces, eps: 1e-9 * (Math.abs(scale3) + 1) };
1083
+ }
1084
+ function sampleVectorFreeform(field, p) {
1085
+ const disc = { w: 0, c: [0, 0, 0, 0] };
1086
+ const far = { w: 0, c: [0, 0, 0, 0] };
1087
+ const add5 = (d, s, share) => {
1088
+ let acc2;
1089
+ let w;
1090
+ if (d < s.radius || d <= field.eps) {
1091
+ acc2 = disc;
1092
+ w = (s.radius - d + field.eps) * share;
1093
+ } else {
1094
+ const e = d - s.radius;
1095
+ acc2 = far;
1096
+ w = share / (e * e);
1097
+ }
1098
+ acc2.w += w;
1099
+ for (let k = 0; k < 4; k++) acc2.c[k] += w * s.c[k];
1100
+ };
1101
+ for (const s of field.points) add5(Math.hypot(s.x - p.x, s.y - p.y), s, 1);
1102
+ for (const piece of field.pieces) {
1103
+ const vx = piece.b.x - piece.a.x;
1104
+ const vy = piece.b.y - piece.a.y;
1105
+ const l2 = vx * vx + vy * vy;
1106
+ const t = l2 > 0 ? Math.min(1, Math.max(0, ((p.x - piece.a.x) * vx + (p.y - piece.a.y) * vy) / l2)) : 0;
1107
+ const s = lerpSource(piece.a, piece.b, t);
1108
+ add5(Math.hypot(s.x - p.x, s.y - p.y), s, piece.share);
1109
+ }
1110
+ const acc = disc.w > 0 ? disc : far;
1111
+ if (!(acc.w > 0 && Number.isFinite(acc.w))) return [0, 0, 0, 0];
1112
+ return acc.c.map((v2) => v2 / acc.w);
1113
+ }
1114
+ function autoVectorFreeformGradient(b, colors, inside = () => true) {
1115
+ const w = Math.max(b.width, 1e-9);
1116
+ const h = Math.max(b.height, 1e-9);
1117
+ const long = Math.min(4, Math.max(2, Math.round(2 * Math.max(w, h) / Math.min(w, h))));
1118
+ const [cols, rows] = w >= h ? [long, 2] : [2, long];
1119
+ const cell = (i, n2) => (i + 0.5) / n2;
1120
+ const targets = [];
1121
+ for (let j = 0; j < rows; j++) for (let k = 0; k < cols; k++) targets.push({ x: b.x + cell(j % 2 === 0 ? k : cols - 1 - k, cols) * w, y: b.y + cell(j, rows) * h });
1122
+ const GRID = 24;
1123
+ const candidates = [];
1124
+ for (let k = 0; k < GRID * GRID; k++) {
1125
+ const p = { x: b.x + cell(k % GRID, GRID) * w, y: b.y + cell(Math.floor(k / GRID), GRID) * h };
1126
+ if (inside(p)) candidates.push(p);
1127
+ }
1128
+ const apart = Math.min(w, h) * 0.15;
1129
+ const placed = [];
1130
+ for (const t of targets) {
1131
+ let at2 = t;
1132
+ if (!inside(t)) {
1133
+ let best = null;
1134
+ let bestD = Infinity;
1135
+ for (const c of candidates) {
1136
+ if (!placed.every((q) => Math.hypot(q.x - c.x, q.y - c.y) >= apart)) continue;
1137
+ const d = Math.hypot(c.x - t.x, c.y - t.y);
1138
+ if (d < bestD) {
1139
+ best = c;
1140
+ bestD = d;
1141
+ }
1142
+ }
1143
+ at2 = _nullishCoalesce(best, () => ( t));
1144
+ }
1145
+ placed.push(at2);
1146
+ }
1147
+ const palette = colors.length ? colors : ["#ffffff", "#000000"];
1148
+ const n = placed.length;
1149
+ const colorAt = (k) => {
1150
+ if (palette.length === 1) return palette[0];
1151
+ const t = k / Math.max(1, n - 1) * (palette.length - 1);
1152
+ const i = Math.min(palette.length - 2, Math.floor(t));
1153
+ const a = rgbaOf(palette[i]);
1154
+ const c = rgbaOf(palette[i + 1]);
1155
+ return vectorRgbaToCss(a.map((v2, q) => lerp(v2, c[q], t - i)));
1156
+ };
1157
+ return { type: "freeform", points: placed.map((p, k) => ({ x: p.x, y: p.y, color: colorAt(k) })) };
1158
+ }
1159
+ var fmt2 = (n, digits) => {
1160
+ const k = 10 ** digits;
1161
+ const v2 = Math.round(n * k) / k;
1162
+ return Object.is(v2, -0) ? "0" : String(v2);
1163
+ };
1164
+ var quadD = (pts, precision) => `M${pts.map((p) => `${fmt2(p.x, precision)} ${fmt2(p.y, precision)}`).join("L")}Z`;
1165
+ function vectorShadedSvgDefs(paint, id, options = {}) {
1166
+ const precision = _nullishCoalesce(options.precision, () => ( 3));
1167
+ const bounds = _nullishCoalesce(options.bounds, () => ( null));
1168
+ const area = _nullishCoalesce(options.area, () => ( (bounds ? { x: bounds.x - 1, y: bounds.y - 1, width: bounds.width + 2, height: bounds.height + 2 } : { x: 0, y: 0, width: 1, height: 1 })));
1169
+ const tiles = [];
1170
+ const gradients = [];
1171
+ if (isVectorMeshGradient(paint)) {
1172
+ if (meshOk(paint)) {
1173
+ const k = Math.max(1, Math.min(32, Math.round(_nullishCoalesce(options.meshCells, () => ( 8)))));
1174
+ for (let i = 0; i < paint.rows; i++) {
1175
+ for (let j = 0; j < paint.columns; j++) {
1176
+ const grid = [];
1177
+ for (let a = 0; a <= k; a++) {
1178
+ const row = [];
1179
+ for (let b = 0; b <= k; b++) row.push(vectorMeshPointAt(paint, i, j, b / k, a / k));
1180
+ grid.push(row);
1181
+ }
1182
+ for (let a = 0; a < k; a++) {
1183
+ for (let b = 0; b < k; b++) {
1184
+ const c = vectorMeshColorAt(paint, i, j, (b + 0.5) / k, (a + 0.5) / k);
1185
+ if (c[3] <= 5e-4) continue;
1186
+ const q = [grid[a][b], grid[a][b + 1], grid[a + 1][b + 1], grid[a + 1][b]];
1187
+ const cx = (q[0].x + q[1].x + q[2].x + q[3].x) / 4;
1188
+ const cy = (q[0].y + q[1].y + q[2].y + q[3].y) / 4;
1189
+ const grow = (p) => ({ x: cx + (p.x - cx) * 1.12, y: cy + (p.y - cy) * 1.12 });
1190
+ tiles.push({ d: quadD(q.map(grow), precision), fill: vectorRgbaToCss(c) });
1191
+ }
1192
+ }
1193
+ }
1194
+ }
1195
+ }
1196
+ } else if (bounds && paint.points.length) {
1197
+ const field = vectorFreeformField(paint, vectorFreeformSpreadScale(bounds));
1198
+ const n = Math.max(2, Math.min(256, Math.round(_nullishCoalesce(options.freeformCells, () => ( 96)))));
1199
+ const side = Math.max(area.width, area.height, 1e-9);
1200
+ const rows = Math.max(2, Math.ceil(n * area.height / side));
1201
+ const samples = Math.max(2, Math.min(96, Math.ceil(n * area.width / side) + 1));
1202
+ const ch = area.height / rows;
1203
+ for (let r = 0; r < rows; r++) {
1204
+ const y = area.y + r * ch;
1205
+ const stops = [];
1206
+ for (let k = 0; k < samples; k++) {
1207
+ const t = k / (samples - 1);
1208
+ const c = sampleVectorFreeform(field, { x: area.x + t * area.width, y: y + ch / 2 });
1209
+ const opaque = vectorRgbaToCss([c[0], c[1], c[2], 1]);
1210
+ stops.push({ offset: `${fmt2(t * 100, 3)}%`, stopColor: opaque, ...c[3] < 0.9995 ? { stopOpacity: Math.round(Math.max(0, c[3]) * 1e3) / 1e3 } : {} });
1211
+ }
1212
+ const gid = `${id}-r${r}`;
1213
+ gradients.push({ id: gid, type: "linear", attrs: { gradientUnits: "userSpaceOnUse", x1: fmt2(area.x, precision), y1: "0", x2: fmt2(area.x + area.width, precision), y2: "0" }, stops });
1214
+ const h = r < rows - 1 ? ch * 1.25 : ch;
1215
+ tiles.push({ d: quadD([{ x: area.x, y }, { x: area.x + area.width, y }, { x: area.x + area.width, y: y + h }, { x: area.x, y: y + h }], precision), fill: `url(#${gid})` });
1216
+ }
1217
+ }
1218
+ return [{ id, type: "pattern", attrs: patternAttrs(area), gradients, tiles }];
1219
+ }
1220
+ var apply2 = (m, p) => ({ x: m[0] * p.x + m[2] * p.y + m[4], y: m[1] * p.x + m[3] * p.y + m[5] });
1221
+ function mapVectorShadedPaint(paint, f) {
1222
+ if (isVectorMeshGradient(paint)) return { ...paint, points: paint.points.map((p) => f(p)) };
1223
+ return { ...paint, points: paint.points.map((p) => ({ ...p, ...f(p) })) };
1224
+ }
1225
+ function transformVectorShadedPaint(paint, m) {
1226
+ return mapVectorShadedPaint(paint, (p) => apply2(m, p));
1227
+ }
1228
+ var finite = (v2) => typeof v2 === "number" && Number.isFinite(v2);
1229
+ var color = (v2) => typeof v2 === "string" && parseVectorColor(v2) ? v2 : null;
1230
+ function sanitizeVectorShadedPaint(input) {
1231
+ if (!input || typeof input !== "object") return null;
1232
+ const r = input;
1233
+ if (r.type === "mesh") {
1234
+ const rows = r.rows;
1235
+ const columns = r.columns;
1236
+ if (!finite(rows) || !finite(columns) || rows < 1 || columns < 1 || rows > VECTOR_MESH_MAX || columns > VECTOR_MESH_MAX || !Number.isInteger(rows) || !Number.isInteger(columns)) return null;
1237
+ const n = (rows + 1) * (columns + 1);
1238
+ if (!Array.isArray(r.points) || !Array.isArray(r.colors) || r.points.length !== n || r.colors.length !== n) return null;
1239
+ const points = [];
1240
+ for (const p of r.points) {
1241
+ const q = p;
1242
+ if (!q || !finite(q.x) || !finite(q.y)) return null;
1243
+ points.push({ x: q.x, y: q.y });
1244
+ }
1245
+ const colors = [];
1246
+ for (const c of r.colors) {
1247
+ const k = color(c);
1248
+ if (!k) return null;
1249
+ colors.push(k);
1250
+ }
1251
+ const out = { type: "mesh", rows, columns, points, colors };
1252
+ if (Array.isArray(r.opacities) && r.opacities.length === n && r.opacities.every(finite)) out.opacities = r.opacities.map((o) => Math.min(1, Math.max(0, o)));
1253
+ return out;
1254
+ }
1255
+ if (r.type === "freeform") {
1256
+ if (!Array.isArray(r.points) || !r.points.length) return null;
1257
+ const points = [];
1258
+ for (const p of r.points) {
1259
+ const q = p;
1260
+ const c = q ? color(q.color) : null;
1261
+ if (!q || !finite(q.x) || !finite(q.y) || !c) return null;
1262
+ points.push({
1263
+ x: q.x,
1264
+ y: q.y,
1265
+ color: c,
1266
+ ...finite(q.opacity) && q.opacity < 1 ? { opacity: Math.max(0, q.opacity) } : {},
1267
+ ...finite(q.spread) && q.spread > 0 ? { spread: Math.min(1, q.spread) } : {}
1268
+ });
1269
+ }
1270
+ const out = { type: "freeform", points };
1271
+ if (Array.isArray(r.lines)) {
1272
+ const lines = r.lines.filter((l) => Array.isArray(l) && l.length >= 2 && l.every((i) => Number.isInteger(i) && i >= 0 && i < points.length) && l.every((i, k) => k === 0 || i !== l[k - 1]));
1273
+ if (lines.length) out.lines = lines.map((l) => [...l]);
1274
+ }
1275
+ return out;
1276
+ }
1277
+ return null;
1278
+ }
1279
+ function removeVectorFreeformPoint(f, index) {
1280
+ if (index < 0 || index >= f.points.length || f.points.length <= 1) return null;
1281
+ const points = f.points.filter((_, k) => k !== index);
1282
+ const lines = (_nullishCoalesce(f.lines, () => ( []))).map(
1283
+ (l) => l.filter((i) => i !== index).map((i) => i > index ? i - 1 : i).filter((i, k, arr) => k === 0 || i !== arr[k - 1])
1284
+ ).filter((l) => l.length >= 2);
1285
+ return { type: "freeform", points, ...lines.length ? { lines } : {} };
1286
+ }
1287
+ function nearestVectorShadingPoint(paint, p, radius) {
1288
+ let best = -1;
1289
+ let bestD = radius;
1290
+ paint.points.forEach((q, k) => {
1291
+ const d = Math.hypot(q.x - p.x, q.y - p.y);
1292
+ if (d <= bestD) {
1293
+ best = k;
1294
+ bestD = d;
1295
+ }
1296
+ });
1297
+ return best;
1298
+ }
1299
+
939
1300
  // src/geom/affine.ts
940
1301
  var IDENTITY_MATRIX = [1, 0, 0, 1, 0, 0];
941
1302
  function multiplyMatrices(a, b) {
@@ -1156,7 +1517,7 @@ function cutCorner(c, radius, kind, smoothing = 0) {
1156
1517
  return { tu: a.t, tv: b.t, start: a.p, out: add2(a.p, mul2(d1, k)), in: add2(b.p, mul2(d2, k)), end: b.p };
1157
1518
  }
1158
1519
  var radiusOf = (a) => {
1159
- const r = _optionalChain([a, 'access', _12 => _12.corner, 'optionalAccess', _13 => _13.radius]);
1520
+ const r = _optionalChain([a, 'access', _21 => _21.corner, 'optionalAccess', _22 => _22.radius]);
1160
1521
  return typeof r === "number" && r > 0 && Number.isFinite(r) ? r : 0;
1161
1522
  };
1162
1523
  function hasVectorCorners(subpaths) {
@@ -1170,7 +1531,7 @@ function expandVectorCornersOf(sp, subpath = 0) {
1170
1531
  const c = cornerOf(sp, subpath, i);
1171
1532
  if (!c) return null;
1172
1533
  const fitted = fitCornerRadius(c, r);
1173
- return fitted > EPS ? cutCorner(c, fitted, _nullishCoalesce(_optionalChain([a, 'access', _14 => _14.corner, 'optionalAccess', _15 => _15.kind]), () => ( "round")), _nullishCoalesce(_optionalChain([a, 'access', _16 => _16.corner, 'optionalAccess', _17 => _17.smoothing]), () => ( 0))) : null;
1534
+ return fitted > EPS ? cutCorner(c, fitted, _nullishCoalesce(_optionalChain([a, 'access', _23 => _23.corner, 'optionalAccess', _24 => _24.kind]), () => ( "round")), _nullishCoalesce(_optionalChain([a, 'access', _25 => _25.corner, 'optionalAccess', _26 => _26.smoothing]), () => ( 0))) : null;
1174
1535
  });
1175
1536
  if (!cuts.some(Boolean)) return { subpath: { closed: sp.closed, anchors: sp.anchors.map(plain) }, sources: sp.anchors.map((_, i) => i) };
1176
1537
  const trimmed = sp.anchors.map((a, j) => {
@@ -1242,8 +1603,8 @@ function expandVectorCorners(subpaths) {
1242
1603
  function setAnchorCorner(a, radius, kind, smoothing) {
1243
1604
  const { corner, ...rest } = a;
1244
1605
  const r = Number.isFinite(radius) ? Math.max(0, radius) : 0;
1245
- const k = _nullishCoalesce(kind, () => ( _optionalChain([corner, 'optionalAccess', _18 => _18.kind])));
1246
- const s = Math.max(0, Math.min(1, _nullishCoalesce(_nullishCoalesce(smoothing, () => ( _optionalChain([corner, 'optionalAccess', _19 => _19.smoothing]))), () => ( 0))));
1606
+ const k = _nullishCoalesce(kind, () => ( _optionalChain([corner, 'optionalAccess', _27 => _27.kind])));
1607
+ const s = Math.max(0, Math.min(1, _nullishCoalesce(_nullishCoalesce(smoothing, () => ( _optionalChain([corner, 'optionalAccess', _28 => _28.smoothing]))), () => ( 0))));
1247
1608
  if (r <= 0 && !kind) return rest;
1248
1609
  return { ...rest, corner: { radius: r, ...k && k !== "round" ? { kind: k } : {}, ...s > 0 ? { smoothing: s } : {} } };
1249
1610
  }
@@ -1292,7 +1653,7 @@ function sanitizeWidthProfile(points) {
1292
1653
  return out.map((p, i) => [p, i]).sort((a, b) => a[0].t - b[0].t || a[1] - b[1]).map(([p]) => p);
1293
1654
  }
1294
1655
  function isUniformWidthProfile(points) {
1295
- return !_optionalChain([points, 'optionalAccess', _20 => _20.length]) || points.every((p) => p.left === 1 && p.right === 1);
1656
+ return !_optionalChain([points, 'optionalAccess', _29 => _29.length]) || points.every((p) => p.left === 1 && p.right === 1);
1296
1657
  }
1297
1658
  function secant(pts, i, k) {
1298
1659
  const a = pts[i];
@@ -1325,11 +1686,11 @@ function interp(pts, t, k) {
1325
1686
  return Math.max(0, w);
1326
1687
  }
1327
1688
  function widthProfileAt(points, t) {
1328
- if (!_optionalChain([points, 'optionalAccess', _21 => _21.length])) return { left: 1, right: 1 };
1689
+ if (!_optionalChain([points, 'optionalAccess', _30 => _30.length])) return { left: 1, right: 1 };
1329
1690
  return { left: interp(points, t, "left"), right: interp(points, t, "right") };
1330
1691
  }
1331
1692
  function widthProfileMaxScale(points) {
1332
- if (!_optionalChain([points, 'optionalAccess', _22 => _22.length])) return 1;
1693
+ if (!_optionalChain([points, 'optionalAccess', _31 => _31.length])) return 1;
1333
1694
  return points.reduce((m, p) => Math.max(m, p.left, p.right), 0);
1334
1695
  }
1335
1696
  function widthProfilePreset(id) {
@@ -1339,7 +1700,7 @@ function widthProfilePreset(id) {
1339
1700
  function widthProfilePresetId(points) {
1340
1701
  if (isUniformWidthProfile(points)) return "uniform";
1341
1702
  const same2 = (a, b) => a.length === b.length && a.every((p, i) => Math.abs(p.t - b[i].t) < 1e-9 && Math.abs(p.left - b[i].left) < 1e-9 && Math.abs(p.right - b[i].right) < 1e-9);
1342
- return _nullishCoalesce(_optionalChain([VECTOR_WIDTH_PRESETS, 'access', _23 => _23.find, 'call', _24 => _24((p) => p.points.length && same2(points, p.points)), 'optionalAccess', _25 => _25.id]), () => ( "custom"));
1703
+ return _nullishCoalesce(_optionalChain([VECTOR_WIDTH_PRESETS, 'access', _32 => _32.find, 'call', _33 => _33((p) => p.points.length && same2(points, p.points)), 'optionalAccess', _34 => _34.id]), () => ( "custom"));
1343
1704
  }
1344
1705
  function reverseWidthProfile(points) {
1345
1706
  return points.map((p) => ({ t: 1 - p.t, left: p.right, right: p.left })).reverse();
@@ -1348,12 +1709,12 @@ function mirrorWidthProfile(points) {
1348
1709
  return points.map((p) => ({ t: p.t, left: p.right, right: p.left }));
1349
1710
  }
1350
1711
  function editable(points) {
1351
- return _optionalChain([points, 'optionalAccess', _26 => _26.length]) ? points.map((p) => ({ ...p })) : [sym(0, 1), sym(1, 1)];
1712
+ return _optionalChain([points, 'optionalAccess', _35 => _35.length]) ? points.map((p) => ({ ...p })) : [sym(0, 1), sym(1, 1)];
1352
1713
  }
1353
1714
  function insertWidthPoint(points, t, sides = {}, options = {}) {
1354
1715
  const pts = editable(points);
1355
1716
  const tt = Math.min(Math.max(Number.isFinite(t) ? t : 0, 0), 1);
1356
- const here = widthProfileAt(_optionalChain([points, 'optionalAccess', _27 => _27.length]) ? points : null, tt);
1717
+ const here = widthProfileAt(_optionalChain([points, 'optionalAccess', _36 => _36.length]) ? points : null, tt);
1357
1718
  const p = {
1358
1719
  t: tt,
1359
1720
  left: _nullishCoalesce(clean(sides.left, VECTOR_WIDTH_PROFILE_MAX_SCALE), () => ( here.left)),
@@ -1424,7 +1785,7 @@ function generateWidthProfile(options) {
1424
1785
  const n = Math.max(8, Math.min(VECTOR_WIDTH_PROFILE_MAX_POINTS * 4, _nullishCoalesce(options.samples, () => ( Math.ceil(32 + cycles * 16)))));
1425
1786
  const raw = [];
1426
1787
  for (let i = 0; i <= n; i++) raw.push([i / n, taperWaveFactor(i / n, options.taper, options.wave)]);
1427
- const ts = [_optionalChain([options, 'access', _28 => _28.taper, 'optionalAccess', _29 => _29.startLength]), _optionalChain([options, 'access', _30 => _30.taper, 'optionalAccess', _31 => _31.endLength]) !== void 0 ? 1 - options.taper.endLength : void 0];
1788
+ const ts = [_optionalChain([options, 'access', _37 => _37.taper, 'optionalAccess', _38 => _38.startLength]), _optionalChain([options, 'access', _39 => _39.taper, 'optionalAccess', _40 => _40.endLength]) !== void 0 ? 1 - options.taper.endLength : void 0];
1428
1789
  for (const t of ts) if (typeof t === "number" && t > 0 && t < 1) raw.push([t, taperWaveFactor(t, options.taper, options.wave)]);
1429
1790
  raw.sort((a, b) => a[0] - b[0]);
1430
1791
  const kept = simplifySamples(raw, _nullishCoalesce(options.tolerance, () => ( 0.01)), VECTOR_WIDTH_PROFILE_MAX_POINTS);
@@ -1472,7 +1833,7 @@ var SAMPLES_PER_SUBPATH = 128;
1472
1833
  var MAX_DASHES = 5e3;
1473
1834
  var sub3 = (a, b) => [a[0] - b[0], a[1] - b[1]];
1474
1835
  var along = (p, v2, k) => [p[0] + v2[0] * k, p[1] + v2[1] * k];
1475
- var lerp = (a, b, u) => [a[0] + (b[0] - a[0]) * u, a[1] + (b[1] - a[1]) * u];
1836
+ var lerp2 = (a, b, u) => [a[0] + (b[0] - a[0]) * u, a[1] + (b[1] - a[1]) * u];
1476
1837
  var dist = (a, b) => Math.hypot(a[0] - b[0], a[1] - b[1]);
1477
1838
  var unitOf = (v2) => {
1478
1839
  const l = Math.hypot(v2[0], v2[1]);
@@ -1507,7 +1868,7 @@ function flatten(segments, closed, tol) {
1507
1868
  for (let i = 1; i < pts.length; i++) {
1508
1869
  const n = Math.max(1, Math.ceil(dist(pts[i - 1], pts[i]) / step));
1509
1870
  for (let k = 1; k <= n; k++) {
1510
- fine.push(k === n ? pts[i] : lerp(pts[i - 1], pts[i], k / n));
1871
+ fine.push(k === n ? pts[i] : lerp2(pts[i - 1], pts[i], k / n));
1511
1872
  fineCorner.push(k === n ? corner[i] : false);
1512
1873
  }
1513
1874
  }
@@ -1544,7 +1905,7 @@ function at(poly, t) {
1544
1905
  const a = poly.s[i - 1];
1545
1906
  const b = poly.s[i];
1546
1907
  const u = b > a ? Math.min(Math.max((t - a) / (b - a), 0), 1) : 0;
1547
- return [lerp(poly.pts[i - 1], poly.pts[i], u), i];
1908
+ return [lerp2(poly.pts[i - 1], poly.pts[i], u), i];
1548
1909
  }
1549
1910
  function arcPoints(c, a0, sweep, r0, r1, tol) {
1550
1911
  const r = Math.max(r0, r1);
@@ -1591,7 +1952,7 @@ function variableStrokeRings(path, options) {
1591
1952
  const w = widthProfileAt(options.profile, s / len2);
1592
1953
  return [w.left * half, w.right * half];
1593
1954
  };
1594
- const intervals = _optionalChain([options, 'access', _32 => _32.dash, 'optionalAccess', _33 => _33.some, 'call', _34 => _34((v2) => v2 > 0)]) ? dashIntervals(options.dash, _nullishCoalesce(options.dashOffset, () => ( 0)), len2) : [[0, len2]];
1955
+ const intervals = _optionalChain([options, 'access', _41 => _41.dash, 'optionalAccess', _42 => _42.some, 'call', _43 => _43((v2) => v2 > 0)]) ? dashIntervals(options.dash, _nullishCoalesce(options.dashOffset, () => ( 0)), len2) : [[0, len2]];
1595
1956
  const whole = intervals.length === 1 && intervals[0][0] <= 0 && intervals[0][1] >= len2;
1596
1957
  for (const [a, b] of intervals) {
1597
1958
  const [pa, ia] = at(poly, a);
@@ -1742,7 +2103,7 @@ function nearestStrokePosition(path, p, only) {
1742
2103
  if (!best || near3.distance < best.distance) {
1743
2104
  const s = acc + _chunkXGD3FSNCcjs.segmentLength.call(void 0, seg, 0, near3.t);
1744
2105
  const tan = _chunkXGD3FSNCcjs.segmentTangent.call(void 0, seg, near3.t);
1745
- const pt2 = seg.length === 2 ? lerp(seg[0], seg[1], near3.t) : evalSeg(seg, near3.t);
2106
+ const pt2 = seg.length === 2 ? lerp2(seg[0], seg[1], near3.t) : evalSeg(seg, near3.t);
1746
2107
  const n = leftNormal([tan[0], tan[1]]);
1747
2108
  const side = (p[0] - pt2[0]) * n[0] + (p[1] - pt2[1]) * n[1] >= 0 ? "left" : "right";
1748
2109
  best = { contour: ci, t: Math.min(Math.max(s / total, 0), 1), distance: near3.distance, side, point: pt2, tangent: [tan[0], tan[1]], length: total };
@@ -1754,12 +2115,12 @@ function nearestStrokePosition(path, p, only) {
1754
2115
  }
1755
2116
  function evalSeg(seg, t) {
1756
2117
  let pts = seg.map((q) => [q[0], q[1]]);
1757
- while (pts.length > 1) pts = pts.slice(1).map((q, i) => lerp(pts[i], q, t));
2118
+ while (pts.length > 1) pts = pts.slice(1).map((q, i) => lerp2(pts[i], q, t));
1758
2119
  return pts[0];
1759
2120
  }
1760
2121
  function strokePositionPoint(path, index, t) {
1761
2122
  const c = _chunkXGD3FSNCcjs.pathToContours.call(void 0, path)[index];
1762
- if (!_optionalChain([c, 'optionalAccess', _35 => _35.segments, 'access', _36 => _36.length])) return null;
2123
+ if (!_optionalChain([c, 'optionalAccess', _44 => _44.segments, 'access', _45 => _45.length])) return null;
1763
2124
  const lengths = c.segments.map((s) => _chunkXGD3FSNCcjs.segmentLength.call(void 0, s));
1764
2125
  const total = lengths.reduce((a, b) => a + b, 0);
1765
2126
  let want = Math.min(Math.max(t, 0), 1) * total;
@@ -1795,7 +2156,7 @@ function effectiveStrokeAlign(style, closedShape) {
1795
2156
  return closedShape ? a : "center";
1796
2157
  }
1797
2158
  function strokeWidthProfileOf(style) {
1798
- if (!_optionalChain([style, 'access', _37 => _37.strokeWidthProfile, 'optionalAccess', _38 => _38.length])) return null;
2159
+ if (!_optionalChain([style, 'access', _46 => _46.strokeWidthProfile, 'optionalAccess', _47 => _47.length])) return null;
1799
2160
  const p = sanitizeWidthProfile(style.strokeWidthProfile);
1800
2161
  return isUniformWidthProfile(p) ? null : p;
1801
2162
  }
@@ -1804,7 +2165,7 @@ function hasStrokeExtras(style) {
1804
2165
  }
1805
2166
  function vectorStrokeLineArea(parts, style, tolerance) {
1806
2167
  const profile = strokeWidthProfileOf(style);
1807
- const dash = _optionalChain([style, 'access', _39 => _39.strokeDasharray, 'optionalAccess', _40 => _40.length]) ? { dash: style.strokeDasharray } : {};
2168
+ const dash = _optionalChain([style, 'access', _48 => _48.strokeDasharray, 'optionalAccess', _49 => _49.length]) ? { dash: style.strokeDasharray } : {};
1808
2169
  const join = _nullishCoalesce(style.strokeLinejoin, () => ( "miter"));
1809
2170
  const cap = _nullishCoalesce(style.strokeLinecap, () => ( "butt"));
1810
2171
  if (profile) return variableStrokeOutline(parts.line, { width: parts.drawWidth, profile, join, cap, ...dash, ...tolerance ? { tolerance } : {} });
@@ -2098,7 +2459,7 @@ function withVectorFills(node, fills) {
2098
2459
  const next = { ...node };
2099
2460
  if (fills.length === 0 || fills.length === 1 && isPlainVectorPaintLayer(fills[0])) {
2100
2461
  delete next.fills;
2101
- next.fill = _nullishCoalesce(_optionalChain([fills, 'access', _41 => _41[0], 'optionalAccess', _42 => _42.paint]), () => ( null));
2462
+ next.fill = _nullishCoalesce(_optionalChain([fills, 'access', _50 => _50[0], 'optionalAccess', _51 => _51.paint]), () => ( null));
2102
2463
  return next;
2103
2464
  }
2104
2465
  next.fills = fills.map((l) => ({ ...l }));
@@ -2123,8 +2484,8 @@ function withVectorStrokes(node, strokes) {
2123
2484
  var json = (v2) => JSON.stringify(_nullishCoalesce(v2, () => ( null)));
2124
2485
  function strokeShorthandDiff(node, top) {
2125
2486
  const out = [];
2126
- if (json(node.stroke) !== json(_optionalChain([top, 'optionalAccess', _43 => _43.paint]))) out.push("stroke");
2127
- for (const key of VECTOR_STROKE_SETTING_KEYS) if (json(node[key]) !== json(_optionalChain([top, 'optionalAccess', _44 => _44[key]]))) out.push(key);
2487
+ if (json(node.stroke) !== json(_optionalChain([top, 'optionalAccess', _52 => _52.paint]))) out.push("stroke");
2488
+ for (const key of VECTOR_STROKE_SETTING_KEYS) if (json(node[key]) !== json(_optionalChain([top, 'optionalAccess', _53 => _53[key]]))) out.push(key);
2128
2489
  return out;
2129
2490
  }
2130
2491
  var checked = /* @__PURE__ */ new WeakSet();
@@ -2141,7 +2502,7 @@ function normalizeVectorPaintStacks(node, prefer = "shorthand") {
2141
2502
  if (Array.isArray(node.fills)) {
2142
2503
  let fills = node.fills;
2143
2504
  const top = fills[fills.length - 1];
2144
- if (prefer === "shorthand" && json(node.fill) !== json(_optionalChain([top, 'optionalAccess', _45 => _45.paint]))) {
2505
+ if (prefer === "shorthand" && json(node.fill) !== json(_optionalChain([top, 'optionalAccess', _54 => _54.paint]))) {
2145
2506
  if (!draws(node.fill)) fills = [];
2146
2507
  else fills = top ? [...fills.slice(0, -1), { ...top, paint: node.fill }] : [{ paint: node.fill }];
2147
2508
  }
@@ -2174,7 +2535,7 @@ function normalizeVectorPaintStacks(node, prefer = "shorthand") {
2174
2535
  function sanitizePaint(value) {
2175
2536
  if (value === null || value === void 0) return null;
2176
2537
  if (typeof value === "string") return value;
2177
- return sanitizeVectorGradient(value);
2538
+ return _nullishCoalesce(sanitizeVectorShadedPaint(value), () => ( sanitizeVectorGradient(value)));
2178
2539
  }
2179
2540
  function sanitizeLayerBase(raw) {
2180
2541
  const out = { paint: sanitizePaint(raw.paint) };
@@ -2292,22 +2653,22 @@ function withVectorTargetPaint(node, target, layer, paint) {
2292
2653
  var MAX_PIECES = 1 << 20;
2293
2654
  var MAX_DEPTH = 6;
2294
2655
  var PROBES = [0.25, 0.5, 0.75];
2295
- var lerp2 = (a, b, t) => ({ x: a.x + (b.x - a.x) * t, y: a.y + (b.y - a.y) * t });
2656
+ var lerp3 = (a, b, t) => ({ x: a.x + (b.x - a.x) * t, y: a.y + (b.y - a.y) * t });
2296
2657
  var dist2 = (a, b) => Math.hypot(a.x - b.x, a.y - b.y);
2297
2658
  var same = (a, b) => Math.abs(a.x - b.x) < 1e-9 && Math.abs(a.y - b.y) < 1e-9;
2298
2659
  function evalCubic(s, t) {
2299
- const ab = lerp2(s[0], s[1], t);
2300
- const bc = lerp2(s[1], s[2], t);
2301
- const cd = lerp2(s[2], s[3], t);
2302
- return lerp2(lerp2(ab, bc, t), lerp2(bc, cd, t), t);
2660
+ const ab = lerp3(s[0], s[1], t);
2661
+ const bc = lerp3(s[1], s[2], t);
2662
+ const cd = lerp3(s[2], s[3], t);
2663
+ return lerp3(lerp3(ab, bc, t), lerp3(bc, cd, t), t);
2303
2664
  }
2304
2665
  function halves(s) {
2305
- const ab = lerp2(s[0], s[1], 0.5);
2306
- const bc = lerp2(s[1], s[2], 0.5);
2307
- const cd = lerp2(s[2], s[3], 0.5);
2308
- const abc = lerp2(ab, bc, 0.5);
2309
- const bcd = lerp2(bc, cd, 0.5);
2310
- const m = lerp2(abc, bcd, 0.5);
2666
+ const ab = lerp3(s[0], s[1], 0.5);
2667
+ const bc = lerp3(s[1], s[2], 0.5);
2668
+ const cd = lerp3(s[2], s[3], 0.5);
2669
+ const abc = lerp3(ab, bc, 0.5);
2670
+ const bcd = lerp3(bc, cd, 0.5);
2671
+ const m = lerp3(abc, bcd, 0.5);
2311
2672
  return [
2312
2673
  [s[0], ab, abc, m],
2313
2674
  [m, bcd, cd, s[3]]
@@ -2369,8 +2730,8 @@ function mapSegment(seg, f, tol, depth, fit) {
2369
2730
  if (same(seg[1], seg[0]) && same(seg[2], seg[3])) {
2370
2731
  const a = f(seg[0]);
2371
2732
  const b = f(seg[3]);
2372
- if (PROBES.every((t) => offLine(f(lerp2(seg[0], seg[3], t)), a, b) <= tol)) return [[a, a, b, b]];
2373
- const line = [seg[0], lerp2(seg[0], seg[3], 1 / 3), lerp2(seg[0], seg[3], 2 / 3), seg[3]];
2733
+ if (PROBES.every((t) => offLine(f(lerp3(seg[0], seg[3], t)), a, b) <= tol)) return [[a, a, b, b]];
2734
+ const line = [seg[0], lerp3(seg[0], seg[3], 1 / 3), lerp3(seg[0], seg[3], 2 / 3), seg[3]];
2374
2735
  const out2 = [];
2375
2736
  splitMapped(line, f, tol, depth, out2);
2376
2737
  return fit ? refit(line, out2, f, tol) : out2;
@@ -2437,7 +2798,7 @@ function mapBezierPath(path, f, tolerance = 0.1, options = {}) {
2437
2798
 
2438
2799
  // src/vector/frames.ts
2439
2800
  function isVectorFrame(node) {
2440
- return _optionalChain([node, 'optionalAccess', _46 => _46.type]) === "group" && !!node.frame && !node.blend && !node.liveBoolean && !node.mask;
2801
+ return _optionalChain([node, 'optionalAccess', _55 => _55.type]) === "group" && !!node.frame && !node.blend && !node.liveBoolean && !node.mask;
2441
2802
  }
2442
2803
  function vectorFrameRectPath(frame) {
2443
2804
  const { x, y, width: w, height: h } = frame;
@@ -2481,17 +2842,17 @@ function placeSpan(rule, a0, a1, f0, f1, g0, g1) {
2481
2842
  }
2482
2843
  }
2483
2844
  function vectorFrameChildMatrix(resizing, box, from, to) {
2484
- const [x0, x1] = placeSpan(_nullishCoalesce(H[_nullishCoalesce(_optionalChain([resizing, 'optionalAccess', _47 => _47.horizontal]), () => ( "left"))], () => ( "start")), box.x, box.x + box.width, from.x, from.x + from.width, to.x, to.x + to.width);
2485
- const [y0, y1] = placeSpan(_nullishCoalesce(V[_nullishCoalesce(_optionalChain([resizing, 'optionalAccess', _48 => _48.vertical]), () => ( "top"))], () => ( "start")), box.y, box.y + box.height, from.y, from.y + from.height, to.y, to.y + to.height);
2845
+ const [x0, x1] = placeSpan(_nullishCoalesce(H[_nullishCoalesce(_optionalChain([resizing, 'optionalAccess', _56 => _56.horizontal]), () => ( "left"))], () => ( "start")), box.x, box.x + box.width, from.x, from.x + from.width, to.x, to.x + to.width);
2846
+ const [y0, y1] = placeSpan(_nullishCoalesce(V[_nullishCoalesce(_optionalChain([resizing, 'optionalAccess', _57 => _57.vertical]), () => ( "top"))], () => ( "start")), box.y, box.y + box.height, from.y, from.y + from.height, to.y, to.y + to.height);
2486
2847
  const sx = box.width > 1e-9 ? (x1 - x0) / box.width : 1;
2487
2848
  const sy = box.height > 1e-9 ? (y1 - y0) / box.height : 1;
2488
2849
  return [sx, 0, 0, sy, x0 - sx * box.x, y0 - sy * box.y];
2489
2850
  }
2490
- var finite = (v2) => typeof v2 === "number" && Number.isFinite(v2);
2851
+ var finite2 = (v2) => typeof v2 === "number" && Number.isFinite(v2);
2491
2852
  function sanitizeVectorFrame(value) {
2492
2853
  if (!value || typeof value !== "object") return null;
2493
2854
  const r = value;
2494
- if (!finite(r.x) || !finite(r.y) || !finite(r.width) || !finite(r.height) || r.width < 0 || r.height < 0) return null;
2855
+ if (!finite2(r.x) || !finite2(r.y) || !finite2(r.width) || !finite2(r.height) || r.width < 0 || r.height < 0) return null;
2495
2856
  const out = { x: r.x, y: r.y, width: r.width, height: r.height };
2496
2857
  if (typeof r.fill === "string" || r.fill && typeof r.fill === "object") out.fill = r.fill;
2497
2858
  if (r.clip === false) out.clip = false;
@@ -2536,7 +2897,7 @@ function vectorFrameDocument(doc, id, find) {
2536
2897
  height,
2537
2898
  ...doc.background ? { background: doc.background } : {},
2538
2899
  nodes: [placed],
2539
- ..._optionalChain([doc, 'access', _49 => _49.symbols, 'optionalAccess', _50 => _50.length]) ? { symbols: doc.symbols } : {}
2900
+ ..._optionalChain([doc, 'access', _58 => _58.symbols, 'optionalAccess', _59 => _59.length]) ? { symbols: doc.symbols } : {}
2540
2901
  };
2541
2902
  }
2542
2903
  function getVectorFramePanel(state) {
@@ -2556,7 +2917,7 @@ function getVectorFramePanel(state) {
2556
2917
  const one = (values) => values.every((v2) => v2 === values[0]) ? values[0] : "mixed";
2557
2918
  return {
2558
2919
  frame: f ? { id: f.id, name: _nullishCoalesce(f.name, () => ( "Frame")), artboard: parents.get(f.id) === null, frame: f.frame } : null,
2559
- resizing: children.length ? { ids: children.map((c) => c.id), horizontal: one(children.map((c) => _nullishCoalesce(_optionalChain([c, 'access', _51 => _51.resizing, 'optionalAccess', _52 => _52.horizontal]), () => ( "left")))), vertical: one(children.map((c) => _nullishCoalesce(_optionalChain([c, 'access', _53 => _53.resizing, 'optionalAccess', _54 => _54.vertical]), () => ( "top")))) } : null
2920
+ resizing: children.length ? { ids: children.map((c) => c.id), horizontal: one(children.map((c) => _nullishCoalesce(_optionalChain([c, 'access', _60 => _60.resizing, 'optionalAccess', _61 => _61.horizontal]), () => ( "left")))), vertical: one(children.map((c) => _nullishCoalesce(_optionalChain([c, 'access', _62 => _62.resizing, 'optionalAccess', _63 => _63.vertical]), () => ( "top")))) } : null
2560
2921
  };
2561
2922
  }
2562
2923
 
@@ -2942,7 +3303,7 @@ function normalizeVectorFilterParams(type, params, base) {
2942
3303
  if (!isVectorFilterType(type)) return null;
2943
3304
  const out = { ...VECTOR_FILTER_DEFAULTS[type], ..._nullishCoalesce(base, () => ( {})) };
2944
3305
  for (const spec of VECTOR_FILTER_PARAM_SPECS[type]) {
2945
- const v2 = _optionalChain([params, 'optionalAccess', _55 => _55[spec.key]]);
3306
+ const v2 = _optionalChain([params, 'optionalAccess', _64 => _64[spec.key]]);
2946
3307
  if (v2 === void 0) continue;
2947
3308
  if (spec.kind === "number" && typeof v2 === "number" && Number.isFinite(v2)) out[spec.key] = Math.min(_nullishCoalesce(spec.max, () => ( Infinity)), Math.max(_nullishCoalesce(spec.min, () => ( -Infinity)), v2));
2948
3309
  else if (spec.kind === "color" && typeof v2 === "string" && v2.trim()) out[spec.key] = v2.trim();
@@ -3074,7 +3435,7 @@ function vectorFilterSvg(filters, id, bounds) {
3074
3435
  primitives.push(fe("feGaussianBlur", { in: body, stdDeviation: round(f.params.radius / 2), result: name("body") }));
3075
3436
  body = name("body");
3076
3437
  }
3077
- const lastResult = _optionalChain([primitives, 'access', _56 => _56[primitives.length - 1], 'optionalAccess', _57 => _57.attrs, 'access', _58 => _58.result]);
3438
+ const lastResult = _optionalChain([primitives, 'access', _65 => _65[primitives.length - 1], 'optionalAccess', _66 => _66.attrs, 'access', _67 => _67.result]);
3078
3439
  if (lastResult !== body) primitives.push(fe("feMerge", {}, [fe("feMergeNode", { in: body })]));
3079
3440
  const pad = vectorFilterReach(active) + 2;
3080
3441
  return {
@@ -3089,7 +3450,7 @@ function vectorFilterSvg(filters, id, bounds) {
3089
3450
  var escapeAttr = (value) => value.replace(/&/g, "&amp;").replace(/"/g, "&quot;").replace(/</g, "&lt;").replace(/>/g, "&gt;");
3090
3451
  function primitiveMarkup(p) {
3091
3452
  const attrs = Object.entries(p.attrs).map(([k, v2]) => ` ${k}="${escapeAttr(String(v2))}"`).join("");
3092
- return _optionalChain([p, 'access', _59 => _59.children, 'optionalAccess', _60 => _60.length]) ? `<${p.tag}${attrs}>${p.children.map(primitiveMarkup).join("")}</${p.tag}>` : `<${p.tag}${attrs}/>`;
3453
+ return _optionalChain([p, 'access', _68 => _68.children, 'optionalAccess', _69 => _69.length]) ? `<${p.tag}${attrs}>${p.children.map(primitiveMarkup).join("")}</${p.tag}>` : `<${p.tag}${attrs}/>`;
3093
3454
  }
3094
3455
  function vectorFilterMarkup(filter, extra = "") {
3095
3456
  return `<filter id="${escapeAttr(filter.id)}" filterUnits="userSpaceOnUse" x="${filter.x}" y="${filter.y}" width="${filter.width}" height="${filter.height}" color-interpolation-filters="sRGB"${extra}>${filter.primitives.map(primitiveMarkup).join("")}</filter>`;
@@ -3107,7 +3468,7 @@ function sanitizeVectorMask(value) {
3107
3468
  return r.invert === true ? { type: r.type, invert: true } : { type: r.type };
3108
3469
  }
3109
3470
  function isVectorMaskGroup(node) {
3110
- return _optionalChain([node, 'optionalAccess', _61 => _61.type]) === "group" && !!node.mask && isVectorMaskType(node.mask.type) && !node.blend && !node.liveBoolean && node.children.length > 0;
3471
+ return _optionalChain([node, 'optionalAccess', _70 => _70.type]) === "group" && !!node.mask && isVectorMaskType(node.mask.type) && !node.blend && !node.liveBoolean && node.children.length > 0;
3111
3472
  }
3112
3473
  function isVectorMaskActive(node) {
3113
3474
  return isVectorMaskGroup(node) && node.children[0].visible !== false;
@@ -3142,7 +3503,7 @@ function vectorMaskRegionShapes(node, type, parent = IDENTITY_MATRIX, self = tru
3142
3503
  if (!self && node.visible === false) return [];
3143
3504
  if (isVectorFrame(node)) node = vectorFrameDrawn(node);
3144
3505
  const m = multiplyMatrices(nodeMatrix(node), parent);
3145
- if (isVectorMaskActive(node) || node.type === "group" && _optionalChain([node, 'access', _62 => _62.effects, 'optionalAccess', _63 => _63.length])) {
3506
+ if (isVectorMaskActive(node) || node.type === "group" && _optionalChain([node, 'access', _71 => _71.effects, 'optionalAccess', _72 => _72.length])) {
3146
3507
  return vectorAppearanceShapes(node).flatMap((s) => regionOfPath(s.path, s.source, type, m));
3147
3508
  }
3148
3509
  const drawn = expandVectorAppearance(node);
@@ -3347,7 +3708,7 @@ function fitRuns(runs, length2, fallback) {
3347
3708
  }
3348
3709
  if (left2 > 0) {
3349
3710
  if (out.length) out[out.length - 1] = { ...out[out.length - 1], length: out[out.length - 1].length + left2 };
3350
- else out.push({ length: left2, style: _nullishCoalesce(_optionalChain([runs, 'access', _64 => _64[runs.length - 1], 'optionalAccess', _65 => _65.style]), () => ( fallback)) });
3711
+ else out.push({ length: left2, style: _nullishCoalesce(_optionalChain([runs, 'access', _73 => _73[runs.length - 1], 'optionalAccess', _74 => _74.style]), () => ( fallback)) });
3351
3712
  }
3352
3713
  return compact(out);
3353
3714
  }
@@ -3357,7 +3718,7 @@ function styleAt(runs, index, fallback) {
3357
3718
  if (index < at2 + r.length) return r.style;
3358
3719
  at2 += r.length;
3359
3720
  }
3360
- return _nullishCoalesce(_optionalChain([runs, 'access', _66 => _66[runs.length - 1], 'optionalAccess', _67 => _67.style]), () => ( fallback));
3721
+ return _nullishCoalesce(_optionalChain([runs, 'access', _75 => _75[runs.length - 1], 'optionalAccess', _76 => _76.style]), () => ( fallback));
3361
3722
  }
3362
3723
  function restyleRange(runs, start, end, patch) {
3363
3724
  const out = [];
@@ -3413,7 +3774,7 @@ function paragraphRanges(text) {
3413
3774
  return out;
3414
3775
  }
3415
3776
  function fitParagraphRuns(runs, text) {
3416
- const fallback = _nullishCoalesce(_optionalChain([runs, 'access', _68 => _68[0], 'optionalAccess', _69 => _69.style]), () => ( {}));
3777
+ const fallback = _nullishCoalesce(_optionalChain([runs, 'access', _77 => _77[0], 'optionalAccess', _78 => _78.style]), () => ( {}));
3417
3778
  const out = compact(paragraphRanges(text).map((p) => ({ length: p.end - p.start, style: styleAt(runs, p.start, fallback) })));
3418
3779
  return out.length ? out : [{ length: 0, style: fallback }];
3419
3780
  }
@@ -3429,7 +3790,7 @@ var isWide = (code) => code >= 11904 && code <= 40959 || code >= 44032 && code <
3429
3790
  var layoutCache = /* @__PURE__ */ new WeakMap();
3430
3791
  function layoutText(layer, shaper) {
3431
3792
  let byShaper = layoutCache.get(layer);
3432
- const hit = _optionalChain([byShaper, 'optionalAccess', _70 => _70.get, 'call', _71 => _71(shaper.id)]);
3793
+ const hit = _optionalChain([byShaper, 'optionalAccess', _79 => _79.get, 'call', _80 => _80(shaper.id)]);
3433
3794
  if (hit) return hit;
3434
3795
  const out = computeLayout(layer, shaper);
3435
3796
  if (!byShaper) {
@@ -3666,7 +4027,7 @@ function createCanvasTextShaper(options = {}) {
3666
4027
  return null;
3667
4028
  })));
3668
4029
  const canvas = make(1, 1);
3669
- const ctx = _optionalChain([canvas, 'optionalAccess', _72 => _72.getContext, 'call', _73 => _73("2d")]);
4030
+ const ctx = _optionalChain([canvas, 'optionalAccess', _81 => _81.getContext, 'call', _82 => _82("2d")]);
3670
4031
  if (!ctx || typeof ctx.measureText !== "function") return null;
3671
4032
  const fallback = _nullishCoalesce(options.fallbackFamily, () => ( "sans-serif"));
3672
4033
  const available = /* @__PURE__ */ new Map();
@@ -3739,10 +4100,10 @@ function createOutlineTextShaper(fonts, options = {}) {
3739
4100
  const entries = fonts.map((f) => {
3740
4101
  const e = "face" in f ? f : { face: f };
3741
4102
  const names = e.face.names;
3742
- const family = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(e.family, () => ( _optionalChain([names, 'optionalAccess', _74 => _74.fontFamily, 'optionalAccess', _75 => _75.en]))), () => ( Object.values(_nullishCoalesce(_optionalChain([names, 'optionalAccess', _76 => _76.fontFamily]), () => ( {})))[0])), () => ( "Font"));
3743
- const weight = _nullishCoalesce(_nullishCoalesce(e.weight, () => ( _optionalChain([e, 'access', _77 => _77.face, 'access', _78 => _78.tables, 'optionalAccess', _79 => _79.os2, 'optionalAccess', _80 => _80.usWeightClass]))), () => ( 400));
3744
- const italic = _nullishCoalesce(e.italic, () => ( Boolean((_nullishCoalesce(_optionalChain([e, 'access', _81 => _81.face, 'access', _82 => _82.tables, 'optionalAccess', _83 => _83.os2, 'optionalAccess', _84 => _84.fsSelection]), () => ( 0))) & 1)));
3745
- const postScript = _nullishCoalesce(_optionalChain([names, 'optionalAccess', _85 => _85.postScriptName, 'optionalAccess', _86 => _86.en]), () => ( Object.values(_nullishCoalesce(_optionalChain([names, 'optionalAccess', _87 => _87.postScriptName]), () => ( {})))[0]));
4103
+ const family = _nullishCoalesce(_nullishCoalesce(_nullishCoalesce(e.family, () => ( _optionalChain([names, 'optionalAccess', _83 => _83.fontFamily, 'optionalAccess', _84 => _84.en]))), () => ( Object.values(_nullishCoalesce(_optionalChain([names, 'optionalAccess', _85 => _85.fontFamily]), () => ( {})))[0])), () => ( "Font"));
4104
+ const weight = _nullishCoalesce(_nullishCoalesce(e.weight, () => ( _optionalChain([e, 'access', _86 => _86.face, 'access', _87 => _87.tables, 'optionalAccess', _88 => _88.os2, 'optionalAccess', _89 => _89.usWeightClass]))), () => ( 400));
4105
+ const italic = _nullishCoalesce(e.italic, () => ( Boolean((_nullishCoalesce(_optionalChain([e, 'access', _90 => _90.face, 'access', _91 => _91.tables, 'optionalAccess', _92 => _92.os2, 'optionalAccess', _93 => _93.fsSelection]), () => ( 0))) & 1)));
4106
+ const postScript = _nullishCoalesce(_optionalChain([names, 'optionalAccess', _94 => _94.postScriptName, 'optionalAccess', _95 => _95.en]), () => ( Object.values(_nullishCoalesce(_optionalChain([names, 'optionalAccess', _96 => _96.postScriptName]), () => ( {})))[0]));
3746
4107
  return { face: e.face, family, key: family.toLowerCase(), weight, italic, postScript };
3747
4108
  });
3748
4109
  const fallbackKey = (_nullishCoalesce(options.fallback, () => ( entries[0].family))).toLowerCase();
@@ -3848,7 +4209,7 @@ function vectorTextHasOutlines() {
3848
4209
  return typeof getVectorTextShaper().outline === "function";
3849
4210
  }
3850
4211
  function vectorTextFamilies() {
3851
- return _nullishCoalesce(_optionalChain([getVectorTextShaper, 'call', _88 => _88(), 'access', _89 => _89.families, 'optionalCall', _90 => _90()]), () => ( ["sans-serif", "serif", "monospace"]));
4212
+ return _nullishCoalesce(_optionalChain([getVectorTextShaper, 'call', _97 => _97(), 'access', _98 => _98.families, 'optionalCall', _99 => _99()]), () => ( ["sans-serif", "serif", "monospace"]));
3852
4213
  }
3853
4214
  var DEFAULT_VECTOR_FONT = { fontFamily: "sans-serif", fontWeight: 400, fontSize: 24 };
3854
4215
  var VECTOR_CHARACTER_STYLE_KEYS = ["fontFamily", "fontWeight", "italic", "fontSize", "tracking", "leading", "baselineShift", "underline", "strikethrough"];
@@ -4023,7 +4384,7 @@ function computeLayout2(node, shaper) {
4023
4384
  const fragments = [];
4024
4385
  const lines = [];
4025
4386
  let overflow = false;
4026
- const fillOf = (f) => _optionalChain([runs, 'access', _91 => _91.find, 'call', _92 => _92((r) => f.start >= r.start && f.start < r.end), 'optionalAccess', _93 => _93.fill]);
4387
+ const fillOf = (f) => _optionalChain([runs, 'access', _100 => _100.find, 'call', _101 => _101((r) => f.start >= r.start && f.start < r.end), 'optionalAccess', _102 => _102.fill]);
4027
4388
  const styleOf = (f) => {
4028
4389
  const { color: _c, opacity: _o, postScriptName: _p, ...style } = f.style;
4029
4390
  return style;
@@ -4054,11 +4415,11 @@ function computeLayout2(node, shaper) {
4054
4415
  } else {
4055
4416
  const line = text.lines[0];
4056
4417
  const measure = measureVectorPath(subpathPath(frame.path), !!frame.flip);
4057
- const align = _nullishCoalesce(_optionalChain([node, 'access', _94 => _94.paragraph, 'optionalAccess', _95 => _95.align]), () => ( "left"));
4418
+ const align = _nullishCoalesce(_optionalChain([node, 'access', _103 => _103.paragraph, 'optionalAccess', _104 => _104.align]), () => ( "left"));
4058
4419
  const start = Math.max(0, _nullishCoalesce(frame.start, () => ( 0)));
4059
4420
  const end = Math.max(0, _nullishCoalesce(frame.end, () => ( 0)));
4060
4421
  const upright = frame.orientation === "upright";
4061
- const baselineOffset = pathBaselineOffset(_nullishCoalesce(frame.baseline, () => ( "baseline")), _nullishCoalesce(_optionalChain([line, 'optionalAccess', _96 => _96.ascent]), () => ( 0)), _nullishCoalesce(_optionalChain([line, 'optionalAccess', _97 => _97.descent]), () => ( 0)));
4422
+ const baselineOffset = pathBaselineOffset(_nullishCoalesce(frame.baseline, () => ( "baseline")), _nullishCoalesce(_optionalChain([line, 'optionalAccess', _105 => _105.ascent]), () => ( 0)), _nullishCoalesce(_optionalChain([line, 'optionalAccess', _106 => _106.descent]), () => ( 0)));
4062
4423
  if (line) {
4063
4424
  const chars = line.chars.filter((c) => {
4064
4425
  const lo = block.text.charCodeAt(c.index);
@@ -4067,7 +4428,7 @@ function computeLayout2(node, shaper) {
4067
4428
  const advanceOf = (c) => {
4068
4429
  const pair = charAt(block.text, c.index).length === 2;
4069
4430
  const low = pair ? line.chars.find((d) => d.index === c.index + 1) : void 0;
4070
- return c.advance + (_nullishCoalesce(_optionalChain([low, 'optionalAccess', _98 => _98.advance]), () => ( 0)));
4431
+ return c.advance + (_nullishCoalesce(_optionalChain([low, 'optionalAccess', _107 => _107.advance]), () => ( 0)));
4071
4432
  };
4072
4433
  const pivots = chars.map((c) => c.x + advanceOf(c) / 2);
4073
4434
  const positions = vectorPathTextPositions(pivots, [line.x, line.x + line.width], align, measure.length, start, end);
@@ -4122,7 +4483,7 @@ function computeLayout2(node, shaper) {
4122
4483
  if (x0 < Infinity) bounds = { x: x0, y: y0, width: x1 - x0, height: y1 - y0 };
4123
4484
  else if (frame.kind === "point") {
4124
4485
  const l = text.lines[0];
4125
- bounds = { x: frame.x, y: frame.y - (_nullishCoalesce(_optionalChain([l, 'optionalAccess', _99 => _99.ascent]), () => ( 0))), width: 0, height: (_nullishCoalesce(_optionalChain([l, 'optionalAccess', _100 => _100.ascent]), () => ( 0))) + (_nullishCoalesce(_optionalChain([l, 'optionalAccess', _101 => _101.descent]), () => ( 0))) };
4486
+ bounds = { x: frame.x, y: frame.y - (_nullishCoalesce(_optionalChain([l, 'optionalAccess', _108 => _108.ascent]), () => ( 0))), width: 0, height: (_nullishCoalesce(_optionalChain([l, 'optionalAccess', _109 => _109.ascent]), () => ( 0))) + (_nullishCoalesce(_optionalChain([l, 'optionalAccess', _110 => _110.descent]), () => ( 0))) };
4126
4487
  }
4127
4488
  }
4128
4489
  return { shaper: shaper.id, glyphs, fragments, lines, origin, text, bounds, overflow, missingFonts: text.missingFonts };
@@ -4243,7 +4604,7 @@ function vectorTextCaret(node, index) {
4243
4604
  const t = { x: Math.cos(r), y: Math.sin(r) };
4244
4605
  const n2 = { x: -t.y, y: t.x };
4245
4606
  const o = { x: g2.x + t.x * u, y: g2.y + t.y * u };
4246
- return { top: { x: o.x - n2.x * g2.ascent, y: o.y - n2.y * g2.ascent }, bottom: { x: o.x + n2.x * g2.descent, y: o.y + n2.y * g2.descent }, line: _nullishCoalesce(_optionalChain([layout, 'access', _102 => _102.fragments, 'access', _103 => _103[g2.fragment], 'optionalAccess', _104 => _104.line]), () => ( 0)) };
4607
+ return { top: { x: o.x - n2.x * g2.ascent, y: o.y - n2.y * g2.ascent }, bottom: { x: o.x + n2.x * g2.descent, y: o.y + n2.y * g2.descent }, line: _nullishCoalesce(_optionalChain([layout, 'access', _111 => _111.fragments, 'access', _112 => _112[g2.fragment], 'optionalAccess', _113 => _113.line]), () => ( 0)) };
4247
4608
  };
4248
4609
  if (node.frame.kind !== "path") {
4249
4610
  const c = caretAt(layout.text, index);
@@ -4378,7 +4739,7 @@ function sanitizeVectorTextFrame(value, path = "frame") {
4378
4739
  return { kind: "area", x: num2(f.x, `${path}.x`, -1e7, 1e7), y: num2(f.y, `${path}.y`, -1e7, 1e7), width: num2(f.width, `${path}.width`, 0, 1e7), height: num2(f.height, `${path}.height`, 0, 1e7) };
4379
4740
  if (f.kind === "path") {
4380
4741
  const sp = f.path;
4381
- if (!sp || !Array.isArray(sp.anchors) || sp.anchors.length < 2 || !sp.anchors.every((a) => isNum(_optionalChain([a, 'optionalAccess', _105 => _105.x])) && isNum(_optionalChain([a, 'optionalAccess', _106 => _106.y])))) fail(`${path}.path must be a subpath with at least two anchors.`);
4742
+ if (!sp || !Array.isArray(sp.anchors) || sp.anchors.length < 2 || !sp.anchors.every((a) => isNum(_optionalChain([a, 'optionalAccess', _114 => _114.x])) && isNum(_optionalChain([a, 'optionalAccess', _115 => _115.y])))) fail(`${path}.path must be a subpath with at least two anchors.`);
4382
4743
  const out = { kind: "path", path: { closed: !!sp.closed, anchors: sp.anchors.map((a) => ({ ...a })) } };
4383
4744
  if (f.start !== void 0 && f.start !== 0) out.start = num2(f.start, `${path}.start`, 0, 1e7);
4384
4745
  if (f.end !== void 0 && f.end !== 0) out.end = num2(f.end, `${path}.end`, 0, 1e7);
@@ -4396,7 +4757,7 @@ function sanitizeVectorTextFrame(value, path = "frame") {
4396
4757
  return fail(`${path}.kind must be point, area or path, got ${JSON.stringify(f.kind)}.`);
4397
4758
  }
4398
4759
  function normalizeVectorTextRuns(text, runs) {
4399
- if (!_optionalChain([runs, 'optionalAccess', _107 => _107.length])) return null;
4760
+ if (!_optionalChain([runs, 'optionalAccess', _116 => _116.length])) return null;
4400
4761
  const cleaned = fitVectorTextRuns(
4401
4762
  runs.map((r) => ({ length: r.length, style: stripUndefined(r.style) })),
4402
4763
  text.length
@@ -4430,7 +4791,7 @@ function replaceVectorText(node, start, end, insert) {
4430
4791
  const clean2 = insert.replace(/\r\n?/g, "\n");
4431
4792
  const text = node.text.slice(0, start) + clean2 + node.text.slice(end);
4432
4793
  let runs = null;
4433
- if (_optionalChain([node, 'access', _108 => _108.runs, 'optionalAccess', _109 => _109.length])) {
4794
+ if (_optionalChain([node, 'access', _117 => _117.runs, 'optionalAccess', _118 => _118.length])) {
4434
4795
  const fitted = fitVectorTextRuns(node.runs, node.text.length);
4435
4796
  const style = styleAt(fitted, start > 0 ? start - 1 : start, {});
4436
4797
  runs = normalizeVectorTextRuns(text, spliceRuns(fitted, start, end, clean2.length, style));
@@ -4446,7 +4807,7 @@ function styleVectorText(node, start, end, patch) {
4446
4807
  if (whole) {
4447
4808
  let next2 = { ...node, font: patchVectorCharacterStyle(node.font, fields, "style") };
4448
4809
  const keys = Object.keys(fields).filter((k) => fields[k] !== void 0);
4449
- if (_optionalChain([next2, 'access', _110 => _110.runs, 'optionalAccess', _111 => _111.length]) && (keys.length || fill !== void 0)) {
4810
+ if (_optionalChain([next2, 'access', _119 => _119.runs, 'optionalAccess', _120 => _120.length]) && (keys.length || fill !== void 0)) {
4450
4811
  const runs2 = normalizeVectorTextRuns(
4451
4812
  next2.text,
4452
4813
  next2.runs.map((r) => {
@@ -4491,7 +4852,7 @@ function bakeVectorTextGeometry(node, m) {
4491
4852
  ...s.baselineShift !== void 0 ? { baselineShift: s.baselineShift * k } : {}
4492
4853
  });
4493
4854
  const font = scaleStyle(node.font);
4494
- const runs = _optionalChain([node, 'access', _112 => _112.runs, 'optionalAccess', _113 => _113.map, 'call', _114 => _114((r) => ({ length: r.length, style: scaleStyle(r.style) }))]);
4855
+ const runs = _optionalChain([node, 'access', _121 => _121.runs, 'optionalAccess', _122 => _122.map, 'call', _123 => _123((r) => ({ length: r.length, style: scaleStyle(r.style) }))]);
4495
4856
  const p = node.paragraph;
4496
4857
  const paragraph = p ? {
4497
4858
  ...p,
@@ -4621,14 +4982,14 @@ function bezierToSubpathsLite(path) {
4621
4982
  }
4622
4983
  return out.filter((sp) => sp.anchors.length);
4623
4984
  }
4624
- var fmt2 = (n) => Math.round(n * 1e3) / 1e3;
4985
+ var fmt3 = (n) => Math.round(n * 1e3) / 1e3;
4625
4986
  function vectorTextSpanSvg(sp, fill) {
4626
- const list = (v2) => v2.map(fmt2).join(" ");
4987
+ const list = (v2) => v2.map(fmt3).join(" ");
4627
4988
  const deco = [sp.style.underline ? "underline" : "", sp.style.strikethrough ? "line-through" : ""].filter(Boolean).join(" ");
4628
4989
  return {
4629
4990
  text: sp.text,
4630
4991
  x: list(sp.x),
4631
- y: sp.y.every((v2) => v2 === sp.y[0]) ? String(fmt2(sp.y[0])) : list(sp.y),
4992
+ y: sp.y.every((v2) => v2 === sp.y[0]) ? String(fmt3(sp.y[0])) : list(sp.y),
4632
4993
  ...sp.rotate ? { rotate: list(sp.rotate) } : {},
4633
4994
  fontFamily: cssFontFamily(sp.family),
4634
4995
  fontSize: sp.style.fontSize,
@@ -4773,7 +5134,7 @@ function vectorInstanceGroup(node, bake) {
4773
5134
  const m = _nullishCoalesce(node.transform, () => ( [1, 0, 0, 1, 0, 0]));
4774
5135
  const { rigid, residual } = decomposeRigid(m);
4775
5136
  const k = Math.sqrt(Math.abs(residual[0] * residual[3] - residual[1] * residual[2]));
4776
- const hidden = new Set(_nullishCoalesce(_optionalChain([node, 'access', _115 => _115.overrides, 'optionalAccess', _116 => _116.hidden]), () => ( [])));
5137
+ const hidden = new Set(_nullishCoalesce(_optionalChain([node, 'access', _124 => _124.overrides, 'optionalAccess', _125 => _125.hidden]), () => ( [])));
4777
5138
  const keep = (list) => list.filter((n) => !hidden.has(n.id)).map((n) => n.type === "group" ? { ...n, children: keep(n.children) } : n);
4778
5139
  let children = prefixVectorIds(keep(_nullishCoalesce(node.art, () => ( []))), node.id);
4779
5140
  if (!isIdentityMatrix(residual)) children = children.map((c) => bake(c, residual));
@@ -4786,8 +5147,8 @@ function vectorInstanceGroup(node, bake) {
4786
5147
  if (node.locked) group.locked = true;
4787
5148
  if (node.opacity !== void 0) group.opacity = node.opacity;
4788
5149
  if (node.blendMode) group.blendMode = node.blendMode;
4789
- if (_optionalChain([node, 'access', _117 => _117.filters, 'optionalAccess', _118 => _118.length])) group.filters = node.filters;
4790
- if (_optionalChain([node, 'access', _119 => _119.effects, 'optionalAccess', _120 => _120.length])) group.effects = node.effects;
5150
+ if (_optionalChain([node, 'access', _126 => _126.filters, 'optionalAccess', _127 => _127.length])) group.filters = node.filters;
5151
+ if (_optionalChain([node, 'access', _128 => _128.effects, 'optionalAccess', _129 => _129.length])) group.effects = node.effects;
4791
5152
  if (node.booleanOperation) group.booleanOperation = node.booleanOperation;
4792
5153
  if (node.blendStep) group.blendStep = true;
4793
5154
  return group;
@@ -5674,7 +6035,7 @@ function normalizeVectorEffectParams(type, params, base) {
5674
6035
  if (!defaults) return null;
5675
6036
  const out = { ...defaults, ..._nullishCoalesce(base, () => ( {})) };
5676
6037
  for (const spec of VECTOR_EFFECT_PARAM_SPECS[type]) {
5677
- const v2 = _optionalChain([params, 'optionalAccess', _121 => _121[spec.key]]);
6038
+ const v2 = _optionalChain([params, 'optionalAccess', _130 => _130[spec.key]]);
5678
6039
  if (v2 === void 0) continue;
5679
6040
  if (spec.kind === "number" && typeof v2 === "number" && Number.isFinite(v2)) out[spec.key] = Math.min(_nullishCoalesce(spec.max, () => ( Infinity)), Math.max(_nullishCoalesce(spec.min, () => ( -Infinity)), v2));
5680
6041
  else if (spec.kind === "boolean" && typeof v2 === "boolean") out[spec.key] = v2;
@@ -5685,7 +6046,7 @@ function normalizeVectorEffectParams(type, params, base) {
5685
6046
  const o = out;
5686
6047
  o.rows = Math.round(o.rows);
5687
6048
  o.columns = Math.round(o.columns);
5688
- const given = _optionalChain([params, 'optionalAccess', _122 => _122.mesh]);
6049
+ const given = _optionalChain([params, 'optionalAccess', _131 => _131.mesh]);
5689
6050
  let mesh = given !== void 0 ? isValidWarpMesh(given) ? cloneMesh(given) : null : o.mesh;
5690
6051
  if (o.style !== "mesh") mesh = null;
5691
6052
  if (mesh && given !== void 0) {
@@ -5702,10 +6063,10 @@ function createVectorEffect(type, id, params) {
5702
6063
  }
5703
6064
  var isEnabled = (e) => e.enabled !== false && !!VECTOR_EFFECT_DEFAULTS[e.type];
5704
6065
  function activeVectorEffects(node) {
5705
- return _nullishCoalesce(_optionalChain([node, 'access', _123 => _123.effects, 'optionalAccess', _124 => _124.filter, 'call', _125 => _125(isEnabled)]), () => ( []));
6066
+ return _nullishCoalesce(_optionalChain([node, 'access', _132 => _132.effects, 'optionalAccess', _133 => _133.filter, 'call', _134 => _134(isEnabled)]), () => ( []));
5706
6067
  }
5707
6068
  function hasOwnVectorAppearance(node) {
5708
- return node.type === "text" || node.type === "instance" || node.type === "group" && !!node.liveBoolean || isVectorFrame(node) || !!_optionalChain([node, 'access', _126 => _126.effects, 'optionalAccess', _127 => _127.some, 'call', _128 => _128(isEnabled)]);
6069
+ return node.type === "text" || node.type === "instance" || node.type === "group" && !!node.liveBoolean || isVectorFrame(node) || !!_optionalChain([node, 'access', _135 => _135.effects, 'optionalAccess', _136 => _136.some, 'call', _137 => _137(isEnabled)]);
5709
6070
  }
5710
6071
  var liveCache = /* @__PURE__ */ new WeakMap();
5711
6072
  function hasVectorAppearance(node) {
@@ -5717,7 +6078,7 @@ function hasVectorAppearance(node) {
5717
6078
  return v2;
5718
6079
  }
5719
6080
  function isVectorLiveBoolean(node) {
5720
- return _optionalChain([node, 'optionalAccess', _129 => _129.type]) === "group" && !!node.liveBoolean;
6081
+ return _optionalChain([node, 'optionalAccess', _138 => _138.type]) === "group" && !!node.liveBoolean;
5721
6082
  }
5722
6083
  function vectorOperandOperation(group, child) {
5723
6084
  return _nullishCoalesce(_nullishCoalesce(child.booleanOperation, () => ( group.liveBoolean)), () => ( "union"));
@@ -5834,7 +6195,7 @@ var compareOrder = (a, b) => {
5834
6195
  for (let i = 0; i < n; i++) if (a[i] !== b[i]) return a[i] - b[i];
5835
6196
  return a.length - b.length;
5836
6197
  };
5837
- var add3 = (a, b) => ({ x: a.x + (_nullishCoalesce(_optionalChain([b, 'optionalAccess', _130 => _130.x]), () => ( 0))), y: a.y + (_nullishCoalesce(_optionalChain([b, 'optionalAccess', _131 => _131.y]), () => ( 0))) });
6198
+ var add3 = (a, b) => ({ x: a.x + (_nullishCoalesce(_optionalChain([b, 'optionalAccess', _139 => _139.x]), () => ( 0))), y: a.y + (_nullishCoalesce(_optionalChain([b, 'optionalAccess', _140 => _140.y]), () => ( 0))) });
5838
6199
  var mapPaths = (shapes, fn) => {
5839
6200
  const out = fn(shapes.map((s) => s.path));
5840
6201
  return shapes.map((s, i) => ({ ...s, path: _nullishCoalesce(out[i], () => ( [])) }));
@@ -5955,10 +6316,10 @@ function vectorEffectInputBounds(node, effectId) {
5955
6316
  return paths ? pathsBounds(paths) : null;
5956
6317
  }
5957
6318
  function vectorNodeEnvelope(node) {
5958
- return _nullishCoalesce(_optionalChain([node, 'optionalAccess', _132 => _132.effects, 'optionalAccess', _133 => _133.find, 'call', _134 => _134((e) => e.type === "envelope" && e.enabled !== false)]), () => ( null));
6319
+ return _nullishCoalesce(_optionalChain([node, 'optionalAccess', _141 => _141.effects, 'optionalAccess', _142 => _142.find, 'call', _143 => _143((e) => e.type === "envelope" && e.enabled !== false)]), () => ( null));
5959
6320
  }
5960
6321
  function vectorEnvelopeFrame(node, effectId) {
5961
- const e = effectId ? _optionalChain([node, 'access', _135 => _135.effects, 'optionalAccess', _136 => _136.find, 'call', _137 => _137((x) => x.id === effectId)]) : vectorNodeEnvelope(node);
6322
+ const e = effectId ? _optionalChain([node, 'access', _144 => _144.effects, 'optionalAccess', _145 => _145.find, 'call', _146 => _146((x) => x.id === effectId)]) : vectorNodeEnvelope(node);
5962
6323
  if (!e || e.type !== "envelope") return null;
5963
6324
  const bounds = vectorEffectInputBounds(node, e.id);
5964
6325
  if (!bounds || !(bounds.width > 0 && bounds.height > 0)) return null;
@@ -6019,7 +6380,7 @@ function placement(node) {
6019
6380
  ...node.blendStep ? { blendStep: true } : {},
6020
6381
  ...node.booleanOperation ? { booleanOperation: node.booleanOperation } : {},
6021
6382
  ...node.blendMode ? { blendMode: node.blendMode } : {},
6022
- ..._optionalChain([node, 'access', _138 => _138.filters, 'optionalAccess', _139 => _139.length]) ? { filters: node.filters } : {}
6383
+ ..._optionalChain([node, 'access', _147 => _147.filters, 'optionalAccess', _148 => _148.length]) ? { filters: node.filters } : {}
6023
6384
  };
6024
6385
  }
6025
6386
  function vectorAppearanceNodes(node) {
@@ -6141,7 +6502,7 @@ function vectorEnteredGroups(nodes, ids) {
6141
6502
  // src/vector/connectors.ts
6142
6503
  var SIDES = ["top", "right", "bottom", "left", "center"];
6143
6504
  function isVectorConnector(node) {
6144
- return _optionalChain([node, 'optionalAccess', _140 => _140.type]) === "path" && !!node.connector;
6505
+ return _optionalChain([node, 'optionalAccess', _149 => _149.type]) === "path" && !!node.connector;
6145
6506
  }
6146
6507
  function vectorConnectionSites(nodes, id) {
6147
6508
  const node = findVectorNode(nodes, id);
@@ -6198,7 +6559,7 @@ function facingSite(sites, toward) {
6198
6559
  }
6199
6560
  function storedEnds(node, world) {
6200
6561
  const sp = node.subpaths[0];
6201
- if (!_optionalChain([sp, 'optionalAccess', _141 => _141.anchors, 'access', _142 => _142.length])) return null;
6562
+ if (!_optionalChain([sp, 'optionalAccess', _150 => _150.anchors, 'access', _151 => _151.length])) return null;
6202
6563
  const a = sp.anchors[0];
6203
6564
  const b = sp.anchors[sp.anchors.length - 1];
6204
6565
  return [applyMatrix(world, a), applyMatrix(world, b)];
@@ -6305,8 +6666,8 @@ function routeVectorConnector(nodes, id) {
6305
6666
  }));
6306
6667
  return {
6307
6668
  subpaths: [{ closed: false, anchors: local }],
6308
- startSide: _nullishCoalesce(_optionalChain([s, 'optionalAccess', _143 => _143.side]), () => ( null)),
6309
- endSide: _nullishCoalesce(_optionalChain([e, 'optionalAccess', _144 => _144.side]), () => ( null)),
6669
+ startSide: _nullishCoalesce(_optionalChain([s, 'optionalAccess', _152 => _152.side]), () => ( null)),
6670
+ endSide: _nullishCoalesce(_optionalChain([e, 'optionalAccess', _153 => _153.side]), () => ( null)),
6310
6671
  dropped: { start: !!startGlue && !s, end: !!endGlue && !e }
6311
6672
  };
6312
6673
  }
@@ -6318,7 +6679,7 @@ function sameSubpaths(a, b) {
6318
6679
  const o = b[i];
6319
6680
  return sp.closed === o.closed && sp.anchors.length === o.anchors.length && sp.anchors.every((p, k) => {
6320
6681
  const q = o.anchors[k];
6321
- return samePoint(p, q) && samePoint(p.in, q.in) && samePoint(p.out, q.out) && (_nullishCoalesce(_optionalChain([p, 'access', _145 => _145.corner, 'optionalAccess', _146 => _146.radius]), () => ( 0))) === (_nullishCoalesce(_optionalChain([q, 'access', _147 => _147.corner, 'optionalAccess', _148 => _148.radius]), () => ( 0)));
6682
+ return samePoint(p, q) && samePoint(p.in, q.in) && samePoint(p.out, q.out) && (_nullishCoalesce(_optionalChain([p, 'access', _154 => _154.corner, 'optionalAccess', _155 => _155.radius]), () => ( 0))) === (_nullishCoalesce(_optionalChain([q, 'access', _156 => _156.corner, 'optionalAccess', _157 => _157.radius]), () => ( 0)));
6322
6683
  });
6323
6684
  });
6324
6685
  }
@@ -6417,13 +6778,13 @@ function vectorConnectorTargetAt(nodes, p, radius, exclude) {
6417
6778
  var SHARP = 1.25;
6418
6779
  var TOLERANCE = 0.2;
6419
6780
  var OVERLAP = 0.5;
6420
- var fmt3 = (n, digits = 3) => {
6781
+ var fmt4 = (n, digits = 3) => {
6421
6782
  const k = 10 ** digits;
6422
6783
  const v2 = Math.round(n * k) / k;
6423
6784
  return Object.is(v2, -0) ? "0" : String(v2);
6424
6785
  };
6425
- var toSvgStops2 = (stops) => stops.map((s) => ({ offset: `${fmt3(s.offset * 100)}%`, stopColor: s.color, ...s.opacity !== void 0 && s.opacity !== 1 ? { stopOpacity: Math.round(s.opacity * 1e4) / 1e4 } : {} }));
6426
- var polygonD2 = (pts, precision) => `M${pts.map((p) => `${fmt3(p.x, precision)} ${fmt3(p.y, precision)}`).join("L")}Z`;
6786
+ var toSvgStops2 = (stops) => stops.map((s) => ({ offset: `${fmt4(s.offset * 100)}%`, stopColor: s.color, ...s.opacity !== void 0 && s.opacity !== 1 ? { stopOpacity: Math.round(s.opacity * 1e4) / 1e4 } : {} }));
6787
+ var polygonD2 = (pts, precision) => `M${pts.map((p) => `${fmt4(p.x, precision)} ${fmt4(p.y, precision)}`).join("L")}Z`;
6427
6788
  var add4 = (a, b) => ({ x: a.x + b.x, y: a.y + b.y });
6428
6789
  var sub4 = (a, b) => ({ x: a.x - b.x, y: a.y - b.y });
6429
6790
  var scale2 = (a, k) => ({ x: a.x * k, y: a.y * k });
@@ -6542,7 +6903,7 @@ function vectorStrokeGradientDefs(g, id, node, options = {}) {
6542
6903
  gradients.push({
6543
6904
  id: gid,
6544
6905
  type: "linear",
6545
- attrs: { gradientUnits: "userSpaceOnUse", x1: fmt3(a.x, 4), y1: fmt3(a.y, 4), x2: fmt3(b.x, 4), y2: fmt3(b.y, 4) },
6906
+ attrs: { gradientUnits: "userSpaceOnUse", x1: fmt4(a.x, 4), y1: fmt4(a.y, 4), x2: fmt4(b.x, 4), y2: fmt4(b.y, 4) },
6546
6907
  stops: toSvgStops2(spanVectorGradientStops(g, t0, t1, expanded))
6547
6908
  });
6548
6909
  } else {
@@ -6556,7 +6917,7 @@ function vectorStrokeGradientDefs(g, id, node, options = {}) {
6556
6917
  gradients.push({
6557
6918
  id: gid,
6558
6919
  type: "linear",
6559
- attrs: { gradientUnits: "userSpaceOnUse", x1: fmt3(p0.x, 4), y1: fmt3(p0.y, 4), x2: fmt3(p1.x, 4), y2: fmt3(p1.y, 4) },
6920
+ attrs: { gradientUnits: "userSpaceOnUse", x1: fmt4(p0.x, 4), y1: fmt4(p0.y, 4), x2: fmt4(p1.x, 4), y2: fmt4(p1.y, 4) },
6560
6921
  stops: toSvgStops2(expanded)
6561
6922
  });
6562
6923
  }
@@ -6597,7 +6958,7 @@ function applyVectorCornersAttribute(subpaths, value) {
6597
6958
  for (const item of value.trim().split(/\s+/)) {
6598
6959
  const m = /^(\d+)\.(\d+):([\d.eE+-]+)(?::([a-z]+))?$/.exec(item);
6599
6960
  if (!m) continue;
6600
- const a = _optionalChain([subpaths, 'access', _149 => _149[+m[1]], 'optionalAccess', _150 => _150.anchors, 'access', _151 => _151[+m[2]]]);
6961
+ const a = _optionalChain([subpaths, 'access', _158 => _158[+m[1]], 'optionalAccess', _159 => _159.anchors, 'access', _160 => _160[+m[2]]]);
6601
6962
  const radius = parseFloat(m[3]);
6602
6963
  if (!a || !(radius > 0)) continue;
6603
6964
  const kind = VECTOR_CORNER_KINDS.includes(m[4]) ? m[4] : void 0;
@@ -6615,12 +6976,26 @@ var paintCache = /* @__PURE__ */ new WeakMap();
6615
6976
  function vectorPaintToSvg(paint, gradientId, options = {}) {
6616
6977
  if (!hasPaint(paint)) return { value: "none", defs: [] };
6617
6978
  if (typeof paint === "string") return { value: paint, defs: [] };
6979
+ if (isVectorShadedPaint(paint)) {
6980
+ const node2 = options.node;
6981
+ const bounds2 = node2 ? vectorPathLocalBounds(node2) : null;
6982
+ const reach2 = node2 && options.role === "stroke" ? vectorStrokeReach(node2) + 1 : 1;
6983
+ const area2 = bounds2 ? { x: bounds2.x - reach2, y: bounds2.y - reach2, width: bounds2.width + 2 * reach2, height: bounds2.height + 2 * reach2 } : null;
6984
+ const key2 = `${gradientId}|${_nullishCoalesce(options.role, () => ( "fill"))}|${_nullishCoalesce(options.precision, () => ( 3))}|${area2 ? [area2.x, area2.y, area2.width, area2.height].join(",") : ""}`;
6985
+ let byKey2 = paintCache.get(paint);
6986
+ const hit = _optionalChain([byKey2, 'optionalAccess', _161 => _161.get, 'call', _162 => _162(key2)]);
6987
+ if (hit) return { value: `url(#${gradientId})`, defs: hit };
6988
+ const defs2 = vectorShadedSvgDefs(paint, gradientId, { bounds: bounds2, area: area2, precision: _nullishCoalesce(options.precision, () => ( 3)) });
6989
+ if (!byKey2) paintCache.set(paint, byKey2 = /* @__PURE__ */ new Map());
6990
+ byKey2.set(key2, defs2);
6991
+ return { value: `url(#${gradientId})`, defs: defs2 };
6992
+ }
6618
6993
  if (!isVectorGradient(paint)) return { value: "none", defs: [] };
6619
6994
  const role = _nullishCoalesce(options.role, () => ( "fill"));
6620
6995
  const precision = _nullishCoalesce(options.precision, () => ( 3));
6621
6996
  const key = `${gradientId}|${role}|${precision}`;
6622
6997
  const owner = _nullishCoalesce(options.node, () => ( paint));
6623
- const cached = _optionalChain([paintCache, 'access', _152 => _152.get, 'call', _153 => _153(owner), 'optionalAccess', _154 => _154.get, 'call', _155 => _155(key)]);
6998
+ const cached = _optionalChain([paintCache, 'access', _163 => _163.get, 'call', _164 => _164(owner), 'optionalAccess', _165 => _165.get, 'call', _166 => _166(key)]);
6624
6999
  if (cached && (!options.node || (role === "fill" ? options.node.fill : options.node.stroke) === paint)) return { value: `url(#${gradientId})`, defs: cached };
6625
7000
  const node = options.node;
6626
7001
  const bounds = node ? vectorPathLocalBounds(node) : null;
@@ -6674,7 +7049,7 @@ function vectorNodeLocalPaintBounds(node) {
6674
7049
  }
6675
7050
  var filterCache = /* @__PURE__ */ new WeakMap();
6676
7051
  function vectorNodeFilterSvg(node, id) {
6677
- if (!_optionalChain([node, 'access', _156 => _156.filters, 'optionalAccess', _157 => _157.length])) return null;
7052
+ if (!_optionalChain([node, 'access', _167 => _167.filters, 'optionalAccess', _168 => _168.length])) return null;
6678
7053
  const hit = filterCache.get(node);
6679
7054
  if (hit && hit.id === id) return hit.filter;
6680
7055
  const active = activeVectorFilters(node);
@@ -6754,10 +7129,11 @@ function vectorDocumentToSvg(doc, options = {}) {
6754
7129
  if (node.type === "group" && node.blend) out2 += ` data-vector-blend="${escapeAttr2(JSON.stringify(node.blend))}"`;
6755
7130
  if (node.booleanOperation) out2 += ` data-vector-boolean-operation="${node.booleanOperation}"`;
6756
7131
  if (node.resizing) out2 += ` data-vector-resizing="${escapeAttr2(JSON.stringify(node.resizing))}"`;
7132
+ if (node.type === "path" && isVectorShadedPaint(node.fill)) out2 += ` data-vector-shading="${escapeAttr2(JSON.stringify(node.fill))}"`;
6757
7133
  if (node.type === "path" && node.connector) out2 += ` data-vector-connector="${escapeAttr2(JSON.stringify(node.connector))}"`;
6758
7134
  const blend = vectorBlendModeCss(node.blendMode);
6759
7135
  if (blend) out2 += ` style="mix-blend-mode:${blend}"`;
6760
- if (_optionalChain([node, 'access', _158 => _158.filters, 'optionalAccess', _159 => _159.length])) {
7136
+ if (_optionalChain([node, 'access', _169 => _169.filters, 'optionalAccess', _170 => _170.length])) {
6761
7137
  const filter = vectorNodeFilterSvg(node, `${prefix}filter-${node.id}`);
6762
7138
  const data = ` data-vector-filters="${escapeAttr2(JSON.stringify(node.filters))}"`;
6763
7139
  if (filter) {
@@ -6804,7 +7180,7 @@ function vectorDocumentToSvg(doc, options = {}) {
6804
7180
  let out2 = ` stroke="${escapeAttr2(strokeValue)}" stroke-width="${num3(width)}"`;
6805
7181
  if (node.strokeLinecap && node.strokeLinecap !== "butt") out2 += ` stroke-linecap="${node.strokeLinecap}"`;
6806
7182
  if (node.strokeLinejoin && node.strokeLinejoin !== "miter") out2 += ` stroke-linejoin="${node.strokeLinejoin}"`;
6807
- if (_optionalChain([node, 'access', _160 => _160.strokeDasharray, 'optionalAccess', _161 => _161.length])) out2 += ` stroke-dasharray="${node.strokeDasharray.map(num3).join(" ")}"`;
7183
+ if (_optionalChain([node, 'access', _171 => _171.strokeDasharray, 'optionalAccess', _172 => _172.length])) out2 += ` stroke-dasharray="${node.strokeDasharray.map(num3).join(" ")}"`;
6808
7184
  return out2;
6809
7185
  };
6810
7186
  const liveCorners = (node) => {
@@ -6847,7 +7223,7 @@ function vectorDocumentToSvg(doc, options = {}) {
6847
7223
  };
6848
7224
  const emit2 = (node, depth) => {
6849
7225
  if (node.visible === false && !options.includeHidden) return;
6850
- const wrappers = _nullishCoalesce(_optionalChain([options, 'access', _162 => _162.wrap, 'optionalAccess', _163 => _163[node.id]]), () => ( []));
7226
+ const wrappers = _nullishCoalesce(_optionalChain([options, 'access', _173 => _173.wrap, 'optionalAccess', _174 => _174[node.id]]), () => ( []));
6851
7227
  wrappers.forEach((w2, i) => {
6852
7228
  let attrs = w2.id !== void 0 ? ` id="${escapeAttr2(w2.id)}"` : "";
6853
7229
  if (w2.transform) attrs += ` transform="${escapeAttr2(w2.transform)}"`;
@@ -6868,7 +7244,7 @@ function vectorDocumentToSvg(doc, options = {}) {
6868
7244
  };
6869
7245
  const emitMaskGroup = (node, depth) => {
6870
7246
  const [source, ...contents] = node.children;
6871
- const body = _optionalChain([node, 'access', _164 => _164.effects, 'optionalAccess', _165 => _165.length]) && contents.length ? [{ id: `${node.id}~content`, type: "group", effects: node.effects, children: contents }] : contents;
7247
+ const body = _optionalChain([node, 'access', _175 => _175.effects, 'optionalAccess', _176 => _176.length]) && contents.length ? [{ id: `${node.id}~content`, type: "group", effects: node.effects, children: contents }] : contents;
6872
7248
  const settings = { type: node.mask.type, ...node.mask.invert ? { invert: true } : {} };
6873
7249
  lines.push(`${indent(depth)}<g${common(node)} data-vector-mask="${escapeAttr2(JSON.stringify(settings))}">`);
6874
7250
  const mask = vectorMaskRenderData(node, `${prefix}mask-${node.id}`, `${prefix}mask-filter-${node.id}`, precision);
@@ -6885,7 +7261,7 @@ function vectorDocumentToSvg(doc, options = {}) {
6885
7261
  lines.push(`${indent(depth + 1)}<g data-vector-part="mask-source" display="none">`);
6886
7262
  emitNode(source, depth + 2);
6887
7263
  lines.push(`${indent(depth + 1)}</g>`);
6888
- if (_optionalChain([mask, 'optionalAccess', _166 => _166.clip])) {
7264
+ if (_optionalChain([mask, 'optionalAccess', _177 => _177.clip])) {
6889
7265
  defs.push(`<clipPath id="${escapeAttr2(mask.id)}">${mask.clip.map((c) => `<path d="${c.d}" clip-rule="${c.clipRule}"/>`).join("")}</clipPath>`);
6890
7266
  ref = ` clip-path="url(#${escapeAttr2(mask.id)})"`;
6891
7267
  }
@@ -6897,7 +7273,7 @@ function vectorDocumentToSvg(doc, options = {}) {
6897
7273
  };
6898
7274
  const emitTextElement = (node, depth, attrs) => {
6899
7275
  const geometry = vectorTextGeometryNode(node);
6900
- const fields = { text: node.text, font: node.font, ..._optionalChain([node, 'access', _167 => _167.runs, 'optionalAccess', _168 => _168.length]) ? { runs: node.runs } : {}, ...node.paragraph ? { paragraph: node.paragraph } : {}, frame: node.frame, ..._optionalChain([node, 'access', _169 => _169.effects, 'optionalAccess', _170 => _170.length]) ? { effects: node.effects } : {} };
7276
+ const fields = { text: node.text, font: node.font, ..._optionalChain([node, 'access', _178 => _178.runs, 'optionalAccess', _179 => _179.length]) ? { runs: node.runs } : {}, ...node.paragraph ? { paragraph: node.paragraph } : {}, frame: node.frame, ..._optionalChain([node, 'access', _180 => _180.effects, 'optionalAccess', _181 => _181.length]) ? { effects: node.effects } : {} };
6901
7277
  let data = ` data-vector-text="${escapeAttr2(JSON.stringify(fields))}"`;
6902
7278
  if (hasVectorPaintStacks(node)) data += ` data-vector-fills="${escapeAttr2(JSON.stringify(vectorFills(node)))}" data-vector-strokes="${escapeAttr2(JSON.stringify(vectorStrokes(node)))}"`;
6903
7279
  else {
@@ -6939,12 +7315,12 @@ function vectorDocumentToSvg(doc, options = {}) {
6939
7315
  };
6940
7316
  const emitText = (node, depth) => {
6941
7317
  const outlines = vectorTextPaths(node).outlines;
6942
- const effects = !!_optionalChain([node, 'access', _171 => _171.effects, 'optionalAccess', _172 => _172.some, 'call', _173 => _173((e) => e.enabled !== false)]);
7318
+ const effects = !!_optionalChain([node, 'access', _182 => _182.effects, 'optionalAccess', _183 => _183.some, 'call', _184 => _184((e) => e.enabled !== false)]);
6943
7319
  if (!outlines || !effects && options.text !== "outlines") {
6944
7320
  emitTextElement(node, depth, common(node));
6945
7321
  return;
6946
7322
  }
6947
- lines.push(`${indent(depth)}<g${common(node)} data-vector-live="${escapeAttr2(JSON.stringify({ kind: "text", ..._optionalChain([node, 'access', _174 => _174.effects, 'optionalAccess', _175 => _175.length]) ? { effects: node.effects } : {} }))}">`);
7323
+ lines.push(`${indent(depth)}<g${common(node)} data-vector-live="${escapeAttr2(JSON.stringify({ kind: "text", ..._optionalChain([node, 'access', _185 => _185.effects, 'optionalAccess', _186 => _186.length]) ? { effects: node.effects } : {} }))}">`);
6948
7324
  lines.push(`${indent(depth + 1)}<g data-vector-part="appearance">`);
6949
7325
  for (const shape of vectorAppearanceNodes(node)) emit2(shape, depth + 2);
6950
7326
  lines.push(`${indent(depth + 1)}</g>`);
@@ -6958,7 +7334,7 @@ function vectorDocumentToSvg(doc, options = {}) {
6958
7334
  const symbolRef = (symbolId) => {
6959
7335
  const hit = symbolIds.get(symbolId);
6960
7336
  if (hit) return hit;
6961
- const sym2 = _optionalChain([doc, 'access', _176 => _176.symbols, 'optionalAccess', _177 => _177.find, 'call', _178 => _178((x) => x.id === symbolId)]);
7337
+ const sym2 = _optionalChain([doc, 'access', _187 => _187.symbols, 'optionalAccess', _188 => _188.find, 'call', _189 => _189((x) => x.id === symbolId)]);
6962
7338
  if (!sym2) return null;
6963
7339
  const id = `${prefix}symbol-${symbolId}`;
6964
7340
  symbolIds.set(symbolId, id);
@@ -6968,20 +7344,20 @@ function vectorDocumentToSvg(doc, options = {}) {
6968
7344
  };
6969
7345
  const emitInstance = (node, depth) => {
6970
7346
  const data = { symbolId: node.symbolId, ...node.scaleStrokes === false ? { scaleStrokes: false } : {}, ...node.overrides ? { overrides: node.overrides } : {} };
6971
- const exact = !node.overrides && node.scaleStrokes !== false && !_optionalChain([node, 'access', _179 => _179.effects, 'optionalAccess', _180 => _180.length]) && !_optionalChain([node, 'access', _181 => _181.filters, 'optionalAccess', _182 => _182.length]);
7347
+ const exact = !node.overrides && node.scaleStrokes !== false && !_optionalChain([node, 'access', _190 => _190.effects, 'optionalAccess', _191 => _191.length]) && !_optionalChain([node, 'access', _192 => _192.filters, 'optionalAccess', _193 => _193.length]);
6972
7348
  const ref = symbolRef(node.symbolId);
6973
7349
  if (exact && ref) {
6974
7350
  lines.push(`${indent(depth)}<use${common(node)} href="#${escapeAttr2(ref)}" data-vector-instance="${escapeAttr2(JSON.stringify(data))}"/>`);
6975
7351
  return;
6976
7352
  }
6977
- const full = { ...data, ...node.transform ? { transform: node.transform } : {}, ..._optionalChain([node, 'access', _183 => _183.effects, 'optionalAccess', _184 => _184.length]) ? { effects: node.effects } : {} };
7353
+ const full = { ...data, ...node.transform ? { transform: node.transform } : {}, ..._optionalChain([node, 'access', _194 => _194.effects, 'optionalAccess', _195 => _195.length]) ? { effects: node.effects } : {} };
6978
7354
  lines.push(`${indent(depth)}<g data-vector-instance="${escapeAttr2(JSON.stringify(full))}">`);
6979
7355
  emitNode(vectorInstanceDrawn(node), depth + 1);
6980
7356
  lines.push(`${indent(depth)}</g>`);
6981
7357
  };
6982
7358
  const emitFrame = (node, depth) => {
6983
7359
  const f = node.frame;
6984
- const data = { ...f, ..._optionalChain([node, 'access', _185 => _185.effects, 'optionalAccess', _186 => _186.length]) ? { effects: node.effects } : {} };
7360
+ const data = { ...f, ..._optionalChain([node, 'access', _196 => _196.effects, 'optionalAccess', _197 => _197.length]) ? { effects: node.effects } : {} };
6985
7361
  lines.push(`${indent(depth)}<g${common(node)} data-vector-frame="${escapeAttr2(JSON.stringify(data))}">`);
6986
7362
  const rect = vectorFrameRectPath(f);
6987
7363
  if (f.fill !== void 0 && f.fill !== null && f.fill !== "none") {
@@ -7020,7 +7396,7 @@ function vectorDocumentToSvg(doc, options = {}) {
7020
7396
  if (hasOwnVectorAppearance(node)) {
7021
7397
  const live2 = {
7022
7398
  kind: node.type,
7023
- ..._optionalChain([node, 'access', _187 => _187.effects, 'optionalAccess', _188 => _188.length]) ? { effects: node.effects } : {},
7399
+ ..._optionalChain([node, 'access', _198 => _198.effects, 'optionalAccess', _199 => _199.length]) ? { effects: node.effects } : {},
7024
7400
  ...node.type === "group" && node.liveBoolean ? { liveBoolean: node.liveBoolean } : {}
7025
7401
  };
7026
7402
  lines.push(`${indent(depth)}<g${common(node)} data-vector-live="${escapeAttr2(JSON.stringify(live2))}">`);
@@ -7070,7 +7446,7 @@ function vectorDocumentToSvg(doc, options = {}) {
7070
7446
  data += ` data-vector-width-profile="${widthProfileToAttribute(profile)}"`;
7071
7447
  if (node.strokeLinecap && node.strokeLinecap !== "butt") data += ` data-vector-stroke-linecap="${node.strokeLinecap}"`;
7072
7448
  if (node.strokeLinejoin && node.strokeLinejoin !== "miter") data += ` data-vector-stroke-linejoin="${node.strokeLinejoin}"`;
7073
- if (_optionalChain([node, 'access', _189 => _189.strokeDasharray, 'optionalAccess', _190 => _190.length])) data += ` data-vector-stroke-dasharray="${node.strokeDasharray.map(num3).join(" ")}"`;
7449
+ if (_optionalChain([node, 'access', _200 => _200.strokeDasharray, 'optionalAccess', _201 => _201.length])) data += ` data-vector-stroke-dasharray="${node.strokeDasharray.map(num3).join(" ")}"`;
7074
7450
  }
7075
7451
  lines.push(`${indent(depth)}<g${common(node)}${data}>`);
7076
7452
  lines.push(`${indent(depth + 1)}<path data-vector-part="fill" d="${d}"${fillAttrs}${live}/>`);
@@ -7238,7 +7614,7 @@ function attrOrStyle(el, name) {
7238
7614
  return el.attrs[name];
7239
7615
  }
7240
7616
  function urlId(value) {
7241
- return _nullishCoalesce(_optionalChain([/^url\(\s*['"]?#([^'")\s]+)['"]?\s*\)/, 'access', _191 => _191.exec, 'call', _192 => _192((_nullishCoalesce(value, () => ( ""))).trim()), 'optionalAccess', _193 => _193[1]]), () => ( null));
7617
+ return _nullishCoalesce(_optionalChain([/^url\(\s*['"]?#([^'")\s]+)['"]?\s*\)/, 'access', _202 => _202.exec, 'call', _203 => _203((_nullishCoalesce(value, () => ( ""))).trim()), 'optionalAccess', _204 => _204[1]]), () => ( null));
7242
7618
  }
7243
7619
  function clipRulesAsFillRules(el) {
7244
7620
  const attrs = { ...el.attrs };
@@ -7303,9 +7679,9 @@ function resolveGradient(id, raw) {
7303
7679
  for (let el = first; el && !chain.includes(el) && chain.length < 32; ) {
7304
7680
  chain.push(el);
7305
7681
  const href = _nullishCoalesce(el.attrs.href, () => ( el.attrs["xlink:href"]));
7306
- el = _optionalChain([href, 'optionalAccess', _194 => _194.startsWith, 'call', _195 => _195("#")]) ? raw.get(href.slice(1)) : void 0;
7682
+ el = _optionalChain([href, 'optionalAccess', _205 => _205.startsWith, 'call', _206 => _206("#")]) ? raw.get(href.slice(1)) : void 0;
7307
7683
  }
7308
- const attr = (name) => _optionalChain([chain, 'access', _196 => _196.find, 'call', _197 => _197((el) => el.attrs[name] !== void 0), 'optionalAccess', _198 => _198.attrs, 'access', _199 => _199[name]]);
7684
+ const attr = (name) => _optionalChain([chain, 'access', _207 => _207.find, 'call', _208 => _208((el) => el.attrs[name] !== void 0), 'optionalAccess', _209 => _209.attrs, 'access', _210 => _210[name]]);
7309
7685
  const stops = _nullishCoalesce(chain.map(readStops).find((s) => s.length), () => ( []));
7310
7686
  if (!stops.length) return null;
7311
7687
  const user = attr("gradientUnits") === "userSpaceOnUse";
@@ -7475,7 +7851,7 @@ function parseVectorSvg(svg, options = {}) {
7475
7851
  const stackedPath = (g, _style, m, meta) => {
7476
7852
  const fillEl = g.children.find((c) => c.name === "path" && c.attrs["data-vector-part"] === "fill");
7477
7853
  const subpaths = fillEl ? shapeOf(fillEl) : null;
7478
- if (!_optionalChain([subpaths, 'optionalAccess', _200 => _200.length])) return null;
7854
+ if (!_optionalChain([subpaths, 'optionalAccess', _211 => _211.length])) return null;
7479
7855
  const parse = (v2) => {
7480
7856
  try {
7481
7857
  return v2 ? JSON.parse(v2) : [];
@@ -7494,7 +7870,7 @@ function parseVectorSvg(svg, options = {}) {
7494
7870
  const key = (n) => JSON.stringify([n.subpaths, _nullishCoalesce(n.transform, () => ( null)), _nullishCoalesce(n.opacity, () => ( 1)), n.visible !== false, _nullishCoalesce(n.filters, () => ( null)), _nullishCoalesce(n.blendMode, () => ( "normal")), _nullishCoalesce(n.fillRule, () => ( "nonzero")), _nullishCoalesce(n.booleanOperation, () => ( null))]);
7495
7871
  for (const n of nodes2) {
7496
7872
  const prev = out[out.length - 1];
7497
- if (_optionalChain([prev, 'optionalAccess', _201 => _201.type]) === "path" && n.type === "path" && key(prev) === key(n)) {
7873
+ if (_optionalChain([prev, 'optionalAccess', _212 => _212.type]) === "path" && n.type === "path" && key(prev) === key(n)) {
7498
7874
  const fills = vectorFills(n);
7499
7875
  const strokesBefore = vectorStrokes(prev);
7500
7876
  if (!(fills.length && strokesBefore.length)) {
@@ -7512,7 +7888,7 @@ function parseVectorSvg(svg, options = {}) {
7512
7888
  const part = (name) => g.children.find((c) => c.name === "path" && c.attrs["data-vector-part"] === name);
7513
7889
  const fillEl = part("fill");
7514
7890
  const subpaths = fillEl ? shapeOf(fillEl) : null;
7515
- if (!fillEl || !_optionalChain([subpaths, 'optionalAccess', _202 => _202.length])) return null;
7891
+ if (!fillEl || !_optionalChain([subpaths, 'optionalAccess', _213 => _213.length])) return null;
7516
7892
  const a = g.attrs;
7517
7893
  const fs = readStyle(fillEl, style);
7518
7894
  const strokeEl = part("stroke");
@@ -7549,7 +7925,7 @@ function parseVectorSvg(svg, options = {}) {
7549
7925
  ...profile.length ? { strokeWidthProfile: profile } : {},
7550
7926
  ...keptCap ? { strokeLinecap: keptCap } : {},
7551
7927
  ...keptJoin ? { strokeLinejoin: keptJoin } : {},
7552
- ..._optionalChain([keptDash, 'optionalAccess', _203 => _203.length]) ? { strokeDasharray: keptDash } : {}
7928
+ ..._optionalChain([keptDash, 'optionalAccess', _214 => _214.length]) ? { strokeDasharray: keptDash } : {}
7553
7929
  };
7554
7930
  return placed(node, m);
7555
7931
  };
@@ -7612,8 +7988,8 @@ function parseVectorSvg(svg, options = {}) {
7612
7988
  } else {
7613
7989
  const fill = json2(g.attrs["data-vector-fill"]);
7614
7990
  const stroke = json2(g.attrs["data-vector-stroke"]);
7615
- node.fill = fill == null ? null : _nullishCoalesce(_optionalChain([sanitizeVectorFills, 'call', _204 => _204([{ paint: fill }]), 'access', _205 => _205[0], 'optionalAccess', _206 => _206.paint]), () => ( null));
7616
- node.stroke = stroke == null ? null : _nullishCoalesce(_optionalChain([sanitizeVectorFills, 'call', _207 => _207([{ paint: stroke }]), 'access', _208 => _208[0], 'optionalAccess', _209 => _209.paint]), () => ( null));
7991
+ node.fill = fill == null ? null : _nullishCoalesce(_optionalChain([sanitizeVectorFills, 'call', _215 => _215([{ paint: fill }]), 'access', _216 => _216[0], 'optionalAccess', _217 => _217.paint]), () => ( null));
7992
+ node.stroke = stroke == null ? null : _nullishCoalesce(_optionalChain([sanitizeVectorFills, 'call', _218 => _218([{ paint: stroke }]), 'access', _219 => _219[0], 'optionalAccess', _220 => _220.paint]), () => ( null));
7617
7993
  const settings = json2(g.attrs["data-vector-stroke-settings"]);
7618
7994
  if (settings && typeof settings === "object") {
7619
7995
  const strokes = sanitizeVectorStrokes([{ paint: _nullishCoalesce(node.stroke, () => ( "#000")), ...settings }]);
@@ -7649,8 +8025,8 @@ function parseVectorSvg(svg, options = {}) {
7649
8025
  const anchor = attrOrStyle(el, "text-anchor");
7650
8026
  const first0 = (v2) => _nullishCoalesce(numberList(v2)[0], () => ( 0));
7651
8027
  const tspan = el.children.find((c) => c.name === "tspan");
7652
- const x = el.attrs.x !== void 0 ? first0(el.attrs.x) : first0(_optionalChain([tspan, 'optionalAccess', _210 => _210.attrs, 'access', _211 => _211.x]));
7653
- const y = el.attrs.y !== void 0 ? first0(el.attrs.y) : first0(_optionalChain([tspan, 'optionalAccess', _212 => _212.attrs, 'access', _213 => _213.y]));
8028
+ const x = el.attrs.x !== void 0 ? first0(el.attrs.x) : first0(_optionalChain([tspan, 'optionalAccess', _221 => _221.attrs, 'access', _222 => _222.x]));
8029
+ const y = el.attrs.y !== void 0 ? first0(el.attrs.y) : first0(_optionalChain([tspan, 'optionalAccess', _223 => _223.attrs, 'access', _224 => _224.y]));
7654
8030
  const fillValue = _nullishCoalesce(attrOrStyle(el, "fill"), () => ( style.fill));
7655
8031
  let node = {
7656
8032
  id: idFor(el),
@@ -7681,12 +8057,12 @@ function parseVectorSvg(svg, options = {}) {
7681
8057
  if (symbolOfElement.has(el)) return symbolOfElement.get(el);
7682
8058
  symbolOfElement.set(el, null);
7683
8059
  const own = json2(el.attrs["data-vector-symbol"]);
7684
- let id = typeof _optionalChain([own, 'optionalAccess', _214 => _214.id]) === "string" && own.id ? own.id : _nullishCoalesce(el.attrs.id, () => ( createId()));
8060
+ let id = typeof _optionalChain([own, 'optionalAccess', _225 => _225.id]) === "string" && own.id ? own.id : _nullishCoalesce(el.attrs.id, () => ( createId()));
7685
8061
  while (usedSymbolIds.has(id)) id = `${id}-${usedSymbolIds.size}`;
7686
8062
  usedSymbolIds.add(id);
7687
8063
  const style = readStyle(el, rootStyle);
7688
8064
  const nodes2 = el.name === "symbol" ? visit2(el, style, IDENTITY_MATRIX) : visitOne({ ...el, attrs: { ...el.attrs, transform: "" } }, rootStyle, parseSvgTransform(el.attrs.transform));
7689
- symbols.push({ id, name: typeof _optionalChain([own, 'optionalAccess', _215 => _215.name]) === "string" && own.name ? own.name : _nullishCoalesce(el.attrs.id, () => ( "Symbol")), nodes: nodes2 });
8065
+ symbols.push({ id, name: typeof _optionalChain([own, 'optionalAccess', _226 => _226.name]) === "string" && own.name ? own.name : _nullishCoalesce(el.attrs.id, () => ( "Symbol")), nodes: nodes2 });
7690
8066
  symbolOfElement.set(el, id);
7691
8067
  return id;
7692
8068
  };
@@ -7698,13 +8074,13 @@ function parseVectorSvg(svg, options = {}) {
7698
8074
  if (!symbolId) return null;
7699
8075
  const own = json2(el.attrs["data-vector-instance"]);
7700
8076
  const place2 = multiplyMatrices(translateMatrix(length(el.attrs.x), length(el.attrs.y)), m);
7701
- const node = { id: idFor(el), type: "instance", ...meta, symbolId, ..._optionalChain([own, 'optionalAccess', _216 => _216.scaleStrokes]) === false ? { scaleStrokes: false } : {}, ..._optionalChain([own, 'optionalAccess', _217 => _217.overrides]) ? { overrides: own.overrides } : {} };
8077
+ const node = { id: idFor(el), type: "instance", ...meta, symbolId, ..._optionalChain([own, 'optionalAccess', _227 => _227.scaleStrokes]) === false ? { scaleStrokes: false } : {}, ..._optionalChain([own, 'optionalAccess', _228 => _228.overrides]) ? { overrides: own.overrides } : {} };
7702
8078
  return isIdentityMatrix(place2) ? node : { ...node, transform: place2 };
7703
8079
  };
7704
8080
  const ownInstance = (g, m, meta) => {
7705
8081
  const raw = json2(g.attrs["data-vector-instance"]);
7706
8082
  if (!raw || typeof raw.symbolId !== "string") return null;
7707
- const sym2 = [...byId.values()].find((e) => e.name === "symbol" && _optionalChain([json2, 'call', _218 => _218(e.attrs["data-vector-symbol"]), 'optionalAccess', _219 => _219.id]) === raw.symbolId);
8083
+ const sym2 = [...byId.values()].find((e) => e.name === "symbol" && _optionalChain([json2, 'call', _229 => _229(e.attrs["data-vector-symbol"]), 'optionalAccess', _230 => _230.id]) === raw.symbolId);
7708
8084
  const symbolId = sym2 ? symbolFor(sym2) : raw.symbolId;
7709
8085
  if (!symbolId) return null;
7710
8086
  const t = Array.isArray(raw.transform) && raw.transform.length === 6 && raw.transform.every(Number.isFinite) ? raw.transform : IDENTITY_MATRIX;
@@ -7712,7 +8088,7 @@ function parseVectorSvg(svg, options = {}) {
7712
8088
  const drawn = g.children.find((c) => c.name === "g");
7713
8089
  const effects = sanitizeVectorEffects(raw.effects);
7714
8090
  const node = {
7715
- id: _nullishCoalesce(_optionalChain([drawn, 'optionalAccess', _220 => _220.attrs, 'access', _221 => _221.id]), () => ( idFor(g))),
8091
+ id: _nullishCoalesce(_optionalChain([drawn, 'optionalAccess', _231 => _231.attrs, 'access', _232 => _232.id]), () => ( idFor(g))),
7716
8092
  type: "instance",
7717
8093
  ...meta,
7718
8094
  symbolId,
@@ -7769,12 +8145,12 @@ function parseVectorSvg(svg, options = {}) {
7769
8145
  const masked = (el, nodes2, m) => {
7770
8146
  let out = nodes2;
7771
8147
  const clipEl = rawMasks.get(_nullishCoalesce(urlId(attrOrStyle(el, "clip-path")), () => ( "")));
7772
- if (_optionalChain([clipEl, 'optionalAccess', _222 => _222.name]) === "clipPath") {
8148
+ if (_optionalChain([clipEl, 'optionalAccess', _233 => _233.name]) === "clipPath") {
7773
8149
  const source = maskNode(clipEl, m, out, clipEl.attrs.clipPathUnits);
7774
8150
  if (source) out = [{ id: idFor({ name: "g", attrs: {}, children: [] }), type: "group", name: "Clip Group", mask: { type: "clip" }, children: [source, ...out] }];
7775
8151
  }
7776
8152
  const maskEl = rawMasks.get(_nullishCoalesce(urlId(attrOrStyle(el, "mask")), () => ( "")));
7777
- if (_optionalChain([maskEl, 'optionalAccess', _223 => _223.name]) === "mask") {
8153
+ if (_optionalChain([maskEl, 'optionalAccess', _234 => _234.name]) === "mask") {
7778
8154
  const source = maskNode(maskEl, m, out, maskEl.attrs.maskContentUnits);
7779
8155
  const type = attrOrStyle(maskEl, "mask-type") === "alpha" ? "alpha" : "luminance";
7780
8156
  if (source) out = [{ id: idFor({ name: "g", attrs: {}, children: [] }), type: "group", name: "Opacity Mask", mask: { type }, children: [source, ...out] }];
@@ -7796,19 +8172,19 @@ function parseVectorSvg(svg, options = {}) {
7796
8172
  let sourceEl = part("mask-source");
7797
8173
  if (!sourceEl) {
7798
8174
  const el = rawMasks.get(_nullishCoalesce(urlId(maskedEl.attrs.mask), () => ( "")));
7799
- const invert2 = _optionalChain([el, 'optionalAccess', _224 => _224.children, 'access', _225 => _225.find, 'call', _226 => _226((c) => c.name === "g" && c.attrs["data-vector-part"] === "mask-invert")]);
8175
+ const invert2 = _optionalChain([el, 'optionalAccess', _235 => _235.children, 'access', _236 => _236.find, 'call', _237 => _237((c) => c.name === "g" && c.attrs["data-vector-part"] === "mask-invert")]);
7800
8176
  sourceEl = _nullishCoalesce(invert2, () => ( el));
7801
8177
  }
7802
8178
  const source = sourceEl ? visit2(sourceEl, style, m)[0] : void 0;
7803
8179
  let contents = visit2(maskedEl, style, m);
7804
8180
  let effects;
7805
8181
  const wrapper = contents.length === 1 && contents[0].type === "group" && contents[0].id === `${id}~content` ? contents[0] : null;
7806
- if (_optionalChain([wrapper, 'optionalAccess', _227 => _227.type]) === "group") {
8182
+ if (_optionalChain([wrapper, 'optionalAccess', _238 => _238.type]) === "group") {
7807
8183
  effects = _nullishCoalesce(wrapper.effects, () => ( void 0));
7808
8184
  contents = wrapper.children;
7809
8185
  }
7810
8186
  if (!source) return contents.length ? { id, type: "group", ...meta, children: contents } : null;
7811
- return { id, type: "group", ...meta, mask, ..._optionalChain([effects, 'optionalAccess', _228 => _228.length]) ? { effects } : {}, children: [source, ...contents] };
8187
+ return { id, type: "group", ...meta, mask, ..._optionalChain([effects, 'optionalAccess', _239 => _239.length]) ? { effects } : {}, children: [source, ...contents] };
7812
8188
  };
7813
8189
  const frameGroup = (g, style, m, meta) => {
7814
8190
  const raw = parseJson(g.attrs["data-vector-frame"]);
@@ -7820,7 +8196,7 @@ function parseVectorSvg(svg, options = {}) {
7820
8196
  const { rigid, residual } = decomposeRigid(m);
7821
8197
  const r = _chunkXGD3FSNCcjs.bezierPathBounds.call(void 0, _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, subpathsToBezier(vectorFrameRectPath(frame)), residual));
7822
8198
  const back = invertMatrix(rigid);
7823
- const effects = sanitizeVectorEffects(_optionalChain([raw, 'optionalAccess', _229 => _229.effects]));
8199
+ const effects = sanitizeVectorEffects(_optionalChain([raw, 'optionalAccess', _240 => _240.effects]));
7824
8200
  return {
7825
8201
  id,
7826
8202
  type: "group",
@@ -7917,7 +8293,7 @@ function parseVectorSvg(svg, options = {}) {
7917
8293
  type: "path",
7918
8294
  ...meta,
7919
8295
  subpaths,
7920
- fill: child.name === "line" ? null : paint(s.fill),
8296
+ fill: child.name === "line" ? null : _nullishCoalesce(sanitizeVectorShadedPaint(parseJson(child.attrs["data-vector-shading"])), () => ( paint(s.fill))),
7921
8297
  stroke: paint(s.stroke),
7922
8298
  ...strokeStyle(s)
7923
8299
  },
@@ -8284,13 +8660,13 @@ function hitTestVectorNode(node, p, tolerance = 0, parent = IDENTITY_MATRIX, opt
8284
8660
  }
8285
8661
  if (isVectorMaskGroup(node)) {
8286
8662
  const m = multiplyMatrices(nodeMatrix(node), parent);
8287
- const entered = !!_optionalChain([options, 'access', _230 => _230.entered, 'optionalAccess', _231 => _231.has, 'call', _232 => _232(node.id)]);
8663
+ const entered = !!_optionalChain([options, 'access', _241 => _241.entered, 'optionalAccess', _242 => _242.has, 'call', _243 => _243(node.id)]);
8288
8664
  if (!entered && isVectorMaskActive(node) && !vectorMaskContains(node, applyMatrix(invertMatrix(m), p), tolerance)) return false;
8289
8665
  const shown = !entered && hasOwnVectorAppearance(node) ? expandVectorAppearance(node).children : node.children;
8290
8666
  for (let i = shown.length - 1; i >= 1; i--) if (hitTestVectorNode(shown[i], p, tolerance, m, options)) return true;
8291
8667
  return entered && hitTestVectorMaskSource(node, p, tolerance, m, options);
8292
8668
  }
8293
- if (!(node.type === "group" && (!hasOwnVectorAppearance(node) || _optionalChain([options, 'access', _233 => _233.entered, 'optionalAccess', _234 => _234.has, 'call', _235 => _235(node.id)])))) node = expandVectorAppearance(node);
8669
+ if (!(node.type === "group" && (!hasOwnVectorAppearance(node) || _optionalChain([options, 'access', _244 => _244.entered, 'optionalAccess', _245 => _245.has, 'call', _246 => _246(node.id)])))) node = expandVectorAppearance(node);
8294
8670
  if (node.type === "group") {
8295
8671
  const m = multiplyMatrices(nodeMatrix(node), parent);
8296
8672
  return node.children.some((c) => hitTestVectorNode(c, p, tolerance, m, options));
@@ -8302,7 +8678,7 @@ function hitTestVectorNode(node, p, tolerance = 0, parent = IDENTITY_MATRIX, opt
8302
8678
  function hitTestVectorMaskSource(group, p, tolerance, m, options) {
8303
8679
  const source = group.children[0];
8304
8680
  if (source.visible === false) return false;
8305
- if (_optionalChain([group, 'access', _236 => _236.mask, 'optionalAccess', _237 => _237.type]) !== "clip") return hitTestVectorNode(source, p, tolerance, m, options);
8681
+ if (_optionalChain([group, 'access', _247 => _247.mask, 'optionalAccess', _248 => _248.type]) !== "clip") return hitTestVectorNode(source, p, tolerance, m, options);
8306
8682
  const paths = collectPathNodes(source).filter((n) => n.visible !== false);
8307
8683
  const pt2 = [p.x, p.y];
8308
8684
  return paths.some((n) => {
@@ -8351,30 +8727,30 @@ function mapAnchor(a, m) {
8351
8727
  }
8352
8728
  function bakeIntoGeometry(node, m) {
8353
8729
  if (isIdentityMatrix(m)) return node;
8354
- if (_optionalChain([node, 'access', _238 => _238.effects, 'optionalAccess', _239 => _239.length])) node = { ...node, effects: transformVectorEffects(node.effects, m, node) };
8730
+ if (_optionalChain([node, 'access', _249 => _249.effects, 'optionalAccess', _250 => _250.length])) node = { ...node, effects: transformVectorEffects(node.effects, m, node) };
8355
8731
  if (isVectorFrame(node)) return bakeFrame(node, m);
8356
8732
  if (node.type === "group") {
8357
8733
  const group = node;
8358
8734
  const children = group.children.map((c) => transformVectorNode(c, m));
8359
- const spine = _optionalChain([group, 'access', _240 => _240.blend, 'optionalAccess', _241 => _241.spine]);
8735
+ const spine = _optionalChain([group, 'access', _251 => _251.blend, 'optionalAccess', _252 => _252.spine]);
8360
8736
  if (!spine) return { ...group, children };
8361
8737
  const moved = { closed: spine.closed, anchors: spine.anchors.map((a) => mapAnchor(a, m)) };
8362
8738
  return { ...group, children, blend: { ...group.blend, spine: moved } };
8363
8739
  }
8364
8740
  const path = node.type === "text" ? bakeVectorTextGeometry(node, m) : node;
8365
8741
  const flips = m[0] * m[3] - m[1] * m[2] < 0;
8366
- const mirrored = flips && _optionalChain([path, 'access', _242 => _242.strokeWidthProfile, 'optionalAccess', _243 => _243.length]);
8742
+ const mirrored = flips && _optionalChain([path, 'access', _253 => _253.strokeWidthProfile, 'optionalAccess', _254 => _254.length]);
8367
8743
  const layer = (l) => ({
8368
8744
  ...l,
8369
- ...isVectorGradient(l.paint) ? { paint: transformVectorPaint(l.paint, m) } : {},
8370
- ...flips && _optionalChain([l, 'access', _244 => _244.strokeWidthProfile, 'optionalAccess', _245 => _245.length]) ? { strokeWidthProfile: mirrorWidthProfile(l.strokeWidthProfile) } : {}
8745
+ ...isVectorGradient(l.paint) || isVectorShadedPaint(l.paint) ? { paint: transformVectorPaint(l.paint, m) } : {},
8746
+ ...flips && _optionalChain([l, 'access', _255 => _255.strokeWidthProfile, 'optionalAccess', _256 => _256.length]) ? { strokeWidthProfile: mirrorWidthProfile(l.strokeWidthProfile) } : {}
8371
8747
  });
8372
8748
  return {
8373
8749
  ...path,
8374
8750
  ...mirrored ? { strokeWidthProfile: mirrorWidthProfile(path.strokeWidthProfile) } : {},
8375
8751
  // Gradients in the node's own space move with its geometry.
8376
- ...isVectorGradient(path.fill) ? { fill: transformVectorPaint(path.fill, m) } : {},
8377
- ...isVectorGradient(path.stroke) ? { stroke: transformVectorPaint(path.stroke, m) } : {},
8752
+ ...isVectorGradient(path.fill) || isVectorShadedPaint(path.fill) ? { fill: transformVectorPaint(path.fill, m) } : {},
8753
+ ...isVectorGradient(path.stroke) || isVectorShadedPaint(path.stroke) ? { stroke: transformVectorPaint(path.stroke, m) } : {},
8378
8754
  ...Array.isArray(path.fills) ? { fills: path.fills.map(layer) } : {},
8379
8755
  ...Array.isArray(path.strokes) ? { strokes: path.strokes.map(layer) } : {},
8380
8756
  ...path.type === "path" ? {
@@ -8662,8 +9038,8 @@ var Measured = class {
8662
9038
  append(sa, sb, out) {
8663
9039
  for (const piece of _chunkXGD3FSNCcjs.trimSegments.call(void 0, this.segs, sa, sb, this.lens)) {
8664
9040
  if (degenerate2(piece)) continue;
8665
- const last = _optionalChain([out, 'access', _246 => _246[out.length - 1], 'optionalAccess', _247 => _247.segs]);
8666
- const end = _optionalChain([last, 'optionalAccess', _248 => _248[last.length - 1], 'optionalAccess', _249 => _249.at, 'call', _250 => _250(-1)]);
9041
+ const last = _optionalChain([out, 'access', _257 => _257[out.length - 1], 'optionalAccess', _258 => _258.segs]);
9042
+ const end = _optionalChain([last, 'optionalAccess', _259 => _259[last.length - 1], 'optionalAccess', _260 => _260.at, 'call', _261 => _261(-1)]);
8667
9043
  if (!end || Math.hypot(end[0] - piece[0][0], end[1] - piece[0][1]) > 1e-6) out.push({ segs: [piece], closed: false });
8668
9044
  else last.push(piece);
8669
9045
  }
@@ -8957,9 +9333,9 @@ function vectorRepeaterCopies(r, pivot) {
8957
9333
  for (let i = 0; i < n; i++) {
8958
9334
  const k = i + offset;
8959
9335
  let m = translateMatrix(-pivot.x, -pivot.y);
8960
- m = multiplyMatrices(m, scaleMatrix(Math.pow((_nullishCoalesce(_optionalChain([r, 'access', _251 => _251.scale, 'optionalAccess', _252 => _252.x]), () => ( 100))) / 100, k), Math.pow((_nullishCoalesce(_optionalChain([r, 'access', _253 => _253.scale, 'optionalAccess', _254 => _254.y]), () => ( 100))) / 100, k)));
9336
+ m = multiplyMatrices(m, scaleMatrix(Math.pow((_nullishCoalesce(_optionalChain([r, 'access', _262 => _262.scale, 'optionalAccess', _263 => _263.x]), () => ( 100))) / 100, k), Math.pow((_nullishCoalesce(_optionalChain([r, 'access', _264 => _264.scale, 'optionalAccess', _265 => _265.y]), () => ( 100))) / 100, k)));
8961
9337
  m = multiplyMatrices(m, rotateMatrix((_nullishCoalesce(r.rotation, () => ( 0))) * k));
8962
- m = multiplyMatrices(m, translateMatrix(pivot.x + (_nullishCoalesce(_optionalChain([r, 'access', _255 => _255.position, 'optionalAccess', _256 => _256.x]), () => ( 0))) * k, pivot.y + (_nullishCoalesce(_optionalChain([r, 'access', _257 => _257.position, 'optionalAccess', _258 => _258.y]), () => ( 0))) * k));
9338
+ m = multiplyMatrices(m, translateMatrix(pivot.x + (_nullishCoalesce(_optionalChain([r, 'access', _266 => _266.position, 'optionalAccess', _267 => _267.x]), () => ( 0))) * k, pivot.y + (_nullishCoalesce(_optionalChain([r, 'access', _268 => _268.position, 'optionalAccess', _269 => _269.y]), () => ( 0))) * k));
8963
9339
  const t = n > 1 ? i / (n - 1) : 0;
8964
9340
  const partial = i + 1 === n && fract > 0 ? fract : 1;
8965
9341
  out.push({ index: i, matrix: m, opacity: Math.min(1, Math.max(0, (so + (eo - so) * t) * partial)) });
@@ -9397,5 +9773,25 @@ function pathsCenter(paths) {
9397
9773
 
9398
9774
 
9399
9775
 
9400
- exports.VECTOR_CORNER_KINDS = VECTOR_CORNER_KINDS; exports.VECTOR_GRADIENT_TYPES = VECTOR_GRADIENT_TYPES; exports.VECTOR_GRADIENT_SPREADS = VECTOR_GRADIENT_SPREADS; exports.VECTOR_GRADIENT_INTERPOLATIONS = VECTOR_GRADIENT_INTERPOLATIONS; exports.VECTOR_STROKE_GRADIENT_MODES = VECTOR_STROKE_GRADIENT_MODES; exports.VECTOR_ARROWHEADS = VECTOR_ARROWHEADS; exports.VECTOR_BLEND_MODES = VECTOR_BLEND_MODES; exports.VECTOR_HORIZONTAL_RESIZING = VECTOR_HORIZONTAL_RESIZING; exports.VECTOR_VERTICAL_RESIZING = VECTOR_VERTICAL_RESIZING; exports.VECTOR_CONNECTOR_SIDES = VECTOR_CONNECTOR_SIDES; exports.VECTOR_CONNECTOR_ROUTES = VECTOR_CONNECTOR_ROUTES; exports.VECTOR_BLEND_SPACINGS = VECTOR_BLEND_SPACINGS; exports.VECTOR_MASK_TYPES = VECTOR_MASK_TYPES; exports.VECTOR_TEXT_ALIGNS = VECTOR_TEXT_ALIGNS; exports.VECTOR_PATH_TEXT_BASELINES = VECTOR_PATH_TEXT_BASELINES; exports.VECTOR_CONSTRAINT_KINDS = VECTOR_CONSTRAINT_KINDS; exports.VECTOR_TOOLS = VECTOR_TOOLS; exports.VECTOR_TRANSFORM_HANDLES = VECTOR_TRANSFORM_HANDLES; exports.VECTOR_PATHFINDER_OPERATIONS = VECTOR_PATHFINDER_OPERATIONS; exports.VECTOR_EFFECT_TYPES = VECTOR_EFFECT_TYPES; exports.VECTOR_MERGE_MODES = VECTOR_MERGE_MODES; exports.VECTOR_FILTER_TYPES = VECTOR_FILTER_TYPES; exports.isVectorGradient = isVectorGradient; exports.parseVectorColor = parseVectorColor; exports.VECTOR_GRADIENT_MIN_STOPS = VECTOR_GRADIENT_MIN_STOPS; exports.gradientMidpointRemap = gradientMidpointRemap; exports.sortedVectorGradientStops = sortedVectorGradientStops; exports.vectorGradientNeedsExpansion = vectorGradientNeedsExpansion; exports.vectorGradientRamp = vectorGradientRamp; exports.sampleVectorGradient = sampleVectorGradient; exports.expandVectorGradientStops = expandVectorGradientStops; exports.samplePlainStops = samplePlainStops; exports.reverseVectorGradient = reverseVectorGradient; exports.insertVectorGradientStop = insertVectorGradientStop; exports.moveVectorGradientStop = moveVectorGradientStop; exports.removeVectorGradientStop = removeVectorGradientStop; exports.vectorGradientMidpointPosition = vectorGradientMidpointPosition; exports.vectorGradientMidpointFromPosition = vectorGradientMidpointFromPosition; exports.spanVectorGradientStops = spanVectorGradientStops; exports.hasExplicitGradientGeometry = hasExplicitGradientGeometry; exports.vectorGradientPoints = vectorGradientPoints; exports.vectorBoxMatrix = vectorBoxMatrix; exports.vectorGradientUnitsMatrix = vectorGradientUnitsMatrix; exports.vectorGradientMatrix = vectorGradientMatrix; exports.vectorGradientFocalParam = vectorGradientFocalParam; exports.vectorGradientParam = vectorGradientParam; exports.applyVectorGradientSpread = applyVectorGradientSpread; exports.vectorGradientTAt = vectorGradientTAt; exports.sampleVectorGradientAt = sampleVectorGradientAt; exports.vectorGradientAspect = vectorGradientAspect; exports.explicitVectorGradient = explicitVectorGradient; exports.pinVectorGradient = pinVectorGradient; exports.transformVectorGradient = transformVectorGradient; exports.mapVectorGradient = mapVectorGradient; exports.mapVectorPaint = mapVectorPaint; exports.transformVectorPaint = transformVectorPaint; exports.isCentredVectorGradient = isCentredVectorGradient; exports.vectorGradientHandles = vectorGradientHandles; exports.moveVectorGradientHandle = moveVectorGradientHandle; exports.setVectorGradientVector = setVectorGradientVector; exports.VECTOR_GRADIENT_MAX_PERIODS = VECTOR_GRADIENT_MAX_PERIODS; exports.periodicVectorGradientStops = periodicVectorGradientStops; exports.expandVectorGradientSpread = expandVectorGradientSpread; exports.vectorGradientArea = vectorGradientArea; exports.patternAttrs = patternAttrs; exports.vectorGradientSvgDefs = vectorGradientSvgDefs; exports.sampleVectorPaintDefAt = sampleVectorPaintDefAt; exports.sanitizeVectorGradient = sanitizeVectorGradient; exports.convertVectorGradient = convertVectorGradient; exports.defaultVectorGradient = defaultVectorGradient; exports.applyVectorGradientPatch = applyVectorGradientPatch; exports.IDENTITY_MATRIX = IDENTITY_MATRIX; exports.multiplyMatrices = multiplyMatrices; exports.translateMatrix = translateMatrix; exports.scaleMatrix = scaleMatrix; exports.rotateMatrix = rotateMatrix; exports.matrixAbout = matrixAbout; exports.skewMatrix = skewMatrix; exports.applyMatrix = applyMatrix; exports.isIdentityMatrix = isIdentityMatrix; exports.invertMatrix = invertMatrix; exports.applyMatrixLinear = applyMatrixLinear; exports.matrixRotation = matrixRotation; exports.decomposeRigid = decomposeRigid; exports.vectorCornerAt = vectorCornerAt; exports.vectorCorners = vectorCorners; exports.cornerSetback = cornerSetback; exports.fitCornerRadius = fitCornerRadius; exports.cornerBisectorPoint = cornerBisectorPoint; exports.cornerRadiusChange = cornerRadiusChange; exports.hasVectorCorners = hasVectorCorners; exports.expandVectorCornersOf = expandVectorCornersOf; exports.expandVectorCorners = expandVectorCorners; exports.setAnchorCorner = setAnchorCorner; exports.nextVectorCornerKind = nextVectorCornerKind; exports.setSubpathCorners = setSubpathCorners; exports.VECTOR_WIDTH_PROFILE_MAX_POINTS = VECTOR_WIDTH_PROFILE_MAX_POINTS; exports.VECTOR_WIDTH_PROFILE_MAX_SCALE = VECTOR_WIDTH_PROFILE_MAX_SCALE; exports.VECTOR_WIDTH_SAME_T = VECTOR_WIDTH_SAME_T; exports.VECTOR_WIDTH_PRESETS = VECTOR_WIDTH_PRESETS; exports.VECTOR_WIDTH_PRESET_IDS = VECTOR_WIDTH_PRESET_IDS; exports.sanitizeWidthProfile = sanitizeWidthProfile; exports.isUniformWidthProfile = isUniformWidthProfile; exports.widthProfileAt = widthProfileAt; exports.widthProfileMaxScale = widthProfileMaxScale; exports.widthProfilePreset = widthProfilePreset; exports.widthProfilePresetId = widthProfilePresetId; exports.reverseWidthProfile = reverseWidthProfile; exports.mirrorWidthProfile = mirrorWidthProfile; exports.insertWidthPoint = insertWidthPoint; exports.setWidthPoint = setWidthPoint; exports.removeWidthPoints = removeWidthPoints; exports.taperWaveFactor = taperWaveFactor; exports.generateWidthProfile = generateWidthProfile; exports.VECTOR_PRESSURE_NOMINAL = VECTOR_PRESSURE_NOMINAL; exports.pressureWidthProfile = pressureWidthProfile; exports.dashIntervals = dashIntervals; exports.variableStrokeRings = variableStrokeRings; exports.variableStrokeOutline = variableStrokeOutline; exports.nearestStrokePosition = nearestStrokePosition; exports.strokePositionPoint = strokePositionPoint; exports.isClosedBezierShape = isClosedBezierShape; exports.effectiveStrokeAlign = effectiveStrokeAlign; exports.strokeWidthProfileOf = strokeWidthProfileOf; exports.hasStrokeExtras = hasStrokeExtras; exports.vectorStrokeLineArea = vectorStrokeLineArea; exports.arrowheadWeight = arrowheadWeight; exports.arrowheadInset = arrowheadInset; exports.arrowheadPath = arrowheadPath; exports.vectorStrokeParts = vectorStrokeParts; exports.vectorStrokeOutlinePath = vectorStrokeOutlinePath; exports.hitTestVectorStroke = hitTestVectorStroke; exports.vectorStrokeReach = vectorStrokeReach; exports.VECTOR_STROKE_SETTING_KEYS = VECTOR_STROKE_SETTING_KEYS; exports.VECTOR_BLEND_MODE_LABELS = VECTOR_BLEND_MODE_LABELS; exports.isVectorBlendMode = isVectorBlendMode; exports.vectorBlendModeCss = vectorBlendModeCss; exports.vectorBlendModeFromCss = vectorBlendModeFromCss; exports.isPlainVectorPaintLayer = isPlainVectorPaintLayer; exports.isDrawnVectorPaintLayer = isDrawnVectorPaintLayer; exports.vectorFills = vectorFills; exports.vectorStrokeSettings = vectorStrokeSettings; exports.vectorStrokes = vectorStrokes; exports.hasVectorPaintStacks = hasVectorPaintStacks; exports.withVectorFills = withVectorFills; exports.withVectorStrokes = withVectorStrokes; exports.normalizeVectorPaintStacks = normalizeVectorPaintStacks; exports.sanitizeVectorFills = sanitizeVectorFills; exports.sanitizeVectorStrokeSettings = sanitizeVectorStrokeSettings; exports.sanitizeVectorStrokes = sanitizeVectorStrokes; exports.vectorPaintLayerNodes = vectorPaintLayerNodes; exports.needsVectorPaintLayers = needsVectorPaintLayers; exports.vectorStrokeStackReach = vectorStrokeStackReach; exports.hitTestVectorPaintLayer = hitTestVectorPaintLayer; exports.hitTestVectorPaintStack = hitTestVectorPaintStack; exports.vectorStacksHaveGradient = vectorStacksHaveGradient; exports.newVectorStrokeLayer = newVectorStrokeLayer; exports.vectorTargetPaint = vectorTargetPaint; exports.withVectorTargetPaint = withVectorTargetPaint; exports.effectPathLength = effectPathLength; exports.effectPathVertexCount = effectPathVertexCount; exports.trimIntervals = trimIntervals; exports.trimPaths = trimPaths; exports.trimPathsIndividually = trimPathsIndividually; exports.puckerBloatPaths = puckerBloatPaths; exports.roundCornerPaths = roundCornerPaths; exports.offsetPaths = offsetPaths; exports.twistPaths = twistPaths; exports.zigzagPaths = zigzagPaths; exports.wigglePaths = wigglePaths; exports.mergePaths = mergePaths; exports.vectorRepeaterCopies = vectorRepeaterCopies; exports.repeatPaths = repeatPaths; exports.pathsCenter = pathsCenter; exports.mapVectorPoints = mapVectorPoints; exports.mapVectorSubpaths = mapVectorSubpaths; exports.mapBezierPath = mapBezierPath; exports.isVectorFrame = isVectorFrame; exports.vectorFrameRectPath = vectorFrameRectPath; exports.vectorFrameDrawn = vectorFrameDrawn; exports.vectorFrameContains = vectorFrameContains; exports.vectorFrameChildMatrix = vectorFrameChildMatrix; exports.sanitizeVectorFrame = sanitizeVectorFrame; exports.sanitizeVectorResizing = sanitizeVectorResizing; exports.VECTOR_HORIZONTAL_RESIZING_LABELS = VECTOR_HORIZONTAL_RESIZING_LABELS; exports.VECTOR_VERTICAL_RESIZING_LABELS = VECTOR_VERTICAL_RESIZING_LABELS; exports.vectorBoundsInside = vectorBoundsInside; exports.vectorArtboards = vectorArtboards; exports.vectorFrameDocument = vectorFrameDocument; exports.getVectorFramePanel = getVectorFramePanel; exports.splitIntoFaces = splitIntoFaces; exports.knifePath = knifePath; exports.eraserRegion = eraserRegion; exports.eraseFromFill = eraseFromFill; exports.eraseFromOutline = eraseFromOutline; exports.polylineBounds = polylineBounds; exports.simplifyPolyline = simplifyPolyline; exports.VECTOR_FILTER_DEFAULTS = VECTOR_FILTER_DEFAULTS; exports.VECTOR_FILTER_LABELS = VECTOR_FILTER_LABELS; exports.VECTOR_FILTER_PARAM_SPECS = VECTOR_FILTER_PARAM_SPECS; exports.isVectorFilterType = isVectorFilterType; exports.normalizeVectorFilterParams = normalizeVectorFilterParams; exports.vectorFilterParamKeys = vectorFilterParamKeys; exports.createVectorFilter = createVectorFilter; exports.sanitizeVectorFilters = sanitizeVectorFilters; exports.activeVectorFilters = activeVectorFilters; exports.vectorFilterReach = vectorFilterReach; exports.vectorFilterSvg = vectorFilterSvg; exports.vectorFilterMarkup = vectorFilterMarkup; exports.VECTOR_FILTER_MENU = VECTOR_FILTER_MENU; exports.isVectorMaskType = isVectorMaskType; exports.sanitizeVectorMask = sanitizeVectorMask; exports.isVectorMaskGroup = isVectorMaskGroup; exports.isVectorMaskActive = isVectorMaskActive; exports.vectorMaskSource = vectorMaskSource; exports.vectorMaskContents = vectorMaskContents; exports.vectorMaskOwner = vectorMaskOwner; exports.vectorMaskSummary = vectorMaskSummary; exports.vectorMaskRegionShapes = vectorMaskRegionShapes; exports.vectorMaskRegion = vectorMaskRegion; exports.vectorMaskRegionPath = vectorMaskRegionPath; exports.vectorMaskContains = vectorMaskContains; exports.vectorMaskedShapes = vectorMaskedShapes; exports.vectorMaskedGeometry = vectorMaskedGeometry; exports.vectorMaskedLocalBounds = vectorMaskedLocalBounds; exports.vectorMaskContentBounds = vectorMaskContentBounds; exports.vectorMaskRenderData = vectorMaskRenderData; exports.DEFAULT_TEXT_STYLE = DEFAULT_TEXT_STYLE; exports.DEFAULT_AUTO_LEADING = DEFAULT_AUTO_LEADING; exports.fitRuns = fitRuns; exports.styleAt = styleAt; exports.restyleRange = restyleRange; exports.spliceRuns = spliceRuns; exports.paragraphRanges = paragraphRanges; exports.fitParagraphRuns = fitParagraphRuns; exports.fontOf = fontOf; exports.isTextSpace = isTextSpace; exports.layoutText = layoutText; exports.textIndexAt = textIndexAt; exports.caretAt = caretAt; exports.textDecorations = textDecorations; exports.textRectPath = textRectPath; exports.textFragmentOutline = textFragmentOutline; exports.cssFontFamily = cssFontFamily; exports.cssFont = cssFont; exports.createCanvasTextShaper = createCanvasTextShaper; exports.createOutlineTextShaper = createOutlineTextShaper; exports.createMetricTextShaper = createMetricTextShaper; exports.setVectorTextShaper = setVectorTextShaper; exports.getVectorTextShaper = getVectorTextShaper; exports.vectorTextShaperGeneration = vectorTextShaperGeneration; exports.vectorTextHasOutlines = vectorTextHasOutlines; exports.vectorTextFamilies = vectorTextFamilies; exports.DEFAULT_VECTOR_FONT = DEFAULT_VECTOR_FONT; exports.VECTOR_CHARACTER_STYLE_KEYS = VECTOR_CHARACTER_STYLE_KEYS; exports.VECTOR_PARAGRAPH_STYLE_KEYS = VECTOR_PARAGRAPH_STYLE_KEYS; exports.VectorTextError = VectorTextError; exports.fitVectorTextRuns = fitVectorTextRuns; exports.vectorTextRuns = vectorTextRuns; exports.vectorTextStyleAt = vectorTextStyleAt; exports.measureVectorPath = measureVectorPath; exports.vectorPathAt = vectorPathAt; exports.vectorPathTextPositions = vectorPathTextPositions; exports.layoutVectorText = layoutVectorText; exports.glyphBox = glyphBox; exports.vectorTextPaths = vectorTextPaths; exports.vectorTextPaintSource = vectorTextPaintSource; exports.vectorTextCaret = vectorTextCaret; exports.vectorTextIndexAt = vectorTextIndexAt; exports.vectorTextSelectionQuads = vectorTextSelectionQuads; exports.patchVectorCharacterStyle = patchVectorCharacterStyle; exports.patchVectorParagraphStyle = patchVectorParagraphStyle; exports.sanitizeVectorTextFrame = sanitizeVectorTextFrame; exports.normalizeVectorTextRuns = normalizeVectorTextRuns; exports.sanitizeVectorTextFields = sanitizeVectorTextFields; exports.vectorTextRange = vectorTextRange; exports.replaceVectorText = replaceVectorText; exports.styleVectorText = styleVectorText; exports.bakeVectorTextGeometry = bakeVectorTextGeometry; exports.vectorTextName = vectorTextName; exports.pathTextFrameFromBezier = pathTextFrameFromBezier; exports.vectorTextBoxOutline = vectorTextBoxOutline; exports.vectorTextSpans = vectorTextSpans; exports.vectorTextGeometryNode = vectorTextGeometryNode; exports.vectorTextSpanSvg = vectorTextSpanSvg; exports.VECTOR_SYMBOL_MAX_DEPTH = VECTOR_SYMBOL_MAX_DEPTH; exports.vectorSymbolsUsedIn = vectorSymbolsUsedIn; exports.vectorSymbolUses = vectorSymbolUses; exports.resolveVectorSymbols = resolveVectorSymbols; exports.stripVectorSymbolArt = stripVectorSymbolArt; exports.scaleVectorStrokeWidths = scaleVectorStrokeWidths; exports.tintVectorNode = tintVectorNode; exports.prefixVectorIds = prefixVectorIds; exports.vectorInstanceGroup = vectorInstanceGroup; exports.composeVectorMatrices = composeVectorMatrices; exports.WARP_STYLES = WARP_STYLES; exports.WARP_STYLE_LABELS = WARP_STYLE_LABELS; exports.warpPresetGrid = warpPresetGrid; exports.warpPresetMesh = warpPresetMesh; exports.warpMeshColumns = warpMeshColumns; exports.warpMeshRows = warpMeshRows; exports.isValidWarpMesh = isValidWarpMesh; exports.fitWarpMesh = fitWarpMesh; exports.identityWarpMesh = identityWarpMesh; exports.evalWarpMesh = evalWarpMesh; exports.splitWarpMeshU = splitWarpMeshU; exports.splitWarpMeshV = splitWarpMeshV; exports.removeWarpMeshSplitU = removeWarpMeshSplitU; exports.removeWarpMeshSplitV = removeWarpMeshSplitV; exports.mapWarpMeshPoints = mapWarpMeshPoints; exports.resizeWarpMesh = resizeWarpMesh; exports.warpMeshControlBounds = warpMeshControlBounds; exports.warpMeshParamAt = warpMeshParamAt; exports.dragWarpMeshPoint = dragWarpMeshPoint; exports.pullWarpMesh = pullWarpMesh; exports.warpMeshEditPoints = warpMeshEditPoints; exports.warpMeshGridCurves = warpMeshGridCurves; exports.vectorMeshFromOutline = vectorMeshFromOutline; exports.vectorMeshOutline = vectorMeshOutline; exports.VECTOR_EFFECT_DEFAULTS = VECTOR_EFFECT_DEFAULTS; exports.VECTOR_EFFECT_LABELS = VECTOR_EFFECT_LABELS; exports.VECTOR_EFFECT_PARAM_SPECS = VECTOR_EFFECT_PARAM_SPECS; exports.vectorEnvelopeMesh = vectorEnvelopeMesh; exports.vectorEnvelopeMap = vectorEnvelopeMap; exports.normalizeVectorEffectParams = normalizeVectorEffectParams; exports.createVectorEffect = createVectorEffect; exports.activeVectorEffects = activeVectorEffects; exports.hasOwnVectorAppearance = hasOwnVectorAppearance; exports.hasVectorAppearance = hasVectorAppearance; exports.isVectorLiveBoolean = isVectorLiveBoolean; exports.vectorOperandOperation = vectorOperandOperation; exports.vectorLiveBooleanSteps = vectorLiveBooleanSteps; exports.clearVectorLiveBooleanCache = clearVectorLiveBooleanCache; exports.foldVectorBooleanOperands = foldVectorBooleanOperands; exports.applyVectorEffects = applyVectorEffects; exports.vectorInstanceDrawn = vectorInstanceDrawn; exports.vectorChildAppearanceShapes = vectorChildAppearanceShapes; exports.vectorEffectInputPaths = vectorEffectInputPaths; exports.vectorEffectInputBounds = vectorEffectInputBounds; exports.vectorNodeEnvelope = vectorNodeEnvelope; exports.vectorEnvelopeFrame = vectorEnvelopeFrame; exports.vectorAppearanceShapes = vectorAppearanceShapes; exports.vectorAppearanceOutline = vectorAppearanceOutline; exports.vectorAppearanceNodes = vectorAppearanceNodes; exports.expandVectorAppearance = expandVectorAppearance; exports.expandVectorAppearances = expandVectorAppearances; exports.sanitizeVectorEffects = sanitizeVectorEffects; exports.transformVectorEffects = transformVectorEffects; exports.vectorEnteredGroups = vectorEnteredGroups; exports.isVectorConnector = isVectorConnector; exports.vectorConnectionSites = vectorConnectionSites; exports.nearestVectorConnectionSite = nearestVectorConnectionSite; exports.vectorConnectorWorldAnchors = vectorConnectorWorldAnchors; exports.routeVectorConnector = routeVectorConnector; exports.rerouteVectorConnectors = rerouteVectorConnectors; exports.sanitizeVectorConnector = sanitizeVectorConnector; exports.VECTOR_CONNECTOR_ROUTE_LABELS = VECTOR_CONNECTOR_ROUTE_LABELS; exports.VECTOR_CONNECTOR_SIDE_LABELS = VECTOR_CONNECTOR_SIDE_LABELS; exports.getVectorConnectorPanel = getVectorConnectorPanel; exports.vectorConnectorTargetAt = vectorConnectorTargetAt; exports.vectorStrokeGradientDefs = vectorStrokeGradientDefs; exports.vectorCornersAttribute = vectorCornersAttribute; exports.applyVectorCornersAttribute = applyVectorCornersAttribute; exports.vectorPathLocalBounds = vectorPathLocalBounds; exports.vectorPaintToSvg = vectorPaintToSvg; exports.vectorStrokeSvgParts = vectorStrokeSvgParts; exports.vectorNodeLocalPaintBounds = vectorNodeLocalPaintBounds; exports.vectorNodeFilterSvg = vectorNodeFilterSvg; exports.widthProfileToAttribute = widthProfileToAttribute; exports.widthProfileFromAttribute = widthProfileFromAttribute; exports.vectorDocumentToSvg = vectorDocumentToSvg; exports.parseSvgTransform = parseSvgTransform; exports.parseVectorSvg = parseVectorSvg; exports.VECTOR_SPATIAL_MIN = VECTOR_SPATIAL_MIN; exports.VectorRTree = VectorRTree; exports.vectorNodePaintBox = vectorNodePaintBox; exports.vectorSpatialIndex = vectorSpatialIndex; exports.vectorNodesNear = vectorNodesNear; exports.cloneAnchor = cloneAnchor; exports.cloneSubpath = cloneSubpath; exports.cloneVectorNode = cloneVectorNode; exports.cloneVectorDocument = cloneVectorDocument; exports.hasPaint = hasPaint; exports.subpathSegmentCount = subpathSegmentCount; exports.subpathSegment = subpathSegment; exports.subpathsToBezier = subpathsToBezier; exports.vectorNodeToBezier = vectorNodeToBezier; exports.vectorPathData = vectorPathData; exports.inferAnchorType = inferAnchorType; exports.bezierToSubpaths = bezierToSubpaths; exports.walkVectorNodes = walkVectorNodes; exports.findVectorNode = findVectorNode; exports.locateVectorNode = locateVectorNode; exports.collectPaintedNodes = collectPaintedNodes; exports.collectPathNodes = collectPathNodes; exports.nodeMatrix = nodeMatrix; exports.vectorPathWorldBezier = vectorPathWorldBezier; exports.vectorNodeBounds = vectorNodeBounds; exports.unionBounds = unionBounds; exports.boundsIntersect = boundsIntersect; exports.boundsFromPoints = boundsFromPoints; exports.hitTestVectorNode = hitTestVectorNode; exports.vectorStrokeOutline = vectorStrokeOutline; exports.hitTestVectorNodes = hitTestVectorNodes; exports.nearestSegment = nearestSegment; exports.transformVectorNode = transformVectorNode; exports.vectorNodeRotation = vectorNodeRotation; exports.vectorWorldMatrix = vectorWorldMatrix; exports.vectorParentMatrix = vectorParentMatrix; exports.translateAnchor = translateAnchor; exports.moveAnchorHandle = moveAnchorHandle; exports.convertAnchor = convertAnchor; exports.insertAnchor = insertAnchor; exports.removeAnchors = removeAnchors; exports.reverseSubpath = reverseSubpath; exports.KAPPA = KAPPA2; exports.rectSubpath = rectSubpath; exports.ellipseSubpath = ellipseSubpath; exports.polygonSubpath = polygonSubpath; exports.starSubpath = starSubpath; exports.lineSubpath = lineSubpath; exports.roundSubpaths = roundSubpaths;
9401
- //# sourceMappingURL=chunk-LPLCWZTM.cjs.map
9776
+
9777
+
9778
+
9779
+
9780
+
9781
+
9782
+
9783
+
9784
+
9785
+
9786
+
9787
+
9788
+
9789
+
9790
+
9791
+
9792
+
9793
+
9794
+
9795
+
9796
+ exports.isVectorMeshGradient = isVectorMeshGradient; exports.isVectorFreeformGradient = isVectorFreeformGradient; exports.isVectorShadedPaint = isVectorShadedPaint; exports.vectorRgbaToCss = vectorRgbaToCss; exports.VECTOR_MESH_MAX = VECTOR_MESH_MAX; exports.createVectorMeshGradient = createVectorMeshGradient; exports.vectorMeshPointAt = vectorMeshPointAt; exports.vectorMeshColorAt = vectorMeshColorAt; exports.vectorMeshLines = vectorMeshLines; exports.vectorFreeformSpreadScale = vectorFreeformSpreadScale; exports.vectorFreeformLineSegments = vectorFreeformLineSegments; exports.vectorFreeformField = vectorFreeformField; exports.sampleVectorFreeform = sampleVectorFreeform; exports.autoVectorFreeformGradient = autoVectorFreeformGradient; exports.vectorShadedSvgDefs = vectorShadedSvgDefs; exports.mapVectorShadedPaint = mapVectorShadedPaint; exports.transformVectorShadedPaint = transformVectorShadedPaint; exports.sanitizeVectorShadedPaint = sanitizeVectorShadedPaint; exports.removeVectorFreeformPoint = removeVectorFreeformPoint; exports.nearestVectorShadingPoint = nearestVectorShadingPoint; exports.VECTOR_CORNER_KINDS = VECTOR_CORNER_KINDS; exports.VECTOR_GRADIENT_TYPES = VECTOR_GRADIENT_TYPES; exports.VECTOR_GRADIENT_SPREADS = VECTOR_GRADIENT_SPREADS; exports.VECTOR_GRADIENT_INTERPOLATIONS = VECTOR_GRADIENT_INTERPOLATIONS; exports.VECTOR_STROKE_GRADIENT_MODES = VECTOR_STROKE_GRADIENT_MODES; exports.VECTOR_ARROWHEADS = VECTOR_ARROWHEADS; exports.VECTOR_BLEND_MODES = VECTOR_BLEND_MODES; exports.VECTOR_HORIZONTAL_RESIZING = VECTOR_HORIZONTAL_RESIZING; exports.VECTOR_VERTICAL_RESIZING = VECTOR_VERTICAL_RESIZING; exports.VECTOR_CONNECTOR_SIDES = VECTOR_CONNECTOR_SIDES; exports.VECTOR_CONNECTOR_ROUTES = VECTOR_CONNECTOR_ROUTES; exports.VECTOR_BLEND_SPACINGS = VECTOR_BLEND_SPACINGS; exports.VECTOR_MASK_TYPES = VECTOR_MASK_TYPES; exports.VECTOR_TEXT_ALIGNS = VECTOR_TEXT_ALIGNS; exports.VECTOR_PATH_TEXT_BASELINES = VECTOR_PATH_TEXT_BASELINES; exports.VECTOR_CONSTRAINT_KINDS = VECTOR_CONSTRAINT_KINDS; exports.VECTOR_TOOLS = VECTOR_TOOLS; exports.VECTOR_TRANSFORM_HANDLES = VECTOR_TRANSFORM_HANDLES; exports.VECTOR_PATHFINDER_OPERATIONS = VECTOR_PATHFINDER_OPERATIONS; exports.VECTOR_EFFECT_TYPES = VECTOR_EFFECT_TYPES; exports.VECTOR_MERGE_MODES = VECTOR_MERGE_MODES; exports.VECTOR_FILTER_TYPES = VECTOR_FILTER_TYPES; exports.isVectorGradient = isVectorGradient; exports.parseVectorColor = parseVectorColor; exports.VECTOR_GRADIENT_MIN_STOPS = VECTOR_GRADIENT_MIN_STOPS; exports.gradientMidpointRemap = gradientMidpointRemap; exports.sortedVectorGradientStops = sortedVectorGradientStops; exports.vectorGradientNeedsExpansion = vectorGradientNeedsExpansion; exports.vectorGradientRamp = vectorGradientRamp; exports.sampleVectorGradient = sampleVectorGradient; exports.expandVectorGradientStops = expandVectorGradientStops; exports.samplePlainStops = samplePlainStops; exports.reverseVectorGradient = reverseVectorGradient; exports.insertVectorGradientStop = insertVectorGradientStop; exports.moveVectorGradientStop = moveVectorGradientStop; exports.removeVectorGradientStop = removeVectorGradientStop; exports.vectorGradientMidpointPosition = vectorGradientMidpointPosition; exports.vectorGradientMidpointFromPosition = vectorGradientMidpointFromPosition; exports.spanVectorGradientStops = spanVectorGradientStops; exports.hasExplicitGradientGeometry = hasExplicitGradientGeometry; exports.vectorGradientPoints = vectorGradientPoints; exports.vectorBoxMatrix = vectorBoxMatrix; exports.vectorGradientUnitsMatrix = vectorGradientUnitsMatrix; exports.vectorGradientMatrix = vectorGradientMatrix; exports.vectorGradientFocalParam = vectorGradientFocalParam; exports.vectorGradientParam = vectorGradientParam; exports.applyVectorGradientSpread = applyVectorGradientSpread; exports.vectorGradientTAt = vectorGradientTAt; exports.sampleVectorGradientAt = sampleVectorGradientAt; exports.vectorGradientAspect = vectorGradientAspect; exports.explicitVectorGradient = explicitVectorGradient; exports.pinVectorGradient = pinVectorGradient; exports.transformVectorGradient = transformVectorGradient; exports.mapVectorGradient = mapVectorGradient; exports.mapVectorPaint = mapVectorPaint; exports.transformVectorPaint = transformVectorPaint; exports.isCentredVectorGradient = isCentredVectorGradient; exports.vectorGradientHandles = vectorGradientHandles; exports.moveVectorGradientHandle = moveVectorGradientHandle; exports.setVectorGradientVector = setVectorGradientVector; exports.VECTOR_GRADIENT_MAX_PERIODS = VECTOR_GRADIENT_MAX_PERIODS; exports.periodicVectorGradientStops = periodicVectorGradientStops; exports.expandVectorGradientSpread = expandVectorGradientSpread; exports.vectorGradientArea = vectorGradientArea; exports.patternAttrs = patternAttrs; exports.vectorGradientSvgDefs = vectorGradientSvgDefs; exports.sampleVectorPaintDefAt = sampleVectorPaintDefAt; exports.sanitizeVectorGradient = sanitizeVectorGradient; exports.convertVectorGradient = convertVectorGradient; exports.defaultVectorGradient = defaultVectorGradient; exports.applyVectorGradientPatch = applyVectorGradientPatch; exports.IDENTITY_MATRIX = IDENTITY_MATRIX; exports.multiplyMatrices = multiplyMatrices; exports.translateMatrix = translateMatrix; exports.scaleMatrix = scaleMatrix; exports.rotateMatrix = rotateMatrix; exports.matrixAbout = matrixAbout; exports.skewMatrix = skewMatrix; exports.applyMatrix = applyMatrix; exports.isIdentityMatrix = isIdentityMatrix; exports.invertMatrix = invertMatrix; exports.applyMatrixLinear = applyMatrixLinear; exports.matrixRotation = matrixRotation; exports.decomposeRigid = decomposeRigid; exports.vectorCornerAt = vectorCornerAt; exports.vectorCorners = vectorCorners; exports.cornerSetback = cornerSetback; exports.fitCornerRadius = fitCornerRadius; exports.cornerBisectorPoint = cornerBisectorPoint; exports.cornerRadiusChange = cornerRadiusChange; exports.hasVectorCorners = hasVectorCorners; exports.expandVectorCornersOf = expandVectorCornersOf; exports.expandVectorCorners = expandVectorCorners; exports.setAnchorCorner = setAnchorCorner; exports.nextVectorCornerKind = nextVectorCornerKind; exports.setSubpathCorners = setSubpathCorners; exports.VECTOR_WIDTH_PROFILE_MAX_POINTS = VECTOR_WIDTH_PROFILE_MAX_POINTS; exports.VECTOR_WIDTH_PROFILE_MAX_SCALE = VECTOR_WIDTH_PROFILE_MAX_SCALE; exports.VECTOR_WIDTH_SAME_T = VECTOR_WIDTH_SAME_T; exports.VECTOR_WIDTH_PRESETS = VECTOR_WIDTH_PRESETS; exports.VECTOR_WIDTH_PRESET_IDS = VECTOR_WIDTH_PRESET_IDS; exports.sanitizeWidthProfile = sanitizeWidthProfile; exports.isUniformWidthProfile = isUniformWidthProfile; exports.widthProfileAt = widthProfileAt; exports.widthProfileMaxScale = widthProfileMaxScale; exports.widthProfilePreset = widthProfilePreset; exports.widthProfilePresetId = widthProfilePresetId; exports.reverseWidthProfile = reverseWidthProfile; exports.mirrorWidthProfile = mirrorWidthProfile; exports.insertWidthPoint = insertWidthPoint; exports.setWidthPoint = setWidthPoint; exports.removeWidthPoints = removeWidthPoints; exports.taperWaveFactor = taperWaveFactor; exports.generateWidthProfile = generateWidthProfile; exports.VECTOR_PRESSURE_NOMINAL = VECTOR_PRESSURE_NOMINAL; exports.pressureWidthProfile = pressureWidthProfile; exports.dashIntervals = dashIntervals; exports.variableStrokeRings = variableStrokeRings; exports.variableStrokeOutline = variableStrokeOutline; exports.nearestStrokePosition = nearestStrokePosition; exports.strokePositionPoint = strokePositionPoint; exports.isClosedBezierShape = isClosedBezierShape; exports.effectiveStrokeAlign = effectiveStrokeAlign; exports.strokeWidthProfileOf = strokeWidthProfileOf; exports.hasStrokeExtras = hasStrokeExtras; exports.vectorStrokeLineArea = vectorStrokeLineArea; exports.arrowheadWeight = arrowheadWeight; exports.arrowheadInset = arrowheadInset; exports.arrowheadPath = arrowheadPath; exports.vectorStrokeParts = vectorStrokeParts; exports.vectorStrokeOutlinePath = vectorStrokeOutlinePath; exports.hitTestVectorStroke = hitTestVectorStroke; exports.vectorStrokeReach = vectorStrokeReach; exports.VECTOR_STROKE_SETTING_KEYS = VECTOR_STROKE_SETTING_KEYS; exports.VECTOR_BLEND_MODE_LABELS = VECTOR_BLEND_MODE_LABELS; exports.isVectorBlendMode = isVectorBlendMode; exports.vectorBlendModeCss = vectorBlendModeCss; exports.vectorBlendModeFromCss = vectorBlendModeFromCss; exports.isPlainVectorPaintLayer = isPlainVectorPaintLayer; exports.isDrawnVectorPaintLayer = isDrawnVectorPaintLayer; exports.vectorFills = vectorFills; exports.vectorStrokeSettings = vectorStrokeSettings; exports.vectorStrokes = vectorStrokes; exports.hasVectorPaintStacks = hasVectorPaintStacks; exports.withVectorFills = withVectorFills; exports.withVectorStrokes = withVectorStrokes; exports.normalizeVectorPaintStacks = normalizeVectorPaintStacks; exports.sanitizeVectorFills = sanitizeVectorFills; exports.sanitizeVectorStrokeSettings = sanitizeVectorStrokeSettings; exports.sanitizeVectorStrokes = sanitizeVectorStrokes; exports.vectorPaintLayerNodes = vectorPaintLayerNodes; exports.needsVectorPaintLayers = needsVectorPaintLayers; exports.vectorStrokeStackReach = vectorStrokeStackReach; exports.hitTestVectorPaintLayer = hitTestVectorPaintLayer; exports.hitTestVectorPaintStack = hitTestVectorPaintStack; exports.vectorStacksHaveGradient = vectorStacksHaveGradient; exports.newVectorStrokeLayer = newVectorStrokeLayer; exports.vectorTargetPaint = vectorTargetPaint; exports.withVectorTargetPaint = withVectorTargetPaint; exports.effectPathLength = effectPathLength; exports.effectPathVertexCount = effectPathVertexCount; exports.trimIntervals = trimIntervals; exports.trimPaths = trimPaths; exports.trimPathsIndividually = trimPathsIndividually; exports.puckerBloatPaths = puckerBloatPaths; exports.roundCornerPaths = roundCornerPaths; exports.offsetPaths = offsetPaths; exports.twistPaths = twistPaths; exports.zigzagPaths = zigzagPaths; exports.wigglePaths = wigglePaths; exports.mergePaths = mergePaths; exports.vectorRepeaterCopies = vectorRepeaterCopies; exports.repeatPaths = repeatPaths; exports.pathsCenter = pathsCenter; exports.mapVectorPoints = mapVectorPoints; exports.mapVectorSubpaths = mapVectorSubpaths; exports.mapBezierPath = mapBezierPath; exports.isVectorFrame = isVectorFrame; exports.vectorFrameRectPath = vectorFrameRectPath; exports.vectorFrameDrawn = vectorFrameDrawn; exports.vectorFrameContains = vectorFrameContains; exports.vectorFrameChildMatrix = vectorFrameChildMatrix; exports.sanitizeVectorFrame = sanitizeVectorFrame; exports.sanitizeVectorResizing = sanitizeVectorResizing; exports.VECTOR_HORIZONTAL_RESIZING_LABELS = VECTOR_HORIZONTAL_RESIZING_LABELS; exports.VECTOR_VERTICAL_RESIZING_LABELS = VECTOR_VERTICAL_RESIZING_LABELS; exports.vectorBoundsInside = vectorBoundsInside; exports.vectorArtboards = vectorArtboards; exports.vectorFrameDocument = vectorFrameDocument; exports.getVectorFramePanel = getVectorFramePanel; exports.splitIntoFaces = splitIntoFaces; exports.knifePath = knifePath; exports.eraserRegion = eraserRegion; exports.eraseFromFill = eraseFromFill; exports.eraseFromOutline = eraseFromOutline; exports.polylineBounds = polylineBounds; exports.simplifyPolyline = simplifyPolyline; exports.VECTOR_FILTER_DEFAULTS = VECTOR_FILTER_DEFAULTS; exports.VECTOR_FILTER_LABELS = VECTOR_FILTER_LABELS; exports.VECTOR_FILTER_PARAM_SPECS = VECTOR_FILTER_PARAM_SPECS; exports.isVectorFilterType = isVectorFilterType; exports.normalizeVectorFilterParams = normalizeVectorFilterParams; exports.vectorFilterParamKeys = vectorFilterParamKeys; exports.createVectorFilter = createVectorFilter; exports.sanitizeVectorFilters = sanitizeVectorFilters; exports.activeVectorFilters = activeVectorFilters; exports.vectorFilterReach = vectorFilterReach; exports.vectorFilterSvg = vectorFilterSvg; exports.vectorFilterMarkup = vectorFilterMarkup; exports.VECTOR_FILTER_MENU = VECTOR_FILTER_MENU; exports.isVectorMaskType = isVectorMaskType; exports.sanitizeVectorMask = sanitizeVectorMask; exports.isVectorMaskGroup = isVectorMaskGroup; exports.isVectorMaskActive = isVectorMaskActive; exports.vectorMaskSource = vectorMaskSource; exports.vectorMaskContents = vectorMaskContents; exports.vectorMaskOwner = vectorMaskOwner; exports.vectorMaskSummary = vectorMaskSummary; exports.vectorMaskRegionShapes = vectorMaskRegionShapes; exports.vectorMaskRegion = vectorMaskRegion; exports.vectorMaskRegionPath = vectorMaskRegionPath; exports.vectorMaskContains = vectorMaskContains; exports.vectorMaskedShapes = vectorMaskedShapes; exports.vectorMaskedGeometry = vectorMaskedGeometry; exports.vectorMaskedLocalBounds = vectorMaskedLocalBounds; exports.vectorMaskContentBounds = vectorMaskContentBounds; exports.vectorMaskRenderData = vectorMaskRenderData; exports.DEFAULT_TEXT_STYLE = DEFAULT_TEXT_STYLE; exports.DEFAULT_AUTO_LEADING = DEFAULT_AUTO_LEADING; exports.fitRuns = fitRuns; exports.styleAt = styleAt; exports.restyleRange = restyleRange; exports.spliceRuns = spliceRuns; exports.paragraphRanges = paragraphRanges; exports.fitParagraphRuns = fitParagraphRuns; exports.fontOf = fontOf; exports.isTextSpace = isTextSpace; exports.layoutText = layoutText; exports.textIndexAt = textIndexAt; exports.caretAt = caretAt; exports.textDecorations = textDecorations; exports.textRectPath = textRectPath; exports.textFragmentOutline = textFragmentOutline; exports.cssFontFamily = cssFontFamily; exports.cssFont = cssFont; exports.createCanvasTextShaper = createCanvasTextShaper; exports.createOutlineTextShaper = createOutlineTextShaper; exports.createMetricTextShaper = createMetricTextShaper; exports.setVectorTextShaper = setVectorTextShaper; exports.getVectorTextShaper = getVectorTextShaper; exports.vectorTextShaperGeneration = vectorTextShaperGeneration; exports.vectorTextHasOutlines = vectorTextHasOutlines; exports.vectorTextFamilies = vectorTextFamilies; exports.DEFAULT_VECTOR_FONT = DEFAULT_VECTOR_FONT; exports.VECTOR_CHARACTER_STYLE_KEYS = VECTOR_CHARACTER_STYLE_KEYS; exports.VECTOR_PARAGRAPH_STYLE_KEYS = VECTOR_PARAGRAPH_STYLE_KEYS; exports.VectorTextError = VectorTextError; exports.fitVectorTextRuns = fitVectorTextRuns; exports.vectorTextRuns = vectorTextRuns; exports.vectorTextStyleAt = vectorTextStyleAt; exports.measureVectorPath = measureVectorPath; exports.vectorPathAt = vectorPathAt; exports.vectorPathTextPositions = vectorPathTextPositions; exports.layoutVectorText = layoutVectorText; exports.glyphBox = glyphBox; exports.vectorTextPaths = vectorTextPaths; exports.vectorTextPaintSource = vectorTextPaintSource; exports.vectorTextCaret = vectorTextCaret; exports.vectorTextIndexAt = vectorTextIndexAt; exports.vectorTextSelectionQuads = vectorTextSelectionQuads; exports.patchVectorCharacterStyle = patchVectorCharacterStyle; exports.patchVectorParagraphStyle = patchVectorParagraphStyle; exports.sanitizeVectorTextFrame = sanitizeVectorTextFrame; exports.normalizeVectorTextRuns = normalizeVectorTextRuns; exports.sanitizeVectorTextFields = sanitizeVectorTextFields; exports.vectorTextRange = vectorTextRange; exports.replaceVectorText = replaceVectorText; exports.styleVectorText = styleVectorText; exports.bakeVectorTextGeometry = bakeVectorTextGeometry; exports.vectorTextName = vectorTextName; exports.pathTextFrameFromBezier = pathTextFrameFromBezier; exports.vectorTextBoxOutline = vectorTextBoxOutline; exports.vectorTextSpans = vectorTextSpans; exports.vectorTextGeometryNode = vectorTextGeometryNode; exports.vectorTextSpanSvg = vectorTextSpanSvg; exports.VECTOR_SYMBOL_MAX_DEPTH = VECTOR_SYMBOL_MAX_DEPTH; exports.vectorSymbolsUsedIn = vectorSymbolsUsedIn; exports.vectorSymbolUses = vectorSymbolUses; exports.resolveVectorSymbols = resolveVectorSymbols; exports.stripVectorSymbolArt = stripVectorSymbolArt; exports.scaleVectorStrokeWidths = scaleVectorStrokeWidths; exports.tintVectorNode = tintVectorNode; exports.prefixVectorIds = prefixVectorIds; exports.vectorInstanceGroup = vectorInstanceGroup; exports.composeVectorMatrices = composeVectorMatrices; exports.WARP_STYLES = WARP_STYLES; exports.WARP_STYLE_LABELS = WARP_STYLE_LABELS; exports.warpPresetGrid = warpPresetGrid; exports.warpPresetMesh = warpPresetMesh; exports.warpMeshColumns = warpMeshColumns; exports.warpMeshRows = warpMeshRows; exports.isValidWarpMesh = isValidWarpMesh; exports.fitWarpMesh = fitWarpMesh; exports.identityWarpMesh = identityWarpMesh; exports.evalWarpMesh = evalWarpMesh; exports.splitWarpMeshU = splitWarpMeshU; exports.splitWarpMeshV = splitWarpMeshV; exports.removeWarpMeshSplitU = removeWarpMeshSplitU; exports.removeWarpMeshSplitV = removeWarpMeshSplitV; exports.mapWarpMeshPoints = mapWarpMeshPoints; exports.resizeWarpMesh = resizeWarpMesh; exports.warpMeshControlBounds = warpMeshControlBounds; exports.warpMeshParamAt = warpMeshParamAt; exports.dragWarpMeshPoint = dragWarpMeshPoint; exports.pullWarpMesh = pullWarpMesh; exports.warpMeshEditPoints = warpMeshEditPoints; exports.warpMeshGridCurves = warpMeshGridCurves; exports.vectorMeshFromOutline = vectorMeshFromOutline; exports.vectorMeshOutline = vectorMeshOutline; exports.VECTOR_EFFECT_DEFAULTS = VECTOR_EFFECT_DEFAULTS; exports.VECTOR_EFFECT_LABELS = VECTOR_EFFECT_LABELS; exports.VECTOR_EFFECT_PARAM_SPECS = VECTOR_EFFECT_PARAM_SPECS; exports.vectorEnvelopeMesh = vectorEnvelopeMesh; exports.vectorEnvelopeMap = vectorEnvelopeMap; exports.normalizeVectorEffectParams = normalizeVectorEffectParams; exports.createVectorEffect = createVectorEffect; exports.activeVectorEffects = activeVectorEffects; exports.hasOwnVectorAppearance = hasOwnVectorAppearance; exports.hasVectorAppearance = hasVectorAppearance; exports.isVectorLiveBoolean = isVectorLiveBoolean; exports.vectorOperandOperation = vectorOperandOperation; exports.vectorLiveBooleanSteps = vectorLiveBooleanSteps; exports.clearVectorLiveBooleanCache = clearVectorLiveBooleanCache; exports.foldVectorBooleanOperands = foldVectorBooleanOperands; exports.applyVectorEffects = applyVectorEffects; exports.vectorInstanceDrawn = vectorInstanceDrawn; exports.vectorChildAppearanceShapes = vectorChildAppearanceShapes; exports.vectorEffectInputPaths = vectorEffectInputPaths; exports.vectorEffectInputBounds = vectorEffectInputBounds; exports.vectorNodeEnvelope = vectorNodeEnvelope; exports.vectorEnvelopeFrame = vectorEnvelopeFrame; exports.vectorAppearanceShapes = vectorAppearanceShapes; exports.vectorAppearanceOutline = vectorAppearanceOutline; exports.vectorAppearanceNodes = vectorAppearanceNodes; exports.expandVectorAppearance = expandVectorAppearance; exports.expandVectorAppearances = expandVectorAppearances; exports.sanitizeVectorEffects = sanitizeVectorEffects; exports.transformVectorEffects = transformVectorEffects; exports.vectorEnteredGroups = vectorEnteredGroups; exports.isVectorConnector = isVectorConnector; exports.vectorConnectionSites = vectorConnectionSites; exports.nearestVectorConnectionSite = nearestVectorConnectionSite; exports.vectorConnectorWorldAnchors = vectorConnectorWorldAnchors; exports.routeVectorConnector = routeVectorConnector; exports.rerouteVectorConnectors = rerouteVectorConnectors; exports.sanitizeVectorConnector = sanitizeVectorConnector; exports.VECTOR_CONNECTOR_ROUTE_LABELS = VECTOR_CONNECTOR_ROUTE_LABELS; exports.VECTOR_CONNECTOR_SIDE_LABELS = VECTOR_CONNECTOR_SIDE_LABELS; exports.getVectorConnectorPanel = getVectorConnectorPanel; exports.vectorConnectorTargetAt = vectorConnectorTargetAt; exports.vectorStrokeGradientDefs = vectorStrokeGradientDefs; exports.vectorCornersAttribute = vectorCornersAttribute; exports.applyVectorCornersAttribute = applyVectorCornersAttribute; exports.vectorPathLocalBounds = vectorPathLocalBounds; exports.vectorPaintToSvg = vectorPaintToSvg; exports.vectorStrokeSvgParts = vectorStrokeSvgParts; exports.vectorNodeLocalPaintBounds = vectorNodeLocalPaintBounds; exports.vectorNodeFilterSvg = vectorNodeFilterSvg; exports.widthProfileToAttribute = widthProfileToAttribute; exports.widthProfileFromAttribute = widthProfileFromAttribute; exports.vectorDocumentToSvg = vectorDocumentToSvg; exports.parseSvgTransform = parseSvgTransform; exports.parseVectorSvg = parseVectorSvg; exports.VECTOR_SPATIAL_MIN = VECTOR_SPATIAL_MIN; exports.VectorRTree = VectorRTree; exports.vectorNodePaintBox = vectorNodePaintBox; exports.vectorSpatialIndex = vectorSpatialIndex; exports.vectorNodesNear = vectorNodesNear; exports.cloneAnchor = cloneAnchor; exports.cloneSubpath = cloneSubpath; exports.cloneVectorNode = cloneVectorNode; exports.cloneVectorDocument = cloneVectorDocument; exports.hasPaint = hasPaint; exports.subpathSegmentCount = subpathSegmentCount; exports.subpathSegment = subpathSegment; exports.subpathsToBezier = subpathsToBezier; exports.vectorNodeToBezier = vectorNodeToBezier; exports.vectorPathData = vectorPathData; exports.inferAnchorType = inferAnchorType; exports.bezierToSubpaths = bezierToSubpaths; exports.walkVectorNodes = walkVectorNodes; exports.findVectorNode = findVectorNode; exports.locateVectorNode = locateVectorNode; exports.collectPaintedNodes = collectPaintedNodes; exports.collectPathNodes = collectPathNodes; exports.nodeMatrix = nodeMatrix; exports.vectorPathWorldBezier = vectorPathWorldBezier; exports.vectorNodeBounds = vectorNodeBounds; exports.unionBounds = unionBounds; exports.boundsIntersect = boundsIntersect; exports.boundsFromPoints = boundsFromPoints; exports.hitTestVectorNode = hitTestVectorNode; exports.vectorStrokeOutline = vectorStrokeOutline; exports.hitTestVectorNodes = hitTestVectorNodes; exports.nearestSegment = nearestSegment; exports.transformVectorNode = transformVectorNode; exports.vectorNodeRotation = vectorNodeRotation; exports.vectorWorldMatrix = vectorWorldMatrix; exports.vectorParentMatrix = vectorParentMatrix; exports.translateAnchor = translateAnchor; exports.moveAnchorHandle = moveAnchorHandle; exports.convertAnchor = convertAnchor; exports.insertAnchor = insertAnchor; exports.removeAnchors = removeAnchors; exports.reverseSubpath = reverseSubpath; exports.KAPPA = KAPPA2; exports.rectSubpath = rectSubpath; exports.ellipseSubpath = ellipseSubpath; exports.polygonSubpath = polygonSubpath; exports.starSubpath = starSubpath; exports.lineSubpath = lineSubpath; exports.roundSubpaths = roundSubpaths;
9797
+ //# sourceMappingURL=chunk-FODKPD44.cjs.map