PageSourceSearch

https://blog.vrad.com/hubfs/hub_generated/module_assets/1/18829548…/1763576107212/module_Global_Header.min.js

js vrad.com collected 2026-09-26 05:04:04 UTC 6,525 bytes, 2 lines download raw bytes

1var module_188295489810=void document.addEventListener("DOMContentLoaded",function(){const mobileMenuTrigger=document.querySelector(".vh-mobile-btn-button");mobileMenuTrigger&&mobileMenuTrigger.addEventListener("click",e=>{let btn=e.target.closest(".vh-mobile-btn-button"),mobileNav=document.querySelector(".vh-mobile-navigation");btn.classList.toggle("active"),mobileNav.classList.toggle("active")}),document.querySelectorAll(".vrad-header .vh-mobile-navigation .vh-menu > ul > li > .icon-wrapper, .vrad-header .vh-mobile-navigation .vh-menu > ul > li > .link-text").forEach(item=>{item.addEventListener("click",e=>{const sibling=item.parentElement.querySelector(".mobile-tier-2");sibling&&sibling.classList.toggle("active")})}),document.querySelectorAll(".vrad-header .vh-mobile-navigation .vh-menu .mobile-tier-2 .mobile-go-back").forEach(item=>{item.addEventListener("click",e=>{item.closest(".vrad-header .vh-mobile-navigation .vh-menu .mobile-tier-2").classList.remove("active")})}),document.querySelectorAll(".submenu-mobile-expand").forEach(item=>{item.addEventListener("click",e=>{item.querySelector("ul").classList.toggle("active")})});const header=document.querySelector(".vrad-header");window.addEventListener("scroll",function(){window.scrollY>50?header.classList.add("scrolled"):header.classList.remove("scrolled")});const menuItems=document.querySelectorAll(".vh-menu-item");let activeDropdown=null,mouseInHeader=!1;header.addEventListener("mouseenter",function(){mouseInHeader=!0}),header.addEventListener("mouseleave",function(event){mouseInHeader=!1;const headerBottom=header.getBoundingClientRect().bottom,dropdownBottom=activeDropdown?activeDropdown.getBoundingClientRect().bottom:headerBottom;event.clientY>Math.max(headerBottom,dropdownBottom)&&activeDropdown&&(activeDropdown.classList.remove("open"),activeDropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu").forEach(menu=>menu.classList.remove("active")),activeDropdown.querySelectorAll(".tier-2-item").forEach(link=>link.classList.remove("active")),activeDropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu ul li").forEach(link=>link.classList.remove("active")),activeDropdown.querySelectorAll(".sub-menu-content").forEach(ddc=>ddc.classList.remove("active")),activeDropdown=null)}),menuItems.forEach(item=>{const trigger=item.querySelector("span"),dropdown=item.querySelector(".vh-menu-dropdown"),tier2Items=dropdown?dropdown.querySelectorAll(".tier-2-item"):[];if(trigger&&dropdown){if(trigger.addEventListener("click",function(event){if(event.preventDefault(),event.stopPropagation(),activeDropdown===dropdown)dropdown.classList.remove("open"),dropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu").forEach(menu=>menu.classList.remove("active")),dropdown.querySelectorAll(".tier-2-item").forEach(link=>link.classList.remove("active")),dropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu ul li").forEach(link=>link.classList.remove("active")),dropdown.querySelectorAll(".sub-menu-content").forEach(ddc=>ddc.classList.remove("active")),activeDropdown=null;else if(activeDropdown&&activeDropdown.classList.remove("open"),dropdown.classList.add("open"),activeDropdown=dropdown,dropdown&&tier2Items.length>0){const firstTier2Item=tier2Items[0],hasSubmenu="true"===firstTier2Item.dataset.hassub;if(firstTier2Item.classList.add("active"),hasSubmenu){const firstSubmenu=firstTier2Item.querySelector(".vh-menu-dropdown-wrapper-submenu");firstSubmenu&&firstSubmenu.classList.add("active")}const firstSubContent=dropdown.querySelector(".sub-menu-content");firstSubContent&&firstSubContent.classList.add("active")}}),dropdown){const submenuItems=dropdown.querySelectorAll(".vh-menu-dropdown-wrapper-menu li a");submenuItems.forEach(submenuItem=>{submenuItem.addEventListener("mouseenter",function(){const parentIndex=this.closest(".vh-menu-item").dataset.item||Array.from(this.closest(".vh-menu-item").parentNode.children).indexOf(this.closest(".vh-menu-item"))+1,childIndex=Array.from(this.closest("li").parentNode.children).indexOf(this.closest("li"))+1;submenuItems.forEach(item=>{item.classList.remove("active")}),this.classList.add("active"),dropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu").forEach(menu=>{menu.classList.remove("active")}
1),dropdown.querySelectorAll(".sub-menu-content").forEach(content=>{content.classList.remove("active")});const targetMenu=dropdown.querySelector(`.submenu-${parentIndex}-${childIndex}`),targetContent=dropdown.querySelector(`.dropdown-content-${parentIndex}-${childIndex}-1`);targetMenu&&targetMenu.classList.add("active"),targetContent&&targetContent.classList.add("active")})}),dropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu li a").forEach(subsubItem=>{subsubItem.addEventListener("mouseenter",function(){const parent=this.closest("li"),parentIndex=parent.dataset.item,childIndex=parent.dataset.childitem,grandchildIndex=parent.dataset.grandchilditem;if(parentIndex&&childIndex&&grandchildIndex){dropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu li a").forEach(submenu=>{submenu.classList.remove("active")}),this.classList.add("active");const targetMenu=dropdown.querySelector(`.submenu-${parentIndex}-${childIndex}`);targetMenu&&targetMenu.classList.add("active"),dropdown.querySelectorAll(".sub-menu-content").forEach(content=>{content.classList.remove("active")});const targetContent=dropdown.querySelector(`.dropdown-content-${parentIndex}-${childIndex}-${grandchildIndex}`);targetContent&&targetContent.classList.add("active")}})})}dropdown&&dropdown.addEventListener("click",function(event){event.stopPropagation()})}}),document.addEventListener("click",function(){activeDropdown&&(activeDropdown.classList.remove("open"),activeDropdown=null)}),document.addEventListener("mousemove",function(event){if(!mouseInHeader&&activeDropdown){const headerRect=header.getBoundingClientRect(),dropdownRect=activeDropdown.getBoundingClientRect();event.clientY>Math.max(headerRect.bottom,dropdownRect.bottom)&&(activeDropdown.classList.remove("open"),activeDropdown.querySelectorAll("a").forEach(menuItem=>menuItem.classList.remove("active")),activeDropdown.querySelectorAll(".vh-menu-dropdown-wrapper-submenu").forEach(menu=>menu.classList.remove("active")),activeDropdown.querySelectorAll(".sub-menu-content").forEach(content=>content.classList.remove("active")),activeDropdown=null)}})});
2//# sourceURL=https://3454598.fs1.hubspotusercontent-na1.net/hubfs/3454598/hub_generated/module_assets/1/188295489810/1763576107212/module_Global_Header.js

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.