@pixerate/editor 0.97.0 → 0.98.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. package/THIRD_PARTY_NOTICES.md +4 -2
  2. package/dist/animation-editor/index.cjs +55 -53
  3. package/dist/animation-editor/index.cjs.map +1 -1
  4. package/dist/animation-editor/index.d.cts +3 -2
  5. package/dist/animation-editor/index.d.ts +3 -2
  6. package/dist/animation-editor/index.js +11 -9
  7. package/dist/animation-editor/index.js.map +1 -1
  8. package/dist/chunk-DWGZUSES.cjs +694 -0
  9. package/dist/chunk-DWGZUSES.cjs.map +1 -0
  10. package/dist/chunk-GX332W2C.js +181 -0
  11. package/dist/chunk-GX332W2C.js.map +1 -0
  12. package/dist/{chunk-7MD7C6XQ.cjs → chunk-JF5PXN7W.cjs} +96 -744
  13. package/dist/chunk-JF5PXN7W.cjs.map +1 -0
  14. package/dist/chunk-KKREERP2.js +694 -0
  15. package/dist/chunk-KKREERP2.js.map +1 -0
  16. package/dist/chunk-MUUXNRU4.cjs +181 -0
  17. package/dist/chunk-MUUXNRU4.cjs.map +1 -0
  18. package/dist/{chunk-OEVSVA6V.js → chunk-WIR377F6.js} +788 -22
  19. package/dist/chunk-WIR377F6.js.map +1 -0
  20. package/dist/{chunk-4AB5BHYK.cjs → chunk-WT6ZAWJP.cjs} +788 -22
  21. package/dist/chunk-WT6ZAWJP.cjs.map +1 -0
  22. package/dist/{chunk-4JLB2USO.js → chunk-YGZNGDIT.js} +45 -693
  23. package/dist/chunk-YGZNGDIT.js.map +1 -0
  24. package/dist/image-editor/index.cjs +1280 -299
  25. package/dist/image-editor/index.cjs.map +1 -1
  26. package/dist/image-editor/index.d.cts +304 -5
  27. package/dist/image-editor/index.d.ts +304 -5
  28. package/dist/image-editor/index.js +991 -10
  29. package/dist/image-editor/index.js.map +1 -1
  30. package/dist/raster/index.cjs +23 -2
  31. package/dist/raster/index.cjs.map +1 -1
  32. package/dist/raster/index.d.cts +98 -2
  33. package/dist/raster/index.d.ts +98 -2
  34. package/dist/raster/index.js +23 -2
  35. package/dist/{svg-ymShkNtu.d.cts → svg-C9r284x8.d.cts} +6 -9
  36. package/dist/{svg-Dh17jCyA.d.ts → svg-MVKBqwD4.d.ts} +6 -9
  37. package/dist/types-CwMPoRMU.d.cts +40 -0
  38. package/dist/types-CwMPoRMU.d.ts +40 -0
  39. package/dist/vector/index.cjs +490 -554
  40. package/dist/vector/index.cjs.map +1 -1
  41. package/dist/vector/index.d.cts +154 -292
  42. package/dist/vector/index.d.ts +154 -292
  43. package/dist/vector/index.js +91 -155
  44. package/dist/vector/index.js.map +1 -1
  45. package/dist/warp-B8rAguzs.d.ts +165 -0
  46. package/dist/warp-nYs2DPrx.d.cts +165 -0
  47. package/package.json +1 -1
  48. package/skills/pixerate-image-editor/SKILL.md +49 -3
  49. package/dist/chunk-4AB5BHYK.cjs.map +0 -1
  50. package/dist/chunk-4JLB2USO.js.map +0 -1
  51. package/dist/chunk-7MD7C6XQ.cjs.map +0 -1
  52. package/dist/chunk-OEVSVA6V.js.map +0 -1
@@ -158,7 +158,7 @@ GridCraft. Apache POI is © The Apache Software Foundation, licensed under the A
158
158
  - `crates/export/src/lib.rs` (`body_size`: body text size by character count; `level`: heading levels relative to it, bold body-size headings; `tables`: grid columns from aligned cell edges, rows from overlapping spans, spanning header and totals rows next to a run, the 63-column cap) → `packages/core/src/import/pdf-layout.ts`
159
159
  - `crates/edit/src/text_regions.rs` (`group_layout`: runs joined on a baseline across small gaps, rows grouped into blocks by pitch and alignment, line-end hyphens removed when joining rows) → `packages/core/src/import/pdf-layout.ts`
160
160
  - Test cases from `crates/export/src/lib.rs` (`grid_text_becomes_a_real_table_in_every_format`, `a_staircase_of_blocks_is_not_a_huge_table`, `two_column_body_text_is_not_mistaken_for_a_table`, `word_does_not_invent_borders_for_aligned_invoice_fields`), re-expressed → `packages/core/tests/pdf-layout.test.ts`
161
- - `crates/geom/src/perspective.rs` (`Homography::from_points` with the eight-unknown system and the check that the four points really map, `Homography::apply`, `solve8` Gaussian elimination with partial pivoting, `order_quad`) → `vectorHomography`, `applyVectorHomography`, `solve8` and `orderVectorQuad` in `packages/core/src/vector/perspective.ts`, used by Free Distort; test cases re-expressed → `packages/core/tests/vector-distort.test.ts`
161
+ - `crates/geom/src/perspective.rs` (`Homography::from_points` with the eight-unknown system and the check that the four points really map, `Homography::apply`, `solve8` Gaussian elimination with partial pivoting, `order_quad`) → `homographyFromPoints`, `applyHomography`, `solve8` and `orderQuad` in `packages/core/src/geom/homography.ts` (re-exported as `vectorHomography`, `applyVectorHomography` and `orderVectorQuad` by `packages/core/src/vector/perspective.ts`), used by the vector editor's Free Distort and the image editor's Free Transform; test cases re-expressed → `packages/core/tests/vector-distort.test.ts`
162
162
 
163
163
  ## photocraft
164
164
 
@@ -183,7 +183,7 @@ GridCraft. Apache POI is © The Apache Software Foundation, licensed under the A
183
183
  - Test cases from `crates/algo/src/selection.rs`, `crates/algo/src/selection_blur.rs`, `crates/algo/src/matting.rs` and `crates/algo/src/tests_selection_mix.rs`, re-expressed → `packages/core/tests/image-editor-selection.test.ts`, `packages/core/tests/image-editor-selection-controller.test.ts`
