PageSourceSearch

https://hobbii.fi/cdn/shop/t/34/assets/hobbii-hobbii-modal-DiWfLi34.min.js

js hobbii.fi collected 2026-09-26 08:53:13 UTC 1,765 bytes, 2 lines download raw bytes

1import{m as o}from"./hobbii-constants-DXYrb0R4.min.js";const e=o=>{"Escape"===o.key&&c()},n=()=>{const o=document.querySelectorAll(".js-login-button"),e=document.querySelectorAll(".js-login-modal-close");o.forEach((o=>{o.addEventListener("click",(o=>{o.preventDefault(),t()}))})),e.forEach((o=>{o.addEventListener("click",c)}))},t=()=>{var n,t;if(null==(t=null==(n=window.Hobbii)?void 0:n.flags)?void 0:t.enableNewCustomerAccounts){const o=encodeURIComponent(window.location.pathname+window.location.search+window.location.hash);return window.location.href=`/customer_authentication/login?return_to=${o}`}if(!("customElements"in window))return window.location.href="/account/login";const c=document.querySelector("hb-modal#login-modal").shadowRoot.querySelector("#login-modal");if(!c)return;window.addEventListener("keydown",e);const r=new CustomEvent(o.open);c.dispatchEvent(r)},c=()=>{const n=document.querySelector("hb-modal#login-modal").shadowRoot.querySelector("#login-modal");if(!n)return;window.removeEventListener("keydown",e);const t=new CustomEvent(o.close);n.dispatchEvent(t)},r=()=>{const o=document.querySelector(".js-buy-now-pay-later-button");o&&o.addEventListener("click",(o=>{o.preventDefault(),a()}))},s=()=>{const o=document.querySelector("#js-buy-now-pay-later-modal");o&&o.classList.contains("hidden")&&o.classList.remove("hidden")},a=()=>{if(!("customElements"in window))return;const n=document.querySelector("hb-modal#js-buy-now-pay-later-modal");if(!n||!n.shadowRoot)return;const t=n.shadowRoot.querySelector("#js-buy-now-pay-later-modal");if(!t)return;window.addEventListener("keydown",e);const c=new CustomEvent(o.open);t.dispatchEvent(c)};export{r as a,n as i,t as o,s as r};
2//# sourceMappingURL=hobbii-hobbii-modal-DiWfLi34.min.js.map

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.