All Downloads are FREE. Search and download functionalities are using the official Maven repository.

js.header.js Maven / Gradle / Ivy

There is a newer version: 2.0.3
Show newest version
AJS.$(function(){var customSelectionHandler=function(e,selected){if(selected){if(e.type==="keydown"){if(selected.get(0).nodeName.toLowerCase()!=="a"){window.location=selected.find("a").attr("href")}else{window.location=selected.attr("href")}}}};var userDrop=AJS.$("#header-details-user").dropDown("Standard",{trigger:"a.aui-dd-link",selectionHandler:customSelectionHandler});AJS.$(userDrop).each(function(){var height=AJS.$(this.$[0]).parent().find(".drop").outerHeight()+8;var that=this;this.addCallback("show",function(){that.$.css({top:height+2+"px"});var shadows=AJS.$(that.$[0]).siblings(".aui-shadow-parent");shadows.css({top:height+2+"px"})})});var nonLazyDropdowns=AJS.$("#header-bottom .menu-bar li.aui-dd-parent.nonlazy").dropDown("Standard",{trigger:".aui-dd-link",selectionHandler:customSelectionHandler});AJS.$(nonLazyDropdowns).each(function(){var height=AJS.$(this.$[0]).parent().find(".drop").outerHeight()+8;var that=this;this.addCallback("show",function(){that.$.css({top:height+2+"px",right:"auto",left:"-1px"});var shadows=AJS.$(that.$[0]).siblings(".aui-shadow-parent");shadows.css({top:height+2+"px",right:"auto",left:"-7px"})})});var options={selector:"#header-bottom .menu-bar li.aui-dd-parent.lazy",trigger:"a.aui-dd-link",ajaxOptions:function(){var trigger=this.trigger;return{url:contextPath+"/rest/api/1.0/menus/"+trigger.attr("rel"),dataType:"json",error:function(XMLHttpRequest,textStatus,errorThrown){var mainLinkId=trigger.attr("rel");if(mainLinkId){var mainLink=AJS.$("#"+mainLinkId);if(mainLink){window.location=mainLink.attr("href")}}}}},selectionHandler:customSelectionHandler,formatResults:function(response){var html=AJS.$("
");var isFirst=true;var listNode;AJS.$(response.sections).each(function(){listNode=AJS.$("




© 2015 - 2025 Weber Informatics LLC | Privacy Policy