Server IP : 162.213.251.212 / Your IP : 3.148.103.214 [ Web Server : LiteSpeed System : Linux business55.web-hosting.com 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024 x86_64 User : allssztx ( 535) PHP Version : 8.1.31 Disable Function : NONE Domains : 1 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/allssztx/./www/jollyprecast/wp-content/themes/woodmart/js/scripts/portfolio/ |
Upload File : |
/* global woodmart_settings */ (function($) { woodmartThemeModule.ajaxPortfolio = function() { if ('no' === woodmart_settings.ajax_portfolio || 'undefined' === typeof ($.fn.pjax)) { return; } var ajaxLinks = '.wd-type-links .wd-nav-portfolio a, .tax-project-cat .wd-pagination a, .post-type-archive-portfolio .wd-pagination a'; woodmartThemeModule.$body.on('click', '.tax-project-cat .wd-pagination a, .post-type-archive-portfolio .wd-pagination a', function() { scrollToTop(true); }); woodmartThemeModule.$document.pjax(ajaxLinks, '.main-page-wrapper', { timeout : woodmart_settings.pjax_timeout, scrollTo: false, renderCallback: function(context, html, afterRender) { woodmartThemeModule.removeDuplicatedStylesFromHTML(html, function(html) { context.html(html); afterRender(); woodmartThemeModule.$document.trigger('wdPortfolioPjaxComplete'); woodmartThemeModule.$document.trigger('wood-images-loaded'); }); } }); woodmartThemeModule.$document.on('pjax:start', function() { var $siteContent = $('.site-content'); $siteContent.removeClass('wd-loaded'); $siteContent.addClass('wd-loading'); woodmartThemeModule.$document.trigger('wdPortfolioPjaxStart'); woodmartThemeModule.$window.trigger('scroll.loaderVerticalPosition'); }); woodmartThemeModule.$document.on('pjax:end', function() { $('.site-content').removeClass('wd-loading'); }); woodmartThemeModule.$document.on('pjax:complete', function() { if (!woodmartThemeModule.$body.hasClass('tax-project-cat') && !woodmartThemeModule.$body.hasClass('post-type-archive-portfolio')) { return; } woodmartThemeModule.$document.trigger('wood-images-loaded'); scrollToTop(false); $('.wd-ajax-content').removeClass('wd-loading'); }); var scrollToTop = function(type) { if (woodmart_settings.ajax_scroll === 'no' && type === false) { return false; } var $scrollTo = $(woodmart_settings.ajax_scroll_class), scrollTo = $scrollTo.offset().top - woodmart_settings.ajax_scroll_offset; $('html, body').stop().animate({ scrollTop: scrollTo }, 400); }; }; $(document).ready(function() { woodmartThemeModule.ajaxPortfolio(); }); })(jQuery);