1;(function() { 2 'use strict'; 3 4 // Class className 5 function ModalNav() { 6 // set href to setLang btn 7 // var url = window.location.href 8 // if( url.includes('?lang=') ) { 9 // url = url.slice(0,-8); 10 // } 11 this.init(); 12 //console.log("AUTO_LANGUAGE",AUTO_LANGUAGE) 13 } 14 ModalNav.prototype.init = function() { 15 if ($('#js-modal-nav').hasClass('header_menu_mobile_collapse')) 16 { 17 // Change effect range for all submenu. @CLHOM 18 // $('._modalNav_content__header').find('>li').each(function(idx) { 19 $('._modalNav_content__header').find('li').each(function(idx) { 20 var $list_item = $(this); 21 if ($(this).hasClass('has_children')) 22 { 23 var $tumbTag = $(this).find('>a, >strong'); 24 25 $tumbTag.wrap("<span class='_modalNav_head'></span>"); 26 $(this).find('._modalNav_head').append($('<div class="_modalNav_content__trigger"></div>')); 27 28 // Set active for submenu. @CLHOM 29 if ($list_item.parent('._modalNav_content__header').length == 0) 30 { 31 $list_item.addClass('active'); 32 } 33 } 34 35 $list_item.find('._modalNav_content__trigger').on('click',function(e){ 36 $list_item.toggleClass('active'); 37 38 if($list_item.hasClass('active')) 39 { 40 gsap.to($list_item.find('>ul'), { height: 'auto', duration: .3 }); 41 } 42 else 43 { 44 gsap.to($list_item.find('>ul'), { height: 0 }); 45 } 46 }); 47 48 if ($list_item.hasClass('has_current')) 49 { 50 $list_item.find('._modalNav_content__trigger').trigger('click'); 51 } 52 }); 53 } 54 }; 55 56 $(function() { 57 new ModalNav(); 58 }); 59})();
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.