184
184
  - `crates/compose/src/gradient_fill.rs` (`midpoint_remap`; `Ramp`; `handles` / `from_handles`: the start and end points of the Linear, Radial, Angle, Reflected and Diamond styles) and `crates/compose/src/effects.rs` (`gradient_t`: Reflected as `|u|`, Diamond as `|along| + |across|`, Angle as a clockwise sweep from the gradient's direction) → `gradientMidpointRemap`, `vectorGradientParam` and the reflected / diamond / conic styles in `packages/core/src/vector/gradient.ts`; the styles share vectorcraft's start / end frame instead of an angle, scale and centre offset
185
185
  - `crates/vector/src/map.rs` (`map_points`; `map_path`, `map_subpath`, `map_segment`, `split_mapped`, `halves`, `off_line`: segments halved until the mapped control points follow the mapped curve within a tolerance, straight segments whose image is straight kept as one, the split depth bounded on huge paths) → `mapVectorPoints`, `mapVectorSubpaths` and `mapBezierPath` in `packages/core/src/vector/pathMap.ts`; runs of pieces are then refitted with fewer cubics by our `fitCubicRun` where that stays within the tolerance, and smooth anchors have their handles made collinear again; test cases re-expressed → `packages/core/tests/vector-distort.test.ts`
186
- - `crates/geom/src/warp.rs` (`WarpStyle` and its fifteen presets; `StyleWarp`; `rest_grid`, `edge_arc`, `arc_grid`, `blend_rows` and `preset_grid` with bend, horizontal and vertical distortion and the vertical orientation; `bernstein`, `split_cubic`, `BERN_INV`; `BezierMesh` — `identity`, `fit`, `eval`, `locate`, `split_u` / `split_v`, `remove_split_u` / `remove_split_v`, `transpose`, `map_points`, `param_at`, `pull`, `smooth_lines`, `drag_point`, `control_bounds`; `Warp::map`, `Warp::to_mesh`) → `packages/core/src/vector/warp.ts`, the `envelope` effect in `packages/core/src/vector/appearance.ts` and the Envelope tool in `packages/core/src/vector/controller.ts`; meshes are plain data (points in the node's space), the end patches extrapolate outside the box so handles past it map smoothly, and `vectorMeshFromOutline` (a Coons patch for Make with Top Object) is our own; Photoshop's measured cases were not copied — the presets are tested by their corner and edge behaviour → `packages/core/tests/vector-distort.test.ts`
186
+ - `crates/geom/src/warp.rs` (`WarpStyle` and its fifteen presets; `StyleWarp`; `rest_grid`, `edge_arc`, `arc_grid`, `blend_rows` and `preset_grid` with bend, horizontal and vertical distortion and the vertical orientation; `bernstein`, `split_cubic`, `BERN_INV`; `BezierMesh` — `identity`, `fit`, `eval`, `locate`, `split_u` / `split_v`, `remove_split_u` / `remove_split_v`, `transpose`, `map_points`, `param_at`, `pull`, `smooth_lines`, `drag_point`, `control_bounds`; `Warp::map`, `Warp::to_mesh`) → `packages/core/src/geom/warp.ts` (shared with the image editor's Warp; re-exported under the vector names by `packages/core/src/vector/warp.ts`), the `envelope` effect in `packages/core/src/vector/appearance.ts` and the Envelope tool in `packages/core/src/vector/controller.ts`; meshes are plain data (points in the node's space), the end patches extrapolate outside the box so handles past it map smoothly, and `vectorMeshFromOutline` (a Coons patch for Make with Top Object) is our own; Photoshop's measured cases were not copied — the presets are tested by their corner and edge behaviour → `packages/core/tests/vector-distort.test.ts`
187
187
  - `crates/io/src/gradient_bake.rs` (`eval`: stop midpoints remapping each segment, Smoothness as a blend of linear interpolation and a Catmull-Rom spline through the stop colours with end tangents at half the chord slope, clamped to each segment; the Classic / Linear / Perceptual interpolation spaces as sRGB, linear light and Oklab; `bake`: the curve sampled into linear stops) → `vectorGradientRamp` and `expandVectorGradientStops` in `packages/core/src/vector/gradient.ts`; stops are placed adaptively to a tolerance instead of 96 even samples, and Photoshop's measured Smooth easing table was not ported; test cases re-expressed → `packages/core/tests/vector-gradient.test.ts`
188
188
  - `crates/psd/src/io.rs` (the bounds-checked big-endian reader that never reads past its end, count checks before allocation, Pascal and Unicode strings, legacy names as UTF-8 else Latin-1), `crates/psd/src/descriptor.rs` (ActionDescriptor read / write: 4-character and long ids, every value type, the reference items, version 16, a nesting limit), `crates/psd/src/compression.rs` (PackBits encode / decode, RLE planes with u16 or (PSB) u32 row counts, ZIP and ZIP with prediction for 1, 8, 16 and 32 bits, the decoded-size limit), `crates/psd/src/header.rs`, `file.rs`, `layer.rs`, `tagged.rs`, `tree.rs`, `resources.rs` and `image_data.rs` (header limits, resources, layer records, channel lengths, the user mask with density / feather parameters and the real-before-parameters order Photoshop writes, tagged blocks with PSB long keys and padding detected from the next signature, `Lr16` / `Lr32` layers, `lsct` section dividers to a tree, `luni`, `lyid`, `iOpa`, `lspf`) → `packages/core/src/image-editor/psd/binary.ts`, `descriptor.ts`, `compression.ts` and `file.ts`; only what our layer model reads is kept (unknown blocks are not round-tripped byte for byte), and inflating uses our `raster/zlib.ts`
189
189
  - `crates/io/src/adjust_map.rs` (`parse` / `write` for Levels, Curves including pencil maps, Hue/Saturation with `canonical_bounds`, Vibrance, Color Balance, Black & White with its tint descriptor, Photo Filter v2 and v3 XYZ, Invert, Posterize and Threshold; the adjustment key list and labels) and `crates/io/src/channel_map.rs` (`decode_known_color`: RGB, HSB, CMYK stored inverted, Lab, Grayscale) → `packages/core/src/image-editor/psd/adjust.ts`; parameters stay in our units, and a pencil curve becomes points every 15 levels
@@ -191,6 +191,8 @@ GridCraft. Apache POI is © The Apache Software Foundation, licensed under the A
191
191
  - `crates/io/src/psd_export.rs` and `crates/psd/src/builder.rs` (layer records with RLE channels, group divider and folder records, adjustment blocks, user masks with parameters, `luni` / `lyid` / `iOpa` / `lspf`, the resolution and version-info resources, PSB above 30 000 px) → `packages/core/src/image-editor/psd/export.ts`; 8-bit RGB only, with the merged image from our compositor
192
192
  - `crates/doc/src/effects.rs` (the layer-style model: shadows, glows, strokes, satin, bevel & emboss with its Contour and Texture elements, colour / gradient / pattern overlays, the shared enabled / blend / opacity, Photoshop's defaults, the global light) → `packages/core/src/raster/effects/model.ts`; colours are `#rrggbb`, effects carry ids, and validation, merging and Scale Effects are our own
193
193
  - `crates/compose/src/effects.rs` (render order and the per-kind maps: `margin`, `maps_are_local`, the Felzenszwalb–Huttenlocher `dt1` / `edt_nearest`, the 5 × 5 `chamfer_from`, `dist_outside` / `dist_inside` with coverage-placed edges, `local_coverage`, `dilate`, `spread_split`, the fractional `box_geom` / `box_line` / `tent_line` blur, `contour_lut` with corners, `ranged_lut`, `satin_lut`, `hash_noise` / `noise`, `shadow_map`, `glow_map`, `satin_map`, `bevel_geom`, `bevel_chisel_h`, `bevel_height`, `bevel_maps`, `gradient_units`, `gradient_t`, `paint_glow`, `stroke_widths`, the stroke frame and the outside-stroke shares, `knock_out_exterior`, `premerges_layer` and `composite_with_effects`), `crates/compose/src/fill_layout.rs` (`gradient_layout`) and `crates/compose/src/pattern.rs` (`Tile::sample`, `Placement`) → `packages/core/src/raster/effects/render.ts` and `patterns.ts`; single-threaded, without vector-shape outlines, text gamma, Transparency Shapes Layer or Blend Interior Effects as Group, with chiselled bevel edges measured to the coverage-gradient edge line instead of photocraft's sharp-edge refinement, and the maps built once per layer region and cropped per tile by our compositor; the built-in patterns are our own; test cases re-expressed → `packages/core/tests/raster-effects.test.ts`
194
+ - `crates/algo/src/transform.rs` (Free Transform: `Homography::square_to_quad`, `rect_to_quad`, `inverse`, `mul`, `local_scale`, `front_side`; `warp_output_bounds`, `convex_quad`; Photoshop's Bicubic as the Keys cubic at a = −0.75; the inverse-mapped warp per destination tile with premultiplied nearest / bilinear / bicubic sampling, the source footprint of each tile clipped against the horizon (Sutherland–Hodgman on the inverse w) and the front side of a source straddling it, grid snapping so an identity is exact, and a pre-reduction for bicubic shrinking) and `crates/algo/src/warp.rs` (`warp_mesh_surface` / `warp_triangles`: a forward-mapped grid of 4 px cells rasterized as triangles with barycentric source positions, binned per destination tile, with bilinear subsamples over each pixel's source footprint where the warp shrinks) → `transformSurface` and `warpSurface` in `packages/core/src/raster/transform.ts` and the homography helpers in `packages/core/src/geom/homography.ts`; single-threaded, on 8-bit tiles, with masks warped as value + inside flattened onto their default, a box pre-reduction by whole factors plus a widened cubic instead of photocraft's Image Size resize, and block-sampled previews of our own; test cases re-expressed (the 200 % step edge measured on Photoshop, the steep distort, the distort past the horizon, the prefiltered checkerboard) → `packages/core/tests/raster-transform.test.ts`
195
+ - `crates/engine/src/transform_cmds.rs` (`split_selected` and `split_gray_selected`: lifting the selected pixels and the same part of a mask as grey + coverage, composited back over the rest; linked masks moving with their pixels and an unlinked mask transformed alone; position locks refusing a transform) and `crates/io/src/psd_import.rs` / `psd_export.rs` (mask flag bit 0 as an unlinked mask) → `packages/core/src/image-editor/free-transform.ts` and `packages/core/src/image-editor/psd/`; test cases re-expressed → `packages/core/tests/image-free-transform.test.ts`
194
196
  - `crates/io/src/effects_map.rs` (`parse_lfx2` / `write_lfx2`: the per-kind descriptor keys, the single and `…Multi` instance keys, `present` / `enab`, blend ids as four-character codes or long string ids, contours with corner points, `parse_lrfx` for legacy effects), `crates/io/src/blocks.rs` (`color_from_desc` / `color_to_desc`, `gradient_style`, the `Grdn` colour and transparency stops, `pattern_ref`, `pattern_placement`), `crates/io/src/psd_import.rs` / `psd_export.rs` (`lmfx` over `lfx2` / `lfxs`, the block kept and written back while the effects are unchanged, odd-length blocks padded) and `crates/psd/src/patterns.rs` (`Patt` / `Pat2` / `Pat3` blocks: patterns, virtual memory array lists, written channels, padded channel rectangles) → `packages/core/src/image-editor/psd/effects.ts` and `patterns.ts`; gradient midpoints become extra stops and smoothness is drawn linearly (photocraft bakes Photoshop's interpolation), and patterns are written as 8-bit RGB; test cases re-expressed → `packages/core/tests/image-psd-effects.test.ts`
195
197
 
196
198
  ## soundcraft
@@ -12,6 +12,7 @@
12
12
 
13
13
 
14
14
 
15
+ var _chunkJF5PXN7Wcjs = require('../chunk-JF5PXN7W.cjs');
15
16
 
16
17
 
17
18
 
@@ -19,23 +20,24 @@
19
20
 
20
21
 
21
22
 
23
+ var _chunkWAJQKWQUcjs = require('../chunk-WAJQKWQU.cjs');
22
24
 
23
- var _chunk7MD7C6XQcjs = require('../chunk-7MD7C6XQ.cjs');
24
25
 
25
26
 
26
27
 
27
28
 
28
29
 
30
+ var _chunkXGD3FSNCcjs = require('../chunk-XGD3FSNC.cjs');
29
31
 
30
32
 
31
- var _chunkWAJQKWQUcjs = require('../chunk-WAJQKWQU.cjs');
32
33
 
33
34
 
34
35
 
35
36
 
36
37
 
37
38
 
38
- var _chunkXGD3FSNCcjs = require('../chunk-XGD3FSNC.cjs');
39
+
40
+ var _chunkDWGZUSEScjs = require('../chunk-DWGZUSES.cjs');
39
41
 
40
42
 
41
43
  var _chunkEMQWJA3Gcjs = require('../chunk-EMQWJA3G.cjs');
@@ -556,7 +558,7 @@ function smoothMotionTimes(points, start, duration, pacing = "even") {
556
558
  function motionTextLayout(nodes, id) {
557
559
  const group = _optionalChain([nodes, 'access', _5 => _5.get, 'call', _6 => _6(id), 'optionalAccess', _7 => _7.node]);
558
560
  if (!group || group.type !== "group") return null;
559
- const letters = _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, group).map((p) => ({ id: p.id, b: _optionalChain([nodes, 'access', _8 => _8.get, 'call', _9 => _9(p.id), 'optionalAccess', _10 => _10.bounds]) })).filter((l) => !!l.b && l.b.width + l.b.height > 0);
561
+ const letters = _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, group).map((p) => ({ id: p.id, b: _optionalChain([nodes, 'access', _8 => _8.get, 'call', _9 => _9(p.id), 'optionalAccess', _10 => _10.bounds]) })).filter((l) => !!l.b && l.b.width + l.b.height > 0);
560
562
  if (!letters.length) return null;
561
563
  const lines = [];
562
564
  for (const l of [...letters].sort((a, c) => a.b.y + a.b.height / 2 - (c.b.y + c.b.height / 2))) {
@@ -641,21 +643,21 @@ function indexMotionNodes(nodes) {
641
643
  const out = /* @__PURE__ */ new Map();
642
644
  const walk = (list, parentWorld, ancestors) => {
643
645
  for (const node of list) {
644
- const local = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, node);
645
- const bounds = _chunk7MD7C6XQcjs.vectorNodeBounds.call(void 0, node, parentWorld);
646
+ const local = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, node);
647
+ const bounds = _chunkJF5PXN7Wcjs.vectorNodeBounds.call(void 0, node, parentWorld);
646
648
  const center = local ? { x: local.x + local.width / 2, y: local.y + local.height / 2 } : { x: 0, y: 0 };
647
649
  if (!out.has(node.id)) out.set(node.id, { node, ancestors, parentWorld, center, bounds, box: local });
648
- if (node.type === "group") walk(node.children, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node), parentWorld), [...ancestors, node.id]);
650
+ if (node.type === "group") walk(node.children, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node), parentWorld), [...ancestors, node.id]);
649
651
  }
650
652
  };
