1$(function () { 2 "use strict"; 3 /** no mostrar hover del submenu en tactil **/ 4 $('#menucap > li > a').tap(function (e) { 5 $(this).parent('li').children('.submenucontainer').hide(); 6 }); 7 8 9 var subMenus = new Swiper('div.submenu.swiper-container', { 10 slidesPerView: 'auto', 11 freeMode: false, 12 mousewheel: false, 13 hideOnClick: true, 14 navigation: { 15 nextEl: '.swiper-button-next', 16 prevEl: '.swiper-button-prev', 17 }, 18 on: { 19 resize: function () { 20 21 if ($('body').width() < 790) { 22 this.allowSlideNext = false; 23 this.allowSlidePrev = false; 24 this.allowTouchMove = false; 25 this.update(); 26 } else { 27 this.allowSlideNext = true; 28 this.allowSlidePrev = true; 29 this.allowTouchMove = true; 30 $('#menucap div.submenu').toggleClass('hide'); 31 this.update(); 32 $('#menucap div.submenu').toggleClass('hide'); 33 } 34 35 } 36 } 37 }); 38 39 var subMenus = new Swiper('div.submenuinterior.swiper-container', { 40 slidesPerView: 'auto', 41 freeMode: false, 42 mousewheel: false, 43 hideOnClick: true, 44 navigation: { 45 nextEl: '.swiper-button-next2', 46 prevEl: '.swiper-button-prev2', 47 }, 48 on: { 49 resize: function () { 50 this.update(); 51 52 } 53 } 54 }); 55 56 $('#menucap div.submenu').toggleClass('hide'); 57 58 59 $(window).on("resize, orientationchange,", function () { 60 if ($('body').width() < 770) { 61 /** es para moviles **/ 62 $('#menucap').height($('body').height() - 48); 63 } else { 64 // submenus 65 $('#menucap div.submenu').addClass("hide"); 66 $("#menucap span.plus").text('+'); 67 $('#menucap').height('48px'); 68 } 69 }); 70 71 /* 72 $('#menucap').height($('body').height()-48); 73 $('#menucap').toggleClass('show'); 74 $('#mobilemenu').toggleClass('show'); 75 */ 76 77 $("#menucap span.plus").bind("click", function (e) { 78 e.preventDefault(); 79 if ($(this).text() === '+') { 80 $('#submenu_' + $(this).data("id")).removeClass("hide"); 81 $(this).text('x'); 82 } else { 83 $('#submenu_' + $(this).data("id")).addClass("hide"); 84 $(this).text('+'); 85 86 } 87 //alert('plus'); 88 }); 89 90 $("#mobilemenu, #menucap").bind("click", function (e) { 91 var container = $('#menucap > li'); 92 if (!container.is(e.target) && container.has(e.target).length === 0) { 93 // Altura submenu: 94 $('#menucap').height($('body').height() - 48); 95 96 97 98 // Boton menucap 99 $('#menucap').toggleClass('show'); 100 $('#mobilemenu').toggleClass('show'); 101 } 102 }); 103 104 105 106});
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.