1var pressbook=pressbook||{};function pressbookDomReady(e){if("function"==typeof e)return"interactive"===document.readyState||"complete"===document.readyState?e():void document.addEventListener("DOMContentLoaded",e,!1)}Math.easeInOutQuad=function(e,t,n,o){return(e/=o/2)<1?n/2*e*e+t:-n/2*(--e*(e-2)-1)+t},pressbook.setupMainMenu={init:function(){const e=document.getElementById("site-navigation");if(e){const r=e.getElementsByTagName("ul")[0],c=e.querySelector(".primary-menu-toggle");var t,n,o,a,i,s;void 0!==r?(r.classList.add("nav-menu"),t=e.querySelectorAll(".main-navigation-arrow-btn"),n=e.querySelectorAll("li > a"),o=e.querySelectorAll("li:not(.menu-item-has-children) > a"),a=e.querySelectorAll("li:last-child:not(.menu-item-has-children) > a"),i=e.querySelector(".primary-menu-search"),s=e.querySelector(".primary-menu-search-toggle"),this.toggleTouchClass(e),this.toggleNavigation(c,e),this.collapseIfClickOutside(c,e),this.collapseIfEscapeKeyPress(c,e),this.collapseOnResize(c,e),this.toggleSubmenu(t,n,o,a),this.trapFocusInModal(e),this.toggleSearch(s,i),this.trapFocusInSearch(i)):c&&(c.style.display="none")}},toggleTouchClass:function(e){var t="main-navigation--touch";function n(){return"ontouchstart"in window||0<navigator.maxTouchPoints||0<navigator.msMaxTouchPoints}n()&&e.classList.add(t),window.addEventListener("resize",function(){n()?e.classList.add(t):e.classList.remove(t)})},toggleNavigation:function(t,n){t&&t.addEventListener("click",function(e){e.preventDefault(),n.classList.toggle("toggled"),t&&("true"===t.getAttribute("aria-expanded")?t.setAttribute("aria-expanded","false"):t.setAttribute("aria-expanded","true"))})},collapseIfClickOutside:function(t,n){var o=this;document.addEventListener("click",function(e){n.contains(e.target)||(n.classList.remove("toggled"),t&&t.setAttribute("aria-expanded","false"),[].forEach.call(n.querySelectorAll(".focus"),function(e){e.classList.remove("focus")}),[].forEach.call(n.querySelectorAll(".main-navigation-arrow-btn"),function(e){e.setAttribute("aria-expanded","false")}),o.collapseSearchForm(n))})},collapseIfEscapeKeyPress:function(t,n){var o=this;document.addEventListener("keyup",function(e){"Escape"===e.key&&(n.classList.remove("toggled"),t&&t.setAttribute("aria-expanded","false"),o.collapseSearchForm(n))})},collapseOnResize:function(e,t){window.addEventListener("resize",function(){window.matchMedia("screen and (min-width: 768px)").matches&&(t.classList.remove("toggled"),e&&e.setAttribute("aria-expanded","false"))})},toggleSubmenu:function(e,t,n,o){function a(){for(var e=this,t=!1;"ul"!==e.tagName.toLowerCase();)"li"!==e.tagName.toLowerCase()||t||e.classList.contains("focus")||(t=e),e=e.parentElement;[].forEach.call(e.querySelectorAll(".focus"),function(e){e.classList.remove("focus")}),[].forEach.call(e.querySelectorAll(".main-navigation-arrow-btn"),function(e){e.setAttribute("aria-expanded","false")}),t&&(t.classList.add("focus"),this.setAttribute("aria-expanded","true"))}function i(e){const t=this.parentElement,n=9===e.keyCode,o=e.shiftKey;n&&o&&t.classList.contains("focus")?(t.classList.remove("focus"),this.setAttribute("aria-expanded","false")):!n||o||t.classList.contains("focus")||(t.classList.add("focus"),this.setAttribute("aria-expanded","true"))}function s(){for(var e=this,t=!1;!e.classList.contains("nav-menu");)t||"ul"!==e.tagName.toLowerCase()||([].forEach.call(e.querySelectorAll(".focus"),function(e){e.classList.remove("focus")}),[].forEach.call(e.querySelectorAll(".main-navigation-arrow-btn"),function(e){e.setAttribute("aria-expanded","false")}),t=!0),e=e.parentElement}function r(){for(var e=this;!e.classList.contains("nav-menu");)"li"!==e.tagName.toLowerCase()||e.classList.contains("focus")||(e.classList.add("focus"),e.querySelector(".main-navigation-arrow-btn")&&this.setAttribute("aria-expanded","true")),e=e.parentElement}function c(e){var t,n=this,o=9===e.keyCode,e=e.shiftKey;if(o&&!e){for(;t=function(e){for(;e=e.nextSibling,e&&1!==e.nodeType;);return e}(n),n=n.parentElement,!t;);[].forEach.call(n.querySelectorAll(".focus"),function(e){e.classList.remove("focus")}),[].forEach.call(n.querySelectorAll(".main-navigation-arrow-btn"),function(e){e.setAttribute("aria-expanded","fal
1se")})}}[].forEach.call(e,function(e){e.addEventListener("click",a),e.addEventListener("keydown",i)}),[].forEach.call(t,function(e){e.addEventListener("focus",s)}),[].forEach.call(n,function(e){e.addEventListener("focus",r)}),[].forEach.call(o,function(e){e.addEventListener("keydown",c)})},trapFocusInModal:function(r){document.addEventListener("keydown",function(e){if(r.classList.contains("toggled")){var t=r.querySelectorAll("input, a, button");if(!(t.length<1)){const n=t[0],o=t[t.length-1],a=document.activeElement,i=9===e.keyCode,s=e.shiftKey;i&&!s&&o===a&&(e.preventDefault(),n.focus()),i&&s&&n===a&&(e.preventDefault(),o.focus())}}})},toggleSearch:function(t,n){t&&n&&t.addEventListener("click",function(e){e.preventDefault(),n.classList.toggle("toggled"),"true"===t.getAttribute("aria-expanded")?t.setAttribute("aria-expanded","false"):t.setAttribute("aria-expanded","true")})},collapseSearchForm:function(e){const t=e.querySelector(".primary-menu-search"),n=e.querySelector(".primary-menu-search-toggle");t&&t.classList.remove("toggled"),n&&n.setAttribute("aria-expanded","false")},trapFocusInSearch:function(r){document.addEventListener("keydown",function(e){if(r&&r.classList.contains("toggled")){var t=r.querySelector(".primary-menu-search-toggle");if("none"!==window.getComputedStyle(t,null).display){t=r.querySelectorAll("input, a, button");if(!(t.length<1)){const n=t[0],o=t[t.length-1],a=document.activeElement,i=9===e.keyCode,s=e.shiftKey;i&&!s&&o===a&&(e.preventDefault(),n.focus()),i&&s&&n===a&&(e.preventDefault(),o.focus())}}}})}},pressbook.goToTop={offset:300,offsetOpacity:1200,scrollDuration:700,init:function(){var e=document.querySelector(".go-to-top");e&&(this.handleScroll(e),this.handleClick(e))},handleScroll:function(t){var n=this.offset,o=this.offsetOpacity,a=!1;function e(){var e=window.scrollY||document.documentElement.scrollTop;n<e?t.classList.add("go-to-top--show"):(t.classList.remove("go-to-top--show"),t.classList.remove("go-to-top--fade-out")),o<e&&t.classList.add("go-to-top--fade-out"),a=!1}window.addEventListener("scroll",function(){a||(a=!0,window.requestAnimationFrame?window.requestAnimationFrame(e):setTimeout(e,250))})},handleClick:function(t){t.addEventListener("click",function(e){var n,o,a,i,s,r;e.preventDefault(),window.requestAnimationFrame?(n=0,o=this.scrollDuration,i=window.scrollY||document.documentElement.scrollTop,s=null,r=function(e){var t=e-(s=s||e);o<t&&(t=o);e=Math.easeInOutQuad(t,i,n-i,o);window.scrollTo(0,e),t<o?window.requestAnimationFrame(r):a&&a()},window.requestAnimationFrame(r)):window.scrollTo(0,0),t.blur()}.bind(this))}},pressbookDomReady(function(){pressbook.setupMainMenu.init(),pressbook.goToTop.init()});
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.