651
- walk(nodes, _chunk7MD7C6XQcjs.IDENTITY_MATRIX, []);
653
+ walk(nodes, _chunkDWGZUSEScjs.IDENTITY_MATRIX, []);
652
654
  indexCache.set(nodes, out);
653
655
  return out;
654
656
  }
655
657
  var solid = (paint) => typeof paint === "string" && paint !== "none" ? paint : void 0;
656
658
  function firstPaint(node, key) {
657
659
  if (node.type === "path") return solid(node[key]);
658
- for (const p of _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) {
660
+ for (const p of _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) {
659
661
  const s = solid(p[key]);
660
662
  if (s) return s;
661
663
  }
@@ -663,7 +665,7 @@ function firstPaint(node, key) {
663
665
  }
664
666
  function strokeReach(node) {
665
667
  let reach = 0;
666
- for (const p of node.type === "path" ? [node] : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)) {
668
+ for (const p of node.type === "path" ? [node] : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)) {
667
669
  if (p.stroke == null || p.stroke === "none") continue;
668
670
  const width = _nullishCoalesce(p.strokeWidth, () => ( 1));
669
671
  reach = Math.max(reach, p.strokeAlign === "outside" ? width : p.strokeAlign === "inside" ? 0 : width / 2);
@@ -733,7 +735,7 @@ function motionRestValue(entry, property, artwork) {
733
735
  case "stroke":
734
736
  return _nullishCoalesce((node && firstPaint(node, property)), () => ( "transparent"));
735
737
  case "strokeWidth": {
736
- const path = _optionalChain([node, 'optionalAccess', _13 => _13.type]) === "path" ? node : node ? _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node)[0] : void 0;
738
+ const path = _optionalChain([node, 'optionalAccess', _13 => _13.type]) === "path" ? node : node ? _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node)[0] : void 0;
737
739
  return _nullishCoalesce(_optionalChain([path, 'optionalAccess', _14 => _14.strokeWidth]), () => ( 1));
738
740
  }
739
741
  case "shape":
@@ -844,12 +846,12 @@ function resolveMotionCamera(camera, scene) {
844
846
  const r = camera;
845
847
  return { x: r.x, y: r.y, width: r.width, height: r.height };
846
848
  }
847
- function motionPathLength(node, parentWorld = _chunk7MD7C6XQcjs.IDENTITY_MATRIX) {
849
+ function motionPathLength(node, parentWorld = _chunkDWGZUSEScjs.IDENTITY_MATRIX) {
848
850
  let longest = 0;
849
- const paths = node.type === "path" ? [node] : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node);
851
+ const paths = node.type === "path" ? [node] : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node);
850
852
  for (const p of paths) {
851
853
  try {
852
- longest = Math.max(longest, _chunkXGD3FSNCcjs.bezierPathLength.call(void 0, _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, p, parentWorld, { effects: false })));
854
+ longest = Math.max(longest, _chunkXGD3FSNCcjs.bezierPathLength.call(void 0, _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, p, parentWorld, { effects: false })));
853
855
  } catch (e2) {
854
856
  }
855
857
  }
