@pixldocs/canvas-renderer 0.5.247 → 0.5.248

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.
@@ -12857,7 +12857,7 @@ const PageCanvas = react.forwardRef(
12857
12857
  };
12858
12858
  fabricCanvas.__updateDrilledGroupOutline = updateDrilledGroupOutline;
12859
12859
  fabricCanvas.on("mouse:down:before", (opt) => {
12860
- var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
12860
+ var _a2, _b2, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
12861
12861
  const activeBeforeMouseDown = fabricCanvas.getActiveObject();
12862
12862
  if (editLockRef.current) {
12863
12863
  const active = fabricCanvas.getActiveObject();
@@ -12972,43 +12972,16 @@ const PageCanvas = react.forwardRef(
12972
12972
  }
12973
12973
  pendingGroupDrillInRef.current = null;
12974
12974
  } else if (drillGroup && !drillGroup.backgroundColor && !targetIsInCrop && alreadyThisGroup && !isMultiSelectKey && effectiveTarget !== activeNow) {
12975
- try {
12976
- skipSelectionClearOnDiscardRef.current = true;
12977
- preserveEditingScopeOnSelectionClearRef.current = true;
12978
- restoreSuppressedGroupBorders();
12979
- fabricCanvas.discardActiveObject();
12980
- } finally {
12981
- skipSelectionClearOnDiscardRef.current = false;
12982
- preserveEditingScopeOnSelectionClearRef.current = false;
12983
- }
12984
- fabricCanvas.__activeEditingGroupId = drillGroup.id;
12985
- delete effectiveTarget.__pixldocsGroupSelection;
12986
- delete effectiveTarget.__pixldocsLogicalGroupIds;
12987
- try {
12988
- (_j = effectiveTarget.set) == null ? void 0 : _j.call(effectiveTarget, { selectable: true, evented: true, hasBorders: true, hasControls: true });
12989
- } catch {
12990
- }
12991
- fabricCanvas.setActiveObject(effectiveTarget);
12992
- effectiveTarget.setCoords();
12993
- fabricCanvas._target = effectiveTarget;
12994
- opt.target = effectiveTarget;
12995
12975
  pendingGroupPromotionRef.current = null;
12996
12976
  pendingGroupDrillInRef.current = { groupId: drillGroup.id, childId: effectiveTargetId, target: effectiveTarget };
12997
12977
  if (effectiveTarget instanceof fabric__namespace.Textbox) {
12998
12978
  suppressTextEditForClick(effectiveTarget);
12999
- } else {
13000
- effectiveTarget.selected = false;
13001
- effectiveTarget.__lastSelected = false;
13002
- effectiveTarget.__corner = void 0;
13003
12979
  }
13004
- selectElements([effectiveTargetId], false, false);
13005
- updateDrilledGroupOutline();
13006
- fabricCanvas.requestRenderAll();
13007
12980
  }
13008
12981
  } else if (!target || targetId === "__background__") {
13009
- const isMultiSelectKey = !!(((_k = opt.e) == null ? void 0 : _k.shiftKey) || ((_l = opt.e) == null ? void 0 : _l.metaKey) || ((_m = opt.e) == null ? void 0 : _m.ctrlKey));
12982
+ const isMultiSelectKey = !!(((_j = opt.e) == null ? void 0 : _j.shiftKey) || ((_k = opt.e) == null ? void 0 : _k.metaKey) || ((_l = opt.e) == null ? void 0 : _l.ctrlKey));
13010
12983
  if (isMultiSelectKey) return;
13011
- if ((_n = opt.e) == null ? void 0 : _n.altKey) return;
12984
+ if ((_m = opt.e) == null ? void 0 : _m.altKey) return;
13012
12985
  try {
13013
12986
  const pointer = fabricCanvas.getPointer(opt.e);
13014
12987
  const px = pointer.x;
@@ -23463,9 +23436,9 @@ function captureFabricCanvasSvgForPdf(fabricInstance, canvasWidth, canvasHeight)
23463
23436
  }
23464
23437
  return svgString;
23465
23438
  }
23466
- const resolvedPackageVersion = "0.5.247";
23439
+ const resolvedPackageVersion = "0.5.248";
23467
23440
  const PACKAGE_VERSION = resolvedPackageVersion;
23468
- const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.247";
23441
+ const DEPLOYMENT_VERSION_MARKER = "__PIXLDOCS_CANVAS_RENDERER_VERSION__:0.5.248";
23469
23442
  const roundParityValue = (value) => {
23470
23443
  if (typeof value !== "number") return value;
23471
23444
  return Number.isFinite(value) ? Number(value.toFixed(3)) : value;
@@ -24279,7 +24252,7 @@ class PixldocsRenderer {
24279
24252
  await this.waitForCanvasScene(container, cloned, i);
24280
24253
  }
24281
24254
  console.log(`[canvas-renderer][pdf-unified] mounted ${cloned.pages.length} page(s), handing off to client exportMultiPagePdf`);
24282
- const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-7--PybIt.cjs"));
24255
+ const { exportMultiPagePdf, preparePagesForExport } = await Promise.resolve().then(() => require("./vectorPdfExport-C_y0i2dG.cjs"));
24283
24256
  const prepared = preparePagesForExport(
24284
24257
  cloned.pages,
24285
24258
  canvasWidth,
@@ -26599,7 +26572,7 @@ async function prepareLiveCanvasSvgForPdf(rawSvg, pageWidth, pageHeight, pageKey
26599
26572
  if (options == null ? void 0 : options.stripPageBackground) stripRootPageBackgroundFromSvg(svgToDraw);
26600
26573
  sanitizeSvgTreeForPdf(svgToDraw);
26601
26574
  try {
26602
- const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-7--PybIt.cjs"));
26575
+ const { bakeTextAnchorPositionsFromLiveSvg, logTextMeasurementDiagnostic } = await Promise.resolve().then(() => require("./vectorPdfExport-C_y0i2dG.cjs"));
26603
26576
  try {
26604
26577
  await logTextMeasurementDiagnostic(svgToDraw);
26605
26578
  } catch {
@@ -26996,4 +26969,4 @@ exports.setAutoShrinkDebug = setAutoShrinkDebug;
26996
26969
  exports.setBundledAssetPrefixes = setBundledAssetPrefixes;
26997
26970
  exports.warmResolvedTemplateForPreview = warmResolvedTemplateForPreview;
26998
26971
  exports.warmTemplateFromForm = warmTemplateFromForm;
26999
- //# sourceMappingURL=index-D3P-zkRH.cjs.map
26972
+ //# sourceMappingURL=index-KuNxjXIo.cjs.map