@pixldocs/canvas-renderer 0.5.362 → 0.5.364
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.
- package/dist/{index-WH1l4oST.js → index-BX1STPJj.js} +12 -9
- package/dist/index-BX1STPJj.js.map +1 -0
- package/dist/{index-DQ-6sfz_.cjs → index-C1ijZRH6.cjs} +12 -9
- package/dist/index-C1ijZRH6.cjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-BVELqTIO.js → vectorPdfExport-DHpvNU2-.js} +4 -4
- package/dist/{vectorPdfExport-BVELqTIO.js.map → vectorPdfExport-DHpvNU2-.js.map} +1 -1
- package/dist/{vectorPdfExport-BAjK5RAp.cjs → vectorPdfExport-Sn_yZjdL.cjs} +4 -4
- package/dist/{vectorPdfExport-BAjK5RAp.cjs.map → vectorPdfExport-Sn_yZjdL.cjs.map} +1 -1
- package/package.json +1 -1
- package/dist/index-DQ-6sfz_.cjs.map +0 -1
- package/dist/index-WH1l4oST.js.map +0 -1
|
@@ -12960,7 +12960,6 @@ const PageCanvas = forwardRef(
|
|
|
12960
12960
|
const shouldRestoreGroupSelection = !!((preservedGroupSelection == null ? void 0 : preservedGroupSelection.groupSelectionId) && (!preservedGroupSelection.expiresAt || preservedGroupSelection.expiresAt > Date.now()));
|
|
12961
12961
|
if (skipSelectionClearOnDiscardRef.current) {
|
|
12962
12962
|
skipSelectionClearOnDiscardRef.current = false;
|
|
12963
|
-
if (shouldRestoreGroupSelection) restorePreservedGroupSelectionSoon(preservedGroupSelection);
|
|
12964
12963
|
return;
|
|
12965
12964
|
}
|
|
12966
12965
|
const recentGroupSelectionRestore = recentGroupSelectionRestoreRef.current;
|
|
@@ -15306,8 +15305,13 @@ const PageCanvas = forwardRef(
|
|
|
15306
15305
|
} catch {
|
|
15307
15306
|
}
|
|
15308
15307
|
try {
|
|
15309
|
-
|
|
15310
|
-
|
|
15308
|
+
const textCenterX = decomposed.translateX ?? absoluteLeft;
|
|
15309
|
+
const textCenterY = decomposed.translateY ?? absoluteTop;
|
|
15310
|
+
const theta = fabric.util.degreesToRadians(decomposed.angle ?? 0);
|
|
15311
|
+
const cos = Math.cos(theta);
|
|
15312
|
+
const sin = Math.sin(theta);
|
|
15313
|
+
absoluteLeft = textCenterX - (cos * finalWidth / 2 - sin * finalHeight / 2);
|
|
15314
|
+
absoluteTop = textCenterY - (sin * finalWidth / 2 + cos * finalHeight / 2);
|
|
15311
15315
|
} catch {
|
|
15312
15316
|
}
|
|
15313
15317
|
finalAbsoluteMatrix = fabric.util.composeMatrix({
|
|
@@ -15550,7 +15554,6 @@ const PageCanvas = forwardRef(
|
|
|
15550
15554
|
expiresAt: Date.now() + 1200
|
|
15551
15555
|
};
|
|
15552
15556
|
recentGroupSelectionRestoreRef.current = resizeRestoreSnapshot;
|
|
15553
|
-
restorePreservedGroupSelectionSoon(resizeRestoreSnapshot);
|
|
15554
15557
|
}
|
|
15555
15558
|
fabricCanvas.requestRenderAll();
|
|
15556
15559
|
}
|
|
@@ -24586,9 +24589,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
24586
24589
|
}
|
|
24587
24590
|
return svgString;
|
|
24588
24591
|
}
|
|
24589
|
-
const resolvedPackageVersion = "0.5.
|
|
24592
|
+
const resolvedPackageVersion = "0.5.364";
|
|
24590
24593
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
24591
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
24594
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.364";
|
|
24592
24595
|
const roundParityValue = (value) => {
|
|
24593
24596
|
if (typeof value !== "number") return value;
|
|
24594
24597
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -25402,7 +25405,7 @@ class PixldocsRenderer {
|
|
|
25402
25405
|
await this.waitForCanvasScene(container, cloned, i);
|
|
25403
25406
|
}
|
|
25404
25407
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
25405
|
-
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-
|
|
25408
|
+
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-DHpvNU2-.js");
|
|
25406
25409
|
const prepared = preparePagesForExport(
|
|
25407
25410
|
cloned.pages,
|
|
25408
25411
|
canvasWidth,
|
|
@@ -27722,7 +27725,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
27722
27725
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
27723
27726
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
27724
27727
|
try {
|
|
27725
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-
|
|
27728
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-DHpvNU2-.js");
|
|
27726
27729
|
try {
|
|
27727
27730
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
27728
27731
|
} catch {
|
|
@@ -28122,4 +28125,4 @@ export {
|
|
|
28122
28125
|
buildTeaserBlurFlatKeys as y,
|
|
28123
28126
|
collectFontDescriptorsFromConfig as z
|
|
28124
28127
|
};
|
|
28125
|
-
//# sourceMappingURL=index-
|
|
28128
|
+
//# sourceMappingURL=index-BX1STPJj.js.map
|