X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/845904c7c85fbed75b10be702f102d817ed0d7f5..a18466c5b58ffbcca36e9834fd713b10265ead29:/src/wolnelektury/static/js/book_text/references.js diff --git a/src/wolnelektury/static/js/book_text/references.js b/src/wolnelektury/static/js/book_text/references.js index 4c72fe60b..b75a4daf3 100644 --- a/src/wolnelektury/static/js/book_text/references.js +++ b/src/wolnelektury/static/js/book_text/references.js @@ -78,7 +78,11 @@ $.each(ref.images, function(i, e) { $i = $(""); $i.attr('href', e.page); - $('img', $i).attr('src', e.url); + $('img', $i).attr('src', e.thumburl || e.url); + if (e.thumbresolution) { + $('img', $i).attr('width', e.thumbresolution[0]).attr('height', e.thumbresolution[1]); + } + $("#reference-images").append($i); }) }