1$(document).ready(function () { 2 $.ajaxSetup({ 3 cache: false 4 5 6 7 }); 8 9 if( $(".sortable").length ) 10 { 11 console.log("sortable found!"); 12 console.log("Elements with .sortable: " + $(".sortable").length); 13 14 var elementCount = 1; 15 16 $(".sortable").each(function () { 17 18 if ($(this).hasClass('small-only')) 19 { 20 console.log("Small Only Found!"); 21 $(this).remove(); 22 } 23 else 24 { 25 26 var myTable = $(this).attr("id", "sortClass" + elementCount); 27 elementCount ++; 28 29 } 30 }); 31 32 $.getScript("https://www.lander.edu/_files/js/fancyTable.js", function(){ 33 // here you can use anything you defined in the loaded script 34 $(".sortable").fancyTable({ 35 sortColumn: 0, 36 sortable: true, 37 sortOrder: 'asc', 38 pagination: false, 39 exactMatch: "auto", 40 matchCase: false, 41 inputPlaceholder: "Search", 42 globalSearch: true, 43 searchElement: "#searchContainer", 44 // globalSearchExcludeColumns: [2,4], 45 sortFunction: function(a, b, o){ 46 a = $($.parseHTML(a)).text().trim(); 47 b = $($.parseHTML(b)).text().trim(); 48 // return((a<b)?-o.sortOrder:(a>b)?o.sortOrder:0); 49 if(a === "" || a === null) return 1; 50 if(b === "" || b === null) return -1; 51 if(a === b) return 0; 52 return a < b ? -o.sortOrder : o.sortOrder; 53 } 54 // perPage:10, 55 // paginationClass: "btn btn-info" 56 }); 57 }); 58 59 } 60 else 61 { 62 console.log("sortable does not exist!"); 63 } 64 65 //Lander Directory 66 if ($('.dirItem').length) { 67 const maskEmail = (email = '') => { 68 const [name, domain] = email.split('@'); 69 const { length: len } = name; 70 const maskedName = name[0] + '...' + name[len - 1]; 71 const maskedEmail = maskedName + '@' + domain; 72 return maskedEmail; 73 }; 74 75 const maskPhone = (email = '') => { 76 const [prefix, number] = email.split('-'); 77 const { length: len } = prefix; 78 //const maskedPrefix = prefix[0] + '...' + prefix[len - 1]; 79 const maskedPrefix = '(***) ***'; 80 const maskedNumber = maskedPrefix + '-' + number; 81 return maskedNumber; 82 }; 83 84 $('.email').each(function(){ 85 $(this).append( "<div class='hiddenEmail' style='position:absolute; top:0; visibility:hidden;'>" + $(this).find("a").attr("href") + "</div>" ); 86 //$(this).find("a").attr("href", ""); 87 $(this).find("a").text( maskEmail( $(this).find("a").text() ) ); 88 }); 89 90 $('.panel-text').each(function(){ 91 $(this).append( "<div class='hiddenNumber' style='position:absolute; top:0; visibility:hidden;'>" + $(this).find("small").first().text() + "</div>" ); 92 $(this).find("small").first().text( maskPhone( $(this).find("small").first().text() ) ); 93 }); 94 /* 95 $('.panel-image').each(function(){ 96 $(this).append('<div class="overlay"></div>'); 97 98 // Get the current offset of the image 99 var currentElementOffset=$(this).offset(); 100 101 // set the current offset of the overlay image 102 //alert("top: " + currentElementOffset.top + "<br> left: " + currentElementOffset.left); 103 104 $(".overlay").css({ 105 top: "-15px", 106 left: "-7px" 107 }); 108 $(".overlay").fadeIn(10); 109 }); 110 */ 111 $(".dirItem").on({ 112 mouseenter: function () { 113 $(this).find(".email").find("a").text( $(this).find('.hiddenEmail').text().split(":").pop() ); 114 $(this).find("small").first().text( $(this).find(".hiddenNumber").text() ); 115 //$(this).find(".overlay").fadeOut(250); 116 }, 117 mouseleave: function () { 118 $(this).find(".email").find("a").text( maskEmail( $(this).find(".email").find("a").text() ) ); 119 //$(this).find(".email").find("a").attr("href", ""); 120 $(this).find("small").first().text( maskPhone( $(this).find("small").first().text() ) ); 121 //$(this).find(".overlay").fadeIn(250); 122 } 123 }); 124 }//if 125 126 //areas-of-study-search-mobile 127 /* 128 $('#areas-of-study-mobile-input').on("keyup", function() { 129 console.log($(this).val()); 130 var value = $(this).val().toLowerCase(); 131 $("#mobile-search-table tr").filter(function() { 132 console.log("filter function: " + $(this).text().toLowerCase() + $(this).text().toLowerCase().indexOf(value)); 133 $(this).toggle($(this).text().toLowerCase().indexOf(value) > -1) 134 }); 135 });
136 */ 137 138 139 /* ============================================================ 140 Monthly Report Interactive Deck 141 ============================================================ */ 142 $(function () { // shorthand for $(document).ready â standard in jQuery 3+ 143 'use strict'; 144 145 // Exit on pages with no deck and no pending include placeholder 146 if (!document.querySelector('.deck') && 147 !document.querySelector('[w3-include-html]')) return; 148 149 function countUp(el) { 150 var target = parseInt(el.dataset.count, 10) || 0; 151 var suffix = el.dataset.suffix || ''; 152 var duration = 1200; 153 var start = performance.now(); 154 155 function frame(now) { 156 var t = Math.min((now - start) / duration, 1); 157 var eased = 1 - Math.pow(1 - t, 3); 158 el.textContent = Math.round(target * eased) + suffix; 159 if (t < 1) requestAnimationFrame(frame); 160 } 161 requestAnimationFrame(frame); 162 } 163 164 function initDeck() { 165 var slides = Array.prototype.slice.call(document.querySelectorAll('.slide')); 166 var dotsEl = document.getElementById('dots'); 167 168 if (!dotsEl || slides.length === 0 || dotsEl.dataset.wired) return; 169 dotsEl.dataset.wired = '1'; 170 171 var idx = 0; 172 173 document.getElementById('total').textContent = slides.length; 174 slides.forEach(function (_, i) { 175 var d = document.createElement('div'); 176 d.className = 'dot-nav' + (i === 0 ? ' on' : ''); 177 d.addEventListener('click', function () { show(i); }); 178 dotsEl.appendChild(d); 179 }); 180 181 function animateIn(slide) { 182 slides.forEach(function (s) { 183 s.querySelectorAll('[data-count]').forEach(function (el) { 184 el.textContent = '0' + (el.dataset.suffix || ''); 185 }); 186 }); 187 slide.querySelectorAll('[data-count]').forEach(function (el) { 188 countUp(el); 189 }); 190 slide.querySelectorAll('.bar').forEach(function (b, i) { 191 b.style.height = '0'; 192 setTimeout(function () { 193 b.style.height = b.dataset.h; 194 }, 200 + i * 150);
195 }); 196 } 197 198 function show(n) { 199 idx = Math.max(0, Math.min(slides.length - 1, n)); 200 slides.forEach(function (s, i) { 201 s.classList.toggle('active', i === idx); 202 }); 203 Array.prototype.slice.call(document.querySelectorAll('.dot-nav')).forEach(function (d, i) { 204 d.classList.toggle('on', i === idx); 205 }); 206 document.getElementById('progress').style.width = 207 (((idx + 1) / slides.length) * 100) + '%'; 208 document.getElementById('cur').textContent = idx + 1; 209 animateIn(slides[idx]); 210 } 211 212 window.go = function (dir) { show(idx + dir); }; 213 214 document.addEventListener('keydown', function (e) { 215 if (e.key === 'ArrowRight' || e.key === ' ') { show(idx + 1); } 216 if (e.key === 'ArrowLeft') { show(idx - 1); } 217 }); 218 219 show(0); 220 } 221 222 /* ---------- Poll for the async-injected include ---------- */ 223 var attempts = 0; 224 (function poll() { 225 if (document.querySelector('.deck')) { 226 initDeck(); 227 return; 228 } 229 if (++attempts < 60) { 230 setTimeout(poll, 100); 231 } else { 232 console.warn('Monthly report deck: .deck never appeared â check the w3-include-html path.'); 233 } 234 })(); 235 }); 236 237 238}); //document ready 239 240$(window).on('load', function () { 241 242 $(".rd-navbar-menu-wrap .rd-navbar-nav-wrap .rd-navbar-mobile-scroll .rd-navbar-nav li ul .cu-sub-card").css("display", "block"); 243 $("body").css("visibility", "visible"); 244 245 $(".page-overlay").fadeOut(250, function() { $(this).css("display", "none"); }); 246 247 /*** OMNILERT BOX ***/ 248 if ($(".SmartBoard_Table").length) { 249 $(".omnilert_wrapper").css('display', 'block'); 250 } 251 252 $(".alert_close").click(function () { 253 //alert("Close Clicked!"); 254 $(".omnilert_wrapper").hide(); 255 }); 256 257 /****** BEGIN HOMEPAGE CARD *****/ 258 /****** BEGIN SCROLL *****/ 259 if($('.card-button-cover').length){ 260 var $win = $(window); 261 var $stat = $('.card-button-cover'); // Change this to affect your desired element. 262 var scrollTop; 263 var prev; 264 var diff; 265 266 $win.on('scroll', function (e) { 267 scrollTop = $win.scrollTop(); 268 prev = $stat.offset(); 269 diff = scrollTop - prev.top; 270 //console.log("SCROLLING"); 271 //console.log("DIFF: " + diff); 272 if ( diff >= -250 ) { 273 if( !$stat.hasClass("card-showing") && !$stat.hasClass("scroll-stop") ){
274 $( ".ccu-priority-card" ).animate({ "right": "+=265px" }, "slow", stopSlideIn); 275 e.stopImmediatePropagation(); 276 $stat.addClass("card-showing"); 277 $( ".card-hamburger-container" ).addClass("change"); 278 } 279 //console.log(">= -160" + diff); 280 } 281 /* 282 else if ( diff <= -420 ){ 283 if( $stat.hasClass("card-showing") && !$stat.hasClass("scroll-stop") ){ 284 $( ".ccu-priority-card" ).animate({ "right": "-=225px" }, "slow", stopSlideOut); 285 e.stopImmediatePropagation(); 286 $stat.removeClass("card-showing"); 287 } 288 //console.log("<= -465" + diff); 289 } 290 else { 291 //console.log('n'); 292 } 293 294 function stopSlideOut(){ 295 console.log("stopSlideOut Called"); 296 $( ".ccu-priority-card" ).stop(); 297 } 298 */ 299 300 function stopSlideIn(){ 301 console.log("stopSlideIn Called"); 302 $( ".ccu-priority-card" ).stop(); 303 } 304 305 }).scroll(); 306 307 /****** END SCROLL *****/ 308 /****** BEGIN CARD EDGE CLICK *****/ 309 /* 310 $( ".card-button-cover" ).on('click', function(e){ 311 console.log(e.target.className + "CLICKED!"); 312 if( $(e.target).hasClass("card-showing") ) { 313 e.stopImmediatePropagation(); 314 console.log(e.target.className + "CLICKED!"); 315 $( ".ccu-priority-card" ).animate({ "right": "-=225px" }, "slow"); 316 $( ".card-button-cover" ).removeClass("card-showing"); 317 if( !$( ".card-button-cover" ).hasClass("scroll-stop") ){
318 $( ".card-button-cover" ).addClass("scroll-stop"); 319 } 320 } 321 else if( $(e.target).hasClass("card-button-cover") ) { 322 e.stopImmediatePropagation(); 323 console.log(e.target.className + "CLICKED!"); 324 $( ".ccu-priority-card" ).animate({ "right": "+=225px" }, "slow"); 325 $( ".card-button-cover" ).addClass("card-showing"); 326 if( !$( ".card-button-cover" ).hasClass("scroll-stop") ){ 327 $( ".card-button-cover" ).addClass("scroll-stop"); 328 } 329 } 330 else { 331 e.preventDefault(); 332 } 333 }); 334 */ 335 /****** END CARD EDGE CLICK *****/ 336 /****** BEGIN HAMBURGER CLICK *****/ 337 $( document ).on('click', function(e){ 338 console.log(e.target.className + "CLICKED!"); 339 if ($(e.target).hasClass("card-hamburger-container") || $(e.target).hasClass("bar1") || $(e.target).hasClass("bar2") || $(e.target).hasClass("bar3")) 340 { 341 console.log("IF HIT"); 342 if( $(".card-button-cover").hasClass("card-showing") ) { 343 e.stopImmediatePropagation(); 344 console.log("INSIDE IF HIT"); 345 $( ".ccu-priority-card" ).animate({ "right": "-=265px" }, "slow"); 346 $( ".card-button-cover" ).removeClass("card-showing"); 347 if( !$( ".card-button-cover" ).hasClass("scroll-stop") ){
348 $( ".card-button-cover" ).addClass("scroll-stop"); 349 } 350 } 351 else if( $(e.target).hasClass("card-hamburger-container") || $(e.target).hasClass("bar1") || $(e.target).hasClass("bar2") || $(e.target).hasClass("bar3") ) { 352 e.stopImmediatePropagation(); 353 console.log("INSIDE ELSE IF HIT"); 354 $( ".ccu-priority-card" ).animate({ "right": "+=265px" }, "slow"); 355 $( ".card-button-cover" ).addClass("card-showing"); 356 if( !$( ".card-button-cover" ).hasClass("scroll-stop") ){ 357 $( ".card-button-cover" ).addClass("scroll-stop"); 358 } 359 } 360 else { 361 e.preventDefault(); 362 } 363 } 364 }); 365 } 366 /****** END HAMBURGER CLICK *****/ 367 /****** END HOMEPAGE CARD *****/ 368 369 $(window).resize(function(){ 370 371 }); 372 373}); //window load 374 375 376
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.