jquery(window).load(function(){"function"==typeof jquery.fn.equalheights&&(jquery(".fusion-events-shortcode").each(function(){jquery(this).find(".fusion-events-meta").equalheights()}),jquery(window).on("resize",function(){jquery(".fusion-events-shortcode").each(function(){jquery(this).find(".fusion-events-meta").equalheights()})})),jquery(".fusion-events-pagination-infinite, .fusion-events-pagination-load-more-button").each(function(){var t=jquery(this),e="."+t.attr("class").replace(/\ /g,".").replace(/.fusion\-events\-[a-za-z]+\-sidebar/g,"").replace(".fusion-masonry-has-vertical","")+" ",s=t.find(".fusion-events-wrapper").data("pages");t.find(".fusion-events-wrapper").isotope(),t.children(".fusion-events-wrapper").infinitescroll({navselector:e+".fusion-infinite-scroll-trigger",nextselector:e+".pagination-next",itemselector:e+"div.pagination .current, "+e+" .fusion-events-post",loading:{finishedmsg:avadaportfoliovars.infinite_finished_msg,msg:jquery('
'+avadaportfoliovars.infinite_blog_text+"
")},maxpage:s||void 0,errorcallback:function(){t.find(".fusion-events-post").css("height",""),t.find(".fusion-events-wrapper").isotope()}},function(o){jquery().isotope&&((o=jquery(o)).hide(),imagesloaded(o,function(){var n,e,i;(n=jquery(o).find(".fusion-placeholder-image")).parents(".fusion-events-content-wrapper, .fusion-image-wrapper").animate({opacity:1}),(e=jquery(o).find(".fusion-video")).each(function(){jquery(this).animate({opacity:1}),jquery(this).parents(".fusion-events-content-wrapper").animate({opacity:1})}),e.fitvids(),window.$events_images_index=0,jquery(o).imagesloaded().progress(function(e,i){1<=jquery(i.img).parents(".fusion-events-content-wrapper").length?jquery(i.img,n).parents(".fusion-events-content-wrapper").delay(100*window.$events_images_index).animate({opacity:1}):jquery(i.img,n).parents(".fusion-image-wrapper").delay(100*window.$events_images_index).animate({opacity:1}),window.$events_images_index++}),o.fadein(),t.find(".fusion-events-post").css("height",""),t.find(".fusion-events-wrapper").isotope("appended",o),o.each(function(){jquery(this).find(".full-video, .video-shortcode, .wooslider .slide-content").fitvids()}),jquery('[data-spy="scroll"]').each(function(){jquery(this).scrollspy("refresh")}),"individual"===avadaportfoliovars.lightbox_behavior&&jquery(o).find(".fusion-rollover-gallery").length&&jquery(o).find(".fusion-rollover-gallery").each(function(){window.$ilinstances.push(jquery('[data-rel^="'+jquery(this).attr("data-rel")+'"]').ilightbox(window.avadalightbox.prepare_options(jquery(this).attr("data-rel"))))}),i=t.find(".current").html(),t.find(".current").remove(),s==i&&(t.find(".fusion-loading-container").hide(),t.find(".fusion-load-more-button").hide()),"undefined"!=typeof nicescrollreinit&&nicescrollreinit()}))}),t.hasclass("fusion-events-pagination-load-more-button")&&(t.find(".fusion-events-wrapper").infinitescroll("unbind"),t.find(".fusion-load-more-button").on("click",function(e){e.preventdefault(),t.find(".fusion-events-wrapper").infinitescroll("retrieve")}))})});