@pixldocs/canvas-renderer 0.5.438 → 0.5.439
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-BIvYSBXQ.js → index-C7_iudsO.js} +12 -8
- package/dist/index-C7_iudsO.js.map +1 -0
- package/dist/{index-BIAXZTHb.cjs → index-CfAPR8q1.cjs} +12 -8
- package/dist/index-CfAPR8q1.cjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-DW6SkA07.cjs → vectorPdfExport-CTMHlR-q.cjs} +4 -4
- package/dist/{vectorPdfExport-DW6SkA07.cjs.map → vectorPdfExport-CTMHlR-q.cjs.map} +1 -1
- package/dist/{vectorPdfExport-ddzCO9sg.js → vectorPdfExport-DNxCx3pQ.js} +4 -4
- package/dist/{vectorPdfExport-ddzCO9sg.js.map → vectorPdfExport-DNxCx3pQ.js.map} +1 -1
- package/package.json +1 -1
- package/dist/index-BIAXZTHb.cjs.map +0 -1
- package/dist/index-BIvYSBXQ.js.map +0 -1
|
@@ -15141,7 +15141,7 @@ const PageCanvas = react.forwardRef(
|
|
|
15141
15141
|
const normalizedScaleAngle = ((obj.angle ?? 0) % 360 + 360) % 360;
|
|
15142
15142
|
const isRotatedActiveSelectionCorner = obj instanceof fabric__namespace.ActiveSelection && isCornerResizeHandle(corner) && Math.min(normalizedScaleAngle, 360 - normalizedScaleAngle) > 0.5;
|
|
15143
15143
|
const isRotatedActiveSelectionSide = obj instanceof fabric__namespace.ActiveSelection && (corner === "mt" || corner === "mb" || corner === "ml" || corner === "mr") && Math.min(normalizedScaleAngle, 360 - normalizedScaleAngle) > 0.5;
|
|
15144
|
-
const isRotatedSingleObjectScale = !(obj instanceof fabric__namespace.ActiveSelection) && isCornerResizeHandle(corner) && Math.min(normalizedScaleAngle, 360 - normalizedScaleAngle) > 0.5;
|
|
15144
|
+
const isRotatedSingleObjectScale = !(obj instanceof fabric__namespace.ActiveSelection) && (isCornerResizeHandle(corner) || corner === "mt" || corner === "mb" || corner === "ml" || corner === "mr") && Math.min(normalizedScaleAngle, 360 - normalizedScaleAngle) > 0.5;
|
|
15145
15145
|
if (!isRotatedActiveSelectionCorner && !isRotatedActiveSelectionSide && !isRotatedSingleObjectScale) {
|
|
15146
15146
|
snapDuringScaleCallback(obj, corner);
|
|
15147
15147
|
}
|
|
@@ -15266,8 +15266,12 @@ const PageCanvas = react.forwardRef(
|
|
|
15266
15266
|
const sourceEl = objId ? elementsRef.current.find((el) => el.id === objId) : void 0;
|
|
15267
15267
|
bakeTextboxScaleIntoTypography(obj, sourceEl);
|
|
15268
15268
|
}
|
|
15269
|
-
|
|
15270
|
-
const
|
|
15269
|
+
const normResizeAngle = ((obj.angle ?? 0) % 360 + 360) % 360;
|
|
15270
|
+
const isRotatedSingleResize = !(obj instanceof fabric__namespace.ActiveSelection) && Math.min(normResizeAngle, 360 - normResizeAngle) > 0.5;
|
|
15271
|
+
if (!isRotatedSingleResize) {
|
|
15272
|
+
snapDuringScaleCallback(obj, corner);
|
|
15273
|
+
}
|
|
15274
|
+
const scaleGuides = isRotatedSingleResize ? [] : calculateScaleSnapGuidesCallback(obj, corner);
|
|
15271
15275
|
const gridGuidesForTextResize = [];
|
|
15272
15276
|
try {
|
|
15273
15277
|
const psGrid = projectSettingsRef.current;
|
|
@@ -25849,9 +25853,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
25849
25853
|
}
|
|
25850
25854
|
return svgString;
|
|
25851
25855
|
}
|
|
25852
|
-
const resolvedPackageVersion = "0.5.
|
|
25856
|
+
const resolvedPackageVersion = "0.5.439";
|
|
25853
25857
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
25854
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
25858
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.439";
|
|
25855
25859
|
const roundParityValue = (value) => {
|
|
25856
25860
|
if (typeof value !== "number") return value;
|
|
25857
25861
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -26665,7 +26669,7 @@ class PixldocsRenderer {
|
|
|
26665
26669
|
await this.waitForCanvasScene(container, cloned, i);
|
|
26666
26670
|
}
|
|
26667
26671
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
26668
|
-
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
26672
|
+
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-CTMHlR-q.cjs"));
|
|
26669
26673
|
const prepared = preparePagesForExport(
|
|
26670
26674
|
cloned.pages,
|
|
26671
26675
|
canvasWidth,
|
|
@@ -28985,7 +28989,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
28985
28989
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
28986
28990
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
28987
28991
|
try {
|
|
28988
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
28992
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-CTMHlR-q.cjs"));
|
|
28989
28993
|
try {
|
|
28990
28994
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
28991
28995
|
} catch {
|
|
@@ -29382,4 +29386,4 @@ exports.setAutoShrinkDebug = setAutoShrinkDebug;
|
|
|
29382
29386
|
exports.setBundledAssetPrefixes = setBundledAssetPrefixes;
|
|
29383
29387
|
exports.warmResolvedTemplateForPreview = warmResolvedTemplateForPreview;
|
|
29384
29388
|
exports.warmTemplateFromForm = warmTemplateFromForm;
|
|
29385
|
-
//# sourceMappingURL=index-
|
|
29389
|
+
//# sourceMappingURL=index-CfAPR8q1.cjs.map
|