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

[FR]: Support double-tap zoom #51

Closed
1 task done
herbeth1u opened this issue Apr 22, 2023 · 5 comments
Closed
1 task done

[FR]: Support double-tap zoom #51

herbeth1u opened this issue Apr 22, 2023 · 5 comments

Comments

@herbeth1u
Copy link

Is there an existing issue for this?

  • I have searched the existing issues

Describe the problem

As of now, Zoomable supports a "double-tap + drag" zoom. Is it possible to support the arguably more usual "double-tap" zoom?
For example, it's a feature supported by PhotoView or Discord's image viewer.

Describe the solution

How it works:

Thanks.

@usuiat
Copy link
Owner

usuiat commented Apr 22, 2023

Thanks for the proposal. @herbeth1u
I agree that a double-tap zoom would be useful.

However, is the 3-step behaviour like PhotoView necessary?
I think the following 2-step behaviour is enough.

  • Double-tap once: scale = 2.0
  • Double-tap again: resets zoom

I checked the behavior of Google Photo, Twitter, Facebook, Discord, etc.
They all implement this 2-step behavior.

@herbeth1u
Copy link
Author

How about making the number of steps configurable? If this is too overkill, settling on the 2-step behavior like most popular apps sounds like a reasonable plan as well.

@usuiat
Copy link
Owner

usuiat commented Apr 23, 2023

Noted.
We will consider how to implement it.

@cacato86
Copy link

How is the state of this feature? The library is awesome, but I'm missing this functionality 😞

@usuiat
Copy link
Owner

usuiat commented May 19, 2023

Thank you for waiting.

I have been busy with my personal life recently and implementation has stopped.
I hope to resume in June.

I will push the source code of the implementation in progress, so please take a look if you like.
Your comments are also welcome.

@usuiat usuiat mentioned this issue May 19, 2023
3 tasks
@usuiat usuiat closed this as completed May 28, 2023
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

3 participants