$(document).bind("mobileinit", function () { // jQuery Mobile's Ajax navigation does not work in all cases (e.g., // when navigating from a mobile to a non-mobile page), especially when going back, hence disabling it. $.extend($.mobile, { ajaxEnabled: false }); }); /* ---------- Sticky Nav */ var stickyNavTop = $('.cms-menu').offset().top-74; var stickyNav = function(){ var scrollTop = $(window).scrollTop(); if (scrollTop > stickyNavTop) { $('.cms-menu').addClass('sticky'); } else { $('.cms-menu').removeClass('sticky'); } }; stickyNav(); $(window).scroll(function() { stickyNav(); }); /* ----------- Mobile Menu */ $(".menu-mobile_toggle").click(function() { $(".menu-mobile_items").stop().slideToggle() }); // Scroll to section nav var links = ['#top', '#lame2', '#lame3', '#lame5', '#lame7', '#lame8', '#lame13']; for (var link in links) { var scrollToSections = links[link]; (function(scrollToSection) { $('a[href=' + scrollToSection + ']').on("click", function(e) { $('html, body').stop().animate({ scrollTop: $(scrollToSection).offset().top -135 }, 500); return false; }); }(scrollToSections)) } /* --------------- Video light box */ $(".video-lightbox").colorbox({ iframe:true, title:false, innerWidth:640, innerHeight:390 }); /* -------------- Precision tip Slider (Bee3d) */ var slider = new Bee3D(jQuery('#carrousel')[0], { effect: 'coverflow', focus: 1, loop: { enabled: true, continuous: true, offset: 0 }, listeners: { keys: true }, navigation: { enabled: true, next: '.bee3D--nav__next', prev: '.bee3D--nav__prev' }, }); /* ------------------ The Range Carousel */ ! function() { "use strict" }(), function() { "use strict"; var e = $(".steam-irons-carousel_large"); e.slick({ autoplay: !1, arrows: !0, centerMode: !1, fade: !1, infinite: !0, slidesToShow: 1, slidesToScroll: 1, prevArrow: '
', nextArrow: '' }), $(document).ready(function() { $(".steam-iron-0 .content").addClass("active"), $(".steam-generator-0 .content").addClass("active") }), $(".steam-irons-carousel_small-container").on("click", function() { e.slick("slickGoTo", $(this).data("slide-index")) }), e.on("beforeChange", function(e, t, o) { $(".steam-irons-carousel_small-container .content.active").removeClass("active"), $(".steam-iron-" + o + " .content").addClass("active") }) }(), function() { "use strict"; $("[data-scroll]").click(function() { var e = $(this).data("scroll"); $("html, body").stop().animate({ scrollTop: $(e).offset().top - 150 }, 250) }) }();