-
Notifications
You must be signed in to change notification settings - Fork 0
/
demo-script.min
1 lines (1 loc) · 1.32 KB
/
demo-script.min
1
!function(t){function o(o){var e=t(document).scrollTop();t("#main-menu a").each(function(){var o=t(this),a=t(o.attr("href"));a.position().top-95<=e&&a.position().top+a.height()>e?(t("#main-menu ul li a").removeClass("active"),o.addClass("active")):o.removeClass("active")})}t(document).ready(function(){t(document).on("scroll",o),t('a[href^="#"]').on("click",function(e){e.preventDefault(),t(document).off("scroll");var a=t(this);t("html, body").stop().animate({scrollTop:t(a.attr("href")).offset().top-20},1500),t("a").each(function(){t(this).removeClass("active")}),t(this).addClass("active");var i=this.hash;$target=t(i),window.location.hash=i,t(document).on("scroll",o)})}),smoothScroll.init({speed:1e3,offset:55}),t("a[data-rel^=lightcase]").lightcase(),t(window).on("load",function(){t(".portfolio-items").isotope({itemSelector:".item",masonry:{columnWidth:".col-sm-6"}})});var e=t(".filters-group ul li");e.on("click",function(){e.removeClass("active"),t(this).addClass("active");var o=t(this).attr("data-filter");t(".portfolio-items").isotope({filter:o})});var a=t(".go-up");t(window).on("scroll",function(){t(this).scrollTop()>=50?a.fadeIn():a.fadeOut()}),t("#status").fadeOut(),t("#preloader").delay(200).fadeOut("slow"),t(".counter").counterUp({delay:10,time:5e3,offset:100,beginAt:0,formatter:function(t){return t.replace(/,/g,".")}})}(jQuery);