@pixldocs/canvas-renderer 0.5.278 → 0.5.279

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.
@@ -14398,10 +14398,15 @@ const PageCanvas = forwardRef(
14398
14398
  const bounds = getNodeBounds(node, pageAfterMove, pageBoundsOptions);
14399
14399
  const __prevLeft = obj.left;
14400
14400
  const __prevTop = obj.top;
14401
- if (obj instanceof fabric.Group && obj.__cropGroup || obj instanceof fabric.FabricImage && (obj.originX === "center" || obj.originY === "center")) {
14402
- obj.set({ left: abs.left + Math.max(1, bounds.width) / 2, top: abs.top + Math.max(1, bounds.height) / 2 });
14401
+ const useCenterAnchor = obj instanceof fabric.Group && obj.__cropGroup || obj instanceof fabric.FabricImage && (obj.originX === "center" || obj.originY === "center");
14402
+ const nextPoint = new fabric.Point(
14403
+ useCenterAnchor ? abs.left + Math.max(1, bounds.width) / 2 : abs.left,
14404
+ useCenterAnchor ? abs.top + Math.max(1, bounds.height) / 2 : abs.top
14405
+ );
14406
+ if (typeof obj.setXY === "function") {
14407
+ obj.setXY(nextPoint, useCenterAnchor ? "center" : "left", useCenterAnchor ? "center" : "top");
14403
14408
  } else {
14404
- obj.set({ left: abs.left, top: abs.top });
14409
+ obj.set({ left: nextPoint.x, top: nextPoint.y });
14405
14410
  }
14406
14411
  obj.setCoords();
14407
14412
  if (shouldLogGroupMove()) {
@@ -15082,6 +15087,7 @@ const PageCanvas = forwardRef(
15082
15087
  skipSelectionClearOnDiscardRef.current = false;
15083
15088
  }
15084
15089
  }
15090
+ activeSelectionSnapshot.memberIds.forEach((id) => justModifiedIdsRef.current.delete(id));
15085
15091
  }
15086
15092
  const currentFabricObjects = /* @__PURE__ */ new Map();
15087
15093
  fc.getObjects().forEach((obj) => {
@@ -23863,9 +23869,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
23863
23869
  }
23864
23870
  return svgString;
23865
23871
  }
23866
- const resolvedPackageVersion = "0.5.278";
23872
+ const resolvedPackageVersion = "0.5.279";
23867
23873
  const PACKAGE_VERSION = resolvedPackageVersion;
23868
- const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.278";
23874
+ const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.279";
23869
23875
  const roundParityValue = (value) => {
23870
23876
  if (typeof value !== "number") return value;
23871
23877
  return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
@@ -24679,7 +24685,7 @@ class PixldocsRenderer {
24679
24685
  await this.waitForCanvasScene(container, cloned, i);
24680
24686
  }
24681
24687
  console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
24682
- const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-DZihV42S.js");
24688
+ const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-Bp8RGRa1.js");
24683
24689
  const prepared = preparePagesForExport(
24684
24690
  cloned.pages,
24685
24691
  canvasWidth,
@@ -26999,7 +27005,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
26999
27005
  if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
27000
27006
  sanitizeSvgTreeForPdf(svgToDraw);
27001
27007
  try {
27002
- const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-DZihV42S.js");
27008
+ const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-Bp8RGRa1.js");
27003
27009
  try {
27004
27010
  await logTextMeasurementDiagnostic(svgToDraw);
27005
27011
  } catch {
@@ -27399,4 +27405,4 @@ export {
27399
27405
  buildTeaserBlurFlatKeys as y,
27400
27406
  collectFontDescriptorsFromConfig as z
27401
27407
  };
27402
- //# sourceMappingURL=index-Cui21a0a.js.map
27408
+ //# sourceMappingURL=index-mvcNnW-5.js.map