PageSourceSearch

https://www2.lehigh.edu/themes/custom/lehigh/js/content-types/univ…/search-button-accessibility.js?v=11.4.7

js lehigh.edu collected 2026-09-24 08:28:42 UTC 824 bytes, 24 lines download raw bytes

1document.addEventListener('DOMContentLoaded', function () {
2  const searchButton = document.querySelector('.fa-search');
3
4  if (searchButton) {
5    // Remove aria-hidden on click
6    searchButton.addEventListener('click', function (event) {
7      event.preventDefault();
8      this.removeAttribute('aria-hidden');
9      performSearch();
10    });
11
12    // MutationObserver to prevent aria-hidden from being re-added
13    const observer = new MutationObserver((mutations) => {
14      mutations.forEach((mutation) => {
15        if (mutation.attributeName === 'aria-hidden' && searchButton.getAttribute('aria-hidden') === 'true') {
16          searchButton.removeAttribute('aria-hidden');
17        }
18      });
19    });
20
21    // Observe changes to attributes on the button
22    observer.observe(searchButton, { attributes: true });
23  }
24});

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.