PageSourceSearch

https://cdn.toypro.com/ks_v2/js/components_v6.min.js

js toypro.com collected 2026-10-03 22:01:49 UTC 27,557 bytes, 2 lines download raw bytes

1/*! toypro v1.0.0 | (c) 2026  | MIT License | https://gitlab.keistoer.nl/losse-sites/toypro.git */
2var accordeons=document.querySelectorAll(".c_accordeon");if(accordeons)for(let e=0;e<accordeons.length;e+=1){var accordeonTop=document.querySelectorAll(".c_accordeon__top"),accordeonContent=document.querySelectorAll(".c_accordeon__content");accordeonTop[e].addEventListener("click",function(t){var n=document.querySelectorAll(".c_accordeon__content--active"),r=document.querySelectorAll(".c_accordeon--active"),o=accordeonContent[e].classList.contains("c_accordeon__content--active");for(let e=0;e<n.length;e+=1)n[e].classList.remove("c_accordeon__content--active"),r[e].classList.remove("c_accordeon--active");o||(accordeonContent[e].classList.add("c_accordeon__content--active"),accordeons[e].classList.add("c_accordeon--active"),setTimeout(()=>{const t=accordeons[e],n=t.offsetHeight,r=window.innerHeight,o=t.getBoundingClientRect(),c=window.pageYOffset||document.documentElement.scrollTop;n>r?window.scrollTo({top:c+o.top-20,behavior:"smooth"}):window.scrollTo({top:c+o.top-(r-n)/2,behavior:"smooth"})},10))})}var alerts=document.querySelectorAll(".c_alert--closable");if(alerts.length>0){var closeAlert=function(e){e.classList.add("js_closed"),requestAnimationFrame(function(){window.setBodyPaddingForHeader&&window.setBodyPaddingForHeader()})};[].forEach.call(alerts,function(e){e.querySelector(".c_alert__close").addEventListener("click",function(){closeAlert(e)})})}var cartwidget=document.querySelector(".c_cartwidget");if(cartwidget){var cartwidgetBtn=cartwidget.querySelector(".c_cartwidget__button");cartwidgetBtn.addEventListener("mouseenter",function(){document.querySelector(".c_cartwidget__summarywrapper")||cartwidgetBtn.classList.add("nosummary")})}var collInputs=document.querySelectorAll(".c_collapsable-inputs");if(collInputs)for(let t=0;t<collInputs.length;t+=1){var showMoreBtn=collInputs[t].querySelector(".c_collapsable-inputs__showmore");showMoreBtn.addEventListener("click",function(){var e=collInputs[t].querySelectorAll(".c_collapsable-inputs__input");for(let t=0;t<e.length;t+=1)e[t].classList.add("c_collapsable-inputs__input--visible");this.remove()})}var showBtn=document.querySelector(".c_expandable-products__showmore__button");if(showBtn){var productsWrapper=document.querySelector(".c_expandable-products__products"),products=productsWrapper.querySelectorAll(".c_cart-product"),productsAmount=productsWrapper.getAttribute("products-amount"),index=1;products.forEach(e=>{index<=productsAmount&&(e.classList.add("s_visible"),index+=1)}),productsAmount<products.length&&(showBtn.parentElement.classList.remove("s_hidden"),showBtn.addEventListener("click",function(){productsWrapper.classList.add("c_expandable-products__products--active"),products.forEach(e=>{e.classList.add("s_visible")}),showBtn.parentElement.classList.add("s_hidden")}))}var filters=document.querySelector(".c_filters");if(filters){var arrowBtn=document.querySelector(".c_filters__top__arrow"),filterLabel=document.querySelector(".c_filters__top__info__label");function toggleFilters(){filters.classList.toggle("c_filters--open")}arrowBtn.addEventListener("click",toggleFilters),filterLabel.addEventListener("click",toggleFilters);const n=document.querySelector(".c_filters__form");document.querySelector(".c_filters__search-input input").addEventListener("keyup",function(e){13==e.keyCode&&n.submit()})}var inputs=document.querySelectorAll(".c_input__wrapper");if(inputs){var inputFields=document.querySelectorAll(".c_input"),inputComponents=document.querySelectorAll(".c_input__wrapper");inputs.forEach(e=>{var t=e.querySelector(".c_input"),n="";t&&(n=t.getAttribute("type")),"file"===n&&t.addEventListener("change",function(){var e=t.files[0].name,n=t.parentElement,r=n.parentElement.querySelector(".c_input__file__wrapper");n.classList.add("c_input__wrapper--hidden"),r.classList.add("c_input__file__wrapper--show"),n.parentElement.querySelector(".c_input__file__selected").innerText=e,r.querySelector(".c_input__file__delete").addEventListener("click",function(){t.value="",n.classList.remove("c_input__wrapper--hidden"),r.classList.remove("c_input__file__wrapper--show")})})})}var choiceAssist=document.querySelector(".c_keuzehulp-section");if(choiceAssist){var choiceButtons=document.querySelectorAll(".c_keuzehulp-card__button");for(let r=0;r<choiceButtons.length;r+=1)choiceButtons[r].addEventListener("click",function(){var e=choiceButtons[r].parentElement.parentElement.parentElement.querySelectorAll(".c_keuzehulp-card__button");for(let t=0;t<e.length;t+=1)e[t].classList.remove("c_keuzehulp-card__button--active");choiceButtons[r].classList.toggle("c_keuzehulp-card__button--active");var t=document.querySelectorAll(".c_keuzehulp-section").length-1,n=document.querySelectorAll(".c_keuzehulp-section"),o=0;for(let e=0;e<n.length;e+=1){var c=n[e].querySelector(".c_keuzehulp-card__button--active"),i=document.querySelector(".c_keuzehulp-section__top__button").querySelector(".c_button");null!==c&&(o+=1),o===t&&i.classList.remove("c_button--disabled")}})}var languageSelectors=document.querySelectorAll(".c_language-selector");languageSelectors.length>0&&(window.resetLanguageSelectors=function(){[].forEach.call(languageSelectors,function(e){var t=e.querySelector(".c_language-selector__button");e.classList.remove("s_open"),t&&t.setAttribute("aria-expanded","fal
2se")})},[].forEach.call(languageSelectors,function(e){var t=e.querySelector(".c_language-selector__button"),n=e.querySelector(".c_language-selector__listwrapper");if(t&&n){var r,o=n.querySelectorAll(".c_language-selector__link"),c="ontouchstart"in window||navigator.maxTouchPoints>0,i=!1,a=!1;c&&(t.addEventListener("touchend",function(t){t.preventDefault(),i=!0,a=!0,s(e.classList.toggle("s_open")),setTimeout(function(){i=!1,a=!1},300)}),t.addEventListener("click",function(e){if(a)return e.preventDefault(),e.stopPropagation(),a=!1,!1},!0)),t.addEventListener("focus",function(n){clearTimeout(r),c?r=setTimeout(function(){i||document.activeElement!==t||(e.classList.add("s_open"),s(!0))},100):(e.classList.add("s_open"),s(!0))}),Array.prototype.forEach.call(o,function(t){t.addEventListener("focus",function(){c&&i||(e.classList.add("s_open"),s(!0))})}),e.addEventListener("focusout",function(t){if(!c||!i){var n=t.relatedTarget;e.contains(n)||setTimeout(function(){e.contains(document.activeElement)||(e.classList.remove("s_open"),s(!1))},0)}}),t.addEventListener("keydown",function(n){var r=n.target;if((r===t||t.contains(r))&&n.currentTarget===t)if("Escape"===n.key)n.preventDefault(),e.classList.remove("s_open"),s(!1),t.focus();else if("Enter"===n.key||" "===n.key){n.preventDefault(),s(e.classList.toggle("s_open"))}}),c||t.addEventListener("click",function(n){(n.target===t||t.contains(n.target))&&s(e.classList.toggle("s_open"))})}function s(e){t.setAttribute("aria-expanded",e?"true":"false")}})),initIframe=function(){var e=document.querySelectorAll(".c_lego-iframe");if(e.length>0)for(let n=0;n<e.length;n+=1){var t=document.querySelectorAll(".c_lego-iframe__frame")[n].getAttribute("id");iFrameResize({autoResize:!0,heightCalculationMethod:"bodyOffset",sizeHeight:"true"},"#"+t)}},window.addEventListener("load",initIframe,!1),initMobileSlider=function(){var e=document.querySelectorAll("[data-mobile-slider]");if(0!==e.length){e.forEach(function(e){var t=function(e){var t=e.querySelector(".glide");if(t)return t;var n=Array.from(e.children).filter(function(e){return e.classList&&Array.from(e.classList).some(function(e){return e.startsWith("col-")})});if(0===n.length)return null;var r=document.createElement("div");r.className="glide";var o=document.createElement("div");o.className="glide__track",o.setAttribute("data-glide-el","track");var c=document.createElement("ul");c.className="glide__slides";var i=[];n.forEach(function(e){var t=document.createElement("li");for(t.className="glide__slide";e.firstChild;)t.appendChild(e.firstChild);i.push(t)}),i.forEach(function(e){c.appendChild(e)}),o.appendChild(c),r.appendChild(o);var a=document.createElement("div");return a.className="col-12",a.appendChild(r),n.forEach(function(e){e.remove()}),e.firstChild?e.insertBefore(a,e.firstChild):e.appendChild(a),r}(e);if(t){var n=t.querySelectorAll(".glide__slide");if(!(n.length<=1)){var r=null,o=function(){n.forEach(function(e){e.style.transform="",e.style.width="",e.style.marginLeft="",e.style.marginRight=""});var e=t.querySelector(".glide__slides");e&&(e.style.transform="")},c=function(){window.matchMedia("(max-width: 577.98px)").matches?r||(r=new Glide(t,{type:"slider",startAt:0,gap:2,perView:1.1,peek:{before:0,after:0},autoplay:!1,animationDuration:600,dragThreshold:50,touchAngle:20,touchRatio:.5,touchMultiplier:1.5,rewind:!1,perTouch:1})).mount():r?(r.destroy(),r=null,setTimeout(o,0)):o()};c(),window.addEventListener("resize",c)}}})}},window.addEventListener("load",initMobileSlider,!1);var modal=document.querySelector(".c_modal");if(modal){var modalBackground=document.querySelector(".c_modal__background"),modalContent=document.querySelector(".c_modal__content");function closeModal(){modalContent.classList.remove("c_modal__content--active"),modalBackground.classList.remove("c_modal__background--active"),modal.classList.remove("c_modal--slider"),setTimeout(function(){modal.classList.add("c_modal--hidden")},400)}}var primaryNav=document.querySelector(".c_header__primarynav");if(primaryNav){var delay,activeSubmenuId,submenuWrapper=document.querySelector(".c_header__submenuwrapper"),mobSubMenu=document.querySelector(".c_header__mobsubmenu"),navTrigger=primaryNav.querySelector(".c_header__hamburger"),navwrapper=document.querySelector(".c_header__navwrapper"),defaultHeight=152,defaultHeightMobile=68,mobileMenuOffset=80,mobileMenuBottomPeek=24,stateMobsubmenu=!1,getAvailableMobileMenuHeight=function(){var e=primaryNav.getBoundingClientRect().top;return Math.max(defaultHeightMobile,window.innerHeight-e-mobileMenuBottomPeek)},markMobileHeaderScrollInteraction=function(){window.__mobileHeaderScrollLockUntil=Date.now()+250};[navwrapper,mobSubMenu].forEach(function(e){e&&["scroll","touchstart","touchmove","wheel"].forEach(function(t){e.addEventListener(t,markMobileHeaderScrollInteraction,{passive:!0})})});var updateMobileMenuLayout=function(){if(window.innerWidth>=992)return navwrapper.style.maxHeight="",void(mobSubMenu.style.maxHeight="");var e=getAvailableMobileMenuHeight(),t=Math.max(0,e-mobileMenuOffset),n=Math.max(0,e-defaultHeightMobile);stateMobsubmenu||navwrapper.classList.contains("js_active")?primaryNav.style.height=e+"px":primaryNav.style.height=defaultHeightMobile+"px",navwrapper.style.maxHeight=t+"px",mobSubMenu.style.maxHeight=n+"px"};window.resetMobileHeaderMenuState=function(){stateMobsubmenu=!1,activeSubmenuId="0",updateMobileMenuLayout()};var handleSubmenu=function(e){var t=e.getAttribute("data-id");if(delay=0,submenuWrapper.classList.contains("js_active")&&(closeSubmenu(),t===activeSubmenuId))return!1;t&&setTimeout(function(){openSubmenu(t,e)},delay)},openSubmenu=function(e,t){var n=document.querySelector('.c_submenu[data-id="'+e+'"]');primaryNav.style.height=n.clientHeight+defaultHeight+"px",submenuWrapper.style.height=n.clientHeight+"px"},closeSubmenu=function(){submenuWrapper.classList.remove("js_active"),primaryNav.style.height=defaultHeight+"px",submenuWrapper.style.height="0px";var e=document.querySelectorAll(".c_submenu");[].forEach.call(e,function(e){e.classList.remove("js_active")});var t=document.querySelectorAll(".c_primary-nav__subtrigger");[].forEach.call(t,function(e){e.classList.remove("js_active"),e.setAttribute("aria-expanded","fal
2se")}),delay=400,activeSubmenuId="0"},submenuTriggers=document.querySelectorAll(".c_primary-nav__linkwrapper");submenuTriggers.forEach(e=>{hoverintent(e,function(){var t=window.innerWidth,n=e.querySelector(".c_primary-nav__subtrigger"),r=n.getAttribute("data-id");t<=992?handleMobsubmenu(n):r!==activeSubmenuId&&(handleSubmenu(n),activeSubmenuId=r,submenuWrapper.classList.add("js_active"),n.classList.add("js_active"),setTimeout(function(){document.querySelector('.c_submenu[data-id="'+r+'"]').classList.add("js_active")},100))},function(){}).options({timeout:300,interval:150});var t=e.querySelector(".c_primary-nav__subtrigger"),n=t?t.getAttribute("data-id"):null,r=e.querySelector(".c_primary-nav__link"),o=document.querySelector('.c_submenu[data-id="'+n+'"]');r&&t&&r.addEventListener("click",function(e){window.innerWidth});var c,i=function(){if(window.innerWidth>992&&n){if(activeSubmenuId&&activeSubmenuId!==n){var e=document.querySelectorAll(".c_submenu");[].forEach.call(e,function(e){e.classList.remove("js_active")});var r=document.querySelectorAll(".c_primary-nav__subtrigger");[].forEach.call(r,function(e){e.classList.remove("js_active"),e.setAttribute("aria-expanded","false")}),submenuWrapper.classList.remove("js_active"),submenuWrapper.style.height="0px",primaryNav.style.height=defaultHeight+"px"}handleSubmenu(t),activeSubmenuId=n,submenuWrapper.classList.add("js_active"),t.classList.add("js_active"),t.setAttribute("aria-expanded","true"),setTimeout(function(){o&&o.classList.add("js_active")},100)}};if(t&&(t.addEventListener("focus",i),t.addEventListener("blur",function(e){window.innerWidth>992&&n&&(clearTimeout(c),c=setTimeout(function(){var e;(e=document.activeElement)&&(t&&t===e||o&&o.contains(e))||(closeSubmenu(),t&&t.setAttribute("aria-expanded","false"))},200))}),t.addEventListener("keydown",function(e){window.innerWidth>992&&("Enter"===e.key||13===e.keyCode)&&(e.preventDefault(),submenuWrapper.classList.contains("js_active")&&activeSubmenuId===n||i(),setTimeout(function(){if(o){var e=o.querySelector(".c_submenu__link");e&&e.focus()}},150))}),t.addEventListener("click",function(e){window.innerWidth>992?(e.preventDefault(),submenuWrapper.classList.contains("js_active")&&activeSubmenuId===n?closeSubmenu():i()):handleMobsubmenu(t)})),o){var a=o.querySelectorAll(".c_submenu__link");a.forEach(function(r,c){r.addEventListener("focus",function(){window.innerWidth>992&&n&&(submenuWrapper.classList.add("js_active"),o.classList.add("js_active"),t&&(t.classList.add("js_active"),t.setAttribute("aria-expanded","true")),activeSubmenuId=n)}),c===a.length-1&&r.addEventListener("keydown",function(t){if(window.innerWidth>992&&"Tab"===t.key&&!t.shiftKey){var n=document.querySelectorAll(".c_primary-nav__linkwrapper"),r=-1;if(n.forEach(function(t,n){t===e&&(r=n)}),r>=0&&r<n.length-1){t.preventDefault(),closeSubmenu();var o=n[r+1].querySelector(".c_primary-nav__link");o&&setTimeout(function(){o.focus()},100)}}})})}}),primaryNav.addEventListener("mouseleave",function(e){window.innerWidth>992&&setTimeout(function(){closeSubmenu()},delay)});var handleMobmenu=function(){navwrapper.classList.contains("js_active")||stateMobsubmenu?closeMobmenu():openMobmenu()},openMobmenu=function(){navwrapper.classList.add("js_active"),navTrigger.classList.add("s_active"),updateMobileMenuLayout()},closeMobmenu=function(){navwrapper.classList.remove("js_active"),navTrigger.classList.remove("s_active"),closeMobsubmenu(),primaryNav.style.height=defaultHeightMobile+"px",navwrapper.style.maxHeight="",mobSubMenu.style.maxHeight=""};navTrigger.addEventListener("click",function(){handleMobmenu()});var handleMobsubmenu=function(e){stateMobsubmenu=!0,mobSubMenu.classList.add("s-active");var t=e.getAttribute("data-id");document.querySelector('.c_header__mobsubmenu__list[data-id="'+t+'"]').classList.add("s-active"),setTimeout(()=>{document.querySelector('.c_header__mobsubmenu__list[data-id="'+t+'"] ul').classList.add("s-active"),document.querySelector('.c_header__mobsubmenu__list[data-id="'+t+'"] span').classList.add("s-active")},250),navwrapper.classList.remove("js_active"),updateMobileMenuLayout(),document.querySelectorAll(".c_header__mobsubmenu__close").forEach(e
2=>{e.addEventListener("click",()=>{closeMobsubmenu(),navwrapper.classList.add("js_active"),updateMobileMenuLayout()})})},closeMobsubmenu=function(){stateMobsubmenu=!1,mobSubMenu.classList.remove("s-active"),document.querySelectorAll(".c_header__mobsubmenu__list").forEach(e=>{e.classList.remove("s-active"),e.querySelector("ul").classList.remove("s-active"),e.querySelector("span").classList.remove("s-active")}),updateMobileMenuLayout()};window.addEventListener("resize",function(){var e=navwrapper.classList.contains("js_active");closeSubmenu(),window.innerWidth<992&&stateMobsubmenu||window.innerWidth<992&&e?updateMobileMenuLayout():window.innerWidth<992&&!e?(primaryNav.style.height=defaultHeightMobile+"px",navwrapper.style.maxHeight="",mobSubMenu.style.maxHeight=""):window.innerWidth>=992&&(closeMobmenu(),closeMobsubmenu(),primaryNav.style.height=defaultHeight+"px")}),document.addEventListener("click",function(e){const t=primaryNav.contains(e.target);!t&&window.innerWidth<992?closeMobmenu():!t&&window.innerWidth>992&&closeSubmenu()})}if(document.querySelector(".c_cart-delivery")){var deliveryChoicesBtns=document.querySelectorAll(".c_cart-delivery__item__method__button"),buttonsWrapper=document.querySelector(".c_order-delivery__button");if(buttonsWrapper)var nextBtn=buttonsWrapper.querySelector(".c_button");for(let o=0;o<deliveryChoicesBtns.length;o++){var deliveryChoices=document.querySelectorAll(".c_cart-delivery__item"),deliveryChoicesBtn=deliveryChoicesBtns[o],deliveryChoice=deliveryChoices[o];deliveryChoicesBtns[o].addEventListener("click",function(){var e=this.parentElement;buttonsWrapper&&nextBtn.classList.remove("c_button--disabled");for(let e=0;e<deliveryChoices.length;e++)deliveryChoices[e].classList.remove("c_cart-delivery__item--active");e.classList.add("c_cart-delivery__item--active")})}buttonsWrapper&&deliveryChoicesBtns[2].addEventListener("click",function(){nextBtn.classList.add("c_button--disabled");var e=document.querySelectorAll(".c_cart-delivery__item__location__button");for(let t=0;t<e.length;t+=1){e[t].querySelector(".c_input").checked&&nextBtn.classList.remove("c_button--disabled"),e[t].addEventListener("click",function(){nextBtn.classList.remove("c_button--disabled")})}})}const productBlockComponentClass="c_product-block",sliderProductBlocks=document.querySelectorAll(".c_product-block--slider");if(sliderProductBlocks.forEach(e=>{var t=e.querySelectorAll(".glide__slide"),n=e.querySelector(".glide__arrows");const r=e.querySelector(".c_product-block__imgwrapper").querySelector(".glide");if(t.length>1){new Glide(r,{type:"slider",startAt:0,gap:0,autoplay:!1,animationDuration:800}).mount(),n.classList.remove("s_hidden")}}),document.querySelector(".checkout_delivery_parcel_shop")){var zipcodeBtn=document.querySelector(".checkout_delivery_parcel_shop .c_input__arrow"),zipcodeInput=document.querySelector(".checkout_delivery_parcel_shop .c_input");zipcodeBtn.addEventListener("click",function(){window.location.href=window.location.origin+window.location.pathname+"?zipcode="+zipcodeInput.value})}if(document.querySelector(".cart_items_list")){var qtyInputBoxes=document.querySelectorAll(".c_cart-product__input .c_input");for(let c=0;c<qtyInputBoxes.length;c++){var timeout;qtyInputBoxes[c].addEventListener("input",function(){var e=this;clearTimeout(timeout),timeout=setTimeout(function(){var t=e.name,n=e.value;(n<0||""===n)&&(n=1);var r=new XMLHttpRequest;r.onreadystatechange=function(){r.responseText,200==r.status},r.open("GET","/api/cart/item/changeqty/nl/"+t+"/"+n+"/1",!1),r.send(),window.location.reload(!0)},2500)})}}var observer=new MutationObserver((e,t)=>{if(document.querySelector(".c_product-popup")){updateCart(settings.updateCartDataUrl);var n,r=document.querySelector(".c_product-popup__input .c_input"),o=document.querySelector(".c_product-popup__input .c_pid"),c=document.querySelector(".c_product-popup__input .c_locale");r.addEventListener("input",function(){clearTimeout(n),n=setTimeout(function(){var e=r.value,t=o.value;if(""!=e){(e<0||""===e)&&(e=1,r.value=1);var n=!1,i="",a=new XMLHttpRequest;a.onreadystatechange=function(){i=a.responseText,n=200==a.status},a.open("GET","/api/cart/item/changeqty/"+c.value+"/"+t+"/"+e+"/0",!1),a.send();var s=document.querySelector(".c_product-popup__status");s&&(n?(s.classList.remove("c_product-popup__status--hidden"),s.classList.remove("c_product-popup__status--nostock"),s.classList.add("c_product-popup__status--success"),s.innerHTML=JSON.parse(i)):(s.classList.remove("c_product-popup__status--hidden"),s.classList.remove("c_product-popup__status--success"),s.classList.add("c_product-popup__status--nostock"),s.innerHTML=JSON.parse(i)))}},300)}),updateCart(settings.updateCartDataUrl+"/"+c.value)}});async function updateCart(e){var t=e,n=await retrieveCartData(t);updateCartWidget(n.html,n.amount)}function updateCartWidget(e,t){if(""!==e){var n=document.querySelector(".c_cartwidget"),r=document.querySelector(".c_cartwidget__summarywrapper");if(r)r.querySelector("table").innerHTML=e;else{(r=document.createElement("div")).setAttribute("class","c_cartwidget__summarywrapper");var o=document.createElement("table");o.setAttribute("class","c_cartwidget__summary"),o.innerHTML=e,r.appendChild(o),n.appendChild(r)}}if(""!==t){var c=document.querySelector(".c_cartwidget__count");c.classList.remove("s_animated"),setTimeout(()=>{c.classList.add("s_animated")},50),setTimeout(()=>{c.innerText=t},500)}}function retrieveCartData(e){return new Promise(function(t,n){fetch(e).then(e=>e.json()).then(e=>{newAmount=e.uniqueProductsCount?e.uniqueProductsCount:"",html=e.html?e.html:"",t({amount:newAmount,html:html})})})}(modalContent=document.querySelector(".c_modal__content"))&&observer.observe(modalContent,{childList:!0}),initProductBlock=function(){if(document.querySelectorAll(".c_product-top").length>0){var e=document.querySelectorAll(".c_product-top .glide");
2e&&e.forEach(e=>{var t=e.querySelectorAll(".glide__slide"),n=e.querySelector(".glide__arrows");t.length>1&&(new Glide(e,{type:"slider",startAt:0,gap:0,autoplay:!1,animationDuration:800}).mount(),n.classList.remove("s_hidden"))});var t=document.querySelector(".c_product-top__input .c_input"),n=document.querySelector(".c_product-top__button");t&&n&&t.addEventListener("change",function(){var e=t.value;n.setAttribute("modal-product-quantity",e)})}},window.addEventListener("load",initProductBlock,!1);var quickFiltersInputs=document.querySelectorAll(".c_quick-filters__input input");if(0!==quickFiltersInputs.length){for(let i=0;i<quickFiltersInputs.length;i++)quickFiltersInputs[i].addEventListener("keyup",function(e){13==e.keyCode&&quickFiltersInputs[i].parentElement.submit()});document.querySelectorAll(".c_quick-filters__trigger").forEach(e=>{e.addEventListener("click",()=>{const t=e.parentElement.querySelector(".c_quick-filters__input");t.classList.toggle("s_visible"),setTimeout(()=>{t.classList.toggle("s_opacity")},50)})})}const rangeSliderComponentClass="c_range-slider",rangeSliders=document.querySelectorAll(".c_range-slider");[...rangeSliders].forEach(e=>{function t(e,t){const n=parseInt(e.value,10),r=parseInt(t.value,10);return s.value=`${n}-${r}`,[n,r]}function n(e,t,n,r,o){const c=t.max-t.min,i=e.value-t.min,a=t.value-t.min;o.style.background=`linear-gradient(\n      to right,\n      ${n} 0%,\n      ${n} ${i/c*100}%,\n      ${r} ${i/c*100}%,\n      ${r} ${a/c*100}%,\n      ${n} ${a/c*100}%,\n      ${n} 100%)`}function r(t){const n=e.querySelector("[data-to-slider]");Number(t.value)<=0?n.style.zIndex=2:n.style.zIndex=0}const o=e.querySelector("[data-from-slider]"),c=e.querySelector("[data-to-slider]"),i=e.querySelector("[data-from-label]"),a=e.querySelector("[data-to-label]"),s=e.querySelector("[data-output]");n(o,c,"#d8d8d8","#ed1c24",c),r(c),o.oninput=()=>function(e,r,o){const[c,i]=t(e,r);n(e,r,"#d8d8d8","#ed1c24",r),c>i?(e.value=i,o.innerText=i):o.innerText=c}(o,c,i),c.oninput=()=>function(e,o,c){const[i,a]=t(e,o);n(e,o,"#d8d8d8","#ed1c24",o),r(o),i<=a?(o.value=a,c.innerText=a):(c.innerText=i,o.value=i)}(o,c,a),i.oninput=()=>function(e,r,o,c){const[i,a]=t(r,o);n(r,o,"#d8d8d8","#ed1c24",c),i>a?(e.value=a,r.innerText=a):e.value=i}(o,i,a,c),a.oninput=()=>function(e,o,c,i){const[a,s]=t(o,c);n(o,c,"#d8d8d8","#ed1c24",i),r(c),a<=s?(e.value=s,c.innerText=s):c.innerText=a}(c,i,a,c)}),window.onload=function(){var e=document.getElementById("search_locale").value,t=new autoComplete({data:{src:async t=>{try{const n=await fetch("/"+e+`/suggest/${t}`);return await n.json()}catch(e){return e}},keys:["Set","Part","Minifig","Other"]},threshold:3,debounce:200,resultsList:{noResults:!0,maxResults:25},searchEngine:"strict",diacritics:"false",resultItem:{element:(e,t)=>{e.style="display: flex; justify-content: space-between; font-size: 14px;",e.innerHTML=`\n                  <span style="text-overflow: ellipsis; white-space: nowrap; overflow: hidden;">\n                    ${t.match}\n                  </span>\n                  <span style="display: flex; align-items: center; font-size: 13px; font-weight: 100; text-transform: uppercase; color: rgba(0,0,0,.2);">\n                    ${t.key}\n                  </span>`},highlight:!0},submit:!0,events:{input:{focus(){t.input.value.length&&t.start()},selection(n){const r=n.detail;t.input.blur();const o=r.selection.value[r.selection.key];t.input.value=o;const c=r.selection.value.pid,i=r.selection.value.product_slug,a=r.selection.value.color_slug;$color_url="",a&&($color_url="/"+a),window.location.href="/"+e+"/product/"+c+"/"+i+$color_url}}}})};var observerSlider=new MutationObserver((e,t)=>{var n=document.querySelectorAll(".c_slider-popup__wrapper .glide");if(n.length>=1){var r=document.querySelector(".glide__slides"),o=document.querySelector(".glide__slide--active"),c=Array.prototype.indexOf.call(r.children,o);c<0&&(c=0),n.forEach(e=>{var t=e.querySelectorAll(".glide__slide"),n=e.querySelector(".c_slider-popup__controls");1===t.length&&n.classList.add("s_hidden"),setTimeout(()=>{new Glide(e,{type:"slider",startAt:c,gap:0,autoplay:!1,animationDuration:800}).mount()},100)})}});observerSlider.observe(document,{childList:!0,subtree:!0});var subscribeBlock=document.querySelector(".c_subscribe");if(subscribeBlock){var subscribeForm=subscribeBlock.querySelector(".c_subscribe__form"),subscribeNotification=subscribeBlock.querySelector(".c_subscribe__success"),subscribeFormFields=subscribeForm.querySelectorAll(".c_subscribe__input .c_input"),subscribeFormSubmit=subscribeBlock.querySelector(".c_subscribe__link");subscribeForm.addEventListener("submit",function(e){e.preventDefault()}),subscribeFormSubmit.addEventListener("click",function(){var e=!0,t="",n="",r="";for(let a=0;a<subscribeFormFields.length;a++){var o=subscribeFormFields[a],c=o.getAttribute("type"),i=o.value;"email"===c&&(i.length<3||-1===i.indexOf("@")||-1===i.indexOf(".")||-1!==i.indexOf(",")?(o.parentElement.classList.add("c_input__wrapper--error"),e=!1):o.parentElement.classList.remove("c_input__wrapper--error"),n=i),"text"===c&&(i.length<2?(o.parentElement.classList.add("c_input__wrapper--error"),e=!1):o.parentElement.classList.remove("c_input__wrapper--error"),t=i),"hidden"===c&&(r=i)}if(!0===e){var a=new XMLHttpRequest;a.onreadystatechange=function(){200==a.status&&(subscribeForm.remove(),subscribeFormSubmit.remove(),subscribeNotification.classList.remove("c_subscribe__success--hidden"))}
2,a.open("GET","/api/subscribe/newsletter/"+r+"/"+t+"/"+n),a.send()}})}initTeaser=function(){var e=document.querySelectorAll(" .c_teaser-block .glide");e.length>0&&e.forEach(e=>{e.querySelectorAll(".glide__slide").length>1&&new Glide(e,{type:"slider",startAt:0,gap:0,autoplay:7e3,hoverpauze:!0,animationDuration:800}).mount()})},window.addEventListener("load",initTeaser,!1);

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.