stickyflow 0.8.0 → 0.9.1

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 (63) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/README.md +1 -1
  3. package/dist/binding/index.cjs +9 -9
  4. package/dist/binding/index.d.cts +4 -4
  5. package/dist/binding/index.d.ts +4 -4
  6. package/dist/binding/index.js +3 -3
  7. package/dist/{chunk-VOYX6JMW.cjs → chunk-5EY7EK5V.cjs} +797 -669
  8. package/dist/chunk-5EY7EK5V.cjs.map +1 -0
  9. package/dist/{chunk-EDOPENSE.js → chunk-7ZEC7AB4.js} +228 -46
  10. package/dist/chunk-7ZEC7AB4.js.map +1 -0
  11. package/dist/{chunk-XPM3E7NV.cjs → chunk-BL5NCXS4.cjs} +23 -23
  12. package/dist/chunk-BL5NCXS4.cjs.map +1 -0
  13. package/dist/{chunk-LFEGZJWC.js → chunk-CM35H45Z.js} +3 -3
  14. package/dist/{chunk-LFEGZJWC.js.map → chunk-CM35H45Z.js.map} +1 -1
  15. package/dist/{chunk-GLZVHUSW.js → chunk-D2266VBZ.js} +393 -5
  16. package/dist/chunk-D2266VBZ.js.map +1 -0
  17. package/dist/{chunk-CZW3ARXQ.js → chunk-IKTSCLIK.js} +5 -5
  18. package/dist/chunk-IKTSCLIK.js.map +1 -0
  19. package/dist/{chunk-FQ7GMLCM.cjs → chunk-OUWGWDJ2.cjs} +15 -15
  20. package/dist/{chunk-FQ7GMLCM.cjs.map → chunk-OUWGWDJ2.cjs.map} +1 -1
  21. package/dist/{chunk-LNW5VIEA.cjs → chunk-QL7MNEMT.cjs} +393 -4
  22. package/dist/chunk-QL7MNEMT.cjs.map +1 -0
  23. package/dist/{chunk-IR2T47NW.cjs → chunk-RUSNRDLI.cjs} +257 -75
  24. package/dist/chunk-RUSNRDLI.cjs.map +1 -0
  25. package/dist/{chunk-MAPNY7MJ.js → chunk-TH2HFMEL.js} +147 -19
  26. package/dist/chunk-TH2HFMEL.js.map +1 -0
  27. package/dist/index.cjs +36 -36
  28. package/dist/index.d.cts +5 -5
  29. package/dist/index.d.ts +5 -5
  30. package/dist/index.js +5 -5
  31. package/dist/interaction/index.cjs +232 -230
  32. package/dist/interaction/index.cjs.map +1 -1
  33. package/dist/interaction/index.d.cts +2 -2
  34. package/dist/interaction/index.d.ts +2 -2
  35. package/dist/interaction/index.js +4 -2
  36. package/dist/interaction/index.js.map +1 -1
  37. package/dist/{render-Bp2FLEzv.d.cts → render-DU4lYbRl.d.cts} +19 -11
  38. package/dist/{render-Bp2FLEzv.d.ts → render-DU4lYbRl.d.ts} +19 -11
  39. package/dist/{runtime-DIag-XBa.d.cts → runtime-DG8X3Fwf.d.cts} +2 -2
  40. package/dist/{runtime-CWIGxRcL.d.ts → runtime-kqD1RS17.d.ts} +2 -2
  41. package/dist/{runtimeTypes-C7sSLfOK.d.ts → runtimeTypes-CvjlBZds.d.cts} +7 -3
  42. package/dist/{runtimeTypes-BYODuxHk.d.cts → runtimeTypes-vRaHOIHi.d.ts} +7 -3
  43. package/dist/stickyflow-diagram.global.js +192 -40
  44. package/dist/stickyflow-diagram.global.js.map +1 -1
  45. package/dist/{types-D2w6D_wG.d.cts → types-B5jrEEcF.d.cts} +1 -1
  46. package/dist/{types-B9QM_H3R.d.ts → types-B7IkZ0w4.d.ts} +1 -1
  47. package/dist/viewer/index.cjs +9 -9
  48. package/dist/viewer/index.d.cts +4 -4
  49. package/dist/viewer/index.d.ts +4 -4
  50. package/dist/viewer/index.js +4 -4
  51. package/dist/web-component/index.cjs +6 -6
  52. package/dist/web-component/index.d.cts +2 -2
  53. package/dist/web-component/index.d.ts +2 -2
  54. package/dist/web-component/index.js +4 -4
  55. package/package.json +1 -1
  56. package/dist/chunk-CZW3ARXQ.js.map +0 -1
  57. package/dist/chunk-EDOPENSE.js.map +0 -1
  58. package/dist/chunk-GLZVHUSW.js.map +0 -1
  59. package/dist/chunk-IR2T47NW.cjs.map +0 -1
  60. package/dist/chunk-LNW5VIEA.cjs.map +0 -1
  61. package/dist/chunk-MAPNY7MJ.js.map +0 -1
  62. package/dist/chunk-VOYX6JMW.cjs.map +0 -1
  63. package/dist/chunk-XPM3E7NV.cjs.map +0 -1
