@pixldocs/canvas-renderer 0.5.305 → 0.5.306
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-fZq9e7bO.js → index-DG1oNkJx.js} +39 -5
- package/dist/index-DG1oNkJx.js.map +1 -0
- package/dist/{index-C8ZNStHz.cjs → index-Dtus6g8-.cjs} +39 -5
- package/dist/{index-C8ZNStHz.cjs.map → index-Dtus6g8-.cjs.map} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-BwMJ3-iw.js → vectorPdfExport-CBKunRKb.js} +4 -4
- package/dist/{vectorPdfExport-BwMJ3-iw.js.map → vectorPdfExport-CBKunRKb.js.map} +1 -1
- package/dist/{vectorPdfExport-fYp0UsD2.cjs → vectorPdfExport-DlIHeeIS.cjs} +4 -4
- package/dist/{vectorPdfExport-fYp0UsD2.cjs.map → vectorPdfExport-DlIHeeIS.cjs.map} +1 -1
- package/package.json +1 -1
- package/dist/index-fZq9e7bO.js.map +0 -1
|
@@ -14883,6 +14883,40 @@ const PageCanvas = forwardRef(
|
|
|
14883
14883
|
bakedTextScaleUpdates.minBoxHeight = Math.max(0, nextMinH);
|
|
14884
14884
|
obj.minBoxHeight = bakedTextScaleUpdates.minBoxHeight;
|
|
14885
14885
|
}
|
|
14886
|
+
const effectScale = isCornerHandle ? fontScale : Math.max(1e-3, Math.sqrt(sx * sy));
|
|
14887
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "strokeWidth", effectScale);
|
|
14888
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textShadowBlur", effectScale);
|
|
14889
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textShadowDistance", effectScale);
|
|
14890
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textShadowOffsetX", sx);
|
|
14891
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textShadowOffsetY", sy);
|
|
14892
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgPaddingTop", sy);
|
|
14893
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgPaddingBottom", sy);
|
|
14894
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgPaddingLeft", sx);
|
|
14895
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgPaddingRight", sx);
|
|
14896
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgPadding", effectScale);
|
|
14897
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgRxTL", effectScale);
|
|
14898
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgRxTR", effectScale);
|
|
14899
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgRxBR", effectScale);
|
|
14900
|
+
scaleUpdateNumber(bakedTextScaleUpdates, sourceElement ?? void 0, "textBgRxBL", effectScale);
|
|
14901
|
+
const tpSource = obj.textPath ?? (sourceElement == null ? void 0 : sourceElement.textPath);
|
|
14902
|
+
if (tpSource) {
|
|
14903
|
+
bakedTextScaleUpdates.textPath = scaleTextPathConfig(tpSource, sx, sy, effectScale);
|
|
14904
|
+
obj.textPath = bakedTextScaleUpdates.textPath;
|
|
14905
|
+
}
|
|
14906
|
+
if (bakedTextScaleUpdates.strokeWidth !== void 0) {
|
|
14907
|
+
obj.set({ strokeWidth: bakedTextScaleUpdates.strokeWidth });
|
|
14908
|
+
}
|
|
14909
|
+
const shadow = obj.shadow;
|
|
14910
|
+
if (shadow) {
|
|
14911
|
+
if (bakedTextScaleUpdates.textShadowBlur !== void 0) shadow.blur = bakedTextScaleUpdates.textShadowBlur;
|
|
14912
|
+
if (bakedTextScaleUpdates.textShadowOffsetX !== void 0) shadow.offsetX = bakedTextScaleUpdates.textShadowOffsetX;
|
|
14913
|
+
if (bakedTextScaleUpdates.textShadowOffsetY !== void 0) shadow.offsetY = bakedTextScaleUpdates.textShadowOffsetY;
|
|
14914
|
+
}
|
|
14915
|
+
if ((sourceElement == null ? void 0 : sourceElement.type) === "text") {
|
|
14916
|
+
const bakedElement = { ...sourceElement, ...bakedTextScaleUpdates };
|
|
14917
|
+
applyTextBackground(obj, extractTextBgConfig(bakedElement));
|
|
14918
|
+
applyTextShadow(obj, bakedElement);
|
|
14919
|
+
}
|
|
14886
14920
|
const prevObjCaching = obj.objectCaching;
|
|
14887
14921
|
obj.set({ width: bakedWidth, scaleX: 1, scaleY: 1, objectCaching: false });
|
|
14888
14922
|
obj.initDimensions();
|
|
@@ -24159,9 +24193,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
24159
24193
|
}
|
|
24160
24194
|
return svgString;
|
|
24161
24195
|
}
|
|
24162
|
-
const resolvedPackageVersion = "0.5.
|
|
24196
|
+
const resolvedPackageVersion = "0.5.306";
|
|
24163
24197
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
24164
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
24198
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.306";
|
|
24165
24199
|
const roundParityValue = (value) => {
|
|
24166
24200
|
if (typeof value !== "number") return value;
|
|
24167
24201
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -24975,7 +25009,7 @@ class PixldocsRenderer {
|
|
|
24975
25009
|
await this.waitForCanvasScene(container, cloned, i);
|
|
24976
25010
|
}
|
|
24977
25011
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
24978
|
-
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-
|
|
25012
|
+
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-CBKunRKb.js");
|
|
24979
25013
|
const prepared = preparePagesForExport(
|
|
24980
25014
|
cloned.pages,
|
|
24981
25015
|
canvasWidth,
|
|
@@ -27295,7 +27329,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
27295
27329
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
27296
27330
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
27297
27331
|
try {
|
|
27298
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-
|
|
27332
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-CBKunRKb.js");
|
|
27299
27333
|
try {
|
|
27300
27334
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
27301
27335
|
} catch {
|
|
@@ -27695,4 +27729,4 @@ export {
|
|
|
27695
27729
|
buildTeaserBlurFlatKeys as y,
|
|
27696
27730
|
collectFontDescriptorsFromConfig as z
|
|
27697
27731
|
};
|
|
27698
|
-
//# sourceMappingURL=index-
|
|
27732
|
+
//# sourceMappingURL=index-DG1oNkJx.js.map
|