expand images in new posts
This commit is contained in:
parent
b6bf9436d0
commit
35069a9ae5
@ -380,6 +380,7 @@ imageClick = (e) ->
|
||||
|
||||
imageExpandClick = ->
|
||||
thumbs = $$ 'img[md5]'
|
||||
g.expand = @checked
|
||||
if @checked #expand
|
||||
for thumb in thumbs
|
||||
if thumb.className isnt 'hide'
|
||||
@ -823,6 +824,7 @@ AEOS.init()
|
||||
g =
|
||||
callbacks: []
|
||||
count: 0
|
||||
expand: false
|
||||
favEmpty: 'data:image/gif;base64,R0lGODlhEAAQAJEAAAAAAP///9vb2////yH5BAEAAAMALAAAAAAQABAAAAIvnI+pq+D9DBAUoFkPFnbs7lFZKIJOJJ3MyraoB14jFpOcVMpzrnF3OKlZYsMWowAAOw=='
|
||||
favNormal: $('link[rel="shortcut icon"]', $('head', d))?.href or 'http://static.4chan.org/image/favicon.ico'
|
||||
flavors: [
|
||||
@ -982,6 +984,7 @@ if getConfig 'Image Expansion'
|
||||
thumbs = $$ 'img[md5]', root
|
||||
for thumb in thumbs
|
||||
thumb.parentNode.addEventListener 'click', imageClick, true
|
||||
if g.expand then imageFull thumb
|
||||
|
||||
if getConfig 'Localize Time'
|
||||
g.callbacks.push (root) ->
|
||||
|
||||
@ -489,6 +489,7 @@
|
||||
imageExpandClick = function() {
|
||||
var thumb, thumbs, _i, _j, _len, _len2, _results, _results2;
|
||||
thumbs = $$('img[md5]');
|
||||
g.expand = this.checked;
|
||||
if (this.checked) {
|
||||
_results = [];
|
||||
for (_i = 0, _len = thumbs.length; _i < _len; _i++) {
|
||||
@ -1091,6 +1092,7 @@
|
||||
g = {
|
||||
callbacks: [],
|
||||
count: 0,
|
||||
expand: false,
|
||||
favEmpty: 'data:image/gif;base64,R0lGODlhEAAQAJEAAAAAAP///9vb2////yH5BAEAAAMALAAAAAAQABAAAAIvnI+pq+D9DBAUoFkPFnbs7lFZKIJOJJ3MyraoB14jFpOcVMpzrnF3OKlZYsMWowAAOw==',
|
||||
favNormal: ((_ref = $('link[rel="shortcut icon"]', $('head', d))) != null ? _ref.href : void 0) || 'http://static.4chan.org/image/favicon.ico',
|
||||
flavors: ['http://regex.info/exif.cgi?url=', 'http://iqdb.org/?url=', 'http://saucenao.com/search.php?db=999&url=', 'http://tineye.com/search?url='].join('\n'),
|
||||
@ -1255,7 +1257,8 @@
|
||||
_results = [];
|
||||
for (_i = 0, _len = thumbs.length; _i < _len; _i++) {
|
||||
thumb = thumbs[_i];
|
||||
_results.push(thumb.parentNode.addEventListener('click', imageClick, true));
|
||||
thumb.parentNode.addEventListener('click', imageClick, true);
|
||||
_results.push(g.expand ? imageFull(thumb) : void 0);
|
||||
}
|
||||
return _results;
|
||||
});
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user