FIX: control+shitf selects area

This commit is contained in:
Nicolás Hatcher
2025-06-02 20:49:43 +02:00
committed by Nicolás Hatcher Andrés
parent a5d8ee9ef0
commit 3e015bf13a

View File

@@ -236,9 +236,16 @@ const usePointer = (options: PointerSettings): PointerEvents => {
); );
// we continue to select the new cell // we continue to select the new cell
} }
options.onCellSelected(cell, event); if (event.shiftKey) {
isSelecting.current = true; // We are extending the selection
worksheetWrapper.setPointerCapture(event.pointerId); options.onAreaSelecting(cell);
options.onAreaSelected();
} else {
// We are selecting a single cell
options.onCellSelected(cell, event);
isSelecting.current = true;
worksheetWrapper.setPointerCapture(event.pointerId);
}
} }
}, },
[options], [options],