@@ -1,4 +1,4 @@
1
- import { componentRegistryVersion, isDimensionObject, isIsometricObject, sflToCanvasState, registerComponentDescriptor, isBuiltInComponentType, getComponentDescriptor, tag, EMPTY_BOUNDS, DOM_CONTRACT_VERSION, edgePointToward, elementCenter, VISIBLE_ISOMETRIC_FACES, isometricFaceCenter, finite, freeformPathData, rotatedBounds, DEFAULT_FONT, isGenericComponent, cleanFootprint, pointAtNormalizedPort, boxBounds, cornersRoundedRectPath, calculateLinkRoute, labelGapDash, getLineMidpoint, personLabelArea, wrapText, heuristicRichMeasure, shadeFill, extrudeFootprint, isometricFaces, roundedPolygonPath, stackSequence, stackRank, topRoundedRectPath, rightRoundedRectPath, leftRoundedRectPath, bottomRoundedRectPath, isHorizontalBar, paint, CHART_TITLE_PROP, chartText, chartTicks, mapChartValue, roundedOrthogonalPathData, localShapePath, pillCornerRadius, isometricBounds, AXIS_SIN, deriveFaceFills, labelTilt, tiltedLabelRoom, resolveChartShadow, CHART_COLORS, angleForAxisValue, horizontalRows, rowTop, categoryProp, isometricTopFaceCenter, ISOMETRIC_SIZE_ATTR, CORNER_RADIUS_ATTR, ISOMETRIC_LABEL_OFFSET_ATTR, PATH_POINTS_ATTR, PATH_TENSION_ATTR, PATH_CLOSED_ATTR, SYMBOL_BOUNDS_ATTR, SYMBOL_POINTS_ATTR, SYMBOL_TENSION_ATTR, SQUARE_CORNER_ATTR, resolvePieRadii, radarCategoryCount, radarRadius, createPieGeometry, DEFAULT_HEX_RADIUS, DEFAULT_HEATMAP_ZONES, axisBands, DEFAULT_ZONE_FILL, representativeColor, computeBoxplotStats, barCategoryCount, ruleAtProp, ruleTextProp, labelBelowFrame, seriesLabelProp, axisLabelProp, seriesColorProp, seriesValueProp, radarSeriesPath, radarRadiusForValue, createPieSlicePath, clipSegmentToRect, formatFieldValue, renderPieLabels, interpolateHexColorStops, contrastTextColor, sameHueTint, isLightColor, barShapePath, linePathData, colorWithAlpha, estimateTextWidth, segmentedBarPath, roundedBarPath, radarPointAt, gapInsetAngle, pieUsesInnerArc, maxPieCornerRadius, pieApexRadius, maxApexCornerRadius, pieArcPoint, sameHueContrastColor, zoneColorAtValue, ellipsizeToWidth, barPath, labelAboveFrame, seriesValueColorProp, stackedSegment, errorBarRange, createVerticalErrorWhiskerNode, formatBarLabel, barLabelSize, CATEGORY_LABEL_ROW, BAR_LABEL, pillPath, resolveRollingNumberStyle, formatRollingNumber } from './chunk-GLZVHUSW.js';
1
+ import { componentRegistryVersion, isDimensionObject, isIsometricObject, sflToCanvasState, registerComponentDescriptor, isBuiltInComponentType, getComponentDescriptor, tag, EMPTY_BOUNDS, DOM_CONTRACT_VERSION, edgePointToward, elementCenter, VISIBLE_ISOMETRIC_FACES, isometricFaceCenter, finite, freeformPathData, rotatedBounds, DEFAULT_FONT, isGenericComponent, cleanFootprint, pointAtNormalizedPort, boxBounds, cornersRoundedRectPath, calculateLinkRoute, labelGapDash, getLineMidpoint, personLabelArea, wrapText, heuristicRichMeasure, shadeFill, extrudeFootprint, isometricFaces, roundedPolygonPath, stackSequence, stackRank, topRoundedRectPath, rightRoundedRectPath, leftRoundedRectPath, bottomRoundedRectPath, isHorizontalBar, paint, CHART_TITLE_PROP, chartText, chartTicks, mapChartValue, roundedOrthogonalPathData, localShapePath, pillCornerRadius, isometricBounds, AXIS_SIN, deriveFaceFills, labelTilt, tiltedLabelRoom, resolveChartShadow, CHART_COLORS, angleForAxisValue, horizontalRows, rowTop, categoryProp, isometricTopFaceCenter, ISOMETRIC_SIZE_ATTR, CORNER_RADIUS_ATTR, ISOMETRIC_LABEL_OFFSET_ATTR, PATH_POINTS_ATTR, PATH_TENSION_ATTR, PATH_CLOSED_ATTR, SYMBOL_BOUNDS_ATTR, SYMBOL_POINTS_ATTR, SYMBOL_TENSION_ATTR, SQUARE_CORNER_ATTR, resolvePieRadii, radarCategoryCount, radarRadius, createPieGeometry, DEFAULT_HEX_RADIUS, DEFAULT_HEATMAP_ZONES, axisBands, DEFAULT_ZONE_FILL, representativeColor, computeBoxplotStats, barCategoryCount, ruleAtProp, ruleTextProp, labelBelowFrame, seriesLabelProp, axisLabelProp, seriesColorProp, seriesValueProp, radarSeriesPath, radarRadiusForValue, createPieSlicePath, clipSegmentToRect, formatFieldValue, renderPieLabels, interpolateHexColorStops, contrastTextColor, sameHueTint, isLightColor, barShapePath, linePathData, colorWithAlpha, estimateTextWidth, segmentedBarPath, roundedBarPath, radarPointAt, gapInsetAngle, pieUsesInnerArc, maxPieCornerRadius, pieApexRadius, maxApexCornerRadius, pieArcPoint, sameHueContrastColor, zoneColorAtValue, ellipsizeToWidth, barPath, labelAboveFrame, seriesValueColorProp, stackedSegment, errorBarRange, createVerticalErrorWhiskerNode, formatBarLabel, barLabelSize, CATEGORY_LABEL_ROW, BAR_LABEL, pillPath, resolveRollingNumberStyle, formatRollingNumber } from './chunk-D2266VBZ.js';
2
2
 
