kylewetton / image-compare-viewer

Compare before and after images, for grading and other retouching for instance. Vanilla JS, zero dependencies.
https://image-compare-viewer.netlify.com
MIT License
545 stars 32 forks source link

There is a bug in script version 1.6.2 #60

Open sergeydemin30111997 opened 9 months ago

sergeydemin30111997 commented 9 months ago

In version 1.6.2 there is a bug that can only be reproduced on the iPhone in the Safari browser. Its essence is that when we try to move the bar before/after, our page moves to the top. Everything is fine in version 1.5.0

nnrahm commented 9 months ago

I'm also having this issue. I'm using the viewer on a SvelteKit app.

Jorge-Mauricio-Rodriguez commented 9 months ago

I think is due the update of the body-scroll-lock dependency.

It appears that it changes how it works for iOs from one version to another

You can look it here: https://github.com/willmcpo/body-scroll-lock/releases/tag/v4.0.0-beta.0

Maybe downgrade the dependency just one version till the v4.0.0 is no longer beta can be a solution.

image
TheFienix commented 8 months ago

I can confirm this issue on apple devices. I had to revert to 1.5 version.

ahmed-mera commented 8 months ago

I'm also having this issue in all browsers on ios (iphone/ipad). when I try to move the bar before/after the page refreshes

4wk- commented 7 months ago

Body Scroll Lock project seems abandoned.

However, we might have a way to make it work with iOS, if you check this guy: https://github.com/rick-liruixin/body-scroll-lock-upgrade

npm i body-scroll-lock-upgrade
nguyenhc-bitvn commented 6 months ago

Body Scroll Lock project seems abandoned.

However, we might have a way to make it work with iOS, if you check this guy: https://github.com/rick-liruixin/body-scroll-lock-upgrade

npm i body-scroll-lock-upgrade

I'm using plain HTML and JavaScript, how can I call body-scroll-lock? Does ImageCompare library support event listeners?