Skip to content

Commit 7aa0a01

Browse files
committed
fix: extend pointer sensor
1 parent 4e1856b commit 7aa0a01

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/ChessboardProvider.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import {
44
DragStartEvent,
55
KeyboardSensor,
66
MouseSensor,
7-
PointerSensor,
87
pointerWithin,
98
TouchSensor,
109
useSensor,
@@ -603,7 +602,7 @@ export function ChessboardProvider({
603602
);
604603

605604
const sensors = useSensors(
606-
useSensor(PointerSensor, {
605+
useSensor(RightClickCancelSensor, {
607606
activationConstraint:
608607
dragActivationDistance > 0
609608
? {
@@ -614,7 +613,6 @@ export function ChessboardProvider({
614613
useSensor(KeyboardSensor),
615614
useSensor(TouchSensor),
616615
useSensor(MouseSensor),
617-
useSensor(RightClickCancelSensor),
618616
);
619617

620618
// collision detection that first tries pointer-based detection and then falls back to rectangle intersection for keyboards

0 commit comments

Comments
 (0)