@pixldocs/canvas-renderer 0.5.293 → 0.5.294
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-CRNg3m2o.js → index-CvuMfLba.js} +32 -8
- package/dist/index-CvuMfLba.js.map +1 -0
- package/dist/{index-CvP_zeI7.cjs → index-YNCK2XyZ.cjs} +32 -8
- package/dist/index-YNCK2XyZ.cjs.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-B089WLSf.cjs → vectorPdfExport-CtQnH_h8.cjs} +4 -4
- package/dist/{vectorPdfExport-B089WLSf.cjs.map → vectorPdfExport-CtQnH_h8.cjs.map} +1 -1
- package/dist/{vectorPdfExport-BtxsxKxp.js → vectorPdfExport-uoX8_JuH.js} +4 -4
- package/dist/{vectorPdfExport-BtxsxKxp.js.map → vectorPdfExport-uoX8_JuH.js.map} +1 -1
- package/package.json +1 -1
- package/dist/index-CRNg3m2o.js.map +0 -1
- package/dist/index-CvP_zeI7.cjs.map +0 -1
|
@@ -11014,6 +11014,7 @@ const scaleUpdateNumber = (updates, source, key, factor) => {
|
|
|
11014
11014
|
if (Number.isFinite(value)) updates[key] = value * factor;
|
|
11015
11015
|
};
|
|
11016
11016
|
const GROUP_TEXT_RESIZE_DEBUG_PREFIX = "[Pixldocs][group-text-corner-resize]";
|
|
11017
|
+
const GROUP_TEXT_RESIZE_DEBUG_MAX_ENTRIES = 200;
|
|
11017
11018
|
const isCornerResizeHandle = (handle) => handle === "tl" || handle === "tr" || handle === "bl" || handle === "br";
|
|
11018
11019
|
const summarizeFabricObjectForResizeDebug = (obj) => {
|
|
11019
11020
|
var _a2;
|
|
@@ -11046,9 +11047,32 @@ const summarizeFabricObjectForResizeDebug = (obj) => {
|
|
|
11046
11047
|
const logGroupTextResizeDebug = (phase, payload) => {
|
|
11047
11048
|
if (typeof console === "undefined") return;
|
|
11048
11049
|
try {
|
|
11049
|
-
|
|
11050
|
-
|
|
11051
|
-
|
|
11050
|
+
const seen = /* @__PURE__ */ new WeakSet();
|
|
11051
|
+
const normalize = (value) => {
|
|
11052
|
+
if (value == null) return value;
|
|
11053
|
+
const valueType = typeof value;
|
|
11054
|
+
if (valueType === "number") return Number.isFinite(value) ? Math.round(value * 1e3) / 1e3 : String(value);
|
|
11055
|
+
if (valueType === "string" || valueType === "boolean") return value;
|
|
11056
|
+
if (valueType === "function") return `[Function ${value.name || "anonymous"}]`;
|
|
11057
|
+
if (Array.isArray(value)) return value.map((entry) => normalize(entry));
|
|
11058
|
+
if (valueType === "object") {
|
|
11059
|
+
if (seen.has(value)) return "[Circular]";
|
|
11060
|
+
seen.add(value);
|
|
11061
|
+
if (value instanceof fabric__namespace.FabricObject) return normalize(summarizeFabricObjectForResizeDebug(value));
|
|
11062
|
+
const output = {};
|
|
11063
|
+
Object.entries(value).forEach(([key, entry]) => {
|
|
11064
|
+
output[key] = normalize(entry);
|
|
11065
|
+
});
|
|
11066
|
+
return output;
|
|
11067
|
+
}
|
|
11068
|
+
return String(value);
|
|
11069
|
+
};
|
|
11070
|
+
const normalizedPayload = normalize(payload);
|
|
11071
|
+
const line = `${GROUP_TEXT_RESIZE_DEBUG_PREFIX} ${phase} ${JSON.stringify(normalizedPayload)}`;
|
|
11072
|
+
const debugWindow = window;
|
|
11073
|
+
debugWindow.__pixldocsGroupTextResizeLogs = Array.isArray(debugWindow.__pixldocsGroupTextResizeLogs) ? debugWindow.__pixldocsGroupTextResizeLogs.slice(-GROUP_TEXT_RESIZE_DEBUG_MAX_ENTRIES + 1) : [];
|
|
11074
|
+
debugWindow.__pixldocsGroupTextResizeLogs.push(line);
|
|
11075
|
+
console.log(line);
|
|
11052
11076
|
} catch {
|
|
11053
11077
|
console.log(GROUP_TEXT_RESIZE_DEBUG_PREFIX, phase, payload);
|
|
11054
11078
|
}
|
|
@@ -23819,9 +23843,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
23819
23843
|
}
|
|
23820
23844
|
return svgString;
|
|
23821
23845
|
}
|
|
23822
|
-
const resolvedPackageVersion = "0.5.
|
|
23846
|
+
const resolvedPackageVersion = "0.5.294";
|
|
23823
23847
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
23824
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
23848
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.294";
|
|
23825
23849
|
const roundParityValue = (value) => {
|
|
23826
23850
|
if (typeof value !== "number") return value;
|
|
23827
23851
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -24635,7 +24659,7 @@ class PixldocsRenderer {
|
|
|
24635
24659
|
await this.waitForCanvasScene(container, cloned, i);
|
|
24636
24660
|
}
|
|
24637
24661
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
24638
|
-
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
24662
|
+
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-CtQnH_h8.cjs"));
|
|
24639
24663
|
const prepared = preparePagesForExport(
|
|
24640
24664
|
cloned.pages,
|
|
24641
24665
|
canvasWidth,
|
|
@@ -26955,7 +26979,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
26955
26979
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
26956
26980
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
26957
26981
|
try {
|
|
26958
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
26982
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-CtQnH_h8.cjs"));
|
|
26959
26983
|
try {
|
|
26960
26984
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
26961
26985
|
} catch {
|
|
@@ -27352,4 +27376,4 @@ exports.setAutoShrinkDebug = setAutoShrinkDebug;
|
|
|
27352
27376
|
exports.setBundledAssetPrefixes = setBundledAssetPrefixes;
|
|
27353
27377
|
exports.warmResolvedTemplateForPreview = warmResolvedTemplateForPreview;
|
|
27354
27378
|
exports.warmTemplateFromForm = warmTemplateFromForm;
|
|
27355
|
-
//# sourceMappingURL=index-
|
|
27379
|
+
//# sourceMappingURL=index-YNCK2XyZ.cjs.map
|