simplezoom.js
simplezoom.js copied to clipboard
option to specify the preview URL
Currently, the library uses the hovered thumbnail image URL to show as preview too. So basically, the thumbnail URL and preview URL are both same right now. This is wrong assumption because thumbnails generally have smaller image sizes for perf.
There should be an option to allow developers to specify the preview (large) image url for every thumbnail or all thumbnail in general.
Some ideas:
-
Using attributes:
<img src="thumbnail.png" data-simplezoom-url="large-img.png" /> -
General modifier:
simplezoom.init({ previewUrl: { suffix: 'large-', prefix: '-2x' } // will transform every abc.png into large-abc-2x.png });