1(function ($) { 2 $(function () { 3 $('.main-navigation .has-mega-menu.has-stretchwidth').hover(function (e) { 4 let $body = $('body'), 5 pleft = $(this).offset().left, 6 bodyleft = $body.offset().left; 7 $('.mega-stretchwidth', this).css({ 8 left: -pleft + bodyleft, 9 width: $body.width() 10 }); 11 }); 12 13 $('.main-navigation .has-mega-menu.has-containerwidth').hover(function (e) { 14 let $parent = $(this).closest('.container , .elementor-container, .col-full, .header-container'), 15 pleft = $parent.offset().left + parseInt($parent.css('padding-left')), 16 cleft = $(this).offset().left; 17 18 $('.mega-containerwidth', this).css({ 19 left: pleft - cleft, 20 width: $parent.width() 21 }); 22 }); 23 24 $('.main-navigation .has-mega-menu').has('ul.custom-subwidth').hover(function (e) { 25 let pleft = parseFloat($(this).children('a').css('padding-left')), 26 $oleft = $(this).offset().left + pleft, 27 $itemwidth = parseInt($(this).children('.custom-subwidth').css('width')), 28 $bodywidth = $('body').width(); 29 30 let $offset = $oleft + $itemwidth - $bodywidth; 31 32 if ($offset >= 0){ 33 $('.mega-menu.custom-subwidth', this).css({ 34 left: -$offset + pleft 35 }); 36 } 37 else{ 38 $('.mega-menu.custom-subwidth', this).css({ 39 left: pleft 40 }); 41 } 42 }); 43 }); 44})(jQuery);
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.