@@ -1102,12 +1104,12 @@ function compileMotionScene(scene) {
1102
1104
  const order2 = _nullishCoalesce(o.order, () => ( "together"));
1103
1105
  const pace = _nullishCoalesce(o.pace, () => ( "time"));
1104
1106
  if (order2 === "together" && pace === "time") return null;
1105
- const paths = entry.node.type === "path" ? [entry.node] : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, entry.node);
1107
+ const paths = entry.node.type === "path" ? [entry.node] : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, entry.node);
1106
1108
  let list = paths.map((p) => {
1107
1109
  const at = nodes.get(p.id);
1108
1110
  let first = { x: 0, y: 0 };
1109
1111
  try {
1110
- const m = _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, p, _nullishCoalesce(_optionalChain([at, 'optionalAccess', _41 => _41.parentWorld]), () => ( _chunk7MD7C6XQcjs.IDENTITY_MATRIX)), { effects: false })[0];
1112
+ const m = _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, p, _nullishCoalesce(_optionalChain([at, 'optionalAccess', _41 => _41.parentWorld]), () => ( _chunkDWGZUSEScjs.IDENTITY_MATRIX)), { effects: false })[0];
1111
1113
  if (m && m.type === "M") first = { x: m.x, y: m.y };
1112
1114
  } catch (e3) {
1113
1115
  }
