@pixldocs/canvas-renderer 0.5.173 → 0.5.174
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-ZehEOqUB.cjs → index-BH1kJLpb.cjs} +11 -9
- package/dist/{index-ZehEOqUB.cjs.map → index-BH1kJLpb.cjs.map} +1 -1
- package/dist/{index-ChHYFk0E.js → index-DLAkGTqW.js} +11 -9
- package/dist/{index-ChHYFk0E.js.map → index-DLAkGTqW.js.map} +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-CyTa-D1p.js → vectorPdfExport-B4B0CPjW.js} +8 -4
- package/dist/{vectorPdfExport-CyTa-D1p.js.map → vectorPdfExport-B4B0CPjW.js.map} +1 -1
- package/dist/{vectorPdfExport-BWDj55kq.cjs → vectorPdfExport-wyGn4ybk.cjs} +8 -4
- package/dist/{vectorPdfExport-BWDj55kq.cjs.map → vectorPdfExport-wyGn4ybk.cjs.map} +1 -1
- package/package.json +1 -1
|
@@ -16331,9 +16331,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
16331
16331
|
}
|
|
16332
16332
|
return svgString;
|
|
16333
16333
|
}
|
|
16334
|
-
const resolvedPackageVersion = "0.5.
|
|
16334
|
+
const resolvedPackageVersion = "0.5.174";
|
|
16335
16335
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
16336
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
16336
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.174";
|
|
16337
16337
|
const roundParityValue = (value) => {
|
|
16338
16338
|
if (typeof value !== "number") return value;
|
|
16339
16339
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -16707,7 +16707,8 @@ class PixldocsRenderer {
|
|
|
16707
16707
|
*/
|
|
16708
16708
|
async renderPdf(templateConfig, options) {
|
|
16709
16709
|
return this.renderPdfViaClientExport(templateConfig, {
|
|
16710
|
-
title: options == null ? void 0 : options.title
|
|
16710
|
+
title: options == null ? void 0 : options.title,
|
|
16711
|
+
textMode: options == null ? void 0 : options.textMode
|
|
16711
16712
|
});
|
|
16712
16713
|
}
|
|
16713
16714
|
/**
|
|
@@ -16715,7 +16716,7 @@ class PixldocsRenderer {
|
|
|
16715
16716
|
* This is the primary PDF export API — mirrors renderFromForm() but returns a PDF.
|
|
16716
16717
|
*/
|
|
16717
16718
|
async renderPdfFromForm(options) {
|
|
16718
|
-
const { templateId, formSchemaId, sectionState, themeId, watermark, watermarkOptions, prefetched, title, fontBaseUrl } = options;
|
|
16719
|
+
const { templateId, formSchemaId, sectionState, themeId, watermark, watermarkOptions, prefetched, title, fontBaseUrl, textMode } = options;
|
|
16719
16720
|
const resolved = await resolveFromForm({
|
|
16720
16721
|
templateId,
|
|
16721
16722
|
formSchemaId,
|
|
@@ -16733,7 +16734,8 @@ class PixldocsRenderer {
|
|
|
16733
16734
|
}
|
|
16734
16735
|
return this.renderPdfViaClientExport(configToRender, {
|
|
16735
16736
|
title: title ?? resolved.config.name,
|
|
16736
|
-
watermark: shouldWatermark
|
|
16737
|
+
watermark: shouldWatermark,
|
|
16738
|
+
textMode
|
|
16737
16739
|
});
|
|
16738
16740
|
}
|
|
16739
16741
|
async renderById(templateId, formData, options) {
|
|
@@ -16832,7 +16834,7 @@ class PixldocsRenderer {
|
|
|
16832
16834
|
await this.waitForCanvasScene(container, cloned, i);
|
|
16833
16835
|
}
|
|
16834
16836
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
16835
|
-
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-
|
|
16837
|
+
const { exportMultiPagePdf, preparePagesForExport } = await import("./vectorPdfExport-B4B0CPjW.js");
|
|
16836
16838
|
const prepared = preparePagesForExport(
|
|
16837
16839
|
cloned.pages,
|
|
16838
16840
|
canvasWidth,
|
|
@@ -16842,7 +16844,7 @@ class PixldocsRenderer {
|
|
|
16842
16844
|
title: options.title,
|
|
16843
16845
|
watermark: !!options.watermark,
|
|
16844
16846
|
returnBlob: true,
|
|
16845
|
-
pdfTextMode: ((_a = cloned.canvas) == null ? void 0 : _a.n) ?? "
|
|
16847
|
+
pdfTextMode: options.textMode ?? (cloned == null ? void 0 : cloned.pdfTextMode) ?? ((_a = cloned.canvas) == null ? void 0 : _a.n) ?? "auto"
|
|
16846
16848
|
});
|
|
16847
16849
|
if (!result || typeof result === "undefined") {
|
|
16848
16850
|
throw new Error("exportMultiPagePdf returned no blob (returnBlob path failed)");
|
|
@@ -18968,7 +18970,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
18968
18970
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
18969
18971
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
18970
18972
|
try {
|
|
18971
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-
|
|
18973
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await import("./vectorPdfExport-B4B0CPjW.js");
|
|
18972
18974
|
try {
|
|
18973
18975
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
18974
18976
|
} catch {
|
|
@@ -19381,4 +19383,4 @@ export {
|
|
|
19381
19383
|
collectFontDescriptorsFromConfig as y,
|
|
19382
19384
|
collectFontsFromConfig as z
|
|
19383
19385
|
};
|
|
19384
|
-
//# sourceMappingURL=index-
|
|
19386
|
+
//# sourceMappingURL=index-DLAkGTqW.js.map
|