fat / zoom.js

Medium's Image Zoom for jQuery
https://fat.github.io/zoom.js
MIT License
4.04k stars 331 forks source link

Need srcset support #44

Open joshuapekera opened 9 years ago

joshuapekera commented 9 years ago

When using images with srcset in browsers that have native support (Chrome & Firefox) the plugin breaks. The plugin depends on a src to be specified. Polyfills, like picturefill or lazysizes/respimage, create a src image in Safari 8 because full native support for srcset isn't implemented yet. However, that will change with the release of Safari 9, which I confirmed by testing with Webkit Nightly. I'll look into a fix my self, but any thoughts on how to extend this to use srcset if src is not specified would be very helpful.

nelga commented 9 years ago

+1

Schweinepriester commented 8 years ago

+1

andre3wap commented 8 years ago

+1

nextgenthemes commented 8 years ago

+1

heavybeard commented 8 years ago

+1

PS: A <picture> extension would be very helpful too

heavybeard commented 8 years ago

I add a new pull request with .currentSrc https://github.com/fat/zoom.js/pull/65

In theory this fix the srcset too. Can someone confirm this?

strarsis commented 8 years ago

+1

adi- commented 8 years ago

+1