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

Incorrect calculation of X&Y focal point zooming #668

Open
IgorA100 opened this issue Jun 8, 2024 · 0 comments
Open

Incorrect calculation of X&Y focal point zooming #668

IgorA100 opened this issue Jun 8, 2024 · 0 comments

Comments

@IgorA100
Copy link

IgorA100 commented Jun 8, 2024

Describe the bug

When you specify a focal point on the edge (border) of a scaled image, then reduce the image to MinScale, the image shifts. The shift occurs at the moment of the last scaling, i.e. when Scale becomes MinScale. Once the image is enlarged, it remains shifted.

Your environment

  • Version of panzoom - 4.5.1
  • Browser and browser version - Chrome 125.0.6422.142

Expected behavior

The image should not shifted.

Actual behavior

The image shifted.

Steps to reproduce

  1. Initialize the object with {contain: 'inside'}
  2. Execute zoomToPoint indicating the coordinates on the edge (border) of the scaled image,
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant