Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: The mouse control doesn't switch back to select once middle button is used for pan #3733

Closed
1 task done
mostaphaRoudsari opened this issue May 10, 2024 · 2 comments · Fixed by #3792
Closed
1 task done
Labels
bug Something isn't working

Comments

@mostaphaRoudsari
Copy link

What happened?

I was playing around with the camera options and the change in the wheel behavior which is excellent! I notice that the cursor stays as a hand if I use the left click for panning instead of changing back to select mode. I can get around the issue by using the right click but it should not happen in the first place.

hand-vs-select.mp4

How can we reproduce the bug?

Go to https://examples.tldraw.com/camera-options/full. Click on the middle button to pan. Now select by clicking on the left click and dragging. A hand shows up instead of the selection cursor. Here is a recording with a voice-over.

pan-selection-bug.mp4

What browsers are you seeing the problem on?

Microsoft Edge

Contact Details

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@mostaphaRoudsari mostaphaRoudsari added the bug Something isn't working label May 10, 2024
github-merge-queue bot pushed a commit that referenced this issue May 21, 2024
closes #3013 
closes #3733

This fixes a bug wherein the `inputs.isPanning` state was not being
unset correctly after a middle-click-to-pan gesture with a mouse.

### Change Type

<!-- ❗ Please select a 'Scope' label ❗️ -->

- [x] `sdk` — Changes the tldraw SDK
- [ ] `dotcom` — Changes the tldraw.com web app
- [ ] `docs` — Changes to the documentation, examples, or templates.
- [ ] `vs code` — Changes to the vscode plugin
- [ ] `internal` — Does not affect user-facing stuff

<!-- ❗ Please select a 'Type' label ❗️ -->

- [x] `bugfix` — Bug fix
- [ ] `feature` — New feature
- [ ] `improvement` — Improving existing features
- [ ] `chore` — Updating dependencies, other boring stuff
- [ ] `galaxy brain` — Architectural changes
- [ ] `tests` — Changes to any test code
- [ ] `tools` — Changes to infrastructure, CI, internal scripts,
debugging tools, etc.
- [ ] `dunno` — I don't know


### Test Plan

1. Add a step-by-step description of how to test your PR here.
2.

- [ ] Unit Tests
- [ ] End to end tests

### Release Notes

- Add a brief release note for your PR here.
@ds300
Copy link
Collaborator

ds300 commented May 21, 2024

Thanks for the report! ❤️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants