PageSourceSearch

https://bernstein-badshop.de/cdn/shop/t/2/assets/drawer.js?v=79847421199403571401785918118

js bernstein-badshop.de collected 2026-09-26 02:25:51 UTC 3,749 bytes, 1 lines download raw bytes

1if(!customElements.get("drawer-section")){class a extends HTMLElement{constructor(){super(),this.header=document.querySelector(".header"),this.content=this.querySelector(".drawer__content"),this.heading=this.querySelector("[data-drawer-heading]"),this.richtext=this.querySelector("[data-drawer-richtext]"),this.addEventListener("click",()=>{this.close()}),this.querySelectorAll("[data-drawer-close]").forEach(e=>{e.addEventListener("click",()=>{this.close()})}),this.content.addEventListener("click",e=>{e.stopPropagation()}),this.scrollbar=new PerfectScrollbar(this.querySelector(".drawer__scroll"),{suppressScrollX:!0,wheelPropagation:!0,swipeEasing:!0,minScrollbarLength:0});var e=new ResizeObserver(e=>{this.scrollbar.update()});e.observe(this.content),e.observe(this.querySelector(".drawer__scroll-inner")),this.resizeObserver=e,window.addEventListener("drawerOpen",this.drawerOpenHandler=e=>{var t;"drawer-collection-filters"!==e.detail.id&&"drawer-search-filters"!==e.detail.id||(t=this.querySelector(".drawer__scroll-sort"))&&(t.open="sort-opened"===e.detail.richtext),e.detail.id==this.id&&((e.detail.heading||e.detail.richtext)&&this.loadText(e.detail),this.open(),t=this.querySelector("details.drawer__scroll-sort"))&&("sorting"===e.detail.section?t.setAttribute("open",""):t.removeAttribute("open"))}),document.addEventListener("change",this.documentChangeHandler=e=>{e=e.target;if(e.matches('input[name^="mobile-product-option-"]')){var t=e.name.replace("mobile-product-option-","");const r=e.value;document.querySelectorAll(`input[data-product-option="${t}"]`).forEach(e=>{e.value=r,e.dispatchEvent(new Event("change",{bubbles:!0})),e.dispatchEvent(new Event("input",{bubbles:!0}));var t,e=e.closest("product-options");e&&(e=e.querySelector(".product-options__mobile-trigger .selected-variant"))&&((t=[...e.childNodes].find(e=>e.nodeType===Node.TEXT_NODE))?t.textContent=r+" ":e.insertBefore(document.createTextNode(r+" "),e.firstChild))});t=e.closest("drawer-section");t&&t.close()}}),window.addEventListener("drawerClose",this.drawerCloseHandler=e=>{this.close()}),window.addEventListener("escPressed",this.escPressedHandler=()=>{this.close()})}disconnectedCallback(){this.resizeObserver&&this.resizeObserver.disconnect(),void 0!==this.scrollbar&&(this.scrollbar.destroy(),this.scrollbar=void 0),this.drawerOpenHandler&&window.removeEventListener("drawerOpen",this.drawerOpenHandler),this.drawerCloseHandler&&window.removeEventListener("drawerClose",this.drawerCloseHandler),this.escPressedHandler&&window.removeEventListener("escPressed",this.escPressedHandler),this.documentChangeHandler&&document.removeEventListener("change",this.documentChangeHandler),this.clickHandler&&this.removeEventListener("click",this.clickHandler),this.contentClickHandler&&this.content.removeEventListener("click",this.contentClickHandler),this.closeButtons?.forEach(({button:e,handler:t})=>{e.removeEventListener("click",t)}),this.closeButtons=null}open(){this.style.display="flex",document.body.style.overflow="hidden",document.body.style.paddingRight=window.scrollbarWidth+"px",this.header.style.paddingRight=window.scrollbarWidth+"px",setTimeout(()=>{this.classList.add("drawer--opened"),document.body.classList.add("hide-badges")}),this.scrollbar.update()}close(){const e=document.querySelectorAll(".drawer");e.forEach(e=>e.classList.remove("drawer--opened")),setTimeout(()=>{e.forEach(e=>e.style.display="none"),document.body.style.removeProperty("overflow"),document.body.style.removeProperty("padding-right"),this.header.style.removeProperty("padding-right")},300)}loadText(e){this.heading&&e.heading&&(this.heading.innerHTML=e.heading),this.richtext&&e.richtext&&(this.richtext.innerHTML=e.richtext)}}customElements.define("drawer-section",a)}

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.