PageSourceSearch

https://www.baylor.edu/themes/custom/baylor_united_2/js/tables.js?tlsx92

js baylor.edu collected 2026-09-24 06:52:34 UTC 1,786 bytes, 61 lines download raw bytes

1const uiTable = document.querySelectorAll("[class*=uiTable-]");
2const classExists = document.querySelectorAll("[class*=uiTable-]").length > 0;
3const minWidth = 640;
4
5if(classExists){
6  const classCount = uiTable.length;
7  uiTable.forEach(item => {
8    let className = item.className;
9    let classType = className.split('-').pop();
10    let table = document.querySelector("."+className);
11    let thead = document.querySelector("."+className+" > thead");
12    let tbody = document.querySelector("."+className+" > tbody");
13    wrap(table, className, "-container");
14    wrap(table, className);
15    remove(table, className);
16    if(classType === 'card') {
17      if(window.innerWidth <= minWidth) {
18        //setMobileTableHeaders(table, tbody);
19      } else {
20        //setTableHeaders(table, tbody, thead);
21      }
22    }
23  });
24
25}
26
27function setMobileTableHeaders(table, tbody, thead) {
28  table.classList.add("mobile_table_headers");
29  var tbodyRows = tbody.childElementCount;
30  var theadRows = thead.childElementCount+1;
31  var element = thead.lastChild;
32
33  while (theadRows <= tbodyRows) {
34    thead.appendChild(element.cloneNode(true));
35    theadRows++;
36  }
37}
38function setTableHeaders(table, thead) {
39  table.classList.remove("mobile_table_headers");
40  while (thead.childNodes.length > 1) {
41    thead.removeChild(thead.lastChild);
42  }
43}
44
45function remove(el, className) {
46  if (el && el.parentNode) {
47    el.removeAttribute('class');
48  }
49}
50// wrap an element with another;
51function wrap(el, className, option=null) {
52  if (el && el.parentNode) {
53    const tempDiv = document.createElement('div');
54    if(option !== null) {
55      className = className+option;
56    }
57    tempDiv.classList.add(className);
58    el.insertAdjacentElement('beforebegin', tempDiv);
59    tempDiv.appendChild(el);
60  }
61}

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.