orcasvn-react-diagrams 0.1.49 → 0.1.50

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/cjs/index.js CHANGED
@@ -714,7 +714,9 @@ var Port$1 = /** @class */ (function () {
714
714
  }
715
715
  else if (shapeRenderer && shapeRenderer.customShapeWithJSX) {
716
716
  this.renderShape = React.forwardRef(function (props, ref) {
717
- return (React.createElement(CustomShape, { ref: ref, x: props.x, y: props.y, width: props.width, height: props.height, rotation: props.rotation, positioningAnchor: shapeRenderer.positioningAnchor, onClick: function (e) { var _a; return (_a = props.onSelected) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseDown: function (e) { var _a; return (_a = props.onMouseDown) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseUp: function (e) { var _a; return (_a = props.onMouseUp) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); } }, shapeRenderer.customShapeWithJSX));
717
+ return (React.createElement(CustomShape, { ref: ref, x: props.x, y: props.y, width: props.width, height: props.height, rotation: props.rotation, positioningAnchor: shapeRenderer.positioningAnchor, onClick: function (e) { var _a; return (_a = props.onSelected) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseDown: function (e) { var _a; return (_a = props.onMouseDown) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseUp: function (e) { var _a; return (_a = props.onMouseUp) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); } },
718
+ shapeRenderer.customShapeWithJSX,
719
+ props.children));
718
720
  });
719
721
  }
720
722
  }
@@ -8577,6 +8579,7 @@ var Element = React.forwardRef(function (props, forwardedRef) {
8577
8579
  }, []);
8578
8580
  var handleSelectedPort = React.useCallback(function (portId, e) {
8579
8581
  e.stopPropagation();
8582
+ logger.debug('Port selected', portId, e);
8580
8583
  var port = portsRef.current.find(function (p) { return p.id === portId; });
8581
8584
  if (!port)
8582
8585
  return;
@@ -8625,6 +8628,8 @@ var Element = React.forwardRef(function (props, forwardedRef) {
8625
8628
  //Handle when mouse down on port
8626
8629
  var handlePortMouseDown = React.useCallback(function (portId, e) {
8627
8630
  e.stopPropagation();
8631
+ //log debugger
8632
+ logger.debug('Port mouse down', portId, e);
8628
8633
  var port = portsRef.current.find(function (p) { return p.id === portId; });
8629
8634
  if (!port)
8630
8635
  return;
package/dist/esm/index.js CHANGED
@@ -710,7 +710,9 @@ var Port$1 = /** @class */ (function () {
710
710
  }
711
711
  else if (shapeRenderer && shapeRenderer.customShapeWithJSX) {
712
712
  this.renderShape = forwardRef(function (props, ref) {
713
- return (React.createElement(CustomShape, { ref: ref, x: props.x, y: props.y, width: props.width, height: props.height, rotation: props.rotation, positioningAnchor: shapeRenderer.positioningAnchor, onClick: function (e) { var _a; return (_a = props.onSelected) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseDown: function (e) { var _a; return (_a = props.onMouseDown) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseUp: function (e) { var _a; return (_a = props.onMouseUp) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); } }, shapeRenderer.customShapeWithJSX));
713
+ return (React.createElement(CustomShape, { ref: ref, x: props.x, y: props.y, width: props.width, height: props.height, rotation: props.rotation, positioningAnchor: shapeRenderer.positioningAnchor, onClick: function (e) { var _a; return (_a = props.onSelected) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseDown: function (e) { var _a; return (_a = props.onMouseDown) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); }, onMouseUp: function (e) { var _a; return (_a = props.onMouseUp) === null || _a === void 0 ? void 0 : _a.call(props, _this.id, e); } },
714
+ shapeRenderer.customShapeWithJSX,
715
+ props.children));
714
716
  });
715
717
  }
716
718
  }
@@ -8573,6 +8575,7 @@ var Element = forwardRef(function (props, forwardedRef) {
8573
8575
  }, []);
8574
8576
  var handleSelectedPort = useCallback(function (portId, e) {
8575
8577
  e.stopPropagation();
8578
+ logger.debug('Port selected', portId, e);
8576
8579
  var port = portsRef.current.find(function (p) { return p.id === portId; });
8577
8580
  if (!port)
8578
8581
  return;
@@ -8621,6 +8624,8 @@ var Element = forwardRef(function (props, forwardedRef) {
8621
8624
  //Handle when mouse down on port
8622
8625
  var handlePortMouseDown = useCallback(function (portId, e) {
8623
8626
  e.stopPropagation();
8627
+ //log debugger
8628
+ logger.debug('Port mouse down', portId, e);
8624
8629
  var port = portsRef.current.find(function (p) { return p.id === portId; });
8625
8630
  if (!port)
8626
8631
  return;