3
3
  // src/renderInput/styleDecoding/colorToken.ts
4
4
  var COLOR_TOKEN_PATTERN = String.raw`rgba?\([^)]*\)|#[0-9a-fA-F]+|[a-zA-Z][\w-]*`;
@@ -161,6 +161,23 @@ var PATH_TYPES = ["straight", "curved", "orthogonal"];
161
161
  function optionalOneOf(value, allowed) {
162
162
  return value !== void 0 && allowed.includes(value) ? value : void 0;
163
163
  }
164
+ var BLEND_MODES = [
165
+ "multiply",
166
+ "screen",
167
+ "overlay",
168
+ "darken",
169
+ "lighten",
170
+ "color-dodge",
171
+ "color-burn",
172
+ "hard-light",
173
+ "soft-light",
174
+ "difference",
175
+ "exclusion",
176
+ "hue",
177
+ "saturation",
178
+ "color",
179
+ "luminosity"
180
+ ];
164
181
  var SHAPE_STROKE_STYLES = ["solid", "dashed", "dotted", "double"];
165
182
  var MARKER_TYPES = [
166
183
  "none",
@@ -896,6 +913,7 @@ function frameObject(e) {
896
913
  showLabel: p.showLabel !== "false",
897
914
  labelPosition: oneOf(p.labelPosition, LABEL_POSITIONS, "top"),
898
915
  shadow: p.shadow !== "false",
916
+ clip: p.clip === "true" || void 0,
899
917
  order: e.order,
900
918
  sourceIndex: e.sourceIndex
901
919
  };
@@ -923,6 +941,7 @@ function isometricObject(canvasObject) {
923
941
  strokeColor: solidColor(presentation.stroke) ?? "#111827",
924
942
  strokeWidth: numOf(presentation.strokeWidth) ?? 1,
925
943
  cornerRadius: numOf(presentation.cornerRadius) ?? (canvasObject.isometric.footprint ? 0 : 8),
944
+ seams: presentation.seams === "false" ? false : void 0,
926
945
  hasShadow: shadowStyle?.enabled ?? false,
927
946
  shadowStyle,
928
947
  labelOffsetX: numOf(presentation.labelOffsetX) ?? 0,
@@ -1027,6 +1046,8 @@ function shapeObject(e, shaders) {
1027
1046
  dash: dashArray(p.dash),
1028
1047
  strokeStyle: optionalOneOf(p.strokeStyle, SHAPE_STROKE_STYLES),
1029
1048
  opacity: numOf(p.opacity),
1049
+ blur: numOf(p.blur),
1050
+ blend: optionalOneOf(p.blend, BLEND_MODES),
1030
1051
  parentFrameId: e.parentFrameId,
1031
1052
  order: e.order,
1032
1053
  sourceIndex: e.sourceIndex,
@@ -2957,10 +2978,10 @@ function buildBox(object, index) {
2957
2978
  const hullPath = roundedPolygonPath(silhouette(object), cornerRadius);
2958
2979
  const hullClip = { type: "path", d: hullPath };
2959
2980
  const groundShadow = groundShadowNode(context, faces.top);
2960
- const seams = seamsNode(context, faces, hullClip);
2981
+ const seams = object.seams === false ? void 0 : seamsNode(context, faces, hullClip);
2961
2982
  const hull = hullNode(context, hullPath, cornerRadius);
2962
2983
  const facesNodes = faceNodes(context, faces, hullClip);
2963
- const objectNodes = groundShadow ? [hull, ...facesNodes, groundShadow, seams] : [hull, ...facesNodes, seams];
2984
+ const objectNodes = groundShadow ? [hull, ...facesNodes, groundShadow, ...seams ? [seams] : []] : [hull, ...facesNodes, ...seams ? [seams] : []];
2964
2985
  return object.text ? [...objectNodes, ...labelNodes(context, object.text)] : objectNodes;
2965
2986
  }
2966
2987
 
@@ -3553,7 +3574,8 @@ var RECT_PROGRAMS = /* @__PURE__ */ new Set([
3553
3574
  "ledMatrix",
3554
3575
  "lightBand",
3555
3576
  "silkFolds",
3556
- "glowCard"
3577
+ "glowCard",
3578
+ "glassDots"
3557
3579
  ]);
3558
3580
  function shaderMask(context) {
3559
3581
  if (context.shape.shapeType === "circle" || context.shape.shapeType === "oval") {
@@ -3664,6 +3686,8 @@ function shapeStyle(shape, diagnostics) {
3664
3686
  dash: shapeDash(shape, strokeWidth),
3665
3687
  lineCap: shape.strokeStyle === "dotted" ? "round" : "butt",
3666
3688
  opacity: finite(shape.opacity, defaults.opacity),
3689
+ blur: shape.blur !== void 0 && shape.blur > 0 ? shape.blur : void 0,
3690
+ blend: shape.blend,
3667
3691
  shadow: shadow?.enabled ? {
3668
3692
  color: shadow.color ?? "#000000",
3669
3693
  opacity: finite(shadow.opacity, 0.25),
@@ -9473,16 +9497,111 @@ function buildCharts(charts, diagnostics) {
9473
9497
  );
9474
9498
  }
9475
9499
 
9500
+ // src/renderScene/scene/frameClip.ts
9501
+ var ARC_STEPS = 8;
9502
+ function turnOf(node) {
9503
+ const turned = node;
9504
+ if (!turned.rotation) {
9505
+ return void 0;
9506
+ }
9507
+ if (turned.rotationCenter) {
9508
+ return { angle: turned.rotation, x: turned.rotationCenter.x, y: turned.rotationCenter.y };
9509
+ }
9510
+ if (turned.cx !== void 0 && turned.cy !== void 0) {
9511
+ return { angle: turned.rotation, x: turned.cx, y: turned.cy };
9512
+ }
9513
+ if (turned.x !== void 0 && turned.y !== void 0 && turned.width !== void 0 && turned.height !== void 0) {
9514
+ return { angle: turned.rotation, x: turned.x + turned.width / 2, y: turned.y + turned.height / 2 };
9515
+ }
9516
+ return void 0;
9517
+ }
9518
+ function roundedRectPoints(frame) {
9519
+ const { x, y, width, height } = frame;
9520
+ const r = Math.max(0, Math.min(frame.cornerRadius, width / 2, height / 2));
9521
+ if (r === 0) {
9522
+ return [
9523
+ [x, y],
9524
+ [x + width, y],
9525
+ [x + width, y + height],
9526
+ [x, y + height]
9527
+ ];
9528
+ }
9529
+ const corners = [
9530
+ [x + width - r, y + r, -90],
9531
+ [x + width - r, y + height - r, 0],
9532
+ [x + r, y + height - r, 90],
9533
+ [x + r, y + r, 180]
9534
+ ];
9535
+ return corners.flatMap(
9536
+ ([cx, cy, start]) => Array.from({ length: ARC_STEPS + 1 }, (_, step) => {
9537
+ const angle = (start + 90 * step / ARC_STEPS) * Math.PI / 180;
9538
+ return [cx + r * Math.cos(angle), cy + r * Math.sin(angle)];
9539
+ })
9540
+ );
9541
+ }
9542
+ function clipFor(frame, turn) {
9543
+ if (!turn) {
9544
+ return { type: "rect", x: frame.x, y: frame.y, width: frame.width, height: frame.height, rx: frame.cornerRadius };
9545
+ }
9546
+ const back = -turn.angle * Math.PI / 180;
9547
+ const cos = Math.cos(back);
9548
+ const sin = Math.sin(back);
9549
+ const points = roundedRectPoints(frame).map(([px, py]) => {
9550
+ const dx = px - turn.x;
9551
+ const dy = py - turn.y;
9552
+ return [turn.x + dx * cos - dy * sin, turn.y + dx * sin + dy * cos];
9553
+ });
9554
+ const round2 = (value) => Math.round(value * 100) / 100;
9555
+ return { type: "path", d: `M${points.map(([px, py]) => `${round2(px)} ${round2(py)}`).join("L")}Z` };
9556
+ }
9557
+ function applyFrameClips(nodes, frames) {
9558
+ const clipping = new Map(frames.filter((frame) => frame.clip).map((frame) => [frame.id, frame]));
9559
+ if (clipping.size === 0) {
9560
+ return;
9561
+ }
9562
+ const inside = /* @__PURE__ */ new Map();
9563
+ for (const node of nodes) {
9564
+ const parent = node.identity?.parentFrameId;
9565
+ const frame = parent ? clipping.get(parent) : void 0;
9566
+ if (node.identity && frame) {
9567
+ inside.set(`${node.identity.role}:${node.identity.id}`, frame);
9568
+ }
9569
+ }
9570
+ for (const node of nodes) {
9571
+ const frame = node.identity ? inside.get(`${node.identity.role}:${node.identity.id}`) : void 0;
9572
+ const styled = node;
9573
+ if (frame && styled.style) {
9574
+ const edge = clipFor(frame, turnOf(node));
9575
+ styled.style = { ...styled.style, clip: styled.style.clip ? { ...styled.style.clip, within: edge } : edge };
9576
+ }
9577
+ }
9578
+ }
9579
+
9476
9580
  // src/renderScene/scene/build.ts
9581
+ function visibleBounds(node) {
9582
+ let { minX, minY, maxX, maxY } = node.bounds;
9583
+ let clip = "style" in node ? node.style?.clip : void 0;
9584
+ while (clip) {
9585
+ if (clip.type === "rect") {
9586
+ minX = Math.max(minX, clip.x);
9587
+ minY = Math.max(minY, clip.y);
9588
+ maxX = Math.min(maxX, clip.x + clip.width);
9589
+ maxY = Math.min(maxY, clip.y + clip.height);
9590
+ }
9591
+ clip = clip.within;
9592
+ }
9593
+ return minX <= maxX && minY <= maxY ? { minX, minY, maxX, maxY } : node.bounds;
9594
+ }
9477
9595
  function sceneBounds(nodes) {
9478
9596
  if (!nodes.length) {
9479
9597
  return EMPTY_BOUNDS;
9480
9598
  }
9599
+ const all = nodes.map(visibleBounds);
9481
9600
  return {
9482
- minX: Math.min(...nodes.map((n) => n.bounds.minX)),
9483
- minY: Math.min(...nodes.map((n) => n.bounds.minY)),
9484
- maxX: Math.max(...nodes.map((n) => n.bounds.maxX)),
9485
- maxY: Math.max(...nodes.map((n) => n.bounds.maxY))
9601
+ minX: Math.min(...all.map((b) => b.minX)),
9602
+ minY: Math.min(...all.map((b) => b.minY)),
9603
+ maxX: Math.max(...all.map((b) => b.maxX)),
9604
+ maxY: Math.max(...all.map((b) => b.maxY))
9486
9605
  };
9487
9606
  }
9488
9607
  function stackingOf(input) {
@@ -9531,6 +9650,7 @@ function buildRenderScene(input, options = {}) {
9531
9650
  ...buildIsometricObjects(input.isometricObjects ?? []),
9532
9651
  ...buildDimensions(input.dimensions ?? [])
9533
9652
  ];
9653
+ applyFrameClips(nodes, input.frames);
9534
9654
  stampStacking(nodes, input);
9535
9655
  nodes.sort(
9536
9656
  (a, b) => (a.rank ?? 0) - (b.rank ?? 0) || (a.sequence ?? 0) - (b.sequence ?? 0) || a.order - b.order || (a.id < b.id ? -1 : a.id > b.id ? 1 : 0)
@@ -9553,17 +9673,17 @@ var SvgClipDefinitions = class {
9553
9673
  prefix;
9554
9674
  ids = /* @__PURE__ */ new Map();
9555
9675
  clip(style) {
9556
- if (!style.clip) {
9557
- return void 0;
9558
- }
9559
- const key = JSON.stringify(style.clip);
9676
+ return style.clip ? this.define(style.clip) : void 0;
9677
+ }
9678
+ define(clip) {
9679
+ const key = JSON.stringify(clip);
9560
9680
  let id = this.ids.get(key);
9561
9681
  if (!id) {
9682
+ const outer = clip.within ? this.define(clip.within) : void 0;
9562
9683
  id = safeId(`${this.prefix}clip-${this.ids.size}`);
9563
9684
  this.ids.set(key, id);
9564
- const clip = style.clip;
9565
9685
  const shape = clip.type === "path" ? `<path clip-rule="evenodd" d="${xml(clip.d)}"/>` : `<rect x="${num(clip.x)}" y="${num(clip.y)}" width="${num(clip.width)}" height="${num(clip.height)}" rx="${num(clip.rx)}"/>`;
9566
- this.addDefinition(`<clipPath id="${id}">${shape}</clipPath>`);
9686
+ this.addDefinition(`<clipPath id="${id}"${outer ? ` clip-path="url(#${outer})"` : ""}>${shape}</clipPath>`);
9567
9687
  }
9568
9688
  return id;
9569
9689
  }
@@ -9592,7 +9712,8 @@ var SvgFilterDefinitions = class {
9592
9712
  );
9593
9713
  }
9594
9714
  if (style.blur || style.saturate !== void 0) {
9595
- return this.define(nodeId, { blur: style.blur ?? 0, saturate: style.saturate ?? 1 }, blurPrimitives);
9715
+ const margin = size && size > 0 && style.blur ? Math.max(0.5, style.blur * 1.5 / size) : 0.5;
9716
+ return this.define(nodeId, { blur: style.blur ?? 0, saturate: style.saturate ?? 1 }, blurPrimitives, margin);
9596
9717
  }
9597
9718
  return void 0;
9598
9719
  }
@@ -9839,12 +9960,19 @@ function addStrokeAttrs(attrs, style) {
9839
9960
  if (style.pointerEvents) {
9840
9961
  attrs.push(`pointer-events="${style.pointerEvents}"`);
9841
9962
  }
9963
+ const css = [];
9842
9964
  if (style.transition && style.transition > 0) {
9843
9965
  const time = `${num(style.transition)}ms ease`;
9844
- attrs.push(
9845
- `style="transition: x ${time}, y ${time}, width ${time}, height ${time}, cx ${time}, cy ${time}, rx ${time}, ry ${time}, fill ${time}, stroke ${time}, stroke-width ${time}, stroke-dasharray ${time}, opacity ${time}"`
9966
+ css.push(
9967
+ `transition: x ${time}, y ${time}, width ${time}, height ${time}, cx ${time}, cy ${time}, rx ${time}, ry ${time}, fill ${time}, stroke ${time}, stroke-width ${time}, stroke-dasharray ${time}, opacity ${time}`
9846
9968
  );
9847
9969
  }
9970
+ if (style.blend) {
9971
+ css.push(`mix-blend-mode: ${xml(style.blend)}`);
9972
+ }
9973
+ if (css.length > 0) {
9974
+ attrs.push(`style="${css.join("; ")}"`);
9975
+ }
9848
9976
  }
9849
9977
  function elementSize(node) {
9850
9978
  const shape = node;
@@ -10212,5 +10340,5 @@ function defineComponent(definition) {
10212
10340
  }
10213
10341
 
10214
10342
  export { collectCanvasObjects, decodeColor, decodeShadow, defineComponent, render, renderCanvas, sflToRenderInput, sliderReach };
10215
- //# sourceMappingURL=chunk-MAPNY7MJ.js.map
10216
- //# sourceMappingURL=chunk-MAPNY7MJ.js.map
10343
+ //# sourceMappingURL=chunk-TH2HFMEL.js.map
10344
+ //# sourceMappingURL=chunk-TH2HFMEL.js.map