@@ -1219,17 +1221,17 @@ function compileMotionScene(scene) {
1219
1221
  let dx = _nullishCoalesce(_optionalChain([command3, 'access', _44 => _44.by, 'optionalAccess', _45 => _45.x]), () => ( 0));
1220
1222
  let dy = _nullishCoalesce(_optionalChain([command3, 'access', _46 => _46.by, 'optionalAccess', _47 => _47.y]), () => ( 0));
1221
1223
  if (command3.to) {
1222
- const inv = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, entry.parentWorld);
1223
- const target = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, inv, command3.to);
1224
+ const inv = _chunkDWGZUSEScjs.invertMatrix.call(void 0, entry.parentWorld);
1225
+ const target = _chunkDWGZUSEScjs.applyMatrix.call(void 0, inv, command3.to);
1224
1226
  dx = target.x - (entry.center.x + num2("x"));
1225
1227
  dy = target.y - (entry.center.y + num2("y"));
1226
1228
  }
1227
1229
  if (_optionalChain([command3, 'access', _48 => _48.via, 'optionalAccess', _49 => _49.length])) {
1228
- const inv = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, entry.parentWorld);
1230
+ const inv = _chunkDWGZUSEScjs.invertMatrix.call(void 0, entry.parentWorld);
1229
1231
  const x0 = num2("x");
1230
1232
  const y0 = num2("y");
1231
1233
  const add = command3.blend === "add";
1232
- const offsets = [{ x: 0, y: 0 }, ...command3.via.map((p) => _chunk7MD7C6XQcjs.applyMatrix.call(void 0, inv, p)).map((p) => ({ x: p.x - entry.center.x - x0, y: p.y - entry.center.y - y0 })), { x: dx, y: dy }];
1234
+ const offsets = [{ x: 0, y: 0 }, ...command3.via.map((p) => _chunkDWGZUSEScjs.applyMatrix.call(void 0, inv, p)).map((p) => ({ x: p.x - entry.center.x - x0, y: p.y - entry.center.y - y0 })), { x: dx, y: dy }];
1233
1235
  const times = smoothMotionTimes(offsets, start, end - start, _nullishCoalesce(command3.pacing, () => ( "even")));
1234
1236
  for (const axis of ["x", "y"]) {
1235
1237
  const base = add ? 0 : axis === "x" ? x0 : y0;
@@ -1371,13 +1373,13 @@ function morphBetween(a, b) {
1371
1373
  let inner = morphCache.get(a);
1372
1374
  if (!inner) morphCache.set(a, inner = /* @__PURE__ */ new WeakMap());
1373
1375
  let morph = inner.get(b);
1374
- if (!morph) inner.set(b, morph = _chunk7MD7C6XQcjs.createVectorMorph.call(void 0, a, b, { id: a.id }));
1376
+ if (!morph) inner.set(b, morph = _chunkJF5PXN7Wcjs.createVectorMorph.call(void 0, a, b, { id: a.id }));
1375
1377
  return morph;
1376
1378
  }
1377
1379
  function shapeIn(entry, shape) {
1378
1380
  if (shape === entry) return entry.node;
1379
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, shape.node), shape.parentWorld), _chunk7MD7C6XQcjs.invertMatrix.call(void 0, entry.parentWorld));
1380
- return { ...shape.node, ..._chunk7MD7C6XQcjs.isIdentityMatrix.call(void 0, m) ? { transform: void 0 } : { transform: m } };
1381
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, shape.node), shape.parentWorld), _chunkDWGZUSEScjs.invertMatrix.call(void 0, entry.parentWorld));
1382
+ return { ...shape.node, ..._chunkDWGZUSEScjs.isIdentityMatrix.call(void 0, m) ? { transform: void 0 } : { transform: m } };
1381
1383
  }
1382
1384
  function shapeAt(entry, timeline, nodes, time) {
1383
1385
  const track = timeline.tracks.get(motionTrackKey(entry.node.id, "shape"));
@@ -1397,7 +1399,7 @@ function shapeAt(entry, timeline, nodes, time) {
1397
1399
  function motionFollowRoute(entry, path) {
1398
1400
  if (!path || path.node.type !== "path") return null;
1399
1401
  try {
1400
- return _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, path.node, path.parentWorld, { effects: false }), _chunk7MD7C6XQcjs.invertMatrix.call(void 0, entry.parentWorld));
1402
+ return _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, path.node, path.parentWorld, { effects: false }), _chunkDWGZUSEScjs.invertMatrix.call(void 0, entry.parentWorld));
1401
1403
  } catch (e4) {
1402
1404
  return null;
1403
1405
  }
@@ -1431,9 +1433,9 @@ function motionNodeOffset(entry, timeline, time, nodes = indexMotionNodes([entry
1431
1433
  const scaleX = read("scaleX", 1);
1432
1434
  const scaleY = read("scaleY", 1);
1433
1435
  const c = entry.center;
1434
- let matrix = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.scaleMatrix.call(void 0, scaleX, scaleY, c), _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, rotation, c)), _chunk7MD7C6XQcjs.translateMatrix.call(void 0, dx, dy));
1436
+ let matrix = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.scaleMatrix.call(void 0, scaleX, scaleY, c), _chunkDWGZUSEScjs.rotateMatrix.call(void 0, rotation, c)), _chunkDWGZUSEScjs.translateMatrix.call(void 0, dx, dy));
1435
1437
  const along = follow ? followAt(entry, timeline, nodes, time) : null;
1436
- if (along) matrix = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, matrix, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.translateMatrix.call(void 0, -c.x, -c.y), _chunk7MD7C6XQcjs.rotateMatrix.call(void 0, along.angle)), _chunk7MD7C6XQcjs.translateMatrix.call(void 0, along.x, along.y)));
1438
+ if (along) matrix = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, matrix, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkDWGZUSEScjs.translateMatrix.call(void 0, -c.x, -c.y), _chunkDWGZUSEScjs.rotateMatrix.call(void 0, along.angle)), _chunkDWGZUSEScjs.translateMatrix.call(void 0, along.x, along.y)));
1437
1439
  return { matrix, dx, dy, rotation, scaleX, scaleY, follow: along };
