@pixldocs/canvas-renderer 0.5.123 → 0.5.125
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-BIjYOVnw.cjs → index-CNN2CRQh.cjs} +7 -6
- package/dist/{index-BIjYOVnw.cjs.map → index-CNN2CRQh.cjs.map} +1 -1
- package/dist/{index-CL09cdqm.js → index-D7cGwzxX.js} +7 -6
- package/dist/{index-CL09cdqm.js.map → index-D7cGwzxX.js.map} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-Cn3c_VYZ.js → vectorPdfExport-BBV3abJi.js} +6 -6
- package/dist/vectorPdfExport-BBV3abJi.js.map +1 -0
- package/dist/{vectorPdfExport-G2Yz66tj.cjs → vectorPdfExport-DVISwrvS.cjs} +6 -6
- package/dist/vectorPdfExport-DVISwrvS.cjs.map +1 -0
- package/package.json +1 -1
- package/dist/vectorPdfExport-Cn3c_VYZ.js.map +0 -1
- package/dist/vectorPdfExport-G2Yz66tj.cjs.map +0 -1
|
@@ -15660,7 +15660,7 @@ function PixldocsPreview(props) {
|
|
|
15660
15660
|
!canvasSettled && /* @__PURE__ */ jsxRuntime.jsx("div", { style: { position: "absolute", inset: 0, display: "flex", alignItems: "center", justifyContent: "center", minHeight: 200 }, children: /* @__PURE__ */ jsxRuntime.jsx("div", { style: { color: "#888", fontSize: 14 }, children: "Loading preview..." }) })
|
|
15661
15661
|
] });
|
|
15662
15662
|
}
|
|
15663
|
-
const PACKAGE_VERSION = "0.5.
|
|
15663
|
+
const PACKAGE_VERSION = "0.5.125";
|
|
15664
15664
|
const roundParityValue = (value) => {
|
|
15665
15665
|
if (typeof value !== "number") return value;
|
|
15666
15666
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -16079,7 +16079,7 @@ class PixldocsRenderer {
|
|
|
16079
16079
|
await this.waitForCanvasScene(container, cloned, i);
|
|
16080
16080
|
}
|
|
16081
16081
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
16082
|
-
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
16082
|
+
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-DVISwrvS.cjs"));
|
|
16083
16083
|
const prepared = preparePagesForExport(
|
|
16084
16084
|
cloned.pages,
|
|
16085
16085
|
canvasWidth,
|
|
@@ -16573,7 +16573,8 @@ class PixldocsRenderer {
|
|
|
16573
16573
|
try {
|
|
16574
16574
|
const objs = fabricInstance.getObjects().slice();
|
|
16575
16575
|
for (const obj of objs) {
|
|
16576
|
-
const
|
|
16576
|
+
const isGroupLike = obj instanceof fabric__namespace.Group || (obj == null ? void 0 : obj.type) === "group" || Array.isArray(obj == null ? void 0 : obj._objects);
|
|
16577
|
+
const isFadedCropGroup = isGroupLike && (Boolean(obj.__edgeFadeRenderConfig) || Boolean(obj.__edgeFadeKey) || Boolean(obj.__edgeFadeInputKey));
|
|
16577
16578
|
if (!isFadedCropGroup) continue;
|
|
16578
16579
|
try {
|
|
16579
16580
|
const baked = obj.toCanvasElement({
|
|
@@ -17334,10 +17335,10 @@ function bakeGroupOpacityIntoChildren(svg) {
|
|
|
17334
17335
|
walkAndBake(svg, 1);
|
|
17335
17336
|
}
|
|
17336
17337
|
function hasInvalidSvgNumericToken(value) {
|
|
17337
|
-
return typeof value === "string" && /\b(?:NaN|-?Infinity)\b/.test(value);
|
|
17338
|
+
return typeof value === "string" && /\b(?:NaN|-?Infinity|undefined|null)\b/.test(value);
|
|
17338
17339
|
}
|
|
17339
17340
|
function sanitizeSvgNumericTokens(value) {
|
|
17340
|
-
return value.replace(/\bNaN\b/g, "0").replace(/\b-?Infinity\b/g, "0");
|
|
17341
|
+
return value.replace(/\bNaN\b/g, "0").replace(/\b-?Infinity\b/g, "0").replace(/\bundefined\b/g, "0").replace(/\bnull\b/g, "0");
|
|
17341
17342
|
}
|
|
17342
17343
|
function sanitizeSvgTreeForPdf(svg) {
|
|
17343
17344
|
const attrsToSanitize = [
|
|
@@ -18484,4 +18485,4 @@ exports.setAutoShrinkDebug = setAutoShrinkDebug;
|
|
|
18484
18485
|
exports.setBundledAssetPrefixes = setBundledAssetPrefixes;
|
|
18485
18486
|
exports.warmResolvedTemplateForPreview = warmResolvedTemplateForPreview;
|
|
18486
18487
|
exports.warmTemplateFromForm = warmTemplateFromForm;
|
|
18487
|
-
//# sourceMappingURL=index-
|
|
18488
|
+
//# sourceMappingURL=index-CNN2CRQh.cjs.map
|