/* -------------------------------------------- JS Start -------------------------------------------- */ jQuery(document).ready(function($) { /* call foundation */ $(document).foundation(); // sticky menu animation $('.sticky_menu.sticky').on('sticky.zf.stuckto:top', function() { $(this).addClass(' fadeInDown'); }).on('sticky.zf.unstuckfrom:top', function() { $(this).removeClass(' fadeInDown'); }) // carousel post $('.carousel-layout4').slick({ cssEase: 'linear', pauseOnHover: false, prevArrow: '
', nextArrow: '', responsive: [{ breakpoint: 768, settings: { adaptiveHeight: true, slidesToShow: 1, centerMode: false, centerPadding: '0px', } }, ] }); // Slider styl 1 animation $(".modern-Slider").slick({ autoplaySpeed:10000, speed:600, slidesToShow:1, slidesToScroll:1, pauseOnHover:false, dots:true, pauseOnDotsHover:true, cssEase:'linear', // fade:true, draggable:false, prevArrow: '', nextArrow: '', }); // Slider style two $('.slider2').slick({ centerMode: true, centerPadding: '160px', slidesToShow:1, cssEase: 'linear', pauseOnHover:false, prevArrow: '', nextArrow: '', responsive: [ { breakpoint: 768, settings: { adaptiveHeight: true, slidesToShow:1, centerMode: false, centerPadding: '0px', } }, ] }); // scrollup jQuery(window).bind("scroll", function() { if (jQuery(this).scrollTop() > 800) { jQuery(".scroll_to_top").fadeIn('slow'); } else { jQuery(".scroll_to_top").fadeOut('fast'); } }); jQuery(".scroll_to_top").click(function() { jQuery("html, body").animate({ scrollTop: 0 }, "slow"); return false; }); // sticky header $(window).on("scroll", function() { if($(window).scrollTop() > 200) { $(".header3.sticky").addClass("active"); } else { //remove the background property so it comes transparent again (defined in your css) $(".header3.sticky").removeClass("active"); } }); if (Foundation.MediaQuery.atLeast('medium')) { // Adjust height of header 3 var divHeight = $('.header3').outerHeight(); $('.heade-page-nothumb,.page-thumb').css('padding-top', divHeight+'px'); var divHeightcontent = $('.header3').outerHeight()+20; $('#content-page.no-page-header').css('padding-top', divHeightcontent+'px'); var divHeightsub = $('.header3').outerHeight(); $('#sub_banner').css('margin-top', divHeightsub+'px'); } }); /* -------------------------------------------- JS END -------------------------------------------- */