@pixldocs/canvas-renderer 0.5.404 → 0.5.405
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-FljS6ssY.js → index-A1mT_rQo.js} +15 -12
- package/dist/index-A1mT_rQo.js.map +1 -0
- package/dist/{index-BsKKxOH4.cjs → index-uJf5RraI.cjs} +15 -12
- package/dist/index-uJf5RraI.cjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-CWHd6dnp.js → vectorPdfExport-C3La67Vw.js} +4 -4
- package/dist/{vectorPdfExport-CWHd6dnp.js.map → vectorPdfExport-C3La67Vw.js.map} +1 -1
- package/dist/{vectorPdfExport-CMUgVgvn.cjs → vectorPdfExport-DSku6Anm.cjs} +4 -4
- package/dist/{vectorPdfExport-CMUgVgvn.cjs.map → vectorPdfExport-DSku6Anm.cjs.map} +1 -1
- package/package.json +1 -1
- package/dist/index-BsKKxOH4.cjs.map +0 -1
- package/dist/index-FljS6ssY.js.map +0 -1
|
@@ -14169,7 +14169,7 @@ const PageCanvas = forwardRef(
|
|
|
14169
14169
|
fabricCanvas.on("selection:cleared", () => {
|
|
14170
14170
|
});
|
|
14171
14171
|
fabricCanvas.on("object:scaling", (e) => {
|
|
14172
|
-
var _a2, _b2, _c2, _d, _e, _f, _g, _h;
|
|
14172
|
+
var _a2, _b2, _c2, _d, _e, _f, _g, _h, _i, _j;
|
|
14173
14173
|
if (!isActiveRef.current) return;
|
|
14174
14174
|
const t = e.target;
|
|
14175
14175
|
if (t) lastResizeScaleTargetRef.current = t;
|
|
@@ -14353,15 +14353,18 @@ const PageCanvas = forwardRef(
|
|
|
14353
14353
|
}
|
|
14354
14354
|
if (obj instanceof fabric.ActiveSelection && (corner === "ml" || corner === "mr" || corner === "mt" || corner === "mb")) {
|
|
14355
14355
|
const isXSide = corner === "ml" || corner === "mr";
|
|
14356
|
-
const
|
|
14356
|
+
const _cur = fabricCanvas._currentTransform;
|
|
14357
|
+
const startSx = Math.abs(Number(((_d = _cur == null ? void 0 : _cur.original) == null ? void 0 : _d.scaleX) ?? 1)) || 1;
|
|
14358
|
+
const startSy = Math.abs(Number(((_e = _cur == null ? void 0 : _cur.original) == null ? void 0 : _e.scaleY) ?? 1)) || 1;
|
|
14359
|
+
const sAxis = isXSide ? Math.abs((obj.scaleX ?? 1) / startSx) : Math.abs((obj.scaleY ?? 1) / startSy);
|
|
14357
14360
|
if (sAxis > 1e-3) {
|
|
14358
|
-
if (isXSide && ((
|
|
14361
|
+
if (isXSide && ((_f = groupShiftReflowSnapshotRef.current) == null ? void 0 : _f.selection) !== obj) {
|
|
14359
14362
|
groupShiftReflowSnapshotRef.current = null;
|
|
14360
14363
|
const logicalGroupId = obj.__pixldocsGroupSelection;
|
|
14361
14364
|
if (logicalGroupId) {
|
|
14362
14365
|
try {
|
|
14363
14366
|
const state = useEditorStore.getState();
|
|
14364
|
-
const pageChildren2 = ((
|
|
14367
|
+
const pageChildren2 = ((_g = state.canvas.pages.find((p) => p.id === pageId)) == null ? void 0 : _g.children) ?? [];
|
|
14365
14368
|
const groupNode = findNodeById(pageChildren2, logicalGroupId);
|
|
14366
14369
|
if (groupNode && isGroup(groupNode) && !isStackLayoutMode(groupNode.layoutMode)) {
|
|
14367
14370
|
const entries = obj.getObjects().map((c) => ({
|
|
@@ -14399,7 +14402,7 @@ const PageCanvas = forwardRef(
|
|
|
14399
14402
|
}
|
|
14400
14403
|
continue;
|
|
14401
14404
|
}
|
|
14402
|
-
if (child instanceof fabric.Group && (child.__cropGroup || ((
|
|
14405
|
+
if (child instanceof fabric.Group && (child.__cropGroup || ((_h = child._ct) == null ? void 0 : _h.isCropGroup))) {
|
|
14403
14406
|
const ct = child.__cropData;
|
|
14404
14407
|
if (!ct) continue;
|
|
14405
14408
|
if (child.__asLiveOrigAngle == null) {
|
|
@@ -14566,7 +14569,7 @@ const PageCanvas = forwardRef(
|
|
|
14566
14569
|
child.dirty = true;
|
|
14567
14570
|
didReflowTextChild = true;
|
|
14568
14571
|
}
|
|
14569
|
-
if (isXSide && ((
|
|
14572
|
+
if (isXSide && ((_i = groupShiftReflowSnapshotRef.current) == null ? void 0 : _i.selection) === obj) {
|
|
14570
14573
|
const snap = groupShiftReflowSnapshotRef.current;
|
|
14571
14574
|
const anchorEntry = snap.children[0];
|
|
14572
14575
|
const anchorTopLive = anchorEntry.obj.top ?? 0;
|
|
@@ -14726,7 +14729,7 @@ const PageCanvas = forwardRef(
|
|
|
14726
14729
|
setGuides(gridGuidesForScale.length ? [...scaleGuides, ...gridGuidesForScale] : scaleGuides);
|
|
14727
14730
|
if (drilledGroupIdRef.current) {
|
|
14728
14731
|
try {
|
|
14729
|
-
(
|
|
14732
|
+
(_j = fabricCanvas.__updateDrilledGroupOutline) == null ? void 0 : _j.call(fabricCanvas);
|
|
14730
14733
|
} catch {
|
|
14731
14734
|
}
|
|
14732
14735
|
}
|
|
@@ -25135,9 +25138,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
25135
25138
|
}
|
|
25136
25139
|
return svgString;
|
|
25137
25140
|
}
|
|
25138
|
-
const resolvedPackageVersion = "0.5.
|
|
25141
|
+
const resolvedPackageVersion = "0.5.405";
|
|
25139
25142
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
25140
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
25143
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.405";
|
|
25141
25144
|
const roundParityValue = (value) => {
|
|
25142
25145
|
if (typeof value !== "number") return value;
|
|
25143
25146
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -25951,7 +25954,7 @@ class PixldocsRenderer {
|
|
|
25951
25954
|
await this.waitForCanvasScene(container, cloned, i);
|
|
25952
25955
|
}
|
|
25953
25956
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
25954
|
-
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-
|
|
25957
|
+
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-C3La67Vw.js");
|
|
25955
25958
|
const prepared = preparePagesForExport(
|
|
25956
25959
|
cloned.pages,
|
|
25957
25960
|
canvasWidth,
|
|
@@ -28271,7 +28274,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
28271
28274
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
28272
28275
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
28273
28276
|
try {
|
|
28274
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-
|
|
28277
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-C3La67Vw.js");
|
|
28275
28278
|
try {
|
|
28276
28279
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
28277
28280
|
} catch {
|
|
@@ -28671,4 +28674,4 @@ export {
|
|
|
28671
28674
|
buildTeaserBlurFlatKeys as y,
|
|
28672
28675
|
collectFontDescriptorsFromConfig as z
|
|
28673
28676
|
};
|
|
28674
|
-
//# sourceMappingURL=index-
|
|
28677
|
+
//# sourceMappingURL=index-A1mT_rQo.js.map
|