react-chessboard-ui 2.2.0 → 2.2.1

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.js CHANGED
@@ -2708,7 +2708,7 @@ var useChessBoardInteractive = function useChessBoardInteractive(props) {
2708
2708
  clearMarkedCells();
2709
2709
  clearArrows();
2710
2710
  if (viewOnly) return;
2711
- if (clickedPos[0] === -1) {
2711
+ if (clickedPos[0] === -1 || JSChessEngine.hasFigure(actualState, cellPos) && JSChessEngine.getFigureColor(actualState, cellPos) === currentColor) {
2712
2712
  selectClickFrom(cellPos);
2713
2713
  return;
2714
2714
  }