1// if($(window).width() > 992) 2// { 3// $('.top-menu li.menu-item').hover(function() 4// { 5// var wrapper = $(this).find('.hidden-block'), 6// content = $(this).find('.hidden-block').find('ul'); 7 8// $(this).find('.header__menu-link').toggleClass('hover'); 9// wrapper.stop().toggleClass('visible-block'); 10// content.toggleClass('animated fadeInUp fast'); 11 12// //$('.hidden-block').stop().toggleClass('visible-block'); 13// //$('.hidden-block').find('ul').toggleClass('animated fadeInUp fast'); 14// }) 15// } 16 17 18if($(window).width() > 992) 19{ 20 $('.top-menu li.menu-item.menu-item--empty').on('mouseenter', function() { 21 $('.hidden-block').stop().removeClass('visible-block'); 22 $('.hidden-block').find('ul').removeClass('animated fadeInUp fast'); 23 }) 24 25 $('.top-menu li.menu-item:not(.menu-item--empty)').on('mouseenter', function() 26 { 27 $(this).addClass('active-block'); 28 $(this).find('.hidden-block').addClass('active-block'); 29 30 var height = 0; 31 $.each($('.hidden-block ul'), function(i, item) { 32 if (!$(this).parent().parent().hasClass('menu-item--community')) { 33 height = $(this).height() > height ? $(this).height() + 55 : height; 34 } 35 }) 36 37 //if (height > 300) height = 300; 38 39 $('.hidden-block').css('height', height); 40 $('.hidden-block').stop().addClass('visible-block'); 41 $('.hidden-block').find('ul').addClass('animated fadeInUp fast'); 42 43 $('.menu-item--community .hidden-block ul').css('height', height - $('.menu-item--community .menu__search').height() + 'px'); 44 45 $(window).trigger("resize.scrollBox"); 46 }) 47 48 $('.top-menu li.menu-item:not(.menu-item--empty)').on('mouseleave', function() 49 { 50 $(this).find('.hidden-block').removeClass('active-block'); 51 $(this).removeClass('active-block'); 52 }) 53 54 $('.top-menu').on('mouseleave', function() 55 { 56 $('.hidden-block').stop().removeClass('visible-block'); 57 $('.hidden-block').find('ul').removeClass('animated fadeInUp fast'); 58 }) 59} 60 61$(document).ready(function(){ 62 $('.menu-item--community .hidden-block ul').scrollBox(); 63 64 $('.menu__search-icon').on('click', function() { 65 if ($(this).hasClass('icon-modal-close')) { 66 $(this).parent().find('.menu__search-input').val('').trigger('input'); 67 } 68 }); 69 70 $('.menu__search-input').on('input', function() { 71 let value = $(this).val().trim(); 72 73 let items = $(this).parent().parent().find('ul li'); 74 let icon = $(this).parent().find('.menu__search-icon'); 75 76 items.addClass('d-none'); 77 78 if (value != '') { 79 icon.addClass('icon-modal-close'); 80 icon.removeClass('icon-search'); 81 82 items.each(function() { 83 let text = $(this).text(); 84 let regex = new RegExp(value, 'ig'); 85 86 if (regex.test(text)) { 87 $(this).removeClass('d-none'); 88 } 89 }); 90 } else { 91 icon.removeClass('icon-modal-close'); 92 icon.addClass('icon-search'); 93 94 items.removeClass('d-none'); 95 } 96 }) 97});
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.