window.addEventListener("load",function(t){astrawpWooQuantityButtons(),quantityInput()});const astraminiCarttargetNode=document.getElementById("ast-site-header-cart");if(null!=astraminiCarttargetNode){const b={attributes:!1,childList:!0,subtree:!0},c=()=>{astrawpWooQuantityButtons(),quantityInput()},d=new MutationObserver(c);d.observe(astraminiCarttargetNode,b)}function astrawpWooQuantityButtons(c){document.querySelector(".woocommerce div.product form.cart");c=c||".qty",$quantityBoxesWrap=document.querySelectorAll("div.quantity:not(.elementor-widget-woocommerce-cart .quantity):not(.buttons_added), td.quantity:not(.elementor-widget-woocommerce-cart .quantity):not(.buttons_added)");for(var t=0;t<$quantityBoxesWrap.length;t++){var e=$quantityBoxesWrap[t],a=e.querySelector(c);if(a&&"date"!==a.getAttribute("type")&&"hidden"!==a.getAttribute("type")){switch(($qty_parent=a.parentElement).classList.add("buttons_added"),astra_qty_btn.style_type){case"no-internal-border":a.classList.add("ast-no-internal-border"),$qty_parent.insertAdjacentHTML("afterbegin",'-'),$qty_parent.insertAdjacentHTML("beforeend",'+ ');break;case"vertical-icon":$qty_parent.classList.add("ast-vertical-style-applied"),a.classList.add("vertical-icons-applied"),$qty_parent.insertAdjacentHTML("beforeend",'+-');break;default:$qty_parent.insertAdjacentHTML("afterbegin",'-'),$qty_parent.insertAdjacentHTML("beforeend",'+')}$quantityEach=document.querySelectorAll("input"+c+":not(.product-quantity)");for(var n=0;n<$quantityEach.length;n++){var r=$quantityEach[n],s=r.getAttribute("min");s&&0{r.classList.remove("ajax-mini-cart-qty-loading")},500))}}}jQuery(function(t){t(document.body).on("wc_fragments_refreshed",function(){astrawpWooQuantityButtons(),quantityInput()})}),function(){var t=XMLHttpRequest.prototype.send;XMLHttpRequest.prototype.send=function(){return this.addEventListener("load",function(){astrawpWooQuantityButtons()}),t.apply(this,arguments)}}();let typingTimer,doneTypingInterval=500;function quantityInput(){document.querySelector(".woocommerce-mini-cart")&&document.querySelectorAll(".input-text.qty").forEach(t=>{t.addEventListener("keyup",a=>{clearTimeout(typingTimer),t.value&&(typingTimer=setTimeout(()=>{var t=a.target.value,e=a.target.getAttribute("name").replace(/cart\[([\w]+)\]\[qty\]/g,"$1");t&&sendAjaxQuantityRequest(a.target,t,e)},doneTypingInterval))})})}