1const e={init(){this.bindEvents()},bindEvents(){document.addEventListener("click",e=>{e.target.closest(".header__search button")&&(e.preventDefault(),this.showPopup())}),document.addEventListener("click",e=>{const t=document.querySelector(".search-popup-overlay");t&&(e.target===t||e.target.closest(".search-popup__close"))&&this.hidePopup()}),document.addEventListener("keydown",e=>{"Escape"===e.key&&this.isPopupOpen()&&this.hidePopup()}),document.addEventListener("submit",e=>{e.target.closest(".search-popup__form")&&(e.preventDefault(),this.submitSearch())})},showPopup(){const e=document.querySelector(".search-popup-overlay"),t=document.querySelector(".search-popup__input");e&&(document.body.classList.add("search-popup-open"),e.classList.add("search-popup-overlay--visible"),setTimeout(()=>{t&&t.focus()},100))},hidePopup(){const e=document.querySelector(".search-popup-overlay"),t=document.querySelector(".search-popup__input");e&&(document.body.classList.remove("search-popup-open"),e.classList.remove("search-popup-overlay--visible"),t&&(t.value=""))},isPopupOpen:()=>document.body.classList.contains("search-popup-open"),submitSearch(){const e=document.querySelector(".search-popup__input");(null==e?void 0:e.value.trim())&&this.performSearch(e.value.trim())},performSearch(e){const t=`${window.location.origin}/?s=${encodeURIComponent(e)}`;window.location.href=t}};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",()=>{e.init()}):e.init();export{e as default};
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.