Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Chen-Zhe/photo-grid.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChen Zhe <chenzhesg@gmail.com>2020-02-18 18:13:57 +0300
committerChen Zhe <chenzhesg@gmail.com>2020-02-18 18:13:57 +0300
commitf8a67e992d0c93a685ddf8c4b82964f21528d6eb (patch)
treed9af2de84d168a9737362865e38d8cfa840af8c1 /static/js/main.js
parent98a90bd0eb7c5bddabd936b1d2c636a9c185fade (diff)
bump to latest jquery version
Diffstat (limited to 'static/js/main.js')
-rw-r--r--static/js/main.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/static/js/main.js b/static/js/main.js
index 5cd7662..124131f 100644
--- a/static/js/main.js
+++ b/static/js/main.js
@@ -345,7 +345,7 @@ var Grid = (function() {
if( self.$fullimage.is( ':visible' ) ) {
this.$loading.show();
- $( '<img/>' ).load( function() {
+ $( '<img/>' ).on("load", function() {
var $img = $( this );
if( $img.attr( 'src' ) === self.$item.children('a').data( 'largesrc' ) ) {
self.$loading.hide();
@@ -462,7 +462,7 @@ document.addEventListener("DOMContentLoaded", function() {
entries.forEach(function(entry) {
if (entry.isIntersecting) {
var image = entry.target;
- $(image).load(function(){
+ $(image).on("load", function(){
image.classList.remove("lazy");
image.style.removeProperty("width");
}).attr('src', image.dataset.src);