You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
During the troubleshooting process, I found that when initializing the container variable, the document.documentElement.clientHeight property is set to the height of the entire document, causing the image to appear in the middle of the document. I temporarily solved this problem by adding options and setting the container to .medium-zoom-overlay.
importmediumZoomfrom'medium-zoom';// Medium Zoom.u-rich-text img,figure imgexportdefaultfunctioninitMediumZoom(){constimages=document.querySelectorAll('.u-rich-text img');mediumZoom(images,{background: 'rgba(0,0,0,0.75)',container: '.medium-zoom-overlay'});}
I also noticed that when using the srcset attribute, medium-zoom seems to clone the image node. What is the reason behind this? Additionally, there is a flickering issue on the webpage when zooming in on the image.
Bug description
How to reproduce
use code
Expected behavior
Reproducible example
please see my blog
https://1900.live/top-5-personal-movies-of-the-year-2023/
Environment
medium-zoom
version:The text was updated successfully, but these errors were encountered: