@pixldocs/canvas-renderer 0.5.289 → 0.5.290

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.
@@ -14479,6 +14479,7 @@ const PageCanvas = forwardRef(
14479
14479
  finalScaleX = 1;
14480
14480
  finalScaleY = 1;
14481
14481
  try {
14482
+ const preBakeCenter = obj.getCenterPoint();
14482
14483
  if (isCornerHandle) {
14483
14484
  const baseFontSize = Number((sourceElement == null ? void 0 : sourceElement.fontSize) ?? obj.fontSize ?? 16);
14484
14485
  const nextFontSize = Math.max(1, baseFontSize * fontScale);
@@ -14489,8 +14490,13 @@ const PageCanvas = forwardRef(
14489
14490
  bakedTextScaleUpdates.minBoxHeight = Math.max(0, nextMinH);
14490
14491
  obj.minBoxHeight = bakedTextScaleUpdates.minBoxHeight;
14491
14492
  }
14492
- obj.set({ width: bakedWidth, scaleX: 1, scaleY: 1 });
14493
+ const prevObjCaching = obj.objectCaching;
14494
+ obj.set({ width: bakedWidth, scaleX: 1, scaleY: 1, objectCaching: false });
14493
14495
  obj.initDimensions();
14496
+ obj.setPositionByOrigin(preBakeCenter, "center", "center");
14497
+ obj.objectCaching = prevObjCaching;
14498
+ obj.dirty = true;
14499
+ if (activeObj) activeObj.dirty = true;
14494
14500
  finalWidth = bakedWidth;
14495
14501
  finalHeight = Math.max(1, obj.height ?? intrinsicHeight * sy);
14496
14502
  obj.__pixldocsBakedTextScaleUpdates = bakedTextScaleUpdates;
@@ -23649,9 +23655,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
23649
23655
  }
23650
23656
  return svgString;
23651
23657
  }
23652
- const resolvedPackageVersion = "0.5.289";
23658
+ const resolvedPackageVersion = "0.5.290";
23653
23659
  const PACKAGE_VERSION = resolvedPackageVersion;
23654
- const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.289";
23660
+ const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.290";
23655
23661
  const roundParityValue = (value) => {
23656
23662
  if (typeof value !== "number") return value;
23657
23663
  return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
@@ -24465,7 +24471,7 @@ class PixldocsRenderer {
24465
24471
  await this.waitForCanvasScene(container, cloned, i);
24466
24472
  }
24467
24473
  console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
24468
- const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-rGdZJ7ux.js");
24474
+ const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-BW4Ihi3j.js");
24469
24475
  const prepared = preparePagesForExport(
24470
24476
  cloned.pages,
24471
24477
  canvasWidth,
@@ -26785,7 +26791,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
26785
26791
  if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
26786
26792
  sanitizeSvgTreeForPdf(svgToDraw);
26787
26793
  try {
26788
- const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-rGdZJ7ux.js");
26794
+ const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-BW4Ihi3j.js");
26789
26795
  try {
26790
26796
  await logTextMeasurementDiagnostic(svgToDraw);
26791
26797
  } catch {
@@ -27185,4 +27191,4 @@ export {
27185
27191
  buildTeaserBlurFlatKeys as y,
27186
27192
  collectFontDescriptorsFromConfig as z
27187
27193
  };
27188
- //# sourceMappingURL=index-8DBd7ACA.js.map
27194
+ //# sourceMappingURL=index-B6JMRs-J.js.map