@pixldocs/canvas-renderer 0.5.410 → 0.5.411
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-xCnkRHXB.cjs → index-BzO7hSG5.cjs} +143 -21
- package/dist/index-BzO7hSG5.cjs.map +1 -0
- package/dist/{index-CS_cFpCL.js → index-DIx3vAjy.js} +143 -21
- package/dist/index-DIx3vAjy.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/{vectorPdfExport-BnnUwU40.cjs → vectorPdfExport-DUaCeIGH.cjs} +4 -4
- package/dist/{vectorPdfExport-BnnUwU40.cjs.map → vectorPdfExport-DUaCeIGH.cjs.map} +1 -1
- package/dist/{vectorPdfExport-DE2UhH5g.js → vectorPdfExport-DgFZfNsT.js} +4 -4
- package/dist/{vectorPdfExport-DE2UhH5g.js.map → vectorPdfExport-DgFZfNsT.js.map} +1 -1
- package/package.json +1 -1
- package/dist/index-CS_cFpCL.js.map +0 -1
- package/dist/index-xCnkRHXB.cjs.map +0 -1
|
@@ -4722,11 +4722,19 @@ const svgMaskApply = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.define
|
|
|
4722
4722
|
syncSvgMaskClipPath
|
|
4723
4723
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
4724
4724
|
const SELECTION_BORDER_SCALE$1 = 2;
|
|
4725
|
-
const ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX = "[Pixldocs][rotated-group-image-resize]";
|
|
4726
|
-
const ROTATED_GROUP_IMAGE_RESIZE_DEBUG_MAX_ENTRIES = 400;
|
|
4725
|
+
const ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX$1 = "[Pixldocs][rotated-group-image-resize]";
|
|
4726
|
+
const ROTATED_GROUP_IMAGE_RESIZE_DEBUG_MAX_ENTRIES$1 = 400;
|
|
4727
4727
|
function isInsideRotatedActiveSelection(obj) {
|
|
4728
|
-
|
|
4729
|
-
|
|
4728
|
+
var _a2;
|
|
4729
|
+
const debugObj = obj;
|
|
4730
|
+
const ownAngle = Math.abs(((obj.angle ?? 0) % 360 + 360) % 360);
|
|
4731
|
+
if ((debugObj.__cropData || debugObj.__cropGroup || ((_a2 = debugObj._ct) == null ? void 0 : _a2.isCropGroup)) && Math.min(ownAngle, 360 - ownAngle) > 0.5) return true;
|
|
4732
|
+
const logicalParentAngle = Math.abs(((debugObj.__pixldocsParentGroupAngle ?? 0) % 360 + 360) % 360);
|
|
4733
|
+
if (debugObj.__pixldocsParentGroupId && Math.min(logicalParentAngle, 360 - logicalParentAngle) > 0.5) return true;
|
|
4734
|
+
const parent = debugObj.group;
|
|
4735
|
+
if (!parent) return false;
|
|
4736
|
+
const pType = parent.type;
|
|
4737
|
+
if (pType !== "activeSelection" && pType !== "group") return false;
|
|
4730
4738
|
const angle = Math.abs(((parent.angle ?? 0) % 360 + 360) % 360);
|
|
4731
4739
|
return Math.min(angle, 360 - angle) > 0.5;
|
|
4732
4740
|
}
|
|
@@ -4800,10 +4808,15 @@ function logRotatedGroupImageResize(phase, target, payload = {}) {
|
|
|
4800
4808
|
signX: start.signX,
|
|
4801
4809
|
signY: start.signY
|
|
4802
4810
|
} : void 0;
|
|
4803
|
-
const line = `${ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX} ${phase} ${JSON.stringify(normalize({
|
|
4811
|
+
const line = `${ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX$1} ${phase} ${JSON.stringify(normalize({
|
|
4804
4812
|
...payload,
|
|
4805
4813
|
target: summarizeResizeObject(target),
|
|
4806
4814
|
parent: summarizeResizeObject(parent),
|
|
4815
|
+
logicalParent: debugTarget.__pixldocsParentGroupId ? {
|
|
4816
|
+
id: debugTarget.__pixldocsParentGroupId,
|
|
4817
|
+
type: debugTarget.__pixldocsParentGroupType,
|
|
4818
|
+
angle: debugTarget.__pixldocsParentGroupAngle
|
|
4819
|
+
} : void 0,
|
|
4807
4820
|
frameW: ct == null ? void 0 : ct.frameW,
|
|
4808
4821
|
frameH: ct == null ? void 0 : ct.frameH,
|
|
4809
4822
|
img: summarizeResizeObject(ct == null ? void 0 : ct._img),
|
|
@@ -4812,12 +4825,12 @@ function logRotatedGroupImageResize(phase, target, payload = {}) {
|
|
|
4812
4825
|
}))}`;
|
|
4813
4826
|
if (typeof window !== "undefined") {
|
|
4814
4827
|
const debugWindow = window;
|
|
4815
|
-
debugWindow.__pixldocsRotatedGroupImageResizeLogs = Array.isArray(debugWindow.__pixldocsRotatedGroupImageResizeLogs) ? debugWindow.__pixldocsRotatedGroupImageResizeLogs.slice(-ROTATED_GROUP_IMAGE_RESIZE_DEBUG_MAX_ENTRIES + 1) : [];
|
|
4828
|
+
debugWindow.__pixldocsRotatedGroupImageResizeLogs = Array.isArray(debugWindow.__pixldocsRotatedGroupImageResizeLogs) ? debugWindow.__pixldocsRotatedGroupImageResizeLogs.slice(-ROTATED_GROUP_IMAGE_RESIZE_DEBUG_MAX_ENTRIES$1 + 1) : [];
|
|
4816
4829
|
debugWindow.__pixldocsRotatedGroupImageResizeLogs.push(line);
|
|
4817
4830
|
}
|
|
4818
4831
|
console.log(line);
|
|
4819
4832
|
} catch {
|
|
4820
|
-
console.log(ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX, phase, payload);
|
|
4833
|
+
console.log(ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX$1, phase, payload);
|
|
4821
4834
|
}
|
|
4822
4835
|
}
|
|
4823
4836
|
function clamp$1(v, min, max) {
|
|
@@ -5300,6 +5313,12 @@ function installCanvaMaskControls(g) {
|
|
|
5300
5313
|
logRotatedGroupImageResize("snap-skipped-active-selection-child", target, { corner });
|
|
5301
5314
|
return;
|
|
5302
5315
|
}
|
|
5316
|
+
const ownAngle = Math.abs(((target.angle ?? 0) % 360 + 360) % 360);
|
|
5317
|
+
const parentAngle = Math.abs(((target.__pixldocsParentGroupAngle ?? 0) % 360 + 360) % 360);
|
|
5318
|
+
if (Math.min(ownAngle, 360 - ownAngle) > 0.5 || Math.min(parentAngle, 360 - parentAngle) > 0.5) {
|
|
5319
|
+
logRotatedGroupImageResize("snap-skipped-rotated-image", target, { corner, ownAngle, parentAngle });
|
|
5320
|
+
return;
|
|
5321
|
+
}
|
|
5303
5322
|
const handler = target.__resizeSnapHandler;
|
|
5304
5323
|
if (typeof handler === "function") {
|
|
5305
5324
|
logRotatedGroupImageResize("snap-before", target, { corner });
|
|
@@ -11400,10 +11419,34 @@ const summarizeFabricObjectForResizeDebug = (obj) => {
|
|
|
11400
11419
|
const logGroupTextResizeDebug = (phase, payload) => {
|
|
11401
11420
|
return;
|
|
11402
11421
|
};
|
|
11422
|
+
const ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX = "[Pixldocs][rotated-group-image-resize]";
|
|
11423
|
+
const ROTATED_GROUP_IMAGE_RESIZE_DEBUG_MAX_ENTRIES = 400;
|
|
11403
11424
|
const roundRotDriftNumber = (value) => {
|
|
11404
11425
|
if (typeof value !== "number") return value;
|
|
11405
11426
|
return Number.isFinite(value) ? Math.round(value * 1e3) / 1e3 : String(value);
|
|
11406
11427
|
};
|
|
11428
|
+
const normalizeRotDriftPayload = (value) => {
|
|
11429
|
+
const seen = /* @__PURE__ */ new WeakSet();
|
|
11430
|
+
const normalize = (entry) => {
|
|
11431
|
+
if (entry == null) return entry;
|
|
11432
|
+
const valueType = typeof entry;
|
|
11433
|
+
if (valueType === "number") return roundRotDriftNumber(entry);
|
|
11434
|
+
if (valueType === "string" || valueType === "boolean") return entry;
|
|
11435
|
+
if (Array.isArray(entry)) return entry.map((item) => normalize(item));
|
|
11436
|
+
if (valueType === "object") {
|
|
11437
|
+
if (seen.has(entry)) return "[Circular]";
|
|
11438
|
+
seen.add(entry);
|
|
11439
|
+
if (entry instanceof fabric__namespace.FabricObject) return normalize(summarizeRotDriftObject(entry));
|
|
11440
|
+
const output = {};
|
|
11441
|
+
Object.entries(entry).forEach(([key, item]) => {
|
|
11442
|
+
output[key] = normalize(item);
|
|
11443
|
+
});
|
|
11444
|
+
return output;
|
|
11445
|
+
}
|
|
11446
|
+
return String(entry);
|
|
11447
|
+
};
|
|
11448
|
+
return normalize(value);
|
|
11449
|
+
};
|
|
11407
11450
|
const matrixForRotDriftLog = (matrix) => {
|
|
11408
11451
|
if (!matrix) return void 0;
|
|
11409
11452
|
return matrix.map((entry) => roundRotDriftNumber(entry));
|
|
@@ -11461,6 +11504,20 @@ const summarizeRotDriftObject = (obj, worldMatrix) => {
|
|
|
11461
11504
|
const logRotGroupImageDrift = (phase, payload) => {
|
|
11462
11505
|
return;
|
|
11463
11506
|
};
|
|
11507
|
+
const logRotatedGroupImageResizeDebug = (phase, payload) => {
|
|
11508
|
+
if (typeof console === "undefined") return;
|
|
11509
|
+
try {
|
|
11510
|
+
const line = `${ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX} ${phase} ${JSON.stringify(normalizeRotDriftPayload(payload))}`;
|
|
11511
|
+
if (typeof window !== "undefined") {
|
|
11512
|
+
const debugWindow = window;
|
|
11513
|
+
debugWindow.__pixldocsRotatedGroupImageResizeLogs = Array.isArray(debugWindow.__pixldocsRotatedGroupImageResizeLogs) ? debugWindow.__pixldocsRotatedGroupImageResizeLogs.slice(-ROTATED_GROUP_IMAGE_RESIZE_DEBUG_MAX_ENTRIES + 1) : [];
|
|
11514
|
+
debugWindow.__pixldocsRotatedGroupImageResizeLogs.push(line);
|
|
11515
|
+
}
|
|
11516
|
+
console.log(line);
|
|
11517
|
+
} catch {
|
|
11518
|
+
console.log(ROTATED_GROUP_IMAGE_RESIZE_DEBUG_PREFIX, phase, payload);
|
|
11519
|
+
}
|
|
11520
|
+
};
|
|
11464
11521
|
const shouldLogRotDriftLiveTick = (target, phase) => {
|
|
11465
11522
|
return false;
|
|
11466
11523
|
};
|
|
@@ -12266,6 +12323,22 @@ const PageCanvas = react.forwardRef(
|
|
|
12266
12323
|
[canvasWidth, canvasHeight, getLogicalGroupSnapBoundsCallback, getResizeExcludeIdsCallback]
|
|
12267
12324
|
);
|
|
12268
12325
|
const installImageResizeControlsWithSnap = react.useCallback((group) => {
|
|
12326
|
+
var _a2;
|
|
12327
|
+
try {
|
|
12328
|
+
const groupId = getObjectId(group);
|
|
12329
|
+
const pageChildrenNow = ((_a2 = useEditorStore.getState().canvas.pages.find((p) => p.id === pageId)) == null ? void 0 : _a2.children) ?? [];
|
|
12330
|
+
const parent = groupId ? findParentGroup(pageChildrenNow, groupId) : null;
|
|
12331
|
+
if (parent) {
|
|
12332
|
+
group.__pixldocsParentGroupId = parent.id;
|
|
12333
|
+
group.__pixldocsParentGroupAngle = parent.angle ?? 0;
|
|
12334
|
+
group.__pixldocsParentGroupType = "logical-group";
|
|
12335
|
+
} else {
|
|
12336
|
+
delete group.__pixldocsParentGroupId;
|
|
12337
|
+
delete group.__pixldocsParentGroupAngle;
|
|
12338
|
+
delete group.__pixldocsParentGroupType;
|
|
12339
|
+
}
|
|
12340
|
+
} catch {
|
|
12341
|
+
}
|
|
12269
12342
|
group.__resizeSnapHandler = (target, corner) => {
|
|
12270
12343
|
const fc = fabricRef.current ?? target.canvas;
|
|
12271
12344
|
if (!fc || !isActiveRef.current || !corner) return;
|
|
@@ -14299,7 +14372,7 @@ const PageCanvas = react.forwardRef(
|
|
|
14299
14372
|
fabricCanvas.on("selection:cleared", () => {
|
|
14300
14373
|
});
|
|
14301
14374
|
fabricCanvas.on("object:scaling", (e) => {
|
|
14302
|
-
var _a2, _b2, _c2, _d, _e, _f, _g, _h, _i, _j;
|
|
14375
|
+
var _a2, _b2, _c2, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
|
|
14303
14376
|
if (!isActiveRef.current) return;
|
|
14304
14377
|
const t = e.target;
|
|
14305
14378
|
if (t) lastResizeScaleTargetRef.current = t;
|
|
@@ -14470,12 +14543,61 @@ const PageCanvas = react.forwardRef(
|
|
|
14470
14543
|
const corner = (transform == null ? void 0 : transform.corner) || "";
|
|
14471
14544
|
if (obj instanceof fabric__namespace.ActiveSelection && corner) {
|
|
14472
14545
|
activeSelectionResizeHandleRef.current = corner;
|
|
14546
|
+
const imageChildrenForResizeDebug = obj.getObjects().filter(
|
|
14547
|
+
(child) => {
|
|
14548
|
+
var _a3;
|
|
14549
|
+
return child instanceof fabric__namespace.FabricImage || child instanceof fabric__namespace.Group && (child.__cropGroup || ((_a3 = child._ct) == null ? void 0 : _a3.isCropGroup));
|
|
14550
|
+
}
|
|
14551
|
+
);
|
|
14552
|
+
const normalizedSelectionAngle = ((obj.angle ?? 0) % 360 + 360) % 360;
|
|
14553
|
+
const activeLogicalGroupId = obj.__pixldocsGroupSelection;
|
|
14554
|
+
const transformStartForDebug = activeLogicalGroupId && ((_c2 = groupSelectionTransformStartRef.current) == null ? void 0 : _c2.groupId) === activeLogicalGroupId ? groupSelectionTransformStartRef.current : null;
|
|
14555
|
+
const logicalGroupAngle = (transformStartForDebug == null ? void 0 : transformStartForDebug.groupAngle) ?? obj.__pixldocsFrozenGroupAngle ?? 0;
|
|
14556
|
+
const normalizedLogicalGroupAngle = (logicalGroupAngle % 360 + 360) % 360;
|
|
14557
|
+
const isRotatedImageSelection = imageChildrenForResizeDebug.length > 0 && (Math.min(normalizedSelectionAngle, 360 - normalizedSelectionAngle) > 0.5 || Math.min(normalizedLogicalGroupAngle, 360 - normalizedLogicalGroupAngle) > 0.5);
|
|
14558
|
+
if (isRotatedImageSelection) {
|
|
14559
|
+
const countKey = "__pixldocsRotatedImageResizeScaleTickCount";
|
|
14560
|
+
const count = (obj[countKey] ?? 0) + 1;
|
|
14561
|
+
obj[countKey] = count;
|
|
14562
|
+
if (count <= 5 || count % 8 === 0) {
|
|
14563
|
+
logRotatedGroupImageResizeDebug("active-selection-scaling", {
|
|
14564
|
+
time: Math.round(performance.now()),
|
|
14565
|
+
tick: count,
|
|
14566
|
+
handle: corner,
|
|
14567
|
+
groupSelectionId: activeLogicalGroupId,
|
|
14568
|
+
selectedStoreIds: useEditorStore.getState().canvas.selectedIds,
|
|
14569
|
+
route: typeof window !== "undefined" ? window.location.pathname : void 0,
|
|
14570
|
+
transformAction: (_d = fabricCanvas._currentTransform) == null ? void 0 : _d.action,
|
|
14571
|
+
transformCorner: (_e = fabricCanvas._currentTransform) == null ? void 0 : _e.corner,
|
|
14572
|
+
transformOriginal: (() => {
|
|
14573
|
+
var _a3;
|
|
14574
|
+
const original = (_a3 = fabricCanvas._currentTransform) == null ? void 0 : _a3.original;
|
|
14575
|
+
return original ? {
|
|
14576
|
+
left: original.left,
|
|
14577
|
+
top: original.top,
|
|
14578
|
+
width: original.width,
|
|
14579
|
+
height: original.height,
|
|
14580
|
+
scaleX: original.scaleX,
|
|
14581
|
+
scaleY: original.scaleY,
|
|
14582
|
+
angle: original.angle
|
|
14583
|
+
} : null;
|
|
14584
|
+
})(),
|
|
14585
|
+
transformStart: transformStartForDebug,
|
|
14586
|
+
selection: summarizeRotDriftObject(obj),
|
|
14587
|
+
imageChildren: imageChildrenForResizeDebug.map((child, childIndex) => ({
|
|
14588
|
+
childIndex,
|
|
14589
|
+
id: getObjectId(child),
|
|
14590
|
+
object: summarizeRotDriftObject(child)
|
|
14591
|
+
}))
|
|
14592
|
+
});
|
|
14593
|
+
}
|
|
14594
|
+
}
|
|
14473
14595
|
if (isCornerResizeHandle(corner) && obj.getObjects().some((child) => child instanceof fabric__namespace.Textbox)) {
|
|
14474
14596
|
obj.__pixldocsLastGroupTextScaleDebug = {
|
|
14475
14597
|
time: Math.round(performance.now()),
|
|
14476
14598
|
corner,
|
|
14477
14599
|
groupSelectionId: obj.__pixldocsGroupSelection,
|
|
14478
|
-
currentTransformAction: (
|
|
14600
|
+
currentTransformAction: (_f = fabricCanvas._currentTransform) == null ? void 0 : _f.action,
|
|
14479
14601
|
selection: summarizeFabricObjectForResizeDebug(obj),
|
|
14480
14602
|
textChildren: obj.getObjects().filter((child) => child instanceof fabric__namespace.Textbox).map((child) => summarizeFabricObjectForResizeDebug(child))
|
|
14481
14603
|
};
|
|
@@ -14484,17 +14606,17 @@ const PageCanvas = react.forwardRef(
|
|
|
14484
14606
|
if (obj instanceof fabric__namespace.ActiveSelection && (corner === "ml" || corner === "mr" || corner === "mt" || corner === "mb")) {
|
|
14485
14607
|
const isXSide = corner === "ml" || corner === "mr";
|
|
14486
14608
|
const _cur = fabricCanvas._currentTransform;
|
|
14487
|
-
const startSx = Math.abs(Number(((
|
|
14488
|
-
const startSy = Math.abs(Number(((
|
|
14609
|
+
const startSx = Math.abs(Number(((_g = _cur == null ? void 0 : _cur.original) == null ? void 0 : _g.scaleX) ?? 1)) || 1;
|
|
14610
|
+
const startSy = Math.abs(Number(((_h = _cur == null ? void 0 : _cur.original) == null ? void 0 : _h.scaleY) ?? 1)) || 1;
|
|
14489
14611
|
const sAxis = isXSide ? Math.abs((obj.scaleX ?? 1) / startSx) : Math.abs((obj.scaleY ?? 1) / startSy);
|
|
14490
14612
|
if (sAxis > 1e-3) {
|
|
14491
|
-
if (isXSide && ((
|
|
14613
|
+
if (isXSide && ((_i = groupShiftReflowSnapshotRef.current) == null ? void 0 : _i.selection) !== obj) {
|
|
14492
14614
|
groupShiftReflowSnapshotRef.current = null;
|
|
14493
14615
|
const logicalGroupId = obj.__pixldocsGroupSelection;
|
|
14494
14616
|
if (logicalGroupId) {
|
|
14495
14617
|
try {
|
|
14496
14618
|
const state = useEditorStore.getState();
|
|
14497
|
-
const pageChildren2 = ((
|
|
14619
|
+
const pageChildren2 = ((_j = state.canvas.pages.find((p) => p.id === pageId)) == null ? void 0 : _j.children) ?? [];
|
|
14498
14620
|
const groupNode = findNodeById(pageChildren2, logicalGroupId);
|
|
14499
14621
|
if (groupNode && isGroup(groupNode) && !isStackLayoutMode(groupNode.layoutMode)) {
|
|
14500
14622
|
const entries = obj.getObjects().map((c) => ({
|
|
@@ -14532,7 +14654,7 @@ const PageCanvas = react.forwardRef(
|
|
|
14532
14654
|
}
|
|
14533
14655
|
continue;
|
|
14534
14656
|
}
|
|
14535
|
-
if (child instanceof fabric__namespace.Group && (child.__cropGroup || ((
|
|
14657
|
+
if (child instanceof fabric__namespace.Group && (child.__cropGroup || ((_k = child._ct) == null ? void 0 : _k.isCropGroup))) {
|
|
14536
14658
|
const ct = child.__cropData;
|
|
14537
14659
|
if (!ct) continue;
|
|
14538
14660
|
if (child.__asLiveOrigAngle == null) {
|
|
@@ -14699,7 +14821,7 @@ const PageCanvas = react.forwardRef(
|
|
|
14699
14821
|
child.dirty = true;
|
|
14700
14822
|
didReflowTextChild = true;
|
|
14701
14823
|
}
|
|
14702
|
-
if (isXSide && ((
|
|
14824
|
+
if (isXSide && ((_l = groupShiftReflowSnapshotRef.current) == null ? void 0 : _l.selection) === obj) {
|
|
14703
14825
|
const snap = groupShiftReflowSnapshotRef.current;
|
|
14704
14826
|
const anchorEntry = snap.children[0];
|
|
14705
14827
|
const anchorTopLive = anchorEntry.obj.top ?? 0;
|
|
@@ -14860,7 +14982,7 @@ const PageCanvas = react.forwardRef(
|
|
|
14860
14982
|
setGuides(gridGuidesForScale.length ? [...scaleGuides, ...gridGuidesForScale] : scaleGuides);
|
|
14861
14983
|
if (drilledGroupIdRef.current) {
|
|
14862
14984
|
try {
|
|
14863
|
-
(
|
|
14985
|
+
(_m = fabricCanvas.__updateDrilledGroupOutline) == null ? void 0 : _m.call(fabricCanvas);
|
|
14864
14986
|
} catch {
|
|
14865
14987
|
}
|
|
14866
14988
|
}
|
|
@@ -25269,9 +25391,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
|
|
|
25269
25391
|
}
|
|
25270
25392
|
return svgString;
|
|
25271
25393
|
}
|
|
25272
|
-
const resolvedPackageVersion = "0.5.
|
|
25394
|
+
const resolvedPackageVersion = "0.5.411";
|
|
25273
25395
|
const PACKAGE_VERSION = resolvedPackageVersion;
|
|
25274
|
-
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.
|
|
25396
|
+
const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.411";
|
|
25275
25397
|
const roundParityValue = (value) => {
|
|
25276
25398
|
if (typeof value !== "number") return value;
|
|
25277
25399
|
return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
|
|
@@ -26085,7 +26207,7 @@ class PixldocsRenderer {
|
|
|
26085
26207
|
await this.waitForCanvasScene(container, cloned, i);
|
|
26086
26208
|
}
|
|
26087
26209
|
console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
|
|
26088
|
-
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
26210
|
+
const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-DUaCeIGH.cjs"));
|
|
26089
26211
|
const prepared = preparePagesForExport(
|
|
26090
26212
|
cloned.pages,
|
|
26091
26213
|
canvasWidth,
|
|
@@ -28405,7 +28527,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
|
|
|
28405
28527
|
if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
|
|
28406
28528
|
sanitizeSvgTreeForPdf(svgToDraw);
|
|
28407
28529
|
try {
|
|
28408
|
-
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-
|
|
28530
|
+
const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-DUaCeIGH.cjs"));
|
|
28409
28531
|
try {
|
|
28410
28532
|
await logTextMeasurementDiagnostic(svgToDraw);
|
|
28411
28533
|
} catch {
|
|
@@ -28802,4 +28924,4 @@ exports.setAutoShrinkDebug = setAutoShrinkDebug;
|
|
|
28802
28924
|
exports.setBundledAssetPrefixes = setBundledAssetPrefixes;
|
|
28803
28925
|
exports.warmResolvedTemplateForPreview = warmResolvedTemplateForPreview;
|
|
28804
28926
|
exports.warmTemplateFromForm = warmTemplateFromForm;
|
|
28805
|
-
//# sourceMappingURL=index-
|
|
28927
|
+
//# sourceMappingURL=index-BzO7hSG5.cjs.map
|