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

Help needed: callback on zoom? #31

Open
giofilo opened this issue May 10, 2024 · 0 comments
Open

Help needed: callback on zoom? #31

giofilo opened this issue May 10, 2024 · 0 comments

Comments

@giofilo
Copy link

giofilo commented May 10, 2024

Hi, thank you for this library, it's exactly what I need!
For my purposes, I need to know when an image is zoomed in and zoomed out. So, I would need something like a callback.
Looking at the source code, I saw both the useZoomGesture hook and the animationFunction prop, but I didn't understand how to use them.
So I'm asking for your help on this.
I don't want to customize or rewrite the entire animation, I just need to know when the zoom is activated or deactivated.
Ideally, I would like to have two callbacks: at the beginning of the animation and at the end of the animation.

Thanks!

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