PageSourceSearch

https://www.uhd.edu/_resources/js/web-components.js

js uhd.edu collected 2026-10-01 10:18:39 UTC 6,355 bytes, 5 lines download raw bytes

1/*
2  Build Version: 2.0.0
3  Build Date: 2026-09-29T14:13:36.115Z
4*/
5function isComponentPresent(e){e=e.trim().split(/\s+/).map(e=>"."+e).join("");return null!==document.querySelector(e)}let uhdcPeopleList=(()=>{let i=6,a="flex",r="opacity",e=[],t,l=!1;function n(){e.forEach((e,t)=>{if(l||t<i)(o=e).style.display=a,requestAnimationFrame(()=>{o.classList.remove("uhdc-hidden"),o.classList.add("uhdc-visible")});else{var n=e;n.classList.add("uhdc-hidden"),n.classList.remove("uhdc-visible");let t=e=>{e.propertyName===r&&(n.style.display="none",n.removeEventListener("transitionend",t))};n.addEventListener("transitionend",t)}var o}),t.textContent=l?"Show Less":"Show More"}return{init:function(){e=Array.from(document.querySelectorAll(".uhdc-contact-people-list-item")),t=document.getElementById("people-list-show-more"),e.length&&t&&(n(),t.addEventListener("click",()=>{l=!l,requestAnimationFrame(n)}))}}})();function splitWithRange(n,e,o,i){e.innerHTML="",o.innerHTML="";for(let t=0;t<n.length;t++){var a=n[t].cloneNode(!0);if(e.appendChild(a),e.scrollHeight>i){for(let e=t+1;e<n.length;e++)o.appendChild(n[e].cloneNode(!0));break}}}function applyRevealState(e,{collapsedHeight:t,hasOverflow:n,collapseText:o,expandText:i}){var{container:e,hiddenContent:a,overflowContainer:r,expandBtn:l,expandBtnTextLabel:d,expandBtnIcon:s}=e,c=e.classList.contains("expanded");l.style.display=n?"inline-block":"none",a.classList.toggle("faded-overlay",n&&!c),d.textContent=c?o:i,s.style.transform=c?"rotate(180deg)":"rotate(0deg)",c?(a.style.maxHeight="100%",r.style.maxHeight=r.scrollHeight+"px"):(a.style.maxHeight=t+"px",a.style.opacity="1",r.style.maxHeight="0",e.scrollIntoView({behavior:"smooth",block:"start"}))}function calculateCollapseHeight({hiddenContent:e,contentContainer:t,imageContainer:n}){e=e.offsetTop-t.offsetTop,t=n.offsetHeight-e;return 150<=t?t:150}function initExpandRevealMore(){let t=document.querySelector(".uhdc-expand-reveal-more");var e=t.querySelector(".btn-expand");let n=t.querySelector(".hidden-content"),o=t.querySelector(".overflow-container");var i=t.querySelector(".btn-text-label"),a=t.querySelector(".btn-expand i.fa");let r=t.querySelector(".image-container"),l=t.querySelector(".content-container"),d=e.dataset.collapseText||"Show Less",s=i.innerHTML||"Show More",c=Array.from(n.childNodes).map(e=>e.cloneNode(!0)),h=t.getBoundingClientRect().width,u,p={container:t,hiddenContent:n,overflowContainer:o,imageContainer:r,expandBtn:e,expandBtnTextLabel:i,expandBtnIcon:a};function m(){n.style.opacity="0",o.style.maxHeight="0",o.innerHTML="",t.classList.remove("expanded");var e=calculateCollapseHeight({hiddenContent:n,contentContainer:l,imageContainer:r});splitWithRange(c,n,o,e),u=0<o.childNodes.length,applyRevealState(p,{collapsedHeight:e,hasOverflow:u,collapseText:d,expandText:s})}if(m(),window.ResizeObserver)new ResizeObserver(e=>{for(var t of e){t=t.contentRect.width;t!==h&&(h=t,m())}}).observe(t);else{let e=window.innerWidth;window.addEventListener("resize",()=>{window.innerWidth!==e&&(e=window.innerWidth,m())})}e.addEventListener("click",()=>{var e=calculateCollapseHeight({hiddenContent:n,contentContainer:l,imageContainer:r});t.classList.toggle("expanded"),applyRevealState(p,{collapsedHeight:e,hasOverflow:u,collapseText:d,expandText:s})})}$(document).ready(function(){isComponentPresent("uhdc-contact-people-list")&&uhdcPeopleList.init()}),$(document).ready(function(){isComponentPresent("uhdc-expand-reveal-more")&&initExpandRevealMore()}),(()=>{let e="uhdc-hero-degree-page",l="data-hero-degree-page-initialized";function t(){let n=window.matchMedia("(min-width: 992px)");document.querySelectorAll("."+e).forEach(e=>{var t=n;if(!e.hasAttribute(l)){let n=e.querySelector(".uhdc-hero-degree-page-form-panel"),o=e.querySelector(".uhdc-hero-degree-page-form-slot"),i=e.querySelector(".uhdc-hero-degree-page-modal"),a=i?.querySelector(".modal-body");function r(e){var e=e.matches,t=(e&&i.classList.contains("show")&&(t=window.bootstrap?.Modal)&&t.getOrCreateInstance(i).hide(),e?o:a);n.parentElement!==t&&t.append(n)}n&&o&&i&&a&&(r(t),t.addEventListener("change",r),e.setAttribute(l,""))}})}document.addEventListener("DOMContentLoaded",function(){isComponentPresent(e)&&t()})})(),$(document).ready(function(){isComponentPresent("uhdc-hero-dropdown-slider")&&$(".uhdc-hero-dropdown-slider").slick({fade:!0,dots:!0,infinite:!0,speed:1500,slidesToShow:1,arrows:!1,autoplay:!0,lazyLoad:"ondemand",draggable:!1,pauseOnFocus:!0,pauseOnHover:!0})});let uhdcExploreTabs=(()=>{let a=70,o,r=[];function l(){return r[r.length-1]}function i(){let i=r.length-1;r.forEach((e,t)=>{var n=.8+.2*(t/i),o=100+t;e.style.top=t*a+"px",e.style.setProperty("--depth-scale",n.toFixed(3)),e.style.setProperty("--depth-z",o),e.classList.remove("active")}),l().classList.add("active")}function t(){var e,t=(t=o.closest(".uhdc-highlight-explore-tabs"))?[...t.classList].find(e=>e.startsWith("theme-")):null;if(t){let n=(e={"theme-1":["#E9ECF7","#C4CCE0","#092E6E","#061F49"],"theme-2":["#E7EBE5","#CAD3C8","#3B4C3C","#2C3A2D"],"theme-3":["#F0F0F0","#F0ECEC","#CCCCCC","#999999"]})[t]||e["theme-1"];let o=r.length;r.forEach((e,t)=>{t=o-1-t,t=n[t]||n[n.length-1];e.style.backgroundColor=t})}}
5function n(){r.forEach(e=>{e.addEventListener("click",()=>{var n=e;if(l()!==n){o.classList.add("animating");let t=()=>{var e;l()===n?setTimeout(()=>o.classList.remove("animating"),1150):(e=r.shift(),r.push(e),i(),setTimeout(t,50))};t()}})}),window.addEventListener("resize",i)}return{init:function(){if(o=document.querySelector(".uhdc-highlight-explore-tabs-list"),r=Array.from(document.querySelectorAll(".uhdc-highlight-explore-tabs-item")),o&&0!==r.length){t(),n(),i();{let t=0;var e=r.length-1;r.forEach(e=>{e=e.offsetHeight;e>t&&(t=e)}),o.style.height=t+a*e+"px",o.style.opacity=1}}}}})();$(document).ready(function(){isComponentPresent("uhdc-highlight-explore-tabs-list")&&uhdcExploreTabs.init()}),$(document).ready(function(){document.querySelectorAll('[data-bs-toggle="modal"]').forEach(e=>{e=e.getAttribute("data-bs-target").substring(1);let t=document.getElementById(e);e=t.querySelector("iframe");let n=new Vimeo.Player(e);t.addEventListener("shown.bs.modal",function(){n.play()}),t.addEventListener("hidden.bs.modal",function(){n.pause().then(()=>{n.setCurrentTime(0)})}),n.on("ended",function(){bootstrap.Modal.getInstance(t).hide()})})});

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.