1438
1440
  }
1439
1441
  function motionNodeClips(id, timeline, time) {
@@ -1500,7 +1502,7 @@ function motionFrameAt(scene, time, options = {}) {
1500
1502
  const start = Math.min(1, Math.max(0, typeof drawStart === "number" ? drawStart : 0));
1501
1503
  const end = Math.min(1, Math.max(0, typeof drawEnd === "number" ? drawEnd : 1));
1502
1504
  if (start > 0 || end < 1) {
1503
- const trim = _chunk7MD7C6XQcjs.createVectorEffect.call(void 0, "trim", MOTION_DRAW_EFFECT_ID, { start: tidy(start * 100), end: tidy(end * 100) });
1505
+ const trim = _chunkJF5PXN7Wcjs.createVectorEffect.call(void 0, "trim", MOTION_DRAW_EFFECT_ID, { start: tidy(start * 100), end: tidy(end * 100) });
1504
1506
  p = { ...p, effects: [trim, ...(_nullishCoalesce(p.effects, () => ( []))).filter((e) => e.id !== MOTION_DRAW_EFFECT_ID)] };
1505
1507
  }
1506
1508
  }
@@ -1514,8 +1516,8 @@ function motionFrameAt(scene, time, options = {}) {
1514
1516
  if (o >= 1) delete out.opacity;
1515
1517
  }
1516
1518
  const offset = options.offsets === false ? null : motionNodeOffset(entry, timeline, time, nodes);
1517
- if (offset && !_chunk7MD7C6XQcjs.isIdentityMatrix.call(void 0, offset.matrix)) {
1518
- const m = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, out), offset.matrix).map(tidy);
1519
+ if (offset && !_chunkDWGZUSEScjs.isIdentityMatrix.call(void 0, offset.matrix)) {
1520
+ const m = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, out), offset.matrix).map(tidy);
1519
1521
  out = { ...out, transform: m };
1520
1522
  }
1521
1523
  return out;
@@ -1535,7 +1537,7 @@ function motionFrameToSvg(scene, time, options = {}) {
1535
1537
  const wrap = { ...options.wrap };
1536
1538
  for (const [id, clips] of Object.entries(frame.clips))
1537
1539
  wrap[id] = [..._nullishCoalesce(wrap[id], () => ( [])), ...clips.map((clip, i) => ({ clip: { id: `${prefix}reveal-${id}-${i}`, shape: clip.shape, attrs: motionClipAttrs(clip) } }))];
1538
- return withViewBox(_chunk7MD7C6XQcjs.vectorDocumentToSvg.call(void 0, frame.document, { ...options, wrap }), frame.camera);
1540
+ return withViewBox(_chunkJF5PXN7Wcjs.vectorDocumentToSvg.call(void 0, frame.document, { ...options, wrap }), frame.camera);
1539
1541
  }
1540
1542
  function withViewBox(svg, box) {
1541
1543
  const f = (n) => String(Math.round(n * 1e3) / 1e3);
@@ -1718,8 +1720,8 @@ function visibleAt(timeline, id, time, node) {
1718
1720
  if (Array.isArray(rect) && (rect[2] <= 1e-4 || rect[3] <= 1e-4)) return false;
1719
1721
  const circle = clip("clipCircle");
1720
1722
  if (Array.isArray(circle) && circle[2] <= 1e-4) return false;
1721
- const hasFill = node.type === "path" ? !!node.fill && node.fill !== "none" : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node).some((p) => p.fill && p.fill !== "none");
1722
- const drawn = num2("drawEnd", 1) > 0.01 && (node.type === "path" || _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node).length === 0 || _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node).some((p) => {
1723
+ const hasFill = node.type === "path" ? !!node.fill && node.fill !== "none" : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node).some((p) => p.fill && p.fill !== "none");
1724
+ const drawn = num2("drawEnd", 1) > 0.01 && (node.type === "path" || _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node).length === 0 || _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node).some((p) => {
1723
1725
  const v = trackValue(timeline.tracks.get(motionTrackKey(p.id, "drawEnd")), time);
1724
1726
  return typeof v !== "number" || v > 0.01;
1725
1727
  }));
@@ -1805,7 +1807,7 @@ function checkMotionScene(scene) {
1805
1807
  }
1806
1808
  for (const id of targets) {
1807
1809
  const node = nodes.get(id).node;
1808
- const paths = node.type === "path" ? [node] : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node);
1810
+ const paths = node.type === "path" ? [node] : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node);
1809
1811
  if (paths.some((p) => p[key] !== void 0 && p[key] !== null && typeof p[key] !== "string"))
1810
1812
  issues.push(_chunkWAJQKWQUcjs.motionIssue.call(void 0, "paint-not-color", `"${id}" has a gradient ${key}; it switches to ${color} at the end instead of blending.`, { ...where, ids: [id] }));
1811
1813
  }
@@ -1818,7 +1820,7 @@ function checkMotionScene(scene) {
1818
1820
  else
1819
1821
  for (const id of targets) {
1820
1822
  const node = nodes.get(id).node;
1821
- const paths = node.type === "path" ? [node] : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node);
1823
+ const paths = node.type === "path" ? [node] : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node);
1822
1824
  if (paths.some((p) => typeof p[key] !== "string"))
1823
1825
  issues.push(_chunkWAJQKWQUcjs.motionIssue.call(void 0, "paint-not-color", `"${id}" has a gradient or no ${key}, so a colour pulse cannot tint it; give it a solid ${key} or pulse the ${key === "fill" ? "stroke" : "fill"}.`, { ...where, ids: [id] }));
1824
1826
  }
@@ -2402,7 +2404,7 @@ function toFlairSvgMotion(scene, options = {}) {
2402
2404
  raw: (t) => transformAt(t, true)
2403
2405
  });
2404
2406
  }
