@pixldocs/canvas-renderer 0.5.150 → 0.5.152
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-CczB1vpO.cjs → index-CM_LXIKO.cjs} +82 -9
- package/dist/index-CM_LXIKO.cjs.map +1 -0
- package/dist/{index-khnxviCH.js → index-DjobDQ7X.js} +82 -9
- package/dist/index-DjobDQ7X.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{svgTextToPath-ws6Fh3rx.js → svgTextToPath-BE8TxgiO.js} +2 -2
- package/dist/svgTextToPath-BE8TxgiO.js.map +1 -0
- package/dist/{svgTextToPath-DolCNU9g.cjs → svgTextToPath-qhinMiiS.cjs} +2 -2
- package/dist/svgTextToPath-qhinMiiS.cjs.map +1 -0
- package/dist/{vectorPdfExport-CDnEStQk.js → vectorPdfExport-RiNowoiG.js} +7 -7
- package/dist/vectorPdfExport-RiNowoiG.js.map +1 -0
- package/dist/{vectorPdfExport-qAWd8i87.cjs → vectorPdfExport-gHfbrQfT.cjs} +7 -7
- package/dist/vectorPdfExport-gHfbrQfT.cjs.map +1 -0
- package/package.json +1 -1
- package/dist/index-CczB1vpO.cjs.map +0 -1
- package/dist/index-khnxviCH.js.map +0 -1
- package/dist/svgTextToPath-DolCNU9g.cjs.map +0 -1
- package/dist/svgTextToPath-ws6Fh3rx.js.map +0 -1
- package/dist/vectorPdfExport-CDnEStQk.js.map +0 -1
- package/dist/vectorPdfExport-qAWd8i87.cjs.map +0 -1
|
@@ -3,7 +3,7 @@ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
|
3
3
|
const jspdf = require("jspdf");
|
|
4
4
|
const svg2pdf_js = require("svg2pdf.js");
|
|
5
5
|
const fabric = require("fabric");
|
|
6
|
-
const index = require("./index-
|
|
6
|
+
const index = require("./index-CM_LXIKO.cjs");
|
|
7
7
|
const pdfFonts = require("./pdfFonts-BTEVnYX8.cjs");
|
|
8
8
|
function _interopNamespaceDefault(e) {
|
|
9
9
|
const n = Object.create(null, { [Symbol.toStringTag]: { value: "Module" } });
|
|
@@ -1893,8 +1893,8 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
1893
1893
|
}
|
|
1894
1894
|
await rasterizeShadowMarkers(svgToDraw);
|
|
1895
1895
|
try {
|
|
1896
|
-
if (svgToDraw.querySelector("g[data-pd-shadow-blur] text")) {
|
|
1897
|
-
const { convertAllTextToPath } = await Promise.resolve().then(() => require("./svgTextToPath-
|
|
1896
|
+
if (svgToDraw.querySelector("g[data-pd-shadow-blur] text, g[data-pd-text-bg] text")) {
|
|
1897
|
+
const { convertAllTextToPath } = await Promise.resolve().then(() => require("./svgTextToPath-qhinMiiS.cjs"));
|
|
1898
1898
|
const outlined = await convertAllTextToPath(
|
|
1899
1899
|
new XMLSerializer().serializeToString(svgToDraw),
|
|
1900
1900
|
void 0,
|
|
@@ -1903,7 +1903,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
1903
1903
|
const outlinedDoc = parser.parseFromString(outlined, "image/svg+xml");
|
|
1904
1904
|
if (!outlinedDoc.querySelector("parsererror") && ((_a = outlinedDoc.documentElement) == null ? void 0 : _a.tagName.toLowerCase()) === "svg") {
|
|
1905
1905
|
svgToDraw = outlinedDoc.documentElement;
|
|
1906
|
-
console.log("[Vector PDF][parity]
|
|
1906
|
+
console.log("[Vector PDF][parity] decorated text outlined for headless alignment");
|
|
1907
1907
|
}
|
|
1908
1908
|
}
|
|
1909
1909
|
} catch (outlineErr) {
|
|
@@ -2494,7 +2494,7 @@ async function fetchSvgAsElement(imageUrl, colorMap) {
|
|
|
2494
2494
|
async function getRecoloredSvgDataUrl(imageUrl, colorMap) {
|
|
2495
2495
|
if (!colorMap || Object.keys(colorMap).length === 0) return null;
|
|
2496
2496
|
try {
|
|
2497
|
-
const { getNormalizedSvgUrl } = await Promise.resolve().then(() => require("./index-
|
|
2497
|
+
const { getNormalizedSvgUrl } = await Promise.resolve().then(() => require("./index-CM_LXIKO.cjs")).then((n) => n.canvasImageLoader);
|
|
2498
2498
|
return await getNormalizedSvgUrl(imageUrl, colorMap);
|
|
2499
2499
|
} catch {
|
|
2500
2500
|
return null;
|
|
@@ -3275,7 +3275,7 @@ async function fetchImageAsBase64(imageUrl, opts = {}) {
|
|
|
3275
3275
|
}
|
|
3276
3276
|
let fetchUrl = imageUrl;
|
|
3277
3277
|
if (imageUrl.startsWith("http://") || imageUrl.startsWith("https://")) {
|
|
3278
|
-
const { isPrivateUrl } = await Promise.resolve().then(() => require("./index-
|
|
3278
|
+
const { isPrivateUrl } = await Promise.resolve().then(() => require("./index-CM_LXIKO.cjs")).then((n) => n.canvasImageLoader);
|
|
3279
3279
|
if (isPrivateUrl(imageUrl)) return null;
|
|
3280
3280
|
const proxyUrl = new URL(`${index.API_URL}/image-proxy`);
|
|
3281
3281
|
proxyUrl.searchParams.set("url", imageUrl);
|
|
@@ -5257,4 +5257,4 @@ exports.exportMultiPagePdf = exportMultiPagePdf;
|
|
|
5257
5257
|
exports.logTextMeasurementDiagnostic = logTextMeasurementDiagnostic;
|
|
5258
5258
|
exports.preparePagesForExport = preparePagesForExport;
|
|
5259
5259
|
exports.rewriteSvgFontsForJsPDFWithSourceMeta = rewriteSvgFontsForJsPDFWithSourceMeta;
|
|
5260
|
-
//# sourceMappingURL=vectorPdfExport-
|
|
5260
|
+
//# sourceMappingURL=vectorPdfExport-gHfbrQfT.cjs.map
|