(function($) { "use strict" // Init functions function init () { // Announcement modules var annc = { truncation : function (el, maxLength) { for( var i = 0; i < el.length; i ++ ) { if ( el[i].firstChild !== null ) { if( el[i].firstChild.length > maxLength ) { var newTitle = el[i].firstChild.nodeValue; var newTitle = newTitle.substring(0, maxLength) + '...' el .eq(i) .text(newTitle); } } } } } function anncFix() { var w$ = $('.w-announcement-4'); if( w$.length ) { annc.truncation(w$.find('.w-annc__subtitle'), 25); } } // Necessary for Responsive images function bullEye() { // $(".bullseye").bullseye({ // fadeEffect: false // }); } // Adding class to submenu that has dropdown items function submenuFix () { var item$ = $('.submenu__item.level-1'); var itemLen = item$.length; var list$ = item$.find('.submenu__list.level-2'); for( var i=0; i