worka / vanilla-js-wheel-zoom

Image resizing using mouse wheel (pinch to zoom) + drag scrollable image (as well as any HTML content)
https://worka.github.io/vanilla-js-wheel-zoom
MIT License
168 stars 31 forks source link

original scale fix #50

Open e3rd opened 7 months ago

e3rd commented 7 months ago

This pull addresses the issue from my previous proposal #49 . That was entirely my bad. As we needed to change the underlying picture, we parsed the currently zoomed scale for the original scale. Moreover, I had a bug in the scale property parsing. (Because it may contain 1, 2 or 3 values).

I tried all the examples now, every button, and my PR behaves me just the same as your original examples.

e3rd commented 6 months ago

Is there anything I could add? o:)