From 23f23b830160eaf07d3d0488fd2c6343f33d5448 Mon Sep 17 00:00:00 2001 From: Michael Foster Date: Fri, 16 Aug 2013 22:02:57 +1000 Subject: [PATCH] Make js/inline-expanding.js better, now that post images are marked with .post-image --- js/inline-expanding.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/js/inline-expanding.js b/js/inline-expanding.js index 61085b0d..ac477409 100644 --- a/js/inline-expanding.js +++ b/js/inline-expanding.js @@ -16,10 +16,7 @@ onready(function(){ var link = this.getElementsByTagName('a'); for (var i = 0; i < link.length; i++) { - if (typeof link[i] == "object" && link[i].childNodes && typeof link[i].childNodes[0] !== 'undefined' && link[i].childNodes[0].src && link[i].className != 'file') { - if (window.jQuery && !$(link).prev().hasClass('fileinfo')) { - continue; - } + if (typeof link[i] == "object" && link[i].childNodes && typeof link[i].childNodes[0] !== 'undefined' && link[i].childNodes[0].src && link[i].childNodes[0].className.match(/post-image/)) { link[i].childNodes[0].style.maxWidth = '95%'; link[i].onclick = function(e) { if (this.childNodes[0].className == 'hidden')