1 2var $header = $('header.header'); 3var $menuBtn = $('.menu-btn'); 4var $navigationWrap = $('nav.main-navigation-container'); 5var $blocker = $('.custom-blocker'); 6var mobileNavigationBreakpoint = 600; 7let $headerSearchTargetWrap = $('.header-search-form-wrap'); 8 9 10function toggleMenu() { 11 $headerSearchTargetWrap.removeClass('active'); 12 13 if(!$navigationWrap.hasClass('active')) { 14 $navigationWrap.addClass('active'); 15 $blocker.addClass('active'); 16 $header.addClass('active'); 17 }else { 18 $navigationWrap.removeClass('active'); 19 $blocker.removeClass('active'); 20 $header.removeClass('active'); 21 } 22} 23 24$(document).ready(function(){ 25 26 /* FANCYBOX */ 27 $.fancybox.defaults.hash = false; 28 $.fancybox.defaults.loop = true; 29 $('a[href$=".gif"], a[href$=".jpg"], a[href$=".jpeg"], a[href$=".png"], a[href$=".bmp"]').children('img').each(function( index ) { 30 $(this).parent().attr('data-fancybox', 'gallery').addClass('no-after'); 31 }); 32 /******* */ 33 34 $("a[href^='#'], body.home a[href^='/#']").click(function (e) { 35 e.preventDefault(); 36 37 var target = this.hash, 38 $target = $(target); 39 40 if($target.length) { 41 $("html, body").stop().animate({ 42 "scrollTop": $target.offset().top 43 }, 400, "swing", function () { 44 // window.location.hash = target; 45 }); 46 } 47 }); 48 49 $('nav.main-navigation-container ul.main-navigation > li.menu-item-has-children > a').click(function (e) { 50 if($(window).innerWidth() <= 850) { 51 if($(this).hasClass('active')) { 52 53 }else { 54 e.preventDefault(); 55 $(this).addClass('active'); 56 $(this).parent().find('ul.sub-menu').slideDown(); 57 } 58 } 59 }); 60 61 $('.header-search-form-wrap i').click(function (e) { 62 console.log("lysdjfa"); 63 e.preventDefault(); 64 if($headerSearchTargetWrap.hasClass('active')) { 65 $headerSearchTargetWrap.removeClass('active'); 66 $blocker.removeClass('active'); 67 }else { 68 $blocker.addClass('active'); 69 $headerSearchTargetWrap.addClass('active'); 70 } 71 }); 72 73 $('body').on('click', '.target', function(event) { 74 }); 75 76 $menuBtn.click(function (e) { 77 e.preventDefault(); 78 toggleMenu(); 79 }); 80 81 $blocker.click(function (e) { 82 e.preventDefault(); 83 toggleMenu(); 84 }); 85 86 $('.faq-item').click(function (e) { 87 e.preventDefault(); 88 if($(this).hasClass('active')) { 89 $(this).find('.content').slideUp(300); 90 $(this).removeClass('active'); 91 }else { 92 $(this).find('.content').slideDown(300); 93 $(this).addClass('active'); 94 } 95 }); 96 97}); //ready 98 99$(document).scroll(function() { 100 scroll_pos = $(this).scrollTop(); 101 if(scroll_pos > 0) { 102 $header.addClass('scrolled'); 103 }else { 104 $header.removeClass('scrolled'); 105 } 106 107 if($(window).innerWidth() <= mobileNavigationBreakpoint && $navigationWrap.hasClass('active')) { 108 toggleMenu(); 109 } 110}); //scroll 111 112$(document).resize(function(event) { 113 114}); //resize
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.