Closed 0e4ef622 closed 8 years ago
+1, <img href>
is dubious at best (I've never even heard of it until seeing it in the Miaou source) and bad for accessibility, as well as not being compatible with extensions such as Pentadactyl for Firefox or cVim for Chromium.
... taking a closer look, href
isn't even valid on img
, and the clicking is handled with JavaScript. No point in relying on intercepting click
with JS when you can simply wrap with <a>
, which is far more semantically accurate.
Reminder:
Right now, this has many unwanted side effects:
That's why I removed the a
tag initially. I'm not sure of what would be the best solution for cvim compatibility (and other accessibility problems related to not having a a
element).
Hmm... I could add target="_blank"
to make it open in a new tab. I'm not sure what to do for the other problems though...
Obviously we need the JS handling part. I don't know if cvim is OK with an image in an href element whose behavior is changed by an event handler. In that case it might be possible to combine both.
this should let you "click" on an image using cVim