jQuery(window).on("load",function(){jQuery(".fusion-recent-posts-infinite .fusion-columns").each(function(i){var n,e,o=jQuery(this),t=o.parent(),s="."+t.attr("class").replace(/\ /g,".")+" ",a=jQuery(this).find(".fusion-column");jQuery(o).infinitescroll({navSelector:s+".fusion-infinite-scroll-trigger",nextSelector:s+"a.pagination-next",itemSelector:s+"div.pagination .current, "+s+"article.post",loading:{finishedMsg:fusionRecentPostsVars.infinite_finished_msg,msg:jQuery('<div class="fusion-loading-container fusion-clearfix"><div class="fusion-loading-spinner"><div class="fusion-spinner-1"></div><div class="fusion-spinner-2"></div><div class="fusion-spinner-3"></div></div><div class="fusion-loading-msg">'+fusionRecentPostsVars.infinite_loading_text+"</div>")},maxPage:t.data("pages")?t.data("pages"):void 0,infid:"rp"+i,errorCallback:function(){}},function(i){jQuery(i).hide(),imagesLoaded(i,function(){jQuery(i).fadeIn()}),fusionInitPostFlexSlider(),jQuery(i).each(function(){jQuery(this).find(".full-video, .video-shortcode, .wooslider .slide-content").fitVids()}),n=t.find(".current").html(),t.find(".current").remove(),t.data("pages")==n&&(t.find(".fusion-loading-container").hide(),t.find(".fusion-load-more-button").hide()),jQuery(i).find(".fusion-rollover-gallery").length&&("individual"!==fusionRecentPostsVars.lightbox_behavior&&a.find(".fusion-rollover-gallery").length?(e=a.find(".fusion-rollover-gallery").first().data("rel"),a=o.find(".post"),void 0!==window.$ilInstances[e]&&(window.$ilInstances[e].destroy(),delete window.$ilInstances[e],window.avadaLightBox.activate_lightbox(a))):(window.avadaLightBox.activate_lightbox(jQuery(i)),a=o.find(".post")),window.avadaLightBox.refresh_lightbox()),setTimeout(function(){jQuery(window).trigger("resize",[!1])},500),jQuery.isFunction(jQuery.fn.initElementAnimations)&&jQuery(window).initElementAnimations()}),jQuery(t).hasClass("fusion-recent-posts-load-more")&&(jQuery(o).infinitescroll("unbind"),jQuery(t).find(".fusion-load-more-button").on("click",function(i){i.preventDefault(),jQuery(o).infinitescroll("retrieve")})),1===parseInt(t.data("pages"),10)&&(t.find(".fusion-loading-container").hide(),t.find(".fusion-load-more-button").hide())})});