@aibee/crc-bmap 0.0.25 → 0.0.26

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/lib/bmap.esm.js CHANGED
@@ -1592,8 +1592,9 @@ var BoxSelection = class extends BaseSvg {
1592
1592
  const width = Math.abs(endPoint.x - startPoint.x);
1593
1593
  const height = Math.abs(endPoint.y - startPoint.y);
1594
1594
  setRectPosition(this.rect, leftTop.x, leftTop.y, width, height);
1595
+ } else {
1596
+ setRectPosition(this.rect, 0, 0, 0, 0);
1595
1597
  }
1596
- setRectPosition(this.rect, 0, 0, 0, 0);
1597
1598
  });
1598
1599
  const { config: { selectBox: { fill, stroke } } } = context;
1599
1600
  this.rect = createRect(stroke, fill);
@@ -1681,6 +1682,7 @@ var Selection = class extends EventDispatcher3 {
1681
1682
  __publicField(this, "_list", /* @__PURE__ */ new Set());
1682
1683
  __publicField(this, "boxSelection");
1683
1684
  __publicField(this, "prevPanStatus");
1685
+ __publicField(this, "prevRotateStatus");
1684
1686
  __publicField(this, "onPointerDown", (e) => {
1685
1687
  const { graphics } = this.context.getGraphicsByDeviceXy(e.offsetX, e.offsetY);
1686
1688
  const graphicIdSet = new Set(graphics.map((item) => item.options.id));
@@ -1705,13 +1707,16 @@ var Selection = class extends EventDispatcher3 {
1705
1707
  if (e.key === "Control") {
1706
1708
  this.boxSelection.setEnable(true);
1707
1709
  this.prevPanStatus = this.context.control.enablePan;
1710
+ this.prevRotateStatus = this.context.control.enableRotate;
1708
1711
  this.context.control.enablePan = false;
1712
+ this.context.control.enableRotate = false;
1709
1713
  }
1710
1714
  });
1711
1715
  __publicField(this, "onKeyUp", (e) => {
1712
1716
  if (e.key === "Control") {
1713
1717
  this.boxSelection.setEnable(false);
1714
1718
  this.context.control.enablePan = !!this.prevPanStatus;
1719
+ this.context.control.enableRotate = !!this.prevRotateStatus;
1715
1720
  }
1716
1721
  });
1717
1722
  __publicField(this, "onBoxSelected", ({ list }) => {