PageSourceSearch

https://www.drdishbasketball.com/hubfs/hub_generated/template_asse…/1789761812343/template_nav.min.js

js drdishbasketball.com collected 2026-09-25 00:23:56 UTC 4,848 bytes, 2 lines download raw bytes

1function linkMatchURL(linkElement){const currentURL=window.location.origin+window.location.pathname,href=linkElement.getAttribute("href");if(href.startsWith("#"))return!1;const linkURL=new URL(href,window.location.origin);return currentURL===linkURL.origin+linkURL.pathname}!function(){function setExpanded(li,link,expanded){li.classList.toggle("nav__item--expanded",expanded),link.setAttribute("aria-expanded",expanded?"true":"false")}function collapseLevel1Siblings(nav,exceptLi){if(!nav)return;const items=nav.querySelectorAll(".nav__list--level1 > li.nav__item--branch");for(let k=0;k<items.length;k++){const item=items[k];if(item===exceptLi)continue;item.classList.remove("nav__item--expanded");const a=item.querySelector(":scope > a");a&&a.setAttribute("aria-expanded","false")}}function isLevel1BranchLink(link){const li=link.closest("li");return!!(li&&li.classList.contains("nav__item--branch")&&li.parentElement&&li.parentElement.classList.contains("nav__list--level1"))}function getDelay(nav,li){return li&&li.classList.contains("nav__item--mega-branch")&&Number(nav&&nav.getAttribute("flyout-delay"))||0}const links=document.querySelectorAll(".nav--on-hover .nav__item--branch > a, .nav--on-click .nav__item--branch > a");for(let i=0;i<links.length;i++){const link=links[i],li=link.closest("li"),flyout=link.nextElementSibling;if(!li||!flyout)continue;const nav=link.closest(".nav"),delay=getDelay(nav,li),isLevel1=isLevel1BranchLink(link),isClickNav=nav&&nav.classList.contains("nav--on-click");function shouldAutoOpenLevel(){return!isClickNav||!isLevel1||li.classList.contains("nav__item--expanded")}li.addEventListener("mouseenter",function(){shouldAutoOpenLevel()&&setExpanded(li,link,!0)}),li.addEventListener("mouseleave",act.debounce(function(){isClickNav&&isLevel1||act.ishover(flyout)||setExpanded(li,link,!1)},delay)),link.addEventListener("focus",function(){shouldAutoOpenLevel()&&(isLevel1&&collapseLevel1Siblings(nav,li),setExpanded(li,link,!0))}),li.addEventListener("focusin",function(){shouldAutoOpenLevel()&&setExpanded(li,link,!0)}),li.addEventListener("focusout",act.debounce(function(e){const next=e.relatedTarget||document.activeElement;if(next&&li.contains(next))return;const isMegaBranch=li.classList.contains("nav__item--mega-branch");(isClickNav||!isMegaBranch)&&act.ishover(flyout)||setExpanded(li,link,!1)},delay))}document.addEventListener("click",function(e){const link=e.target.closest(".nav--on-click .nav__list--level1 > .nav__item--branch > a");if(!link)return;const li=link.closest("li"),nav=link.closest(".nav");if(!li)return;const href=link.getAttribute("href")||"",isButtonLink=""===href||"javascript:;"===href||"button"===link.getAttribute("role"),willExpand=!li.classList.contains("nav__item--expanded");(isButtonLink||willExpand)&&e.preventDefault(),willExpand&&collapseLevel1Siblings(nav,li),setExpanded(li,link,willExpand)}),document.addEventListener("click",function(e){const openItems=document.querySelectorAll(".nav--on-click .nav__list--level1 > li.nav__item--branch.nav__item--expanded");for(let i=0;i<openItems.length;i++){const li=openItems[i];if(li.contains(e.target))continue;li.classList.remove("nav__item--expanded");const a=li.querySelector(":scope > a");a&&a.setAttribute("aria-expanded","false")}}),document.addEventListener("keydown",function(e){if("Enter"!==e.key&&" "!==e.key)return;const link=e.target.closest(".nav--on-click .nav__list--level1 > .nav__item--branch > a");link&&(e.preventDefault(),link.click())})}();const mega_link=document.querySelectorAll(".nav__mega a");mega_link.forEach(link=>{linkMatchURL(link)&&!link.closest(".nav__mega-column--disable-active-styling")&&link.classList.add("nav__mega-active-link")}),function(){const topList=document.querySelector(".nav__list--level1");topList&&topList.addEventListener("keydown",function(e){if("ArrowRight"!==e.key&&"ArrowLeft"!==e.key)return;const links=topList.querySelectorAll(":scope > li > a"),active=document.activeElement;let idx=-1;for(let i=0;i<links.length;i++)if(links[i]===active){idx=i;break}if(-1===idx)return;e.preventDefault();const last=links.length-1;links["ArrowRight"===e.key?idx===last?0:idx+1:0===idx?last:idx-1].focus()})}(),document.addEventListener("keydown",function(e){if("Escape"!==e.key)return;
1const subLevel=document.activeElement.closest(".nav__list--level2, .nav__mega");if(document.querySelectorAll(".nav__item--expanded").forEach(function(el){el.classList.remove("nav__item--expanded");let a=el.querySelector(":scope > a");a&&a.setAttribute("aria-expanded","false")}),subLevel){const branch=subLevel.closest(".nav__item--branch");if(!branch)return;const level1Link=branch.querySelector(":scope > a");level1Link&&level1Link.focus()}});
2//# sourceURL=https://735726.fs1.hubspotusercontent-na1.net/hubfs/735726/hub_generated/template_assets/1/112049259033/1789761812343/template_nav.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.