function avadaAddQuantityBoxes(t,a){var e=!1,n=jQuery("body").hasClass("wcopc-product-single");t||(t=".qty"),a||(a=jQuery("div.quantity:not(.buttons_added), td.quantity:not(.buttons_added)").find(t)),a.length&&(jQuery.each(a,(function(t,a){"date"===jQuery(a).prop("type")||"hidden"===jQuery(a).prop("type")||jQuery(a).parent().parent().hasClass("tribe-block__tickets__item__quantity__number")||jQuery(a).parent().hasClass("buttons_added")||(jQuery(a).parent().addClass("buttons_added").prepend('<input type="button" value="-" class="minus" />'),jQuery(a).addClass("input-text").after('<input type="button" value="+" class="plus" />'),e=!0)})),e&&(jQuery("input"+t+":not(.product-quantity input"+t+")").each((function(){var t=parseFloat(jQuery(this).attr("min"));t&&0<t&&parseFloat(jQuery(this).val())<t&&jQuery(this).val(t)})),jQuery(".plus, .minus").off("click"),jQuery(".plus, .minus").on("click",(function(){var a=jQuery(this).parent().find(t),e=parseFloat(a.val()),i=parseFloat(a.attr("max")),o=parseFloat(a.attr("min")),u=a.attr("step");e&&""!==e&&"NaN"!==e||(e=0),""!==i&&"NaN"!==i||(i=""),""!==o&&"NaN"!==o||(o=0),"any"!==u&&""!==u&&void 0!==u&&"NaN"!==parseFloat(u)||(u=1),jQuery(this).is(".plus")?i&&(i==e||e>i)?a.val(i):a.val(e+parseFloat(u)):o&&(o==e||e<o)?a.val(o):0<e&&a.val(e-parseFloat(u)),n&&(jQuery(this).closest("tr").hasClass("opc_cart_item")||jQuery(this).closest(".shop_table").parent().hasClass("wcopc"))?a.trigger("input"):a.trigger("change")}))))}function compositeAddQuantityBoxes(){avadaAddQuantityBoxes()}jQuery(window).on("load updated_wc_div fusion-element-render-fusion_tb_woo_cart",(function(){avadaAddQuantityBoxes()})),jQuery(document).ajaxComplete((function(){avadaAddQuantityBoxes()})),jQuery(document).ready((function(){jQuery(".yith-wacp-mini-cart-icon").on("click",(function(){setTimeout((function(){avadaAddQuantityBoxes()}),100)}))})),jQuery(".composite_data").length&&jQuery(".composite_data").on("wc-composite-initializing",(function(t,a){a.actions.add_action("component_selection_details_updated",compositeAddQuantityBoxes,10)}));