fat / zoom.js

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

Holding META key should open the full-size image as a direct link in a new tab #3

Closed rauchg closed 9 years ago

rauchg commented 9 years ago

eg: ⌘

This is also a neat workaround to the situation where the real image size exceeds the viewport's.

fat commented 9 years ago

you owe me, atleast, 5% of your company

jdreesen commented 9 years ago

Sadly, your fix in b9d978ea doesn't work for me in FF37 and Chrome 43beta on Win7. Maybe I'm just using the wrong meta key? I tried with shift, ctrl, alt, win but nothing works (even in the jQuery demo). So, which one do I have to use?

fat commented 9 years ago

we use this property in jquery: http://api.jquery.com/event.metakey/

Honestly not sure what it maps to on win7 – maybe you don't have a metakey?

jdreesen commented 9 years ago

I already checked the jquery property and it doesn't work. Seems that windows has no metakey, but it's not that easy to find any information about that key.

rauchg commented 9 years ago

I think on Windows it's ctrl ?

jdreesen commented 9 years ago

I thought that too, but it doesn't work - at least for me.

cvrebert commented 9 years ago

MouseEvent.metaKey:

Note: On Macintosh keyboards, this is the command key (⌘). On Windows keyboards, this is the Windows key (⊞).

jdreesen commented 9 years ago

Did you try it? Does it work for you?