(window.blocksyJsonP=window.blocksyJsonP||[]).push([[14],{33:function(t,e,n){"use strict";n.r(e),n.d(e,"mount",(function(){return l}));var a=n(1),r=n.n(a);const s=()=>[...document.querySelectorAll(".quantity")].map(t=>{t.querySelector(".ct-increase")&&[...t.querySelectorAll("input")].map(t=>{t.hasInputListener||(t.hasInputListener=!0,t.addEventListener("input",e=>{t.closest("tr")&&[...t.closest("tr").querySelectorAll(".quantity input")].filter(e=>e!==t).map(t=>t.value=e.target.value)}))})});let u=!1;const l=(t,e)=>{let{event:n}=e;r.a&&!u&&(u=!0,r()(document.body).on("updated_cart_totals",s),s());const a=t.parentNode.querySelector("input"),l=parseFloat(a.value,10)||0;if(t.classList.contains("ct-increase")){const t=a.getAttribute("max")?parseFloat(a.getAttribute("max"),0):1/0;a.value=lt?Math.round(100*(l-parseFloat(a.step||"1")))/100:t}r()(a).trigger("change"),r()(a).trigger("input"),a.dispatchEvent(new Event("input",{bubbles:!0})),a.closest("tr")&&[...a.closest("tr").querySelectorAll(".quantity input")].filter(t=>t!==a).map(t=>t.value=a.value)}}}]);