2405
- const paths = node.type === "path" ? [node] : _chunk7MD7C6XQcjs.collectPathNodes.call(void 0, node);
2407
+ const paths = node.type === "path" ? [node] : _chunkJF5PXN7Wcjs.collectPathNodes.call(void 0, node);
2406
2408
  for (const path of paths) {
2407
2409
  if (pathsSeen.has(path.id)) continue;
2408
2410
  pathsSeen.add(path.id);
@@ -2424,7 +2426,7 @@ function toFlairSvgMotion(scene, options = {}) {
2424
2426
  if (shapeSegments.length) {
2425
2427
  if (node.type !== "path") notes.push(`"${id}" is a group: its morph or effect animation is not exported (Flair tweens one path's "d").`);
2426
2428
  else {
2427
- const inverse = _chunk7MD7C6XQcjs.invertMatrix.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node));
2429
+ const inverse = _chunkDWGZUSEScjs.invertMatrix.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node));
2428
2430
  channels.push({
2429
2431
  id,
2430
2432
  kind: "attr",
@@ -2433,9 +2435,9 @@ function toFlairSvgMotion(scene, options = {}) {
2433
2435
  exact: () => false,
2434
2436
  value: (t) => {
2435
2437
  const frame = motionFrameAt(scene, t, { draw: false, offsets: false });
2436
- const now = _chunk7MD7C6XQcjs.expandVectorAppearance.call(void 0, _optionalChain([indexMotionNodes, 'call', _108 => _108(frame.document.nodes), 'access', _109 => _109.get, 'call', _110 => _110(id), 'optionalAccess', _111 => _111.node]));
2438
+ const now = _chunkJF5PXN7Wcjs.expandVectorAppearance.call(void 0, _optionalChain([indexMotionNodes, 'call', _108 => _108(frame.document.nodes), 'access', _109 => _109.get, 'call', _110 => _110(id), 'optionalAccess', _111 => _111.node]));
2437
2439
  if (!now || now.type !== "path") return "";
2438
- const bezier = _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, now, _chunk7MD7C6XQcjs.IDENTITY_MATRIX, { effects: false }), inverse);
2440
+ const bezier = _chunkXGD3FSNCcjs.transformBezierPath.call(void 0, _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, now, _chunkDWGZUSEScjs.IDENTITY_MATRIX, { effects: false }), inverse);
2439
2441
  return _chunkXGD3FSNCcjs.bezierPathToSvg.call(void 0, bezier, { precision: Math.min(precision, 2) });
2440
2442
  }
2441
2443
  });
@@ -2542,7 +2544,7 @@ function toFlairSvgMotion(scene, options = {}) {
2542
2544
  }
2543
2545
  if (scene.motionBlur) notes.push("Motion blur is drawn on the stage only; Flair plays the scene sharp.");
2544
2546
  if (trigger && (_nullishCoalesce(scene.loop, () => ( "none"))) !== "none") notes.push(`The scene plays on ${trigger}, so its loop does not apply in Flair.`);
2545
- let svg = _chunk7MD7C6XQcjs.vectorDocumentToSvg.call(void 0, { ...scene.artwork, nodes: _chunk7MD7C6XQcjs.expandVectorAppearances.call(void 0, scene.artwork.nodes) }, { pretty: false, precision, wrap });
2547
+ let svg = _chunkJF5PXN7Wcjs.vectorDocumentToSvg.call(void 0, { ...scene.artwork, nodes: _chunkJF5PXN7Wcjs.expandVectorAppearances.call(void 0, scene.artwork.nodes) }, { pretty: false, precision, wrap });
2546
2548
  if (routes.length) svg = svg.replace(/^(<svg[^>]*>)/, `$1<defs>${routes.join("")}</defs>`);
2547
2549
  let motion = { svg, animate };
2548
2550
  if (_optionalChain([scene, 'access', _114 => _114.controls, 'optionalAccess', _115 => _115.length])) {
@@ -2626,14 +2628,14 @@ function easingOf(ease, fallback) {
2626
2628
  return fallback;
2627
2629
  }
2628
2630
  function poseOf(value, entry) {
2629
- const t = _chunk7MD7C6XQcjs.parseSvgTransform.call(void 0, String(value));
2630
- const o = _chunk7MD7C6XQcjs.multiplyMatrices.call(void 0, _nullishCoalesce(_chunk7MD7C6XQcjs.invertMatrix.call(void 0, _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, entry.node)), () => ( [1, 0, 0, 1, 0, 0])), t);
2631
+ const t = _chunkJF5PXN7Wcjs.parseSvgTransform.call(void 0, String(value));
2632
+ const o = _chunkDWGZUSEScjs.multiplyMatrices.call(void 0, _nullishCoalesce(_chunkDWGZUSEScjs.invertMatrix.call(void 0, _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, entry.node)), () => ( [1, 0, 0, 1, 0, 0])), t);
2631
2633
  const sx = Math.hypot(o[0], o[1]);
2632
2634
  if (!(sx > 1e-9)) return null;
2633
2635
  const sy = (o[0] * o[3] - o[1] * o[2]) / sx;
2634
2636
  if (Math.abs(o[2] + o[1] / sx * sy) > 1e-6 || Math.abs(o[3] - o[0] / sx * sy) > 1e-6) return null;
2635
2637
  const c = entry.center;
2636
- const moved = _chunk7MD7C6XQcjs.applyMatrix.call(void 0, o, c);
2638
+ const moved = _chunkDWGZUSEScjs.applyMatrix.call(void 0, o, c);
2637
2639
  return { dx: moved.x - c.x, dy: moved.y - c.y, rotation: Math.atan2(o[1], o[0]) * 180 / Math.PI, sx, sy };
2638
2640
  }
2639
2641
  var near = (a, b, eps = 1e-6) => Math.abs(a - b) < eps;
@@ -2718,7 +2720,7 @@ function fromFlairSvgMotion(input, options = {}) {
2718
2720
  const notes = [];
2719
2721
  if (!input || typeof input.svg !== "string") throw new Error('Give a Flair SvgMotion: { svg: "<svg \u2026>", animate: [ \u2026 ] }.');
2720
2722
  const { motion, controls } = resolvePlaceholders(input, notes);
2721
- const artwork = _chunk7MD7C6XQcjs.parseVectorSvg.call(void 0, motion.svg);
2723
+ const artwork = _chunkJF5PXN7Wcjs.parseVectorSvg.call(void 0, motion.svg);
2722
2724
  const nodes = indexMotionNodes(artwork.nodes);
2723
2725
  const byStep = /* @__PURE__ */ new Map();
2724
2726
  for (const anim of _nullishCoalesce(motion.animate, () => ( []))) {
@@ -2965,9 +2967,9 @@ function toLottie(scene, options = {}) {
2965
2967
  const items = [];
2966
2968
  const shapeSegments = [...timeline.tracks.entries()].filter(([k]) => k.startsWith(`${path.id}\0`) && (k.endsWith("\0shape") || k.includes("\0effect:"))).flatMap(([, v]) => v);
2967
2969
  const geometryAt = (t) => {
2968
- if (!shapeSegments.length) return _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, path);
2970
+ if (!shapeSegments.length) return _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, path);
2969
2971
  const now = _optionalChain([indexMotionNodes, 'call', _124 => _124(motionFrameAt(scene, t, { draw: false, offsets: false }).document.nodes), 'access', _125 => _125.get, 'call', _126 => _126(path.id), 'optionalAccess', _127 => _127.node]);
2970
- return now && now.type === "path" ? _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, _chunk7MD7C6XQcjs.expandVectorAppearances.call(void 0, [now])[0]) : _chunk7MD7C6XQcjs.vectorPathWorldBezier.call(void 0, path);
2972
+ return now && now.type === "path" ? _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, _chunkJF5PXN7Wcjs.expandVectorAppearances.call(void 0, [now])[0]) : _chunkJF5PXN7Wcjs.vectorPathWorldBezier.call(void 0, path);
2971
2973
  };
