wittlock/ngx-image-zoom

Scroll zoom in conjunction with 'toggle' mode

Opened this issue · 1 comments

I've got an ngx-img-zoom component setup like this:

<ngx-image-zoom
    [thumbImage]="www.link-to.img"
    [fullImage]="www.link-to-full.img"
    zoomMode="toggle"
    [enableScrollZoom]=true>
</ngx-image-zoom>

My intent is to use the toggle mode to zoom to the full image, and then the scroll function to adjust the zoomAmount and the location of the zoomed-in portion.

However, it seems that scroll zoom zooms in on the component as if it was hovering over the thumbImage: if I click to toggle-zoom into the lower-left corner of the thumbImage, move the cursor to the top-right part of the currently zoomed-in fullImg and then scroll, the component displays a part of the fullImg that the cursor would have been hovering over on the thumbImg.

I hope that explanation got through correctly. It leads to quite an unintuitive user experience.

I get what you're mentioning, I've encountered this as well. It's clearly an undesired behavior.

Currently life is a bit too hectic to really have a chance to put in the effort for any bigger fixes on my open source projects. I'll happily check some pull requests though. Otherwise life will hopefully settle down come fall and winter and I'll get a chance to revisit my projects and do some much needed catching up on them.