2023-06-28 12:45:44 +00:00
|
|
|
!function(e){var t={};function d(a){if(t[a])return t[a].exports;var n=t[a]={i:a,l:!1,exports:{}};return e[a].call(n.exports,n,n.exports,d),n.l=!0,n.exports}d.m=e,d.c=t,d.d=function(e,t,a){d.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:a})},d.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},d.t=function(e,t){if(1&t&&(e=d(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(d.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)d.d(a,n,function(t){return e[t]}.bind(null,n));return a},d.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return d.d(t,"a",t),t},d.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},d.p="",d(d.s=230)}({1:function(e,t){e.exports=jQuery},13:function(e,t,d){"use strict";(function(e){d.d(t,"a",(function(){return a})),d.d(t,"b",(function(){return r}));var a=function(e){var t,d=e;switch(e){case"amex":d="americanexpress",t=32;break;default:t=50}return"\n <svg\n width=".concat(t,"\n height=",32,'\n class="payment-icon icon-').concat(d,'"\n role="img"\n >\n <use\n href="#icon-').concat(d,'"\n xlink:href="#icon-').concat(d,'">\n </use>\n </svg>')},n=0;function r(t){if("1"==edd_global_vars.taxes_enabled){var d=document.getElementsByClassName("edd_cart_tax");if(d.length>0&&!d[0].querySelector(".edd-recalculate-taxes-loading")){d=d[0];var a=document.createElement("span"),r=document.getElementsByClassName("edd_cart_tax_amount");r.length>0&&d.removeChild(r[0]),a.classList.add("edd-loading-ajax","edd-recalculate-taxes-loading","edd-loading"),d.appendChild(a)}var o=e("#edd_cc_address"),i=o.find("#billing_country").val(),c=o.find("#card_address").val(),s=o.find("#card_address_2").val(),_=o.find("#card_city").val(),l=o.find("#card_state").val();t||(t=l);var u={action:"edd_recalculate_taxes",card_address:c,card_address_2:s,card_city:_,card_zip:o.find("#card_zip").val(),state:t,billing_country:i,nonce:e("#edd-checkout-address-fields-nonce").val(),current_page:edd_global_vars.current_page},p=++n;return e.ajax({type:"POST",data:u,dataType:"json",url:edd_global_vars.ajaxurl,xhrFields:{withCredentials:!0},success:function(t){if(p===n){t.html&&e("#edd_checkout_cart_form").replaceWith(t.html),e(".edd_cart_amount").html(t.total);var d=new Object;d.postdata=u,d.response=t,e("body").trigger("edd_taxes_recalculated",[d])}e(".edd-recalculate-taxes-loading").remove()}}).fail((function(t){window.console&&window.console.log&&(console.log(t),p===n&&e("body").trigger("edd_taxes_recalculated",[tax_data]))}))}}}).call(this,d(1))},230:function(e,t,d){"use strict";d.r(t),function(e){var t=d(13);function a(t){e(".edd-cart-ajax").show(),e("#edd_purchase_form_wrap").html('<span class="edd-loading-ajax edd-loading"></span>');var d=document.getElementById("edd-gateway-"+t).getAttribute("data-"+t+"-nonce"),a=edd_scripts.ajaxurl;a.indexOf("?")>0?a+="&":a+="?",a=a+"payment-mode="+t,e.post(a,{action:"edd_load_gateway",edd_payment_mode:t,nonce:d,current_page:edd_scripts.current_page},(function(d){e("#edd_purchase_form_wrap").html(d),e("body").trigger("edd_gateway_loaded",[t])}))}e(document).ready((function(e){if(e(".edd-add-to-cart:not(.edd-no-js)").addClass("edd-has-js"),e(document.body).on("click.eddRemoveFromCart",".edd-remove-from-cart",(function(t){var d=e(this),a=d.data("cart-item"),n=d.data("action"),r=d.data("download-id"),o=d.data("nonce"),i={action:n,cart_item:a,nonce:o,timestamp:d.data("timestamp"),token:d.data("token"),current_page:edd_scripts.current_page};return e.ajax({type:"POST",data:i,dataType:"json",url:edd_scripts.ajaxurl,xhrFields:{withCredentials:!0},success:function(t){if(t.removed){if(parseInt(edd_scripts.position_in_cart,10)===parseInt(a,10)||edd_scripts.has_purchase_links)return window.location=window.location,!1;e(".edd-cart").each((function(){e(this).find("[data-cart-item='"+a+"']").parent().
|