GoogleChromeLabs/squoosh

Add a button to reset position (move to center)

Open

#292 aberto em 15 de nov. de 2018

Ver no GitHub
 (7 comments) (0 reactions) (0 assignees)TypeScript (1.431 forks)batch import
UIfeature requestgood first issue

Métricas do repositório

Stars
 (20.335 stars)
Métricas de merge de PR
 (Nenhuma PRs mesclada em 30d)

Description

I find it a bit annoying that zooming out can put the image in some awkward corner.

Perhaps it's a good idea to prevent the image from going too far, e.g. ensure it's (1) always visible (so you can't scroll in a way which puts it off-screen) and (2) image edges snap to splitter if taken too much to the left or right.

So if the zoom or pan results in something like this:

image

...it would just snap to this:

image

Guia do colaborador