PageSourceSearch

https://www.comanchenation.com/sites/default/files/js/js_0Vme6ZwAEGO1_2ljdCNSS3mRyUBnysrCOmrk6arhZTA.js

js comanchenation.com collected 2026-10-01 12:01:59 UTC 48,412 bytes, 1,246 lines download raw bytes

1/**
2 * Use minwidth() to bind callbacks to changes of
3 * the window width or a minimum width at page load.
4 *
5 * Copyright by Eike Send, Edenspiekermann AG
6 *
7 * Licensed under the GPLv2 and the MIT license
8 *
9 */
10
11(function(win){
12  var getWindowWidth = function() {
13    // Get window width, code adapted from jQuery
14    if ('innerWidth' in win) {
15      return win.innerWidth;
16    } else {
17      var docwindowProp = doc.documentElement["clientWidth"];
18      return doc.compatMode === "CSS1Compat" && docwindowProp
19            || doc.body && doc.body["clientWidth"]
20            || docwindowProp;
21    }
22  }
23
24  var doc = win.document,
25      instances = [],
26      oldWidth = 0,
27      windowWidth = getWindowWidth();
28
29  var resizeCallback = function() {
30    windowWidth = getWindowWidth();
31    var i, instance;
32    for (i = 0; i < instances.length; i++) {
33      instance = instances[i];
34      // Check Forward:
35      if (instance.old < instance.wdt &&
36          windowWidth >= instance.wdt &&
37          instance.fwd) {
38        instance.fwd();
39      }
40      // Check Backward:
41      if (instance.old >= instance.wdt &&
42          windowWidth < instance.wdt &&
43          instance.bck) {
44        instance.bck();
45      }
46      instance.old = windowWidth;
47    }
48  }
49
50  if (win.addEventListener) {
51    win.addEventListener("resize", resizeCallback, false);
52  } else {
53    win.attachEvent("onresize", resizeCallback);
54  }
55
56  // This is the function that is exported into the global namespace
57  // The paramaters are:
58  // * the width at which the callbacks are called
59  // * the callback going from below to above the width, this is
60  //   initially called if the screen width is wider that "width"
61  // * the callback going back from above the width to below it
62  // * if the fourth paramater is passed as "true", the forward callback
63  //   is initally not called, but the backward callback is called
64  //   if the screenwidth is smaller than width.
65  win.minwidth = function(width, forwardCallback, backwardCallback, desktopFirst) {
66    instances.push({
67      wdt: width,
68      old: desktopFirst ? 1E9 : 0,
69      fwd: forwardCallback,
70      bck: backwardCallback
71    });
72    resizeCallback();
73  }
74
75})(this);
76
77;
78/**
79 * Use relocat() to move HTML elements in the DOM 
80 * above a certain window width.
81 * 
82 * Copyright by Eike Send, Edenspiekermann AG
83 * 
84 * Licensed under the GPLv2 and the MIT license
85 *
86 */
87
88relocate = function(width, elements, destinationElement, desktopFirst) {
89  // ensure that we use an array-like argument, NodeList and HTMLCollection work as well
90  if (elements.nodeName) elements = [elements];
91  var placeHolders = [],
92      els = [], 
93      parentEl, el, i,
94      l = elements.length;
95  // first, create a non-live copy of the elements
96  // this avoids nasty bugs when elements are removed and added again
97  for (i = l-1; i >= 0; i--) {
98    els.push(elements[i]);
99  }
100  var forwardFunction = function() {
101    for (i = 0; i < l; i++) {
102      parentEl = els[i].parentNode;
103      if (placeHolders[i] === undefined) {
104        placeHolders[i] = document.createElement("span");
105        parentEl.insertBefore(placeHolders[i], els[i]);
106      }
107      el = parentEl.removeChild(els[i]);
108      destinationElement.insertBefore(el, destinationElement.firstChild);
109    }
110  }
111  var backwardFunction = function() {
112    for (i = 0; i < l; i++) {
113      parentEl = els[i].parentNode;
114      el = parentEl.removeChild(els[i]);
115      placeHolders[i].parentNode.insertBefore(el, placeHolders[i]);
116    }
117  }
118  // then create a object that operates on it:
119  if (!desktopFirst) {
120    minwidth(width, forwardFunction, backwardFunction);
121  } else {
122    minwidth(width, backwardFunction, forwardFunction, desktopFirst);
123  }
124}
125;
126(function($) {
127var mobileOpen = false;
128var mobileMenuOpen = false;
129	/* ADD NAVIGATION TOGGLE BUTTON FOR USE WITH MOBILE SCREEN WIDTHS */
130	$(function() {
131		
132		$('.mobile-nav-toggle').click(function() {
133			toggleMobileMenu();
134		});
135		/* if enter is pressed on the menu */
136		$('.mobile-nav-toggle').keydown(function(e) {
137			/* Navigation through mobile menu - pressing tab and shift, return to last item */
138			if (e.keyCode == 9 && e.shiftKey && mobileOpen) {
139				e.preventDefault();
140				e.stopPropagation();
141				$('.lastMobileItem')[0].focus();
142			}
143		});
144
145		function toggleMobileMenu() {
146			var menu = $('.global-nav-mega-wrapper');
147			var searchblock = $(".form-item-search-block-form #edit-search-block-form--2")
148			var button = $('.mobile-nav-toggle')
149			var timeoutHandle = null;
150			if (timeoutHandle) {
151				clearTimeout(timeoutHandle);
152				timeoutHandle = null;
153			}
154			/* check to see if jquery block is open and close it */
155			if ($('.mobile-subnav-toggle').hasClass('visible')) {
156				var subnavmenu = $('.block-jquerymenu');
157				subnavmenu.toggleClass('visible');
158				$('.mobile-subnav-toggle').toggleClass('visible');
159			}
160			/* if not open, open the mobile menu, timeoutHandle allows display:none to work */
161			if (!button.hasClass('openMobile')) {
162				mobileOpen = true;
163				button.toggleClass("openMobile");
164				timeoutHandle = setTimeout(function() {
165					menu.toggleClass('left-open').toggleClass('left-closed');
166				}, 1);
167				menu.toggleClass('visible');
168				$('.mega_link').each(function() {
169					$(this).toggleClass('mobileOpen');
170					$(this).toggleClass('aha-focus');
171				})
172				searchblock.attr({ "tabindex": "-1" });
173			} 
174			/* close the menu */
175			else {
176				mobileOpen = false;
177				searchblock.attr({ "tabindex": "3" });
178				menu.toggleClass('left-open').toggleClass('left-closed');
179				timeoutHandle = setTimeout(function() {
180					button.toggleClass("openMobile");
181					menu.toggleClass('visible');
182					$('.mega_link').each(function() {
183						$(this).toggleClass('mobileOpen');
184						$(this).toggleClass('aha-focus');
185					})
186					/* 300 is the time set in css as well */
187				}, 300);
188
189			}
190			/* tell the user that the menu is expanded or collapsed */
191			if (document.activeElement.getAttribute("aria-expanded") == "true") {
192				document.activeElement.setAttribute("aria-expanded", "false");
193			} else {
194				document.activeElement.setAttribute("aria-expanded", "true");
195			}
196			/* if tabbing on list item, return to first item in mobile */
197			$('.lastMobileItem').keydown(function(e) {
198				if ((e.keyCode == 9) && (mobileOpen) && !e.shiftKey && !$(this).closest('li').hasClass('expanded')) {
199					e.preventDefault();
200					e.stopPropagation();
201					$('.mobile-nav-toggle')[0].focus();
202				}
203			})
204			
205
206			
207
208
209		}
210
211	});
212
213	/* Adding the correct tabindex to the entire header*/
214	$(function() {
215		$(".form-item-search-block-form #edit-search-block-form--2").attr({ "tabindex": "4" })
216		$("#edit-actions #edit-submit").attr({ "tabindex": "4" })
217		$("#logo").attr({ "tabindex": "2" })
218		$(".element-invisible.element-focusable").attr({ "tabindex": "1" })
219		/* need to find the last item for mobile */
220		var length = $("li.mega_link > a").length;
221		$("li.mega_link > a").each(function(index) {
222			$(this).attr({ "tabindex": "5" });
223			if (index == length - 1) {
224				$(this).addClass("lastMobileItem")
225				$('li.mega_link div.hover_effect li a').last().addClass('lastMobileItem')
226			}
227		});
228		// var length = $("#block-menu-menu-header-links a").length;
229		$("#block-menu-menu-header-links a").each(function(index) {
230			$(this).attr({ "tabindex": "6" })
231			// if (index == length - 1) {
232			//     $(this).addClass("lastMobileItem")
233			// }   
234		})
235		/* Set the mega wrapper to closed */
236		$('.global-nav-mega-wrapper').addClass("left-closed")
237	});
238
239
240
241	/*MEGA MENU --- ADD SUB-MENU EXPAND/COLLASE FUNCTIONALITY FOR MOBILE SUB_MENU ITEMS */
242	$(function() {
243		$mobileFocus = null;
244		$('#top_level_mega.hover_effect > li div.hover_effect').each(function() {
245			$(this).before('<div title="Click to expand or collapse" class="nested-menu-item-toggle"></div>');
246		}); 
247		$('.page-outer').delegate('.mobileOpen',"keydown click",function(e){
248			$mobileFocus = $(this)
249			/* close on escape */
250			if(e.keyCode == 27) {
251				e.preventDefault();
252				$(document.activeElement).closest('li.mobileOpen').find('a')[0].focus();
253				clearOtherMobileMenu();
254			}
255			
256			/* if on one of the tabs then toggle menu for click and enter */
257			if(e.type == "click"  && !$(document.activeElement).closest('ul').hasClass('column')){
258				toggleMobileMenu();
259			}
260			else if(e.keyCode == 13 && !$(document.activeElement).closest('ul').hasClass('column')) {
261				toggleMobileMenu();
262			}
263		})
264
265		function toggleMobileMenu() {
266			if(!$mobileFocus.closest('li').hasClass('expanded')) {
267					  clearOtherMobileMenu()
268				}
269			$mobileFocus.toggleClass('expanded');
270			$mobileFocus.find('.hover_effect').toggle(); 
271			toggleAria();
272		}
273		function toggleAria() {
274			if ($mobileFocus.find('a')[0].getAttribute("aria-expanded") == "true") {
275				$mobileFocus.find('a')[0].setAttribute("aria-expanded", "false");
276			} else {
277				$mobileFocus.find('a')[0].setAttribute("aria-expanded", "true");
278			}
279		}
280		function clearOtherMobileMenu() {
281			if(document.getElementsByClassName("expanded")[0]){
282				document.getElementsByClassName("expanded")[0].getElementsByTagName('a')[0].setAttribute("aria-expanded", "false");
283				$(document.getElementsByClassName("expanded")[0].getElementsByClassName('hover_effect')[0]).toggle()
284				document.getElementsByClassName("expanded")[0].classList.remove("expanded");
285
286			}
287			
288		}
289		
290
291	});
292
293	/* Delay on the mega menu */
294	$(function() {
295		$('#block-views-mega-menu-node-block ul#top_level_mega li').hover(function() {
296			$(this).find('.mega_hover_wrapper').stop(true, true).delay(500).queue(function() {
297				$(this).addClass('show')
298			});
299		}, function () {
300			$(this).find('.mega_hover_wrapper').stop(true, true).delay(500).queue(function() {
301				$(this).removeClass('show')
302			});
303		});
304	});
305
306})(jQuery);;
307(function ($) {
308
309$(function() {
310      $('.block-jquerymenu ul.jquerymenu > li.parent').each(function() {
311          if (!$(this).hasClass('active-trail')) {
312			  $(this).removeClass('open').addClass('closed');
313		  }
314      });  
315});
316
317$(function() {
318      $('.block-jquerymenu ul.jquerymenu > li.parent > span').each(function() {
319          if (!$(this).hasClass('active-trail')) {
320			  $(this).removeClass('open').addClass('closed');
321		  }
322      });  
323});
324
325/* ADD SUBNAVIGATION TOGGLE BUTTON FOR USE WITH MOBILE SCREEN WIDTHS */
326$(function() {
327	if ($('.block-jquerymenu').length>0) {
328		$('.mobile-subnav-placeholder').addClass('mobile-subnav-toggle');
329	} 		   
330  $('.mobile-subnav-toggle').click(function() {
331    var subnavmenu = $('.block-jquerymenu');
332    subnavmenu.toggleClass('visible');
333	$('.mobile-subnav-toggle').toggleClass('visible');
334    return false;
335  });
336});
337
338} )( jQuery );
339;
340(function ($) {
341
342/* RANDOMIZE SITE BACKGROUND IMAGE Add .random class to html tag */
343$(function() { // onReady() 
344		if ((top.location.pathname === '/')){		/*only randomize the home page*/
345			/* Default numbers */
346			var dt = new Date();
347			var numRand = Math.floor((Math.random()*2)+1); 
348			var dayTime = '';
349			var season = '';
350			var seasonDayPhoto = '';  //These will be how many photo's are in each section
351			var seasonNightPhoto = '';
352
353			/* Find out what season it is */
354			/*var month = dt.getMonth() + 1; //starts at 0
355			
356			if ((month >= 3) && (month <= 5)){
357				season = 'sp'
358				seasonDayPhoto = 3;
359				seasonNightPhoto = 2;
360			}
361			else if ((month >= 6) && (month <= 8)){
362				season = 'su'
363				seasonDayPhoto = 3;
364				seasonNightPhoto = 2;
365			}
366			else if ((month >= 9) && (month <= 11)){
367				season = 'f'
368				seasonDayPhoto = 3;
369				seasonNightPhoto = 2;
370			}
371			else{
372				season = 'w'
373				seasonDayPhoto = 3;
374				seasonNightPhoto = 2;
375			}*/
376			
377			/* Find out if it's night or day */
378			/*if ((dt.getHours() > 6) && (dt.getHours() <= 18)){ 
379				numRand = Math.floor((Math.random()*seasonDayPhoto)+1); //this is here so the client can have a different number of day photos then night photos
380				dayTime = 'd';
381			}
382			else {
383				numRand = Math.floor((Math.random()*seasonNightPhoto)+1);
384				dayTime = 'n';
385			}*/
386			
387			var randomClass = 'random' + numRand + dayTime + season;
388			$('html').addClass(randomClass);
389		} else {
390			$('html').addClass('not-random');
391		}
392});
393
394} )( jQuery );;
395(function ($) {
396
397$(function() {
398	$('.page-search h1#page-title').text('Website Search Results');
399	$('.page-search #block-system-main h2:contains("Search results")').remove();  /*this removes extra unnecessary text from the search results page*/	
400});
401
402$(function () {
403	/*this handles the expand/collapse logic when clicking on the advanced search filter button*/ 
404	$('.block-facetapi').hide();
405    if(window.location.href.indexOf("im_field") > -1) {
406		$('#advancedsearch-button').toggleClass('expanded');
407		$('.block-facetapi').show();
408	}
409});
410
411$(function () {	
412	$('#aha-search-buttons .button.municipalcode span').click(function() {
413		var searchtext = document.querySelector('.search-form .form-item input').value;
414		//window.open('https://www.municode.com/library/search?stateId=9&clientId=2443&searchText=' + searchtext,'_blank');
415		document.location = "/municipalcode?keys=" + searchtext;
416	});
417})
418	
419$(function () {	
420	$('#aha-search-buttons .button.projects span').click(function() {
421		var searchtext = document.querySelector('.search-form .form-item input').value;
422		document.location = "/projects?keys=" + searchtext;
423	});
424});
425	
426$(function () {	
427	$('#aha-search-buttons .button.citycouncil-mtgs span').click(function() {
428		var searchtext = document.querySelector('.search-form .form-item input').value;
429		document.location = "/search/site/" + searchtext + "?f[0]=im_field_microsite%3A27&f[1]=im_field_event_type%3A14";
430	});
431});
432	
433$(function () {	
434	$('#aha-search-buttons .button.all-mtgs span').click(function() {
435		var searchtext = document.querySelector('.search-form .form-item input').value;
436		document.location = "/search/site/" + searchtext + "?f[0]=im_field_event_type%3A14";
437	});
438});
439	
440$(function () {	
441	$('#aha-search-buttons .button.departments span').click(function() {
442		var searchtext = document.querySelector('.search-form .form-item input').value;
443		document.location = "/search/site/" + searchtext + "?f[0]=im_field_microsite%3A20";
444	});
445});
446	
447$(function () {	
448	$('#aha-search-buttons .button.parks span').click(function() {
449		var searchtext = document.querySelector('.search-form .form-item input').value;
450		document.location = "/parksites?keys=" + searchtext;
451	});
452});
453	
454$(function () {	
455	$('#aha-search-buttons .button.bids-rfps span').click(function() {
456		var searchtext = document.querySelector('.search-form .form-item input').value;
457		document.location = "/rfps";
458	});
459});
460	
461$(function () {	
462	$('#aha-search-buttons .button.staff-directory span').click(function() {
463		var searchtext = document.querySelector('.search-form .form-item input').value;
464		document.location = "/directory?keys=" + searchtext;
465	});
466});
467
468$(function () {	
469	$('#aha-search-buttons .button.all-faqs span').click(function() {
470		var searchtext = document.querySelector('.search-form .form-item input').value;
471		document.location = "/faqs?keys=" + searchtext;
472	});
473});
474
475$(function () {	
476	window.onload = function() {
477		if($(window).width() > 1000) {
478			$('.region-content form.search-form').appendTo('#block-block-48');
479		} else {
480			$('#block-block-49').prependTo('.region-content #block-system-main .block-content');
481			$('.block-facetapi').appendTo('.region-content #block-block-49');
482		}
483	}
484});
485
486})( jQuery );;
487/* Version: 1.0 -= 9/18/2017 */
488/* Version: 2.0 = 10/5/2017 -- Old style working with keyboard keys -- extra stuff for some blocks to  */
489(function($) {
490    /* Adding tab function for menu's -- will apply to class aha_focus*/
491    /* When adding .aha-focus to a website element, dont forget to add tabindex="0" as well*/
492
493    /* To add to Menu Setting to the mega menu, you need to go into _nav-global-nav-mega.scss and copy all lines with :hover and replace them with .focus-within. Be careful with ones that have two :hover, 
494        You will need to delete both but only add in one .focus-within. */
495    $(function() {
496        $(".front #block-views-calendar-block-2 .block-header h2").attr({ "class": "aha-focus", "aria-expanded": "false", "tabindex": "0", "role": "button" });
497        $(".front #block-views-calendar-block-2").addClass("aha-focus");
498        /* need to add tab index to all li tags that don't have a tags */
499        $('.aha-focus .hover_effect li').each(function() {
500            if ($(this).find('strong')[0]) {
501                $(this).attr({ "role": "separator" });
502            }
503            if (!$(this).find('a')[0] && $(this).find('strong')[0]) {
504                $(this).attr({ "tabindex": "5" });
505            }
506        });
507        /* add tabindex equal the mega menu tag index */
508        $('.aha-focus .hover_effect li a').each(function() {
509            $(this).attr({ "tabindex": "5" });
510        });
511        keyCode: {
512            ENTER = 13,
513            SPACE = 32,
514            LEFT = 37,
515            UP = 38,
516            RIGHT = 39,
517            DOWN = 40,
518            ESCAPE = 27,
519            TAB = 9
520        };
521        var $blockContent = null;
522        var $parentBlock = null;
523        /* Seems each block is different but it took 3 for brookhaven */
524        var $startingBlockPos = 2;
525        /* this is just used to keep track of the block pos */
526        var $blockPos = $startingBlockPos;
527        var $menuOpen = false;
528        $('#top_level_mega').delegate('.aha-focus','keydown', function(e) {
529            var $focused = $(document.activeElement);
530            if ($focused.is('h2')) {
531                $blockContent = $(document.activeElement.parentNode.parentNode.getElementsByClassName("block-content"));
532                $parentBlock = $(document.activeElement.parentNode.parentNode);
533            }
534            /* this is just for initial use to make sure they aren't blank*/
535            else if (!$blockContent) {
536                $blockContent = $focused;
537                $parentBlock = $focused;
538            }
539
540            /* add event that in case of click */
541            document.addEventListener("mousedown", handler, true);
542            /* If user presses the 'enter' key then it will add 'focus-within' class to current class */
543            if ( ( ( (e.keyCode == ENTER) || (e.keyCode == SPACE)) && $focused.parent().hasClass("aha-focus")) || 
544                ((e.keyCode == DOWN) && !($(this).hasClass("focus-within")) && !($parentBlock.hasClass("open")) && !$(this).hasClass('mobileOpen'))) {
545                e.preventDefault();
546                e.stopPropagation();
547                /* Check to see if we are on h2 block */
548
549                if ($blockContent != $focused && !($(this).is('li.aha-focus'))) {
550                    /* focus-within won't work here for no reason at all */
551                    $parentBlock.toggleClass("open");
552                    if (document.activeElement.getAttribute("aria-expanded") == "true") {
553                        document.activeElement.setAttribute("aria-expanded", "false");
554                    } else {
555                        document.activeElement.setAttribute("aria-expanded", "true");
556                    }
557
558                }
559                /* for menu or mega menu */
560                else {
561                    $(this).toggleClass("focus-within");
562                    if (document.activeElement.getAttribute("aria-expanded") == "true") {
563                        document.activeElement.setAttribute("aria-expanded", "false");
564                    } else {
565                        document.activeElement.setAttribute("aria-expanded", "true");
566                        $menuOpen = true;
567                    }
568                }
569
570
571
572                /* If the user presses enter and the main menu has a A tag under it, it will go to the a tag instead of opening the menu */
573                if ($(this).find('a')[0]) {
574                    if ((e.keyCode == ENTER) && ($(this).find('a')[0].hasAttribute("tabindex"))) {
575                        $(this).find('a:first')[0].click();
576                    }
577                }
578
579            }
580            /* key board keys within the menu */
581            /* now are treating tab the same as long as the menu is open */
582            else if (((e.keyCode == DOWN) || (e.keyCode == UP) || (e.keyCode == TAB)) && !$(this).hasClass('mobileOpen')) {
583                if(e.keyCode == TAB && !$menuOpen){
584                    /* if tab and the menu isn't open, then return and run the tab code */
585                   return;
586                }
587                e.preventDefault();
588                e.stopPropagation();
589                if ( (e.keyCode == DOWN) || ((e.keyCode == TAB && !e.shiftKey)) ) {
590                    /* if it's on the top level, focus the first a tag */
591                    if ($focused.parent().is('.aha-focus') && !$focused.is('h2')) {
592                        /* Go to the first column and then the first child */
593                        if ($(document.activeElement.parentElement.getElementsByClassName("column_1")[0].firstElementChild).find('a')[0]) {
594                            $(document.activeElement.parentElement.getElementsByClassName("column_1")[0].firstElementChild).find('a')[0].focus();
595                        } else {
596                            $(document.activeElement.parentElement.getElementsByClassName("column_1")[0].firstElementChild).focus()
597                        }
598                    } else if ($focused.is('h2') || $blockPos > $startingBlockPos) {
599                        $blockPos += 1;
600                        if ($parentBlock.find('a')[$blockPos]) {
601                            $parentBlock.find('a')[$blockPos].focus();
602                            /* might need to clear this later */
603
604                        } else {
605                            $parentBlock.find('h2')[0].focus();
606                            $blockPos = $startingBlockPos;
607                            clearFocus();
608                        }
609
610                    }
611                    /* not on top level */
612                    else {
613
614                        /* check to see if there is something next */
615                        if ($(document.activeElement).closest('li').next().find('a')[0]) {
616                            $(document.activeElement).closest('li').next().find('a')[0].focus();
617                        } else if ($(document.activeElement).closest('li').next()) {
618                            $(document.activeElement).closest('li').next().focus();
619                        } else {
620                            /* catch any error, this should never get run */
621                            $(document.activeElement).closest('.aha-focus').focus();
622                            clearFocus();
623                        }
624
625
626                        /* check and see if it was the same thing -- meaning it needs to go to the next column*/
627                        if ($focused.context.innerHTML == $(document.activeElement).context.innerHTML) {
628                            /* have to do two next because of the P tag */
629                            if ($(document.activeElement).closest('ul').next().next().children('li')[0]) {
630                                $(document.activeElement).closest('ul').next().next().children('li')[0].focus();
631                                /* check to see if the next column is just an a tag -- deosn't happen very often */
632                                if ($focused.context.innerHTML == $(document.activeElement).context.innerHTML) {
633                                    $(document.activeElement).closest('ul').next().next().find('a')[0].focus()
634                                }
635                            } else {
636                                $(document.activeElement).closest('.aha-focus').find('a')[0].focus();
637                                clearFocus();
638                            }
639                        }
640                    }
641
642
643
644                }
645                if ((e.keyCode == UP) || (e.keyCode == TAB && e.shiftKey) ) {
646                    /* if it's on the top level, focus the first a tag */
647                    if ($blockPos > $startingBlockPos) {
648                        $blockPos -= 1;
649                        if ($parentBlock.find('a')[$blockPos] && $blockPos > $startingBlockPos) {
650                            $parentBlock.find('a')[$blockPos].focus();
651                            /* might need to clear this later */
652
653                        } else {
654                            $parentBlock.find('h2')[0].focus();
655                            $blockPos = $startingBlockPos;
656                            clearFocus();
657                        }
658
659                    }
660                    /* not on top level */
661                    else {
662                        /* check to see if there is something prev */
663
664                        if ($(document.activeElement).closest('li').prev().find('a')[0]) {
665                            $(document.activeElement).closest('li').prev().find('a')[0].focus();
666                        } else if ($(document.activeElement).closest('li').prev()) {
667                            $(document.activeElement).closest('li').prev().focus();
668                        } else {
669                            /* catch any error, this should never get run */
670                            $(document.activeElement).closest('.aha-focus').find('a').focus();
671                            clearFocus();
672                        }
673
674
675                        /* check and see if it was the same thing -- meaning it needs to go to the prev column*/
676                        if ($focused.context.innerHTML == $(document.activeElement).context.innerHTML) {
677                            /* have to do two prev because of the P tag */
678                            if ($(document.activeElement).closest('ul').prev().prev().children('li').last()) {
679                                $(document.activeElement).closest('ul').prev().prev().children('li').last().focus();
680                                /* check to see if the prev column is just an a tag -- deosn't happen very often */
681                                if ($focused.context.innerHTML == $(document.activeElement).context.innerHTML) {
682                                    $(document.activeElement).closest('ul').prev().prev().find('a').last().focus()
683                                    /* checking to see if it's top level up arrow */
684                                    if ($focused.context.innerHTML == $(document.activeElement).context.innerHTML) {
685                                        $(document.activeElement).closest('.aha-focus').find('a')[0].focus();
686                                        clearFocus();
687                                    }
688                                }
689                            }
690                        }
691                    }
692
693                }
694            }
695            /* Left and Right keys */
696            if (e.keyCode == RIGHT && !$(this).hasClass('mobileOpen')) {
697                e.preventDefault();
698                e.stopPropagation();
699                if ($(this).next().find('a')) {
700                    $(this).next().find('a').focus()
701                }
702                clearFocus();
703            }
704            if (e.keyCode == LEFT && !$(this).hasClass('mobileOpen')) {
705                e.preventDefault();
706                e.stopPropagation();
707                if ($(this).prev().find('a')) {
708                    $(this).prev().find('a').focus()
709                }
710                clearFocus();
711            }
712
713
714
715            if (e.keyCode == TAB && e.shiftKey && $blockPos > $startingBlockPos) {
716                $blockPos -= 1;
717            } else if (e.keyCode == TAB && $blockPos > $startingBlockPos) {
718                $blockPos += 1;
719            }
720
721            /* if the user presses 'escape' then it will remove the focus-within class and focus back at the top */
722            else if (e.keyCode == ESCAPE) {
723                e.preventDefault();
724                e.stopPropagation();
725                /* check to see if you are in mobile, then if you are close the expanded menu */
726                if ($(document.activeElement).closest('.aha-focus').is('li')) {
727                    $(document.activeElement).closest('.aha-focus').find('a')[0].focus();
728                } else {
729                    $parentBlock.find('h2')[0].focus();
730                    $blockPos = 0;
731                }
732                clearFocus();
733
734            }
735            
736            /* if hovering, it clears focus-within */
737            $('ul#top_level_mega > li.aha-focus > a').hover(function() {
738                clearFocus();
739            });
740        });
741        /* Create event when the user clicks outside of focus it closes the menu */
742        function handler(e) {
743            if (!($(this).hasClass('open'))) {
744                clearFocus();
745                document.removeEventListener("click", handler, true);
746                $(this).focus();
747            }
748
749        }
750        /* Clear focus-within no matter the focus */
751        function clearFocus() {
752            if ($('.focus-within').length > 0) {
753                document.getElementsByClassName("focus-within")[0].getElementsByTagName('a')[0].setAttribute("aria-expanded", "false");
754                document.getElementsByClassName("focus-within")[0].classList.remove("focus-within");
755                $menuOpen = false;
756            }
757            /* For Blocks */
758            if ($('.open:not(.mobile-nav-toggle)').length > 0) {
759                document.getElementsByClassName("open")[0].setAttribute("aria-expanded", "false");
760                document.getElementsByClassName("open")[0].classList.remove("open");
761            }
762            /* clear because of block */
763            $blockContent = null;
764            $parentBlock = null;
765            $blockPos = $startingBlockPos;
766        }
767
768    });
769
770
771
772
773})(jQuery);;
774(function($) {
775	function resize() {
776		if(document.getElementById('background').classList.contains('not-front')){
777			var $background = document.getElementById('html_background');
778			$($background).css({"height":"auto"}) //Overriding Google Translate
779			var $windowHeight = Math.max(document.documentElement.clientHeight, window.innerHeight || 0);
780			var $curHeight = $background.offsetHeight;
781			var $curContainer = $('.container2-wrapper');
782			if($windowHeight > $curHeight) {
783				var $newContainer = $windowHeight - $curHeight + $curContainer.height();
784				$curContainer.css({'min-height':$newContainer + 'px'})
785			} else {
786				$curContainer.css({'min-height':'750px'})
787			}
788		}
789	}
790	window.addEventListener('load',resize);
791})(jQuery);;
792(function($) {
793	$(document).ready(function() {
794		$('.node').each(function() {
795			addTableStlye()
796		});
797		function addTableStlye() {
798			var $table = document.getElementsByTagName("table");
799			var $widthScreen = $( window ).width();
800			for (i = 0; i < $table.length; i++) {
801				$curTable = $(document.getElementsByTagName("table")[i])
802				if(!$curTable.hasClass('views-table') && !$curTable.parent().hasClass('table-responsive') ) {
803					var $widthTable = document.getElementsByTagName("table")[i].offsetWidth;
804					$curTable.wrap('<div class="table-responsive"></div>');
805					if($widthScreen < $widthTable && $widthScreen < 1000) {
806						$curTable.before('<div class="table-overlay"></div>')
807						$curTable.siblings('.table-overlay').css({
808							'height': $curTable.height() + 'px',
809							'width':$widthScreen + 'px'
810						});
811						$curTable.parent('.table-responsive').addClass('overlayed')
812					}	
813					
814				}
815				
816
817			}
818		}
819		
820	});
821	$(document).ready(function() {
822		$('.region-content').delegate('.table-responsive','touchmove click', function(e) {
823			if(!$(this).hasClass('clicked')){
824				var $this = $(this)
825				$this.addClass('clicked')
826				var timeoutHandle = null;
827				 if (timeoutHandle) {
828					clearTimeout(timeoutHandle);
829					timeoutHandle = null;
830				}
831				timeoutHandle = setTimeout(function() {
832					$this.find('.table-overlay').css({
833						"height": 0,
834						"width":0
835					})
836				}, 1100);
837			}
838		})
839	})
840
841})(jQuery);
842
843;
844(function($) {
845
846  $(document).ready(function() {  
847    /* this is where you add all expandable blocks */
848    var $allBlocks = [
849      $(".front #block-block-141"),
850      $(".page-search #block-block-49"), //Search block, leave this at all times
851      $(".front #block-block-151")
852    ]
853
854
855  var $ifOpen = []
856    $.each($allBlocks, function(i,v) {
857      /* fill array with 0's to show that they are closed */
858      $ifOpen[i] = 0
859
860      
861
862      /* find the clickable area so the whole block doesn't open and close when clicked
863      -- this might not always be needed -- */
864      $button = v.find('button')
865      $button.click(function(){
866        checkOtherBlocks(i)
867      })
868      v.keydown(function(e) {
869        /* pressing enter key */
870        if ((e.keyCode == 13) && v.is(':focus')) {
871          checkOtherBlocks(i)
872        }
873        /* Pressing escape */
874        if (e.keyCode == 27 && $ifOpen[i] == 1) {
875          $(v).find('button').focus();
876          toggleBlock(v,i)
877        }
878      })
879
880    })
881
882        function checkOtherBlocks($posistion) {
883          $.each($ifOpen, function(ii,vv) {
884          /* close all other blocks first */
885        if((vv == 1) && (ii != $posistion)) {
886          toggleBlock($allBlocks[ii],ii)
887        }
888        /* Toggle current block */
889        if(ii == $posistion) {
890          toggleBlock($allBlocks[ii],ii)
891        }
892      })
893        }
894
895    function toggleBlock($block,$posistion){
896      $ifOpen[$posistion] = 1 - $ifOpen[$posistion]
897      $content = $block.find('.expandable-section');
898
899      if (document.activeElement.getAttribute("aria-expanded") == "true") {
900        document.activeElement.setAttribute("aria-expanded", "false");
901
902      } else {
903        document.activeElement.setAttribute("aria-expanded", "true");
904
905      }
906      /* This is for any image changes like + to - */
907      $block.toggleClass('open')
908      $content.slideToggle('slow')
909
910    }
911
912  });
913
914
915
916
917})(jQuery);;
918(function($) {
919	$(function() {
920		if($('.view-alerts')){
921			var alerts = $('.view-alerts');
922			var activeRow = []
923			$.each(alerts,function(key,value){
924				var rows = $(value).find('.views-row')
925				var numOfRows = rows.length
926				activeRow[key] = 0;
927				
928				//Add roles to each row
929				// $.each(rows, function(key2,value2) {
930				// 	value2.setAttribute('role','alert')
931				// })
932
933
934				//Add active to the first one
935				rows[activeRow[key]].classList.add('active')
936				rows[activeRow[key]].getElementsByTagName("a")[0].tabIndex = 2
937
938				//Add multiple class
939				if(numOfRows > 1){
940					$(value).addClass('multiple')
941
942					//add click arrow key functionality 
943					var controls = $(value).find('.alert-controls')
944					controls.find('a').attr({'tabindex':'-1'})
945					controls.find('.alert-prev').click(function(){				
946						prevRow(rows,key, numOfRows);
947					})
948					controls.find('.alert-next').click(function(){				
949						nextRow(rows,key, numOfRows)
950					})
951					//Add keyboard functionality
952					$(value).keydown(function(e){
953						//left
954						if(e.keyCode == 37){
955							prevRow(rows,key, numOfRows)
956
957						}
958						//right
959						if(e.keyCode == 39) {
960							nextRow(rows,key, numOfRows)
961						}
962					})
963				}
964				
965			})
966			
967			
968		}
969		function prevRow(rows,key, numOfRows) {
970			rows[activeRow[key]].classList.remove('active')
971			activeRow[key] = activeRow[key] -1
972			if(activeRow[key] < 0) {
973				activeRow[key] = numOfRows - 1
974			}
975			rows[activeRow[key]].classList.add('active')
976			rows[activeRow[key]].getElementsByTagName('a')[0].focus()
977		}
978		function nextRow(rows, key, numOfRows) {
979
980			rows[activeRow[key]].classList.remove('active')
981			activeRow[key] = 1 + activeRow[key]
982			if(activeRow[key] >= numOfRows){
983				activeRow[key] = 0;
984			}
985			rows[activeRow[key]].classList.add('active')	
986			rows[activeRow[key]].getElementsByTagName('a')[0].focus()
987		}
988
989	})
990
991
992})(jQuery);;
993/*global jQuery */
994/*!
995* FitText.js 1.2
996*
997* Copyright 2011, Dave Rupert http://daverupert.com
998* Released under the WTFPL license
999* http://sam.zoy.org/wtfpl/
1000*
1001* Date: Thu May 05 14:23:00 2011 -0600
1002*/
1003
1004(function( $ ){
1005
1006  $.fn.fitText = function( kompressor, options ) {
1007
1008    // Setup options
1009    var compressor = kompressor || 1,
1010        settings = $.extend({
1011          'minFontSize' : Number.NEGATIVE_INFINITY,
1012          'maxFontSize' : Number.POSITIVE_INFINITY
1013        }, options);
1014
1015    return this.each(function(){
1016
1017      // Store the object
1018      var $this = $(this);
1019
1020      // Resizer() resizes items based on the object width divided by the compressor * 10
1021      var resizer = function () {
1022        $this.css('font-size', Math.max(Math.min($this.width() / (compressor*10), parseFloat(settings.maxFontSize)), parseFloat(settings.minFontSize)));
1023      };
1024
1025      // Call once to set.
1026      resizer();
1027
1028      // Call on resize. Opera debounces their resize by default.
1029      $(window).bind('resize.fittext orientationchange.fittext', resizer);
1030
1031    });
1032
1033  };
1034
1035})( jQuery );
1036
1037(function($) {
1038  $(document).ready(function() {
1039    $('#block-block-13 .microsite_name a').fitText(0.9, {minFontSize: '20px', maxFontSize: '38px'});
1040    $('.sidebar-wrapper .block-header h2, .sidebar-wrapper #block-views-social-media-links-block .heading h2').fitText(0.85, {minFontSize: '19px', maxFontSize: '26px'});
1041  });
1042})( jQuery );
1043;
1044(function($) {
1045  /**
1046   * Add functionality to the home events slider
1047   */
1048  $(document).ready(function() {
1049    var calendarSlides = $('.cp-calendar-slider .cp-calendar-slider__slide');
1050    var calendarMaxIndex = calendarSlides.length-1;
1051    var calendarActiveIndex = 1;
1052    var calendarPrev = $('.cp-calendar-slider .cp-calendar-slider__controls .prev button');
1053    var calendarNext = $('.cp-calendar-slider .cp-calendar-slider__controls .next button');
1054    var maxHeight = 0;
1055
1056    var getWindowWidth = function() {
1057      // Get window width, code adapted from jQuery
1058      if ('innerWidth' in window) {
1059        return window.innerWidth;
1060      } else {
1061        var docwindowProp = doc.documentElement["clientWidth"];
1062        return doc.compatMode === "CSS1Compat" && docwindowProp
1063              || doc.body && doc.body["clientWidth"]
1064              || docwindowProp;
1065      }
1066    }
1067
1068    function setEqualHeight() {
1069      var paddingBottom = 20;
1070      var monthHeaderHeight = 0;
1071      var meetingBlocks = $('.cp-calendar-slider .cp-calendar__block');
1072      var windowWidth = getWindowWidth();
1073
1074      if (windowWidth >= 1000) {
1075        meetingBlocks.css('min-height', 0);
1076        $('.cp-calendar-slider__slide').height('auto');
1077        maxHeight = 0;
1078
1079        meetingBlocks.each(function(index, element) {
1080          // calculate max Height and assign it to the container
1081          var elementHeight = $(element).outerHeight();
1082
1083          if (elementHeight !== 0 && elementHeight > maxHeight) {
1084            maxHeight = elementHeight;
1085          }
1086        });
1087
1088        $('.cp-calendar-slider__slide').height((maxHeight+paddingBottom+monthHeaderHeight)+'px');
1089
1090        meetingBlocks.each(function() {
1091          // assign the calculated max Height as minimum for all blocks
1092          $(this).css('min-height', (maxHeight+paddingBottom)+'px');
1093        });
1094      }
1095
1096    }
1097
1098    setEqualHeight();
1099
1100    function calendarSetIndex(inc) {
1101      var index = calendarActiveIndex + inc;
1102      setEqualHeight();
1103
1104      if (index < 0 || index > calendarMaxIndex) {
1105        return;
1106      } else {
1107        calendarSlides.each(function(current, el) {
1108          if (current < index) {
1109            $(el).addClass('behind').removeClass('ahead');
1110          } else if (current > index) {
1111            $(el).addClass('ahead').removeClass('behind');
1112          }
1113        });
1114        calendarSlides.removeClass('active');
1115        $(calendarSlides[index]).addClass('active').removeClass('behind ahead');
1116        calendarActiveIndex = index;
1117        calendarNext.removeClass('disabled');
1118        calendarPrev.removeClass('disabled');
1119
1120        if (index === 0) {
1121          calendarPrev.addClass('disabled');
1122        } else if (index >= calendarMaxIndex) {
1123          calendarNext.addClass('disabled');
1124        } else {
1125          calendarNext.removeClass('disabled');
1126          calendarPrev.removeClass('disabled');
1127        }
1128      }
1129    }
1130
1131    calendarSetIndex(0);
1132
1133    calendarPrev.click(function() {
1134      calendarSetIndex(-1);
1135    });
1136
1137    calendarPrev.keypress(function (e) {
1138      var key = e.which;
1139      if(key == 13)  // the enter key code
1140        {
1141          calendarSetIndex(-1);
1142        }
1143    });
1144
1145    calendarNext.click(function() {
1146      calendarSetIndex(1);
1147    })
1148
1149    calendarNext.keypress(function (e) {
1150      var key = e.which;
1151      if(key == 13)  // the enter key code
1152        {
1153          calendarSetIndex(1);
1154        }
1155    });
1156
1157    if ($('body.front').length) {
1158      $(window).resize(function () {
1159        setEqualHeight();
1160      });
1161
1162      setTimeout(function() {
1163        setEqualHeight();
1164      }, 1000);
1165    }
1166  });
1167
1168})( jQuery );
1169;
1170(function($) {
1171  /**
1172   * Relocate microsite title
1173   * Requires minwidth.js and relocate.js
1174   */
1175  $(document).ready(function() {
1176    var micrositeBreakpoint = 1000;
1177
1178    var micrositeBlock = $('#block-block-13')[0];
1179    var micrositeCatcher = $('#microsite-catcher')[0];
1180
1181    if (micrositeBlock) {
1182      relocate(micrositeBreakpoint, micrositeBlock, micrositeCatcher, true);
1183    }
1184  });
1185})( jQuery );
1186;
1187(function($) {
1188  /**
1189   * Relocate sidebar-second into sidebar first when the viewport gets narrow
1190   * Relocate search inside global-nav-mega in narrow viewports
1191   */
1192  $(document).ready(function() {
1193    var sidebarSecondBreakpoint = 1440;
1194
1195    var sidebarSecondBlock = $('.sidebar-second-wrapper')[0];
1196    var sidebarSecondCatcher = $('#sidebar-second-catcher')[0];
1197
1198    if (sidebarSecondBlock && sidebarSecondCatcher) {
1199      relocate(sidebarSecondBreakpoint, sidebarSecondBlock, sidebarSecondCatcher, true);
1200    }
1201  });
1202})( jQuery );
1203;
1204(function($) {
1205  /**
1206   * Code to make Views Slideshow more respoinsive
1207   */
1208
1209  $(document).ready(function () {
1210    function addCycleHeight () {
1211      $('#views_slideshow_cycle_main_home_page_widgets_tiles-block_3_1 .views-sli
vendor: 5,574 bytes, lines 1211-1246
1211deshow-cycle-main-frame-row').each(function () {
1212          var row = $(this).height();
1213          if (row !== 0) {
1214              $('#views_slideshow_cycle_main_home_page_widgets_tiles-block_3_1').height(row);
1215              return false;
1216          }
1217      });
1218      equalHeight();
1219    }
1220
1221    function equalHeight() {
1222      var items = $('#views_slideshow_cycle_main_home_page_widgets_tiles-block_3_1 .views-slideshow-cycle-main-frame-row .views-slideshow-cycle-main-frame-row-item');
1223      var maxHeight = 0;
1224      items.css('min-height', 0);
1225      items.each(function() {
1226        var itemHeight = $(this).outerHeight()
1227        maxHeight = maxHeight < itemHeight ? itemHeight : maxHeight;
1228      });
1229      items.css('min-height', maxHeight+'px');
1230    }
1231
1232
1233    if ($('body').hasClass('front')) {
1234      $(window).resize(addCycleHeight);
1235      window.setInterval(addCycleHeight, 1000);
1236      addCycleHeight(); // Set Height even before a window resize happens
1237    }
1238  });
1239})( jQuery );
1240;
1241/*! Respond.js v1.4.2: min/max-width media query polyfill
1242 * Copyright 2014 Scott Jehl
1243 * Licensed under MIT
1244 * http://j.mp/respondjs */
1245
1246!function(a){"use strict";a.matchMedia=a.matchMedia||function(a){var b,c=a.documentElement,d=c.firstElementChild||c.firstChild,e=a.createElement("body"),f=a.createElement("div");return f.id="mq-test-1",f.style.cssText="position:absolute;top:-100em",e.style.background="none",e.appendChild(f),function(a){return f.innerHTML='&shy;<style media="'+a+'"> #mq-test-1 { width: 42px; }</style>',c.insertBefore(e,d),b=42===f.offsetWidth,c.removeChild(e),{matches:b,media:a}}}(a.document)}(this),function(a){"use strict";function b(){v(!0)}var c={};a.respond=c,c.update=function(){};var d=[],e=function(){var b=!1;try{b=new a.XMLHttpRequest}catch(c){b=new a.ActiveXObject("Microsoft.XMLHTTP")}return function(){return b}}(),f=function(a,b){var c=e();c&&(c.open("GET",a,!0),c.onreadystatechange=function(){4!==c.readyState||200!==c.status&&304!==c.status||b(c.responseText)},4!==c.readyState&&c.send(null))},g=function(a){return a.replace(c.regex.minmaxwh,"").match(c.regex.other)};if(c.ajax=f,c.queue=d,c.unsupportedmq=g,c.regex={media:/@media[^\{]+\{([^\{\}]*\{[^\}\{]*\})+/gi,keyframes:/@(?:\-(?:o|moz|webkit)\-)?keyframes[^\{]+\{(?:[^\{\}]*\{[^\}\{]*\})+[^\}]*\}/gi,comments:/\/\*[^*]*\*+([^/][^*]*\*+)*\//gi,urls:/(url\()['"]?([^\/\)'"][^:\)'"]+)['"]?(\))/g,findStyles:/@media *([^\{]+)\{([\S\s]+?)$/,only:/(only\s+)?([a-zA-Z]+)\s?/,minw:/\(\s*min\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/,maxw:/\(\s*max\-width\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/,minmaxwh:/\(\s*m(in|ax)\-(height|width)\s*:\s*(\s*[0-9\.]+)(px|em)\s*\)/gi,other:/\([^\)]*\)/g},c.mediaQueriesSupported=a.matchMedia&&null!==a.matchMedia("only all")&&a.matchMedia("only all").matches,!c.mediaQueriesSupported){var h,i,j,k=a.document,l=k.documentElement,m=[],n=[],o=[],p={},q=30,r=k.getElementsByTagName("head")[0]||l,s=k.getElementsByTagName("base")[0],t=r.getElementsByTagName("link"),u=function(){var a,b=k.createElement("div"),c=k.body,d=l.style.fontSize,e=c&&c.style.fontSize,f=!1;return b.style.cssText="position:absolute;font-size:1em;width:1em",c||(c=f=k.createElement("body"),c.style.background="none"),l.style.fontSize="100%",c.style.fontSize="100%",c.appendChild(b),f&&l.insertBefore(c,l.firstChild),a=b.offsetWidth,f?l.removeChild(c):c.removeChild(b),l.style.fontSize=d,e&&(c.style.fontSize=e),a=j=parseFloat(a)},v=function(b){var c="clientWidth",d=l[c],e="CSS1Compat"===k.compatMode&&d||k.body[c]||d,f={},g=t[t.length-1],p=(new Date).getTime();if(b&&h&&q>p-h)return a.clearTimeout(i),i=a.setTimeout(v,q),void 0;h=p;for(var s in m)if(m.hasOwnProperty(s)){var w=m[s],x=w.minw,y=w.maxw,z=null===x,A=null===y,B="em";x&&(x=parseFloat(x)*(x.indexOf(B)>-1?j||u():1)),y&&(y=parseFloat(y)*(y.indexOf(B)>-1?j||u():1)),w.hasquery&&(z&&A||!(z||e>=x)||!(A||y>=e))||(f[w.media]||(f[w.media]=[]),f[w.media].push(n[w.rules]))}for(var C in o)o.hasOwnProperty(C)&&o[C]&&o[C].parentNode===r&&r.removeChild(o[C]);o.length=0;for(var D in f)if(f.hasOwnProperty(D)){var E=k.createElement("style"),F=f[D].join("\n");E.type="text/css",E.media=D,r.insertBefore(E,g.nextSibling),E.styleSheet?E.styleSheet.cssText=F:E.appendChild(k.createTextNode(F)),o.push(E)}},w=function(a,b,d){var e=a.replace(c.regex.comments,"").replace(c.regex.keyframes,"").match(c.regex.media),f=e&&e.length||0;b=b.substring(0,b.lastIndexOf("/"));var h=function(a){return a.replace(c.regex.urls,"$1"+b+"$2$3")},i=!f&&d;b.length&&(b+="/"),i&&(f=1);for(var j=0;f>j;j++){var k,l,o,p;i?(k=d,n.push(h(a))):(k=e[j].match(c.regex.findStyles)&&RegExp.$1,n.push(RegExp.$2&&h(RegExp.$2))),o=k.split(","),p=o.length;for(var q=0;p>q;q++)l=o[q],g(l)||m.push({media:l.split("(")[0].match(c.regex.only)&&RegExp.$2||"all",rules:n.length-1,hasquery:l.indexOf("(")>-1,minw:l.match(c.regex.minw)&&parseFloat(RegExp.$1)+(RegExp.$2||""),maxw:l.match(c.regex.maxw)&&parseFloat(RegExp.$1)+(RegExp.$2||"")})}v()},x=function(){if(d.length){var b=d.shift();f(b.href,function(c){w(c,b.href,b.media),p[b.href]=!0,a.setTimeout(function(){x()},0)})}},y=function(){for(var b=0;b<t.length;b++){var c=t[b],e=c.href,f=c.media,g=c.rel&&"stylesheet"===c.rel.toLowerCase();e&&g&&!p[e]&&(c.styleSheet&&c.styleSheet.rawCssText?(w(c.styleSheet.rawCssText,e,f),p[e]=!0):(!/^([a-zA-Z:]*\/\/)/.test(e)&&!s||e.replace(RegExp.$1,"").split("/")[0]===a.location.host)&&("//"===e.substring(0,2)&&(e=a.location.protocol+e),d.push({href:e,media:f})))}x()};y(),c.update=y,c.getEmValue=u,a.addEventListener?a.addEventListener("resize",b,!1):a.attachEvent&&a.attachEvent("onresize",b)}}(this);;

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.