2972
2974
  const rest = lottieContours(_chunkXGD3FSNCcjs.toBezierPath.call(void 0, geometryAt(0)), round2);
2973
2975
  rest.forEach((contour, n) => {
@@ -3041,8 +3043,8 @@ function toLottie(scene, options = {}) {
3041
3043
  if (node.type === "path") inner = [...pathShapes(node)];
3042
3044
  else {
3043
3045
  inner = shown(node.children).reverse().map(nodeGroup);
3044
- const m = _chunk7MD7C6XQcjs.nodeMatrix.call(void 0, node);
3045
- if (m !== _chunk7MD7C6XQcjs.IDENTITY_MATRIX) {
3046
+ const m = _chunkJF5PXN7Wcjs.nodeMatrix.call(void 0, node);
3047
+ if (m !== _chunkDWGZUSEScjs.IDENTITY_MATRIX) {
3046
3048
  const parts = staticParts(m);
3047
3049
  if (!parts) notes.push(`"${node.id}": its transform skews, which is not exported; it is drawn without the skew.`);
3048
3050
  else {
@@ -3055,7 +3057,7 @@ function toLottie(scene, options = {}) {
3055
3057
  const body = { ty: "gr", nm: `${node.id} (own)`, it: [...inner, innerTr] };
3056
3058
  return { ty: "gr", nm: _nullishCoalesce(node.name, () => ( node.id)), it: [body, poseTransform(entry)] };
3057
3059
  };
3058
- const artwork = { ...scene.artwork, nodes: _chunk7MD7C6XQcjs.expandVectorAppearances.call(void 0, scene.artwork.nodes) };
3060
+ const artwork = { ...scene.artwork, nodes: _chunkJF5PXN7Wcjs.expandVectorAppearances.call(void 0, scene.artwork.nodes) };
3059
3061
  const content = shown(artwork.nodes).reverse().map(nodeGroup);
3060
3062
  if (artwork.background && rgba(artwork.background))
3061
3063
  content.push({ ty: "gr", nm: "Background", it: [{ ty: "rc", nm: "Background", p: { a: 0, k: [artwork.width / 2, artwork.height / 2] }, s: { a: 0, k: [artwork.width, artwork.height] }, r: { a: 0, k: 0 } }, { ty: "fl", c: { a: 0, k: rgba(artwork.background).map(round2) }, o: { a: 0, k: 100 }, r: 1 }, STATIC_TR()] });
@@ -3154,11 +3156,11 @@ function preset(prst, w, h) {
3154
3156
  const poly = (pts) => [{ closed: true, anchors: pts.map(([x, y]) => ({ x, y })) }];
3155
3157
  switch (prst) {
3156
3158
  case "rect":
3157
- return [_chunk7MD7C6XQcjs.rectSubpath.call(void 0, { x: 0, y: 0, width: w, height: h })];
3159
+ return [_chunkJF5PXN7Wcjs.rectSubpath.call(void 0, { x: 0, y: 0, width: w, height: h })];
3158
3160
  case "roundRect":
3159
- return [_chunk7MD7C6XQcjs.rectSubpath.call(void 0, { x: 0, y: 0, width: w, height: h }, Math.min(w, h) * 0.16667)];
3161
+ return [_chunkJF5PXN7Wcjs.rectSubpath.call(void 0, { x: 0, y: 0, width: w, height: h }, Math.min(w, h) * 0.16667)];
3160
3162
  case "ellipse":
3161
- return [_chunk7MD7C6XQcjs.ellipseSubpath.call(void 0, { x: 0, y: 0, width: w, height: h })];
3163
+ return [_chunkJF5PXN7Wcjs.ellipseSubpath.call(void 0, { x: 0, y: 0, width: w, height: h })];
3162
3164
  case "triangle":
3163
3165
  return poly([[w / 2, 0], [w, h], [0, h]]);
3164
3166
  case "rtTriangle":
@@ -3266,7 +3268,7 @@ function shapes(ctx, tree, map) {
3266
3268
  let subpaths = cust ? custom(cust, w, h) : prst ? preset(prst, w, h) : null;
3267
3269
  if (!subpaths) {
3268
3270
  if (prst) ctx.notes.push(`"${name}" is a ${prst}, drawn as its bounding rectangle.`);
3269
- subpaths = [_chunk7MD7C6XQcjs.rectSubpath.call(void 0, { x: 0, y: 0, width: w, height: h })];
3271
+ subpaths = [_chunkJF5PXN7Wcjs.rectSubpath.call(void 0, { x: 0, y: 0, width: w, height: h })];
3270
3272
  }
3271
3273
  const style = kid(el, "style");
3272
3274
  const fill = kid(spPr, "noFill") ? null : _nullishCoalesce(colour(ctx, kid(spPr, "solidFill")), () => ( (el.localName === "cxnSp" ? null : colour(ctx, kid(style, "fillRef")))));
@@ -4251,7 +4253,7 @@ function createAnimationEditorToolProvider(controller, options = {}) {
4251
4253
  handler: ({ svg }) => {
4252
4254
  let artwork;
4253
4255
  try {
4254
- artwork = _chunk7MD7C6XQcjs.parseVectorSvg.call(void 0, svg);
4256
+ artwork = _chunkJF5PXN7Wcjs.parseVectorSvg.call(void 0, svg);
4255
4257
  } catch (error) {
4256
4258
  throw new Error(`The SVG could not be read: ${error.message}. Nothing was changed.`);
4257
4259
  }