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

Zoom in and out of canvas #1

Open
thisisaaronland opened this issue Mar 23, 2023 · 1 comment
Open

Zoom in and out of canvas #1

thisisaaronland opened this issue Mar 23, 2023 · 1 comment
Labels
help wanted Extra attention is needed todo

Comments

@thisisaaronland
Copy link
Contributor

There were some early tests using escobar5/raphael-pan-zoom which:

  • Works in a desktop context but, as written, don't update the position and offset of the raphael-sketchpad pen so paths don't appear where they should.
  • Seems to work correctly in a mobile context except that the entire HTML canvas, rather than just the SVG element, is zoomed in and out.
@thisisaaronland thisisaaronland added todo help wanted Extra attention is needed labels Mar 23, 2023
@straup
Copy link
Contributor

straup commented Mar 27, 2023

https://dmitrybaranovskiy.github.io/raphael/reference.html#Paper.setViewBox

There are two things to figure out:

  1. UI/UX for taking raphael.sketchpad out of editing mode and listening for pan/zoom events
  2. Adjusting the offset (_offset) for the pen in raphael.sketchpad

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed todo
Projects
None yet
Development

No branches or pull requests

2 participants