Skip to content
This repository has been archived by the owner on Feb 25, 2024. It is now read-only.

Commit

Permalink
Fixed panning/dragging interations (the ones that include pressing po…
Browse files Browse the repository at this point in the history
…inter down) in FireFox (#343)
  • Loading branch information
Andarist authored Feb 1, 2022
1 parent 42d1303 commit 632f950
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/healthy-lies-jump.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'xstate-viz-app': patch
---

Fixed panning/dragging interations (the ones that include pressing pointer down) in FireFox.
2 changes: 1 addition & 1 deletion src/dragSessionTracker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ export const dragSessionTracker = dragSessionModel.createMachine(
ref!.current!.releasePointerCapture(session!.pointerId),
setSessionData: assign({
session: (ctx, ev: any) => {
if (ev.pointerId && ev.point)
if ('pointerId' in ev && ev.point)
return {
pointerId: ev.pointerId,
point: ev.point,
Expand Down

0 comments on commit 632f950

Please sign in to comment.