Payment Plugins for Stripe WooCommerce - Version 3.2.13

Version Description

  • Added - Save new payment method to subscription when failed renewal order is paid for.
  • Added - Permission check "manage_woocommerce" added to Edit Product page for rendering Stripe settings
  • Added - If shipping phone field exists and is empty, populate using GPay/Apple Pay phone number returned
  • Updated - WC Tested up to 5.0
  • Updated - Stripe PHP SDK 7.72.0
  • Updated - Fix change_payment_method request logic so it's processed in the process_payment function
  • Updated - Adjust cart page buttons so last button doesn't have bottom margin
  • Updated - Performance improvement on checkout page when saving a payment method and processing order
Download this release

Release Info

Developer mr.clayton
Plugin Icon wp plugin Payment Plugins for Stripe WooCommerce
Version 3.2.13
Comparing to
See all releases

Code changes from version 3.2.12 to 3.2.13

Files changed (56) hide show
  1. assets/css/stripe-rtl.css +4 -0
  2. assets/css/stripe.css +4 -0
  3. assets/css/stripe.min-rtl.css +1 -1
  4. assets/css/stripe.min.css +1 -1
  5. assets/js/frontend/notices.js +0 -25
  6. assets/js/frontend/notices.min.js +0 -1
  7. assets/js/frontend/wc-stripe.js +10 -0
  8. assets/js/frontend/wc-stripe.min.js +1 -1
  9. i18n/languages/woo-stripe-payment.pot +106 -110
  10. includes/abstract/abstract-wc-payment-gateway-stripe.php +58 -63
  11. includes/admin/class-wc-stripe-admin-user-edit.php +8 -1
  12. includes/admin/meta-boxes/class-wc-stripe-admin-meta-box-product-data.php +98 -92
  13. includes/class-stripe.php +1 -2
  14. includes/class-wc-stripe-field-manager.php +1 -1
  15. includes/class-wc-stripe-frontend-notices.php +0 -58
  16. includes/class-wc-stripe-payment-intent.php +7 -16
  17. includes/wc-stripe-functions.php +14 -0
  18. readme.txt +10 -1
  19. stripe-payments.php +2 -2
  20. vendor/autoload.php +1 -1
  21. vendor/composer/autoload_real.php +4 -4
  22. vendor/composer/autoload_static.php +3 -3
  23. vendor/composer/installed.json +7 -7
  24. vendor/stripe/stripe-php/.php_cs.dist +7 -0
  25. vendor/stripe/stripe-php/CHANGELOG.md +43 -0
  26. vendor/stripe/stripe-php/Makefile +2 -2
  27. vendor/stripe/stripe-php/README.md +4 -0
  28. vendor/stripe/stripe-php/VERSION +1 -1
  29. vendor/stripe/stripe-php/lib/Account.php +4 -4
  30. vendor/stripe/stripe-php/lib/ApiRequestor.php +11 -0
  31. vendor/stripe/stripe-php/lib/ApiResource.php +2 -2
  32. vendor/stripe/stripe-php/lib/BaseStripeClient.php +4 -1
  33. vendor/stripe/stripe-php/lib/Checkout/Session.php +4 -3
  34. vendor/stripe/stripe-php/lib/Collection.php +2 -2
  35. vendor/stripe/stripe-php/lib/Customer.php +1 -1
  36. vendor/stripe/stripe-php/lib/Discount.php +11 -5
  37. vendor/stripe/stripe-php/lib/EphemeralKey.php +2 -2
  38. vendor/stripe/stripe-php/lib/File.php +1 -0
  39. vendor/stripe/stripe-php/lib/HttpClient/CurlClient.php +8 -3
  40. vendor/stripe/stripe-php/lib/Invoice.php +8 -6
  41. vendor/stripe/stripe-php/lib/InvoiceLineItem.php +2 -2
  42. vendor/stripe/stripe-php/lib/Issuing/Dispute.php +2 -2
  43. vendor/stripe/stripe-php/lib/LineItem.php +3 -3
  44. vendor/stripe/stripe-php/lib/PaymentIntent.php +2 -2
  45. vendor/stripe/stripe-php/lib/PaymentMethod.php +1 -0
  46. vendor/stripe/stripe-php/lib/Person.php +9 -0
  47. vendor/stripe/stripe-php/lib/Stripe.php +1 -1
  48. vendor/stripe/stripe-php/lib/StripeObject.php +1 -1
  49. vendor/stripe/stripe-php/lib/Subscription.php +4 -0
  50. vendor/stripe/stripe-php/lib/TaxId.php +2 -1
  51. vendor/stripe/stripe-php/lib/TaxRate.php +2 -0
  52. vendor/stripe/stripe-php/lib/Util/RequestOptions.php +1 -1
  53. vendor/stripe/stripe-php/lib/Util/Util.php +3 -3
  54. vendor/stripe/stripe-php/lib/WebhookSignature.php +1 -1
  55. vendor/stripe/stripe-php/phpstan.neon.dist +2 -1
  56. vendor/stripe/stripe-php/update_certs.php +1 -1
assets/css/stripe-rtl.css CHANGED
@@ -317,6 +317,10 @@ li.payment_method_stripe_payment_request {
317
  .wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_] {
318
  margin: 0 0 1em 0;
319
  }
 
 
 
 
320
 
321
  .wc_stripe_product_payment_methods .gpay-button,
322
  .wc_stripe_cart_payment_methods .gpay-button,
317
  .wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_] {
318
  margin: 0 0 1em 0;
319
  }
320
+ .wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]:last-child,
321
+ .wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_]:last-child{
322
+ margin: 0;
323
+ }
324
 
325
  .wc_stripe_product_payment_methods .gpay-button,
326
  .wc_stripe_cart_payment_methods .gpay-button,
assets/css/stripe.css CHANGED
@@ -317,6 +317,10 @@ li.payment_method_stripe_payment_request {
317
  .wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_] {
318
  margin: 0 0 1em 0;
319
  }
 
 
 
 
320
 
321
  .wc_stripe_product_payment_methods .gpay-button,
322
  .wc_stripe_cart_payment_methods .gpay-button,
317
  .wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_] {
318
  margin: 0 0 1em 0;
319
  }
320
+ .wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]:last-child,
321
+ .wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_]:last-child{
322
+ margin: 0;
323
+ }
324
 
325
  .wc_stripe_product_payment_methods .gpay-button,
326
  .wc_stripe_cart_payment_methods .gpay-button,
assets/css/stripe.min-rtl.css CHANGED
@@ -1 +1 @@
1
- .wc-stripe-card-icons-container,.wc-stripe-paymentRequest-icons-container{float:left;display:inline-block}ul.payment_methods li[class*=payment_method]{margin:0;padding:0}li[class*=payment_method] input[type=radio]{margin:0 5px 0 10px}li[class*=payment_method] input[type=radio]+label:not(.wc-stripe-label-payment-type){margin:0}.woocommerce-checkout #payment ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2),ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2){margin:0}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon,li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{max-width:44px;max-height:27px;width:44px;height:27px;float:none;display:inline}li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{width:25px;height:25px;max-width:25px;max-height:25px}ul.payment_methods label[for*=payment_method_stripe]:after{clear:left;content:"";display:block}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon:nth-child(2n+2){margin:0 2px}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon.open.visa{padding-top:2px}ul.payment_methods li[class*=payment_method_stripe_] label>img:first-of-type{float:left!important}.wc-stripe_cc-new-method-container{margin-bottom:1em}.wc-stripe_cc-container .StripeElement{box-sizing:border-box;height:40px;padding:10px 12px;border-radius:4px;background-color:#fff;-webkit-transition:box-shadow 150ms ease;transition:box-shadow 150ms ease}input.wc-stripe-klarna-category,input.wc-stripe-payment-type{display:none!important}body .wfacp_main_form.woocommerce .wc-stripe-save-source label.checkbox{padding:0!important}input[type=radio]+label.wc-stripe-label-payment-type,label.wc-stripe-label-klarna-category,label.wc-stripe-label-payment-type{margin-bottom:1em;display:block;padding:0!important;color:#000}.theme-flatsome div.wc-stripe-saved-methods-container{margin:0 0 1em 0}label.wc-stripe-label-klarna-category:before,label.wc-stripe-label-payment-type:before{content:"";display:inline-block;width:11px;height:11px;border:2px solid #fff;box-shadow:0 0 0 2px #000;background:#fff;margin-right:4px;margin-left:.5em;border-radius:100%;-webkit-transform:translateY(2px);-ms-transform:translateY(2px);transform:translateY(2px)}input.wc-stripe-klarna-category:checked+label.wc-stripe-label-klarna-category:before,input.wc-stripe-payment-type:checked+label.wc-stripe-label-payment-type:before{background:#000}label.wc-stripe-label-payment-type:after{content:none!important;display:none!important}.select2-results__options li.wc-stripe-select2-container,.wc-stripe-saved-methods-container .select2-container .select2-selection--single .wc-stripe-select2-container{display:flex;align-items:center;height:42px;line-height:42px!important}.select2-container .select2-selection--single .wc-stripe-select2-container:before,.select2-results__options li.wc-stripe-select2-container:before{content:'';background-repeat:no-repeat;background-size:40px 24px;width:40px;height:42px;display:inline-block;margin-left:8px;background-position:center}.select2-container .select2-selection--single .wc-stripe-select2-container.visa:before,.select2-results__options li.wc-stripe-select2-container.visa:before{background-image:url(../img/cards/visa.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.americanexpress:before,.select2-results__options li.wc-stripe-select2-container.americanexpress:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.amex:before,.select2-results__options li.wc-stripe-select2-container.amex:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.discover:before,.select2-results__options li.wc-stripe-select2-container.discover:before{background-image:url(../img/cards/discover.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.dinersclub:before,.select2-results__options li.wc-stripe-select2-container.dinersclub:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.diners:before,.select2-results__options li.wc-stripe-select2-container.diners:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.jcb:before,.select2-results__options li.wc-stripe-select2-container.jcb:before{background-image:url(../img/cards/jcb.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.stripe_sepa:before,.select2-results__options li.wc-stripe-select2-container.stripe_sepa:before{background-image:url(../img/sepa.svg)}.select2-results__options li.wc-stripe-select2-container.wc-stripe-ach:before{display:none}#wc-stripe-card-element{margin-bottom:1em}.wc-stripe_cc-new-method-container .wc-stripe-save-source{display:flex;align-items:center;justify-content:flex-start}.wc-stripe_cc-container .wc-stripe-save-source .save-source-label{display:block;padding:0;margin:0 5px 0 0}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]{opacity:0;position:absolute;width:20px;height:20px}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{position:relative}.wc-stripe_cc-container .save-source-checkbox{height:20px;width:20px;position:relative;background-color:#fff;display:block;border-radius:3px;border:1px solid #bababa}.wc-stripe_cc-container .save-source-checkbox:after{content:"";position:absolute;top:0;right:0}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]:checked+.save-source-checkbox:after{right:6px;top:2px;width:7px;height:12px;border:solid #2196f3;border-width:0 0 3px 3px;-webkit-transform:rotate(-45deg);-ms-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}li.payment_method_stripe_applepay,li.payment_method_stripe_googlepay,li.payment_method_stripe_payment_request{display:none}#payment #place_order.wc-stripe-hide,#place_order.wc-stripe-hide,.woocommerce-checkout-review-order #payment #place_order.wc-stripe-hide{position:absolute!important;z-index:-1000!important;height:0!important;padding:0!important;opacity:0!important}.wc-stripe-product-checkout-container{display:none;width:100%}.wc-stripe-product-checkout-container.bottom{margin-top:1em}.wc-stripe-product-checkout-container.top{margin-bottom:1em}.wc-stripe-product-checkout-container.active{display:block}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods,.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods{list-style:none;margin:0;padding:0}.wc-stripe-cart-checkout-container{margin:0;padding:0;clear:both}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods{margin-bottom:1.5em}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_],.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]{margin:0 0 1em 0}.wc_stripe_cart_payment_methods .gpay-button,.wc_stripe_cart_payment_methods .gpay-card-info-container,.wc_stripe_product_payment_methods .gpay-button,.wc_stripe_product_payment_methods .gpay-card-info-container{width:100%!important;margin:0}.wc_stripe_product_payment_methods .disabled{opacity:.45}.stripe_cart_gateway_active .checkout-button,.woocommerce-cart .stripe_cart_gateway_active .wc-proceed-to-checkout .checkout-button{margin-bottom:0}.wc-stripe-cart-or{margin:1em 0;text-align:center}li.wc-stripe-payment-method.or{display:none}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or{display:block;margin:15px 0}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or p{margin:0}li[class*=payment_method_stripe_].active~li.wc-stripe-payment-method.or{display:block;margin:0}li.payment_method_stripe_applepay label:first-of-type img{width:49px;max-height:32px}li.payment_method_stripe_googlepay label:first-of-type img{width:48px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_standard]{width:60px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_round_outline]{width:56px;max-height:30px}li.payment_method_stripe_ach label:first-of-type img{width:32px;height:32px;min-width:32px;min-height:32px}.gpay-button:hover{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:active{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:focus{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}@supports (-webkit-appearance:-apple-pay-button){.apple-pay-button{display:block;-webkit-appearance:-apple-pay-button;width:100%;max-width:100%;min-width:200px;height:40px;max-height:40px}.apple-pay-button-black{-apple-pay-button-style:#000}.apple-pay-button-white{-apple-pay-button-style:#fff}.apple-pay-button-white-with-line{-apple-pay-button-style:white-outline}.applepay-top-container .apple-pay-button{max-width:240px}.woocommerce-checkout-payment .apple-pay-button{max-width:240px}body.single-product div.product form.cart .wc_stripe_product_payment_methods .apple-pay-button{max-width:100%}}.wc-stripe-banner-checkout{display:none;padding:20px 15px 0 15px;border:1px solid #d1d1d1;border-width:0 0 1px;position:relative;margin:1em 0}.wc-stripe-banner-checkout.active{display:block}.wc-stripe-banner-checkout span.banner-title{position:absolute;display:flex;align-items:center;top:-13px;left:0;right:0;background:0 0;white-space:nowrap;font-size:16px}.wc-stripe-banner-checkout span.banner-title:after,.wc-stripe-banner-checkout span.banner-title:before{content:' ';height:1px;background:#d1d1d1;display:block;width:50%}.wc-stripe-banner-checkout span.banner-title:before{margin-left:8px}.wc-stripe-banner-checkout span.banner-title:after{margin-right:8px}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways{list-style:none;margin:0;padding:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway{margin:0 0 20px 0;display:none}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-card-info-container{margin:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-card-info-container{width:100%}.wc_stripe_cart_payment_methods .payment_method_stripe_payment_request .StripeElement,.wc_stripe_product_payment_methods .payment_method_stripe_payment_request .StripeElement{padding:0;width:100%}.woocommerce-checkout #wc-stripe-payment-request-container.StripeElement{width:240px;padding:0}.wc-stripe-checkout-banner-gateway #wc-stripe-payment-request-banner.StripeElement{width:100%}ul.payment_methods li.payment_method_stripe_p24 img{max-width:90px;width:90px;max-height:45px}ul.payment_methods li.payment_method_stripe_ideal img{max-width:38px;width:38px;max-height:35px}ul.payment_methods li.payment_method_stripe_fpx img{max-width:75px;width:75px;max-height:25px}ul.payment_methods li.payment_method_stripe_klarna img{max-width:72px;width:72px;max-height:20px}ul.payment_methods li.payment_method_stripe_giropay img{max-width:65px;width:65px;max-height:28px}ul.payment_methods li.payment_method_stripe_eps img{max-width:70px;width:70px;max-height:46px}ul.payment_methods li.payment_method_stripe_multibanco img{max-width:48px;width:48px;max-height:48px}ul.payment_methods li.payment_method_stripe_sepa img{max-width:67px;width:67px;max-height:18px}ul.payment_methods li.payment_method_stripe_sofort img{max-width:70px;width:70px;max-height:21px}label[for=payment_method_stripe_bancontact] img,ul.payment_methods li.payment_method_stripe_bancontact img{width:60px;height:42px;max-width:60px;max-height:42px}ul.payment_methods li.payment_method_stripe_wechat label img{max-width:82px;width:82px;max-height:23px}ul.payment_methods li.payment_method_stripe_alipay img{max-width:72px;width:72px;height:36px;max-height:36px}ul.payment_methods li.payment_method_stripe_grabpay img{max-width:95px;width:95px;max-height:28px}#wc-stripe-card-element{width:100%}li.banner_payment_method_stripe_payment_request .StripeElement{padding:0}.single-product .blockMsg{border:none!important;background-color:transparent!important}#wc-stripe-card{position:absolute!important;top:50%;left:8px;transform:translatey(-50%);width:23px;height:15px;padding:0;border:none}#wc-stripe-card.active{width:32px;height:20px}input[id=stripe-postal-code]:focus{outline:0;background:0 0;border:none;box-shadow:none}div.postalCode:focus{outline:0;border:none}li[class*=payment_method_stripe] .select2-container .select2-selection--single{height:42px;padding:0 5px}li[class*=payment_method_stripe] .select2-container--default .select2-selection--single .select2-selection__arrow{height:42px;top:1px;left:1px;transform:translateY(0)}.blockUI.blockMsg{font-size:20px;white-space:nowrap}#wc-stripe-payment-request-container.disabled{opacity:.45}.wc-stripe-paymentRequest-icons-container img{float:none}.select2-container .select2-selection--single .wc-stripe-select2-container.wc-stripe-ach:before{display:none}ul.wc_stripe_cart_payment_methods li.wc-stripe-payment-method button,ul.wc_stripe_checkout_banner_gateways li button,ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_] button{margin:0}ul.payment_methods li[class*=payment_method]{margin:0;padding:10px 0}ul.payment_methods li[class*=payment_method] input[name=payment_method]{margin:0 5px 0 10px;float:none}ul.payment_methods li[class*=payment_method]>input[name=payment_method]+label{padding-top:0;padding-left:0;padding-bottom:0}ul.payment_methods{list-style:none}ul.payment_methods li[class*=payment_method_stripe_] .wc-stripe_cc-new-method-container label:before{display:none}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{padding:0!important;margin:0}div[id*=wc_stripe_local_payment_stripe_].StripeElement{border:1px solid #eee;border-radius:4px}.qrcode-message{margin:10px 0 0 0}#wc_stripe_local_payment_stripe_becs,#wc_stripe_local_payment_stripe_sepa{padding:10px 12px;box-shadow:0 1px 3px 0 #e6ebf1}.wc-stripe-local-desc.stripe_becs,.wc-stripe-local-desc.stripe_sepa{margin:10px 0}.wc-stripe-clear{clear:both;height:0;visibility:hidden}.wc-stripe-gateway-desc p{margin:0}#wc_stripe_local_payment_stripe_klarna,li[class*=payment_method_stripe_] div.wc-stripe-gateway-container.has_tokens{margin-top:10px}.wc-stripe-gateway-desc{margin-top:10px}#wc-stripe-card-element.StripeElement--webkit-autofill{background-color:transparent!important}#wc_stripe_local_payment_stripe_klarna .stripe-klarna-categories{list-style:none;margin:0;padding:10px}li.payment_method_stripe_alipay,li.payment_method_stripe_bancontact,li.payment_method_stripe_becs,li.payment_method_stripe_eps,li.payment_method_stripe_fpx,li.payment_method_stripe_giropay,li.payment_method_stripe_ideal,li.payment_method_stripe_klarna,li.payment_method_stripe_multibanco,li.payment_method_stripe_p24,li.payment_method_stripe_sepa,li.payment_method_stripe_sofort,li.payment_method_stripe_wechat{display:none}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods{list-style:none;margin:0;padding:0}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods li{margin:0}.widget_shopping_cart_content a.wc-stripe-applepay-mini-cart,.widget_shopping_cart_content a.wc-stripe-gpay-mini-cart,.widget_shopping_cart_content a.wc-stripe-payment-request-mini-cart{background:0 0;padding:0;border:none}a.wc-stripe-gpay-mini-cart .gpay-button,a.wc-stripe-gpay-mini-cart .gpay-card-info-container a.wc-stripe-applepay-mini-cart .apple-pay-button{width:100%;margin:0}.wc-stripe-payment-request-mini-cart.StripeElement{padding:0;background:0 0;border:none;width:100%}.wc-stripe-payment-request-mini-cart.StripeElement .__PrivateStripeElement{width:100%}.widget_shopping_cart_content .wc-stripe-overlay{display:none!important;position:absolute;background:rgba(255,255,255,.75);height:100%;width:100%;z-index:-1}.widget_shopping_cart_content .wc-stripe-overlay.active{display:block!important;z-index:9999}.wc-stripe-klarna-loader{display:flex;justify-content:center;position:relative;width:100%;height:30px;box-sizing:border-box;transform:scale(.65)}.wc-stripe-klarna-loader div{box-sizing:border-box;display:block;position:absolute;box-sizing:border-box;width:30px;height:30px;border:3px solid #000;border-radius:50%;animation:klarna-payments-loader 1.3s cubic-bezier(.5,0,.5,1) infinite;border-color:#000 transparent transparent transparent}.wc-stripe-klarna-loader div:nth-child(1){animation-delay:-.45s}.wc-stripe-klarna-loader div:nth-child(2){animation-delay:-.3s}.wc-stripe-klarna-loader div:nth-child(3){animation-delay:-.15s}@keyframes klarna-payments-loader{0%{transform:rotate(0)}100%{transform:rotate(-360deg)}}li.payment_method_stripe_alipay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_applepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_bancontact.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_eps.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_giropay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_googlepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_grabpay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_multibanco.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_p24.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_payment_request.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_sofort.wc-stripe-no-desc .payment_box.wc-stripe-no-methods{padding:0;margin:0}
1
+ .wc-stripe-card-icons-container,.wc-stripe-paymentRequest-icons-container{float:left;display:inline-block}ul.payment_methods li[class*=payment_method]{margin:0;padding:0}li[class*=payment_method] input[type=radio]{margin:0 5px 0 10px}li[class*=payment_method] input[type=radio]+label:not(.wc-stripe-label-payment-type){margin:0}.woocommerce-checkout #payment ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2),ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2){margin:0}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon,li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{max-width:44px;max-height:27px;width:44px;height:27px;float:none;display:inline}li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{width:25px;height:25px;max-width:25px;max-height:25px}ul.payment_methods label[for*=payment_method_stripe]:after{clear:left;content:"";display:block}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon:nth-child(2n+2){margin:0 2px}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon.open.visa{padding-top:2px}ul.payment_methods li[class*=payment_method_stripe_] label>img:first-of-type{float:left!important}.wc-stripe_cc-new-method-container{margin-bottom:1em}.wc-stripe_cc-container .StripeElement{box-sizing:border-box;height:40px;padding:10px 12px;border-radius:4px;background-color:#fff;-webkit-transition:box-shadow 150ms ease;transition:box-shadow 150ms ease}input.wc-stripe-klarna-category,input.wc-stripe-payment-type{display:none!important}body .wfacp_main_form.woocommerce .wc-stripe-save-source label.checkbox{padding:0!important}input[type=radio]+label.wc-stripe-label-payment-type,label.wc-stripe-label-klarna-category,label.wc-stripe-label-payment-type{margin-bottom:1em;display:block;padding:0!important;color:#000}.theme-flatsome div.wc-stripe-saved-methods-container{margin:0 0 1em 0}label.wc-stripe-label-klarna-category:before,label.wc-stripe-label-payment-type:before{content:"";display:inline-block;width:11px;height:11px;border:2px solid #fff;box-shadow:0 0 0 2px #000;background:#fff;margin-right:4px;margin-left:.5em;border-radius:100%;-webkit-transform:translateY(2px);-ms-transform:translateY(2px);transform:translateY(2px)}input.wc-stripe-klarna-category:checked+label.wc-stripe-label-klarna-category:before,input.wc-stripe-payment-type:checked+label.wc-stripe-label-payment-type:before{background:#000}label.wc-stripe-label-payment-type:after{content:none!important;display:none!important}.select2-results__options li.wc-stripe-select2-container,.wc-stripe-saved-methods-container .select2-container .select2-selection--single .wc-stripe-select2-container{display:flex;align-items:center;height:42px;line-height:42px!important}.select2-container .select2-selection--single .wc-stripe-select2-container:before,.select2-results__options li.wc-stripe-select2-container:before{content:'';background-repeat:no-repeat;background-size:40px 24px;width:40px;height:42px;display:inline-block;margin-left:8px;background-position:center}.select2-container .select2-selection--single .wc-stripe-select2-container.visa:before,.select2-results__options li.wc-stripe-select2-container.visa:before{background-image:url(../img/cards/visa.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.americanexpress:before,.select2-results__options li.wc-stripe-select2-container.americanexpress:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.amex:before,.select2-results__options li.wc-stripe-select2-container.amex:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.discover:before,.select2-results__options li.wc-stripe-select2-container.discover:before{background-image:url(../img/cards/discover.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.dinersclub:before,.select2-results__options li.wc-stripe-select2-container.dinersclub:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.diners:before,.select2-results__options li.wc-stripe-select2-container.diners:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.jcb:before,.select2-results__options li.wc-stripe-select2-container.jcb:before{background-image:url(../img/cards/jcb.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.stripe_sepa:before,.select2-results__options li.wc-stripe-select2-container.stripe_sepa:before{background-image:url(../img/sepa.svg)}.select2-results__options li.wc-stripe-select2-container.wc-stripe-ach:before{display:none}#wc-stripe-card-element{margin-bottom:1em}.wc-stripe_cc-new-method-container .wc-stripe-save-source{display:flex;align-items:center;justify-content:flex-start}.wc-stripe_cc-container .wc-stripe-save-source .save-source-label{display:block;padding:0;margin:0 5px 0 0}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]{opacity:0;position:absolute;width:20px;height:20px}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{position:relative}.wc-stripe_cc-container .save-source-checkbox{height:20px;width:20px;position:relative;background-color:#fff;display:block;border-radius:3px;border:1px solid #bababa}.wc-stripe_cc-container .save-source-checkbox:after{content:"";position:absolute;top:0;right:0}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]:checked+.save-source-checkbox:after{right:6px;top:2px;width:7px;height:12px;border:solid #2196f3;border-width:0 0 3px 3px;-webkit-transform:rotate(-45deg);-ms-transform:rotate(-45deg);transform:rotate(-45deg);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}li.payment_method_stripe_applepay,li.payment_method_stripe_googlepay,li.payment_method_stripe_payment_request{display:none}#payment #place_order.wc-stripe-hide,#place_order.wc-stripe-hide,.woocommerce-checkout-review-order #payment #place_order.wc-stripe-hide{position:absolute!important;z-index:-1000!important;height:0!important;padding:0!important;opacity:0!important}.wc-stripe-product-checkout-container{display:none;width:100%}.wc-stripe-product-checkout-container.bottom{margin-top:1em}.wc-stripe-product-checkout-container.top{margin-bottom:1em}.wc-stripe-product-checkout-container.active{display:block}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods,.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods{list-style:none;margin:0;padding:0}.wc-stripe-cart-checkout-container{margin:0;padding:0;clear:both}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods{margin-bottom:1.5em}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_],.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]{margin:0 0 1em 0}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_]:last-child,.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]:last-child{margin:0}.wc_stripe_cart_payment_methods .gpay-button,.wc_stripe_cart_payment_methods .gpay-card-info-container,.wc_stripe_product_payment_methods .gpay-button,.wc_stripe_product_payment_methods .gpay-card-info-container{width:100%!important;margin:0}.wc_stripe_product_payment_methods .disabled{opacity:.45}.stripe_cart_gateway_active .checkout-button,.woocommerce-cart .stripe_cart_gateway_active .wc-proceed-to-checkout .checkout-button{margin-bottom:0}.wc-stripe-cart-or{margin:1em 0;text-align:center}li.wc-stripe-payment-method.or{display:none}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or{display:block;margin:15px 0}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or p{margin:0}li[class*=payment_method_stripe_].active~li.wc-stripe-payment-method.or{display:block;margin:0}li.payment_method_stripe_applepay label:first-of-type img{width:49px;max-height:32px}li.payment_method_stripe_googlepay label:first-of-type img{width:48px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_standard]{width:60px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_round_outline]{width:56px;max-height:30px}li.payment_method_stripe_ach label:first-of-type img{width:32px;height:32px;min-width:32px;min-height:32px}.gpay-button:hover{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:active{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:focus{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}@supports (-webkit-appearance:-apple-pay-button){.apple-pay-button{display:block;-webkit-appearance:-apple-pay-button;width:100%;max-width:100%;min-width:200px;height:40px;max-height:40px}.apple-pay-button-black{-apple-pay-button-style:#000}.apple-pay-button-white{-apple-pay-button-style:#fff}.apple-pay-button-white-with-line{-apple-pay-button-style:white-outline}.applepay-top-container .apple-pay-button{max-width:240px}.woocommerce-checkout-payment .apple-pay-button{max-width:240px}body.single-product div.product form.cart .wc_stripe_product_payment_methods .apple-pay-button{max-width:100%}}.wc-stripe-banner-checkout{display:none;padding:20px 15px 0 15px;border:1px solid #d1d1d1;border-width:0 0 1px;position:relative;margin:1em 0}.wc-stripe-banner-checkout.active{display:block}.wc-stripe-banner-checkout span.banner-title{position:absolute;display:flex;align-items:center;top:-13px;left:0;right:0;background:0 0;white-space:nowrap;font-size:16px}.wc-stripe-banner-checkout span.banner-title:after,.wc-stripe-banner-checkout span.banner-title:before{content:' ';height:1px;background:#d1d1d1;display:block;width:50%}.wc-stripe-banner-checkout span.banner-title:before{margin-left:8px}.wc-stripe-banner-checkout span.banner-title:after{margin-right:8px}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways{list-style:none;margin:0;padding:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway{margin:0 0 20px 0;display:none}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-card-info-container{margin:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-card-info-container{width:100%}.wc_stripe_cart_payment_methods .payment_method_stripe_payment_request .StripeElement,.wc_stripe_product_payment_methods .payment_method_stripe_payment_request .StripeElement{padding:0;width:100%}.woocommerce-checkout #wc-stripe-payment-request-container.StripeElement{width:240px;padding:0}.wc-stripe-checkout-banner-gateway #wc-stripe-payment-request-banner.StripeElement{width:100%}ul.payment_methods li.payment_method_stripe_p24 img{max-width:90px;width:90px;max-height:45px}ul.payment_methods li.payment_method_stripe_ideal img{max-width:38px;width:38px;max-height:35px}ul.payment_methods li.payment_method_stripe_fpx img{max-width:75px;width:75px;max-height:25px}ul.payment_methods li.payment_method_stripe_klarna img{max-width:72px;width:72px;max-height:20px}ul.payment_methods li.payment_method_stripe_giropay img{max-width:65px;width:65px;max-height:28px}ul.payment_methods li.payment_method_stripe_eps img{max-width:70px;width:70px;max-height:46px}ul.payment_methods li.payment_method_stripe_multibanco img{max-width:48px;width:48px;max-height:48px}ul.payment_methods li.payment_method_stripe_sepa img{max-width:67px;width:67px;max-height:18px}ul.payment_methods li.payment_method_stripe_sofort img{max-width:70px;width:70px;max-height:21px}label[for=payment_method_stripe_bancontact] img,ul.payment_methods li.payment_method_stripe_bancontact img{width:60px;height:42px;max-width:60px;max-height:42px}ul.payment_methods li.payment_method_stripe_wechat label img{max-width:82px;width:82px;max-height:23px}ul.payment_methods li.payment_method_stripe_alipay img{max-width:72px;width:72px;height:36px;max-height:36px}ul.payment_methods li.payment_method_stripe_grabpay img{max-width:95px;width:95px;max-height:28px}#wc-stripe-card-element{width:100%}li.banner_payment_method_stripe_payment_request .StripeElement{padding:0}.single-product .blockMsg{border:none!important;background-color:transparent!important}#wc-stripe-card{position:absolute!important;top:50%;left:8px;transform:translatey(-50%);width:23px;height:15px;padding:0;border:none}#wc-stripe-card.active{width:32px;height:20px}input[id=stripe-postal-code]:focus{outline:0;background:0 0;border:none;box-shadow:none}div.postalCode:focus{outline:0;border:none}li[class*=payment_method_stripe] .select2-container .select2-selection--single{height:42px;padding:0 5px}li[class*=payment_method_stripe] .select2-container--default .select2-selection--single .select2-selection__arrow{height:42px;top:1px;left:1px;transform:translateY(0)}.blockUI.blockMsg{font-size:20px;white-space:nowrap}#wc-stripe-payment-request-container.disabled{opacity:.45}.wc-stripe-paymentRequest-icons-container img{float:none}.select2-container .select2-selection--single .wc-stripe-select2-container.wc-stripe-ach:before{display:none}ul.wc_stripe_cart_payment_methods li.wc-stripe-payment-method button,ul.wc_stripe_checkout_banner_gateways li button,ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_] button{margin:0}ul.payment_methods li[class*=payment_method]{margin:0;padding:10px 0}ul.payment_methods li[class*=payment_method] input[name=payment_method]{margin:0 5px 0 10px;float:none}ul.payment_methods li[class*=payment_method]>input[name=payment_method]+label{padding-top:0;padding-left:0;padding-bottom:0}ul.payment_methods{list-style:none}ul.payment_methods li[class*=payment_method_stripe_] .wc-stripe_cc-new-method-container label:before{display:none}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{padding:0!important;margin:0}div[id*=wc_stripe_local_payment_stripe_].StripeElement{border:1px solid #eee;border-radius:4px}.qrcode-message{margin:10px 0 0 0}#wc_stripe_local_payment_stripe_becs,#wc_stripe_local_payment_stripe_sepa{padding:10px 12px;box-shadow:0 1px 3px 0 #e6ebf1}.wc-stripe-local-desc.stripe_becs,.wc-stripe-local-desc.stripe_sepa{margin:10px 0}.wc-stripe-clear{clear:both;height:0;visibility:hidden}.wc-stripe-gateway-desc p{margin:0}#wc_stripe_local_payment_stripe_klarna,li[class*=payment_method_stripe_] div.wc-stripe-gateway-container.has_tokens{margin-top:10px}.wc-stripe-gateway-desc{margin-top:10px}#wc-stripe-card-element.StripeElement--webkit-autofill{background-color:transparent!important}#wc_stripe_local_payment_stripe_klarna .stripe-klarna-categories{list-style:none;margin:0;padding:10px}li.payment_method_stripe_alipay,li.payment_method_stripe_bancontact,li.payment_method_stripe_becs,li.payment_method_stripe_eps,li.payment_method_stripe_fpx,li.payment_method_stripe_giropay,li.payment_method_stripe_ideal,li.payment_method_stripe_klarna,li.payment_method_stripe_multibanco,li.payment_method_stripe_p24,li.payment_method_stripe_sepa,li.payment_method_stripe_sofort,li.payment_method_stripe_wechat{display:none}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods{list-style:none;margin:0;padding:0}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods li{margin:0}.widget_shopping_cart_content a.wc-stripe-applepay-mini-cart,.widget_shopping_cart_content a.wc-stripe-gpay-mini-cart,.widget_shopping_cart_content a.wc-stripe-payment-request-mini-cart{background:0 0;padding:0;border:none}a.wc-stripe-gpay-mini-cart .gpay-button,a.wc-stripe-gpay-mini-cart .gpay-card-info-container a.wc-stripe-applepay-mini-cart .apple-pay-button{width:100%;margin:0}.wc-stripe-payment-request-mini-cart.StripeElement{padding:0;background:0 0;border:none;width:100%}.wc-stripe-payment-request-mini-cart.StripeElement .__PrivateStripeElement{width:100%}.widget_shopping_cart_content .wc-stripe-overlay{display:none!important;position:absolute;background:rgba(255,255,255,.75);height:100%;width:100%;z-index:-1}.widget_shopping_cart_content .wc-stripe-overlay.active{display:block!important;z-index:9999}.wc-stripe-klarna-loader{display:flex;justify-content:center;position:relative;width:100%;height:30px;box-sizing:border-box;transform:scale(.65)}.wc-stripe-klarna-loader div{box-sizing:border-box;display:block;position:absolute;box-sizing:border-box;width:30px;height:30px;border:3px solid #000;border-radius:50%;animation:klarna-payments-loader 1.3s cubic-bezier(.5,0,.5,1) infinite;border-color:#000 transparent transparent transparent}.wc-stripe-klarna-loader div:nth-child(1){animation-delay:-.45s}.wc-stripe-klarna-loader div:nth-child(2){animation-delay:-.3s}.wc-stripe-klarna-loader div:nth-child(3){animation-delay:-.15s}@keyframes klarna-payments-loader{0%{transform:rotate(0)}100%{transform:rotate(-360deg)}}li.payment_method_stripe_alipay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_applepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_bancontact.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_eps.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_giropay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_googlepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_grabpay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_multibanco.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_p24.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_payment_request.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_sofort.wc-stripe-no-desc .payment_box.wc-stripe-no-methods{padding:0;margin:0}
assets/css/stripe.min.css CHANGED
@@ -1 +1 @@
1
- .wc-stripe-card-icons-container,.wc-stripe-paymentRequest-icons-container{float:right;display:inline-block}ul.payment_methods li[class*=payment_method]{margin:0;padding:0}li[class*=payment_method] input[type=radio]{margin:0 10px 0 5px}li[class*=payment_method] input[type=radio]+label:not(.wc-stripe-label-payment-type){margin:0}.woocommerce-checkout #payment ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2),ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2){margin:0}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon,li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{max-width:44px;max-height:27px;width:44px;height:27px;float:none;display:inline}li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{width:25px;height:25px;max-width:25px;max-height:25px}ul.payment_methods label[for*=payment_method_stripe]:after{clear:right;content:"";display:block}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon:nth-child(2n+2){margin:0 2px}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon.open.visa{padding-top:2px}ul.payment_methods li[class*=payment_method_stripe_] label>img:first-of-type{float:right!important}.wc-stripe_cc-new-method-container{margin-bottom:1em}.wc-stripe_cc-container .StripeElement{box-sizing:border-box;height:40px;padding:10px 12px;border-radius:4px;background-color:#fff;-webkit-transition:box-shadow 150ms ease;transition:box-shadow 150ms ease}input.wc-stripe-klarna-category,input.wc-stripe-payment-type{display:none!important}body .wfacp_main_form.woocommerce .wc-stripe-save-source label.checkbox{padding:0!important}input[type=radio]+label.wc-stripe-label-payment-type,label.wc-stripe-label-klarna-category,label.wc-stripe-label-payment-type{margin-bottom:1em;display:block;padding:0!important;color:#000}.theme-flatsome div.wc-stripe-saved-methods-container{margin:0 0 1em 0}label.wc-stripe-label-klarna-category:before,label.wc-stripe-label-payment-type:before{content:"";display:inline-block;width:11px;height:11px;border:2px solid #fff;box-shadow:0 0 0 2px #000;background:#fff;margin-left:4px;margin-right:.5em;border-radius:100%;-webkit-transform:translateY(2px);-ms-transform:translateY(2px);transform:translateY(2px)}input.wc-stripe-klarna-category:checked+label.wc-stripe-label-klarna-category:before,input.wc-stripe-payment-type:checked+label.wc-stripe-label-payment-type:before{background:#000}label.wc-stripe-label-payment-type:after{content:none!important;display:none!important}.select2-results__options li.wc-stripe-select2-container,.wc-stripe-saved-methods-container .select2-container .select2-selection--single .wc-stripe-select2-container{display:flex;align-items:center;height:42px;line-height:42px!important}.select2-container .select2-selection--single .wc-stripe-select2-container:before,.select2-results__options li.wc-stripe-select2-container:before{content:'';background-repeat:no-repeat;background-size:40px 24px;width:40px;height:42px;display:inline-block;margin-right:8px;background-position:center}.select2-container .select2-selection--single .wc-stripe-select2-container.visa:before,.select2-results__options li.wc-stripe-select2-container.visa:before{background-image:url(../img/cards/visa.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.americanexpress:before,.select2-results__options li.wc-stripe-select2-container.americanexpress:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.amex:before,.select2-results__options li.wc-stripe-select2-container.amex:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.discover:before,.select2-results__options li.wc-stripe-select2-container.discover:before{background-image:url(../img/cards/discover.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.dinersclub:before,.select2-results__options li.wc-stripe-select2-container.dinersclub:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.diners:before,.select2-results__options li.wc-stripe-select2-container.diners:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.jcb:before,.select2-results__options li.wc-stripe-select2-container.jcb:before{background-image:url(../img/cards/jcb.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.stripe_sepa:before,.select2-results__options li.wc-stripe-select2-container.stripe_sepa:before{background-image:url(../img/sepa.svg)}.select2-results__options li.wc-stripe-select2-container.wc-stripe-ach:before{display:none}#wc-stripe-card-element{margin-bottom:1em}.wc-stripe_cc-new-method-container .wc-stripe-save-source{display:flex;align-items:center;justify-content:flex-start}.wc-stripe_cc-container .wc-stripe-save-source .save-source-label{display:block;padding:0;margin:0 0 0 5px}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]{opacity:0;position:absolute;width:20px;height:20px}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{position:relative}.wc-stripe_cc-container .save-source-checkbox{height:20px;width:20px;position:relative;background-color:#fff;display:block;border-radius:3px;border:1px solid #bababa}.wc-stripe_cc-container .save-source-checkbox:after{content:"";position:absolute;top:0;left:0}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]:checked+.save-source-checkbox:after{left:6px;top:2px;width:7px;height:12px;border:solid #2196f3;border-width:0 3px 3px 0;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}li.payment_method_stripe_applepay,li.payment_method_stripe_googlepay,li.payment_method_stripe_payment_request{display:none}#payment #place_order.wc-stripe-hide,#place_order.wc-stripe-hide,.woocommerce-checkout-review-order #payment #place_order.wc-stripe-hide{position:absolute!important;z-index:-1000!important;height:0!important;padding:0!important;opacity:0!important}.wc-stripe-product-checkout-container{display:none;width:100%}.wc-stripe-product-checkout-container.bottom{margin-top:1em}.wc-stripe-product-checkout-container.top{margin-bottom:1em}.wc-stripe-product-checkout-container.active{display:block}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods,.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods{list-style:none;margin:0;padding:0}.wc-stripe-cart-checkout-container{margin:0;padding:0;clear:both}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods{margin-bottom:1.5em}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_],.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]{margin:0 0 1em 0}.wc_stripe_cart_payment_methods .gpay-button,.wc_stripe_cart_payment_methods .gpay-card-info-container,.wc_stripe_product_payment_methods .gpay-button,.wc_stripe_product_payment_methods .gpay-card-info-container{width:100%!important;margin:0}.wc_stripe_product_payment_methods .disabled{opacity:.45}.stripe_cart_gateway_active .checkout-button,.woocommerce-cart .stripe_cart_gateway_active .wc-proceed-to-checkout .checkout-button{margin-bottom:0}.wc-stripe-cart-or{margin:1em 0;text-align:center}li.wc-stripe-payment-method.or{display:none}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or{display:block;margin:15px 0}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or p{margin:0}li[class*=payment_method_stripe_].active~li.wc-stripe-payment-method.or{display:block;margin:0}li.payment_method_stripe_applepay label:first-of-type img{width:49px;max-height:32px}li.payment_method_stripe_googlepay label:first-of-type img{width:48px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_standard]{width:60px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_round_outline]{width:56px;max-height:30px}li.payment_method_stripe_ach label:first-of-type img{width:32px;height:32px;min-width:32px;min-height:32px}.gpay-button:hover{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:active{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:focus{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}@supports (-webkit-appearance:-apple-pay-button){.apple-pay-button{display:block;-webkit-appearance:-apple-pay-button;width:100%;max-width:100%;min-width:200px;height:40px;max-height:40px}.apple-pay-button-black{-apple-pay-button-style:#000}.apple-pay-button-white{-apple-pay-button-style:#fff}.apple-pay-button-white-with-line{-apple-pay-button-style:white-outline}.applepay-top-container .apple-pay-button{max-width:240px}.woocommerce-checkout-payment .apple-pay-button{max-width:240px}body.single-product div.product form.cart .wc_stripe_product_payment_methods .apple-pay-button{max-width:100%}}.wc-stripe-banner-checkout{display:none;padding:20px 15px 0 15px;border:1px solid #d1d1d1;border-width:0 0 1px;position:relative;margin:1em 0}.wc-stripe-banner-checkout.active{display:block}.wc-stripe-banner-checkout span.banner-title{position:absolute;display:flex;align-items:center;top:-13px;right:0;left:0;background:0 0;white-space:nowrap;font-size:16px}.wc-stripe-banner-checkout span.banner-title:after,.wc-stripe-banner-checkout span.banner-title:before{content:' ';height:1px;background:#d1d1d1;display:block;width:50%}.wc-stripe-banner-checkout span.banner-title:before{margin-right:8px}.wc-stripe-banner-checkout span.banner-title:after{margin-left:8px}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways{list-style:none;margin:0;padding:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway{margin:0 0 20px 0;display:none}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-card-info-container{margin:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-card-info-container{width:100%}.wc_stripe_cart_payment_methods .payment_method_stripe_payment_request .StripeElement,.wc_stripe_product_payment_methods .payment_method_stripe_payment_request .StripeElement{padding:0;width:100%}.woocommerce-checkout #wc-stripe-payment-request-container.StripeElement{width:240px;padding:0}.wc-stripe-checkout-banner-gateway #wc-stripe-payment-request-banner.StripeElement{width:100%}ul.payment_methods li.payment_method_stripe_p24 img{max-width:90px;width:90px;max-height:45px}ul.payment_methods li.payment_method_stripe_ideal img{max-width:38px;width:38px;max-height:35px}ul.payment_methods li.payment_method_stripe_fpx img{max-width:75px;width:75px;max-height:25px}ul.payment_methods li.payment_method_stripe_klarna img{max-width:72px;width:72px;max-height:20px}ul.payment_methods li.payment_method_stripe_giropay img{max-width:65px;width:65px;max-height:28px}ul.payment_methods li.payment_method_stripe_eps img{max-width:70px;width:70px;max-height:46px}ul.payment_methods li.payment_method_stripe_multibanco img{max-width:48px;width:48px;max-height:48px}ul.payment_methods li.payment_method_stripe_sepa img{max-width:67px;width:67px;max-height:18px}ul.payment_methods li.payment_method_stripe_sofort img{max-width:70px;width:70px;max-height:21px}label[for=payment_method_stripe_bancontact] img,ul.payment_methods li.payment_method_stripe_bancontact img{width:60px;height:42px;max-width:60px;max-height:42px}ul.payment_methods li.payment_method_stripe_wechat label img{max-width:82px;width:82px;max-height:23px}ul.payment_methods li.payment_method_stripe_alipay img{max-width:72px;width:72px;height:36px;max-height:36px}ul.payment_methods li.payment_method_stripe_grabpay img{max-width:95px;width:95px;max-height:28px}#wc-stripe-card-element{width:100%}li.banner_payment_method_stripe_payment_request .StripeElement{padding:0}.single-product .blockMsg{border:none!important;background-color:transparent!important}#wc-stripe-card{position:absolute!important;top:50%;right:8px;transform:translatey(-50%);width:23px;height:15px;padding:0;border:none}#wc-stripe-card.active{width:32px;height:20px}input[id=stripe-postal-code]:focus{outline:0;background:0 0;border:none;box-shadow:none}div.postalCode:focus{outline:0;border:none}li[class*=payment_method_stripe] .select2-container .select2-selection--single{height:42px;padding:0 5px}li[class*=payment_method_stripe] .select2-container--default .select2-selection--single .select2-selection__arrow{height:42px;top:1px;right:1px;transform:translateY(0)}.blockUI.blockMsg{font-size:20px;white-space:nowrap}#wc-stripe-payment-request-container.disabled{opacity:.45}.wc-stripe-paymentRequest-icons-container img{float:none}.select2-container .select2-selection--single .wc-stripe-select2-container.wc-stripe-ach:before{display:none}ul.wc_stripe_cart_payment_methods li.wc-stripe-payment-method button,ul.wc_stripe_checkout_banner_gateways li button,ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_] button{margin:0}ul.payment_methods li[class*=payment_method]{margin:0;padding:10px 0}ul.payment_methods li[class*=payment_method] input[name=payment_method]{margin:0 10px 0 5px;float:none}ul.payment_methods li[class*=payment_method]>input[name=payment_method]+label{padding-top:0;padding-right:0;padding-bottom:0}ul.payment_methods{list-style:none}ul.payment_methods li[class*=payment_method_stripe_] .wc-stripe_cc-new-method-container label:before{display:none}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{padding:0!important;margin:0}div[id*=wc_stripe_local_payment_stripe_].StripeElement{border:1px solid #eee;border-radius:4px}.qrcode-message{margin:10px 0 0 0}#wc_stripe_local_payment_stripe_becs,#wc_stripe_local_payment_stripe_sepa{padding:10px 12px;box-shadow:0 1px 3px 0 #e6ebf1}.wc-stripe-local-desc.stripe_becs,.wc-stripe-local-desc.stripe_sepa{margin:10px 0}.wc-stripe-clear{clear:both;height:0;visibility:hidden}.wc-stripe-gateway-desc p{margin:0}#wc_stripe_local_payment_stripe_klarna,li[class*=payment_method_stripe_] div.wc-stripe-gateway-container.has_tokens{margin-top:10px}.wc-stripe-gateway-desc{margin-top:10px}#wc-stripe-card-element.StripeElement--webkit-autofill{background-color:transparent!important}#wc_stripe_local_payment_stripe_klarna .stripe-klarna-categories{list-style:none;margin:0;padding:10px}li.payment_method_stripe_alipay,li.payment_method_stripe_bancontact,li.payment_method_stripe_becs,li.payment_method_stripe_eps,li.payment_method_stripe_fpx,li.payment_method_stripe_giropay,li.payment_method_stripe_ideal,li.payment_method_stripe_klarna,li.payment_method_stripe_multibanco,li.payment_method_stripe_p24,li.payment_method_stripe_sepa,li.payment_method_stripe_sofort,li.payment_method_stripe_wechat{display:none}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods{list-style:none;margin:0;padding:0}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods li{margin:0}.widget_shopping_cart_content a.wc-stripe-applepay-mini-cart,.widget_shopping_cart_content a.wc-stripe-gpay-mini-cart,.widget_shopping_cart_content a.wc-stripe-payment-request-mini-cart{background:0 0;padding:0;border:none}a.wc-stripe-gpay-mini-cart .gpay-button,a.wc-stripe-gpay-mini-cart .gpay-card-info-container a.wc-stripe-applepay-mini-cart .apple-pay-button{width:100%;margin:0}.wc-stripe-payment-request-mini-cart.StripeElement{padding:0;background:0 0;border:none;width:100%}.wc-stripe-payment-request-mini-cart.StripeElement .__PrivateStripeElement{width:100%}.widget_shopping_cart_content .wc-stripe-overlay{display:none!important;position:absolute;background:rgba(255,255,255,.75);height:100%;width:100%;z-index:-1}.widget_shopping_cart_content .wc-stripe-overlay.active{display:block!important;z-index:9999}.wc-stripe-klarna-loader{display:flex;justify-content:center;position:relative;width:100%;height:30px;box-sizing:border-box;transform:scale(.65)}.wc-stripe-klarna-loader div{box-sizing:border-box;display:block;position:absolute;box-sizing:border-box;width:30px;height:30px;border:3px solid #000;border-radius:50%;animation:klarna-payments-loader 1.3s cubic-bezier(.5,0,.5,1) infinite;border-color:#000 transparent transparent transparent}.wc-stripe-klarna-loader div:nth-child(1){animation-delay:-.45s}.wc-stripe-klarna-loader div:nth-child(2){animation-delay:-.3s}.wc-stripe-klarna-loader div:nth-child(3){animation-delay:-.15s}@keyframes klarna-payments-loader{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}li.payment_method_stripe_alipay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_applepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_bancontact.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_eps.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_giropay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_googlepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_grabpay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_multibanco.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_p24.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_payment_request.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_sofort.wc-stripe-no-desc .payment_box.wc-stripe-no-methods{padding:0;margin:0}
1
+ .wc-stripe-card-icons-container,.wc-stripe-paymentRequest-icons-container{float:right;display:inline-block}ul.payment_methods li[class*=payment_method]{margin:0;padding:0}li[class*=payment_method] input[type=radio]{margin:0 10px 0 5px}li[class*=payment_method] input[type=radio]+label:not(.wc-stripe-label-payment-type){margin:0}.woocommerce-checkout #payment ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2),ul.payment_methods li[class*=payment_method_stripe_]:nth-child(n+2){margin:0}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon,li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{max-width:44px;max-height:27px;width:44px;height:27px;float:none;display:inline}li.payment_method_stripe_payment_request .wc-stripe-paymentRequest-icons-container img{width:25px;height:25px;max-width:25px;max-height:25px}ul.payment_methods label[for*=payment_method_stripe]:after{clear:right;content:"";display:block}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon:nth-child(2n+2){margin:0 2px}li.payment_method_stripe_cc .wc-stripe-card-icons-container img.wc-stripe-card-icon.open.visa{padding-top:2px}ul.payment_methods li[class*=payment_method_stripe_] label>img:first-of-type{float:right!important}.wc-stripe_cc-new-method-container{margin-bottom:1em}.wc-stripe_cc-container .StripeElement{box-sizing:border-box;height:40px;padding:10px 12px;border-radius:4px;background-color:#fff;-webkit-transition:box-shadow 150ms ease;transition:box-shadow 150ms ease}input.wc-stripe-klarna-category,input.wc-stripe-payment-type{display:none!important}body .wfacp_main_form.woocommerce .wc-stripe-save-source label.checkbox{padding:0!important}input[type=radio]+label.wc-stripe-label-payment-type,label.wc-stripe-label-klarna-category,label.wc-stripe-label-payment-type{margin-bottom:1em;display:block;padding:0!important;color:#000}.theme-flatsome div.wc-stripe-saved-methods-container{margin:0 0 1em 0}label.wc-stripe-label-klarna-category:before,label.wc-stripe-label-payment-type:before{content:"";display:inline-block;width:11px;height:11px;border:2px solid #fff;box-shadow:0 0 0 2px #000;background:#fff;margin-left:4px;margin-right:.5em;border-radius:100%;-webkit-transform:translateY(2px);-ms-transform:translateY(2px);transform:translateY(2px)}input.wc-stripe-klarna-category:checked+label.wc-stripe-label-klarna-category:before,input.wc-stripe-payment-type:checked+label.wc-stripe-label-payment-type:before{background:#000}label.wc-stripe-label-payment-type:after{content:none!important;display:none!important}.select2-results__options li.wc-stripe-select2-container,.wc-stripe-saved-methods-container .select2-container .select2-selection--single .wc-stripe-select2-container{display:flex;align-items:center;height:42px;line-height:42px!important}.select2-container .select2-selection--single .wc-stripe-select2-container:before,.select2-results__options li.wc-stripe-select2-container:before{content:'';background-repeat:no-repeat;background-size:40px 24px;width:40px;height:42px;display:inline-block;margin-right:8px;background-position:center}.select2-container .select2-selection--single .wc-stripe-select2-container.visa:before,.select2-results__options li.wc-stripe-select2-container.visa:before{background-image:url(../img/cards/visa.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.americanexpress:before,.select2-results__options li.wc-stripe-select2-container.americanexpress:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.amex:before,.select2-results__options li.wc-stripe-select2-container.amex:before{background-image:url(../img/cards/amex.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.discover:before,.select2-results__options li.wc-stripe-select2-container.discover:before{background-image:url(../img/cards/discover.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.mastercard:before,.select2-results__options li.wc-stripe-select2-container.mastercard:before{background-image:url(../img/cards/mastercard.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.dinersclub:before,.select2-results__options li.wc-stripe-select2-container.dinersclub:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.diners:before,.select2-results__options li.wc-stripe-select2-container.diners:before{background-image:url(../img/cards/diners.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.jcb:before,.select2-results__options li.wc-stripe-select2-container.jcb:before{background-image:url(../img/cards/jcb.svg)}.select2-container .select2-selection--single .wc-stripe-select2-container.stripe_sepa:before,.select2-results__options li.wc-stripe-select2-container.stripe_sepa:before{background-image:url(../img/sepa.svg)}.select2-results__options li.wc-stripe-select2-container.wc-stripe-ach:before{display:none}#wc-stripe-card-element{margin-bottom:1em}.wc-stripe_cc-new-method-container .wc-stripe-save-source{display:flex;align-items:center;justify-content:flex-start}.wc-stripe_cc-container .wc-stripe-save-source .save-source-label{display:block;padding:0;margin:0 0 0 5px}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]{opacity:0;position:absolute;width:20px;height:20px}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{position:relative}.wc-stripe_cc-container .save-source-checkbox{height:20px;width:20px;position:relative;background-color:#fff;display:block;border-radius:3px;border:1px solid #bababa}.wc-stripe_cc-container .save-source-checkbox:after{content:"";position:absolute;top:0;left:0}.wc-stripe_cc-container .wc-stripe-save-source input[type=checkbox]:checked+.save-source-checkbox:after{left:6px;top:2px;width:7px;height:12px;border:solid #2196f3;border-width:0 3px 3px 0;-webkit-transform:rotate(45deg);-ms-transform:rotate(45deg);transform:rotate(45deg);-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}li.payment_method_stripe_applepay,li.payment_method_stripe_googlepay,li.payment_method_stripe_payment_request{display:none}#payment #place_order.wc-stripe-hide,#place_order.wc-stripe-hide,.woocommerce-checkout-review-order #payment #place_order.wc-stripe-hide{position:absolute!important;z-index:-1000!important;height:0!important;padding:0!important;opacity:0!important}.wc-stripe-product-checkout-container{display:none;width:100%}.wc-stripe-product-checkout-container.bottom{margin-top:1em}.wc-stripe-product-checkout-container.top{margin-bottom:1em}.wc-stripe-product-checkout-container.active{display:block}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods,.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods{list-style:none;margin:0;padding:0}.wc-stripe-cart-checkout-container{margin:0;padding:0;clear:both}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods{margin-bottom:1.5em}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_],.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]{margin:0 0 1em 0}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods li[class*=payment_method_stripe_]:last-child,.wc-stripe-product-checkout-container ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_]:last-child{margin:0}.wc_stripe_cart_payment_methods .gpay-button,.wc_stripe_cart_payment_methods .gpay-card-info-container,.wc_stripe_product_payment_methods .gpay-button,.wc_stripe_product_payment_methods .gpay-card-info-container{width:100%!important;margin:0}.wc_stripe_product_payment_methods .disabled{opacity:.45}.stripe_cart_gateway_active .checkout-button,.woocommerce-cart .stripe_cart_gateway_active .wc-proceed-to-checkout .checkout-button{margin-bottom:0}.wc-stripe-cart-or{margin:1em 0;text-align:center}li.wc-stripe-payment-method.or{display:none}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or{display:block;margin:15px 0}.wc-stripe-cart-checkout-container ul.wc_stripe_cart_payment_methods.active li.wc-stripe-payment-method.or p{margin:0}li[class*=payment_method_stripe_].active~li.wc-stripe-payment-method.or{display:block;margin:0}li.payment_method_stripe_applepay label:first-of-type img{width:49px;max-height:32px}li.payment_method_stripe_googlepay label:first-of-type img{width:48px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_standard]{width:60px;max-height:35px}li.payment_method_stripe_googlepay label:first-of-type img[src*=googlepay_round_outline]{width:56px;max-height:30px}li.payment_method_stripe_ach label:first-of-type img{width:32px;height:32px;min-width:32px;min-height:32px}.gpay-button:hover{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:active{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}.gpay-button:focus{background-origin:content-box;background-position:center center;background-repeat:no-repeat;background-size:contain}@supports (-webkit-appearance:-apple-pay-button){.apple-pay-button{display:block;-webkit-appearance:-apple-pay-button;width:100%;max-width:100%;min-width:200px;height:40px;max-height:40px}.apple-pay-button-black{-apple-pay-button-style:#000}.apple-pay-button-white{-apple-pay-button-style:#fff}.apple-pay-button-white-with-line{-apple-pay-button-style:white-outline}.applepay-top-container .apple-pay-button{max-width:240px}.woocommerce-checkout-payment .apple-pay-button{max-width:240px}body.single-product div.product form.cart .wc_stripe_product_payment_methods .apple-pay-button{max-width:100%}}.wc-stripe-banner-checkout{display:none;padding:20px 15px 0 15px;border:1px solid #d1d1d1;border-width:0 0 1px;position:relative;margin:1em 0}.wc-stripe-banner-checkout.active{display:block}.wc-stripe-banner-checkout span.banner-title{position:absolute;display:flex;align-items:center;top:-13px;right:0;left:0;background:0 0;white-space:nowrap;font-size:16px}.wc-stripe-banner-checkout span.banner-title:after,.wc-stripe-banner-checkout span.banner-title:before{content:' ';height:1px;background:#d1d1d1;display:block;width:50%}.wc-stripe-banner-checkout span.banner-title:before{margin-right:8px}.wc-stripe-banner-checkout span.banner-title:after{margin-left:8px}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways{list-style:none;margin:0;padding:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway{margin:0 0 20px 0;display:none}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways li.wc-stripe-checkout-banner-gateway .gpay-card-info-container{margin:0}.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-button,.wc-stripe-banner-checkout ul.wc_stripe_checkout_banner_gateways .gpay-card-info-container{width:100%}.wc_stripe_cart_payment_methods .payment_method_stripe_payment_request .StripeElement,.wc_stripe_product_payment_methods .payment_method_stripe_payment_request .StripeElement{padding:0;width:100%}.woocommerce-checkout #wc-stripe-payment-request-container.StripeElement{width:240px;padding:0}.wc-stripe-checkout-banner-gateway #wc-stripe-payment-request-banner.StripeElement{width:100%}ul.payment_methods li.payment_method_stripe_p24 img{max-width:90px;width:90px;max-height:45px}ul.payment_methods li.payment_method_stripe_ideal img{max-width:38px;width:38px;max-height:35px}ul.payment_methods li.payment_method_stripe_fpx img{max-width:75px;width:75px;max-height:25px}ul.payment_methods li.payment_method_stripe_klarna img{max-width:72px;width:72px;max-height:20px}ul.payment_methods li.payment_method_stripe_giropay img{max-width:65px;width:65px;max-height:28px}ul.payment_methods li.payment_method_stripe_eps img{max-width:70px;width:70px;max-height:46px}ul.payment_methods li.payment_method_stripe_multibanco img{max-width:48px;width:48px;max-height:48px}ul.payment_methods li.payment_method_stripe_sepa img{max-width:67px;width:67px;max-height:18px}ul.payment_methods li.payment_method_stripe_sofort img{max-width:70px;width:70px;max-height:21px}label[for=payment_method_stripe_bancontact] img,ul.payment_methods li.payment_method_stripe_bancontact img{width:60px;height:42px;max-width:60px;max-height:42px}ul.payment_methods li.payment_method_stripe_wechat label img{max-width:82px;width:82px;max-height:23px}ul.payment_methods li.payment_method_stripe_alipay img{max-width:72px;width:72px;height:36px;max-height:36px}ul.payment_methods li.payment_method_stripe_grabpay img{max-width:95px;width:95px;max-height:28px}#wc-stripe-card-element{width:100%}li.banner_payment_method_stripe_payment_request .StripeElement{padding:0}.single-product .blockMsg{border:none!important;background-color:transparent!important}#wc-stripe-card{position:absolute!important;top:50%;right:8px;transform:translatey(-50%);width:23px;height:15px;padding:0;border:none}#wc-stripe-card.active{width:32px;height:20px}input[id=stripe-postal-code]:focus{outline:0;background:0 0;border:none;box-shadow:none}div.postalCode:focus{outline:0;border:none}li[class*=payment_method_stripe] .select2-container .select2-selection--single{height:42px;padding:0 5px}li[class*=payment_method_stripe] .select2-container--default .select2-selection--single .select2-selection__arrow{height:42px;top:1px;right:1px;transform:translateY(0)}.blockUI.blockMsg{font-size:20px;white-space:nowrap}#wc-stripe-payment-request-container.disabled{opacity:.45}.wc-stripe-paymentRequest-icons-container img{float:none}.select2-container .select2-selection--single .wc-stripe-select2-container.wc-stripe-ach:before{display:none}ul.wc_stripe_cart_payment_methods li.wc-stripe-payment-method button,ul.wc_stripe_checkout_banner_gateways li button,ul.wc_stripe_product_payment_methods li[class*=payment_method_stripe_] button{margin:0}ul.payment_methods li[class*=payment_method]{margin:0;padding:10px 0}ul.payment_methods li[class*=payment_method] input[name=payment_method]{margin:0 10px 0 5px;float:none}ul.payment_methods li[class*=payment_method]>input[name=payment_method]+label{padding-top:0;padding-right:0;padding-bottom:0}ul.payment_methods{list-style:none}ul.payment_methods li[class*=payment_method_stripe_] .wc-stripe_cc-new-method-container label:before{display:none}.wc-stripe_cc-container .wc-stripe-save-source label.checkbox{padding:0!important;margin:0}div[id*=wc_stripe_local_payment_stripe_].StripeElement{border:1px solid #eee;border-radius:4px}.qrcode-message{margin:10px 0 0 0}#wc_stripe_local_payment_stripe_becs,#wc_stripe_local_payment_stripe_sepa{padding:10px 12px;box-shadow:0 1px 3px 0 #e6ebf1}.wc-stripe-local-desc.stripe_becs,.wc-stripe-local-desc.stripe_sepa{margin:10px 0}.wc-stripe-clear{clear:both;height:0;visibility:hidden}.wc-stripe-gateway-desc p{margin:0}#wc_stripe_local_payment_stripe_klarna,li[class*=payment_method_stripe_] div.wc-stripe-gateway-container.has_tokens{margin-top:10px}.wc-stripe-gateway-desc{margin-top:10px}#wc-stripe-card-element.StripeElement--webkit-autofill{background-color:transparent!important}#wc_stripe_local_payment_stripe_klarna .stripe-klarna-categories{list-style:none;margin:0;padding:10px}li.payment_method_stripe_alipay,li.payment_method_stripe_bancontact,li.payment_method_stripe_becs,li.payment_method_stripe_eps,li.payment_method_stripe_fpx,li.payment_method_stripe_giropay,li.payment_method_stripe_ideal,li.payment_method_stripe_klarna,li.payment_method_stripe_multibanco,li.payment_method_stripe_p24,li.payment_method_stripe_sepa,li.payment_method_stripe_sofort,li.payment_method_stripe_wechat{display:none}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods{list-style:none;margin:0;padding:0}.widget_shopping_cart_content .wc-stripe-mini-cart-payment-methods li{margin:0}.widget_shopping_cart_content a.wc-stripe-applepay-mini-cart,.widget_shopping_cart_content a.wc-stripe-gpay-mini-cart,.widget_shopping_cart_content a.wc-stripe-payment-request-mini-cart{background:0 0;padding:0;border:none}a.wc-stripe-gpay-mini-cart .gpay-button,a.wc-stripe-gpay-mini-cart .gpay-card-info-container a.wc-stripe-applepay-mini-cart .apple-pay-button{width:100%;margin:0}.wc-stripe-payment-request-mini-cart.StripeElement{padding:0;background:0 0;border:none;width:100%}.wc-stripe-payment-request-mini-cart.StripeElement .__PrivateStripeElement{width:100%}.widget_shopping_cart_content .wc-stripe-overlay{display:none!important;position:absolute;background:rgba(255,255,255,.75);height:100%;width:100%;z-index:-1}.widget_shopping_cart_content .wc-stripe-overlay.active{display:block!important;z-index:9999}.wc-stripe-klarna-loader{display:flex;justify-content:center;position:relative;width:100%;height:30px;box-sizing:border-box;transform:scale(.65)}.wc-stripe-klarna-loader div{box-sizing:border-box;display:block;position:absolute;box-sizing:border-box;width:30px;height:30px;border:3px solid #000;border-radius:50%;animation:klarna-payments-loader 1.3s cubic-bezier(.5,0,.5,1) infinite;border-color:#000 transparent transparent transparent}.wc-stripe-klarna-loader div:nth-child(1){animation-delay:-.45s}.wc-stripe-klarna-loader div:nth-child(2){animation-delay:-.3s}.wc-stripe-klarna-loader div:nth-child(3){animation-delay:-.15s}@keyframes klarna-payments-loader{0%{transform:rotate(0)}100%{transform:rotate(360deg)}}li.payment_method_stripe_alipay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_applepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_bancontact.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_eps.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_giropay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_googlepay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_grabpay.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_multibanco.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_p24.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_payment_request.wc-stripe-no-desc .payment_box.wc-stripe-no-methods,li.payment_method_stripe_sofort.wc-stripe-no-desc .payment_box.wc-stripe-no-methods{padding:0;margin:0}
assets/js/frontend/notices.js DELETED
@@ -1,25 +0,0 @@
1
- (function($) {
2
-
3
- /**
4
- * [Notice description]
5
- */
6
- function Notice() {
7
- this.params = wc_stripe_notices_params;
8
- this.container = this.params.container;
9
- this.notices = this.params.notices;
10
- this.display_notices();
11
- }
12
-
13
- /**
14
- * [display_notice description]
15
- * @return {[type]} [description]
16
- */
17
- Notice.prototype.display_notices = function() {
18
- for (var i = 0; i < this.notices.length; i++) {
19
- $(this.container).prepend(this.notices[i]);
20
- }
21
- }
22
-
23
- new Notice();
24
-
25
- }(jQuery))
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
assets/js/frontend/notices.min.js DELETED
@@ -1 +0,0 @@
1
- !function(i){function t(){this.params=wc_stripe_notices_params,this.container=this.params.container,this.notices=this.params.notices,this.display_notices()}t.prototype.display_notices=function(){for(var t=0;t<this.notices.length;t++)i(this.container).prepend(this.notices[t])},new t}(jQuery);
 
assets/js/frontend/wc-stripe.js CHANGED
@@ -548,6 +548,9 @@
548
 
549
  if (data.payerPhone) {
550
  this.fields.set('phone', data.payerPhone, 'billing');
 
 
 
551
  }
552
 
553
  if (data.shippingAddress) {
@@ -1408,6 +1411,9 @@
1408
  billing_address = {phoneNumber: billing_address.phoneNumber};
1409
  }
1410
  this.populate_billing_fields(billing_address);
 
 
 
1411
  }
1412
 
1413
  if (paymentData.shippingAddress) {
@@ -1867,6 +1873,10 @@
1867
  return false;
1868
  };
1869
 
 
 
 
 
1870
  wc_stripe.CheckoutFields.prototype.isEmpty = function (k) {
1871
  if (this.fields.has(k)) {
1872
  var value = this.fields.get(k);
548
 
549
  if (data.payerPhone) {
550
  this.fields.set('phone', data.payerPhone, 'billing');
551
+ if (this.fields.exists('shipping_phone') && this.fields.isEmpty('shipping_phone')) {
552
+ this.fields.set('shipping_phone', data.payerPhone);
553
+ }
554
  }
555
 
556
  if (data.shippingAddress) {
1411
  billing_address = {phoneNumber: billing_address.phoneNumber};
1412
  }
1413
  this.populate_billing_fields(billing_address);
1414
+ if (billing_address.phoneNumber && this.fields.exists('shipping_phone') && this.fields.isEmpty('shipping_phone')) {
1415
+ this.fields.set('shipping_phone', billing_address.phoneNumber);
1416
+ }
1417
  }
1418
 
1419
  if (paymentData.shippingAddress) {
1873
  return false;
1874
  };
1875
 
1876
+ wc_stripe.CheckoutFields.prototype.exists = function (k) {
1877
+ return k in this.params;
1878
+ }
1879
+
1880
  wc_stripe.CheckoutFields.prototype.isEmpty = function (k) {
1881
  if (this.fields.has(k)) {
1882
  var value = this.fields.get(k);
assets/js/frontend/wc-stripe.min.js CHANGED
@@ -1 +1 @@
1
- !function(a,o){a.wc_stripe={};var i=null;"undefined"==typeof wc_stripe_checkout_fields&&(a.wc_stripe_checkout_fields=[]),wc_stripe.BaseGateway=function(t,e){this.params=t,this.gateway_id=this.params.gateway_id,this.container=void 0===e?"li.payment_method_".concat(this.gateway_id):e,o(this.container).length||(this.container=".payment_method_".concat(this.gateway_id)),this.token_selector=this.params.token_selector,this.saved_method_selector=this.params.saved_method_selector,this.payment_token_received=!1,this.stripe=i,this.elements=i.elements(o.extend({},{locale:"auto"},this.get_element_options())),this.fields=r,this.initialize()},wc_stripe.BaseGateway.prototype.get_page=function(){var t=wc_stripe_params_v3.page;return"cart"===t&&o(document.body).is(".woocommerce-checkout")&&(t="checkout"),t},wc_stripe.BaseGateway.prototype.set_nonce=function(t){this.fields.set(this.gateway_id+"_token_key",t),o(this.token_selector).val(t)},wc_stripe.BaseGateway.prototype.get_element_options=function(){return{}},wc_stripe.BaseGateway.prototype.initialize=function(){},wc_stripe.BaseGateway.prototype.create_button=function(){},wc_stripe.BaseGateway.prototype.is_gateway_selected=function(){return o('[name="payment_method"]:checked').val()===this.gateway_id},wc_stripe.BaseGateway.prototype.is_saved_method_selected=function(){return this.is_gateway_selected()&&"saved"===o('[name="'+this.gateway_id+'_payment_type_key"]:checked').val()},wc_stripe.BaseGateway.prototype.has_checkout_error=function(){return 0<o("#wc_stripe_checkout_error").length&&this.is_gateway_selected()},wc_stripe.BaseGateway.prototype.submit_error=function(t){var e=this.get_error_message(t);e.indexOf("</ul>")<0&&(e='<div class="'+function(){var t="woocommerce-NoticeGroup";return this.is_current_page("checkout")&&(t+=" woocommerce-NoticeGroup-checkout"),t}.bind(this)()+'"><ul class="woocommerce-error"><li>'+e+"</li></ul></div>");t=o(document.body).triggerHandler("wc_stripe_submit_error",[e,t,this]);e=void 0===t?e:t,this.submit_message(e)},wc_stripe.BaseGateway.prototype.submit_error_code=function(t){console.log(t)},wc_stripe.BaseGateway.prototype.get_error_message=function(t){return"object"==typeof t&&t.code&&(t=wc_stripe_messages[t.code]||t.message),t},wc_stripe.BaseGateway.prototype.submit_message=function(t){o(".woocommerce-error, .woocommerce-message, .woocommerce-info").remove();var e=o(this.message_container);e.closest("form").length&&(e=e.closest("form")),e.prepend(t),e.removeClass("processing").unblock(),e.find(".input-text, select, input:checkbox").blur(),o.scroll_to_notices?o.scroll_to_notices(e):o("html, body").animate({scrollTop:e.offset().top-100},1e3)},wc_stripe.BaseGateway.prototype.get_billing_details=function(){var t={name:this.get_customer_name("billing"),address:{city:this.fields.get("billing_city",null),country:this.fields.get("billing_country",null),line1:this.fields.get("billing_address_1",null),line2:this.fields.get("billing_address_2",null),postal_code:this.fields.get("billing_postcode",null),state:this.fields.get("billing_state",null)}};return t.name&&" "!==t.name||delete t.name,""!=this.fields.get("billing_email")&&(t.email=this.fields.get("billing_email")),""!=this.fields.get("billing_phone")&&(t.phone=this.fields.get("billing_phone")),t},wc_stripe.BaseGateway.prototype.get_first_name=function(t){return o("#"+t+"_first_name").val()},wc_stripe.BaseGateway.prototype.get_last_name=function(t){return o("#"+t+"_last_name").val()},wc_stripe.BaseGateway.prototype.get_shipping_prefix=function(){return this.needs_shipping()&&0<o('[name="ship_to_different_address"]').length&&o('[name="ship_to_different_address"]').is(":checked")?"shipping":"billing"},wc_stripe.BaseGateway.prototype.should_save_method=function(){return o("#"+this.gateway_id+"_save_source_key").is(":checked")},wc_stripe.BaseGateway.prototype.is_add_payment_method_page=function(){return"add_payment_method"===this.get_page()||o(document.body).hasClass("woocommerce-add-payment-method")},wc_stripe.BaseGateway.prototype.is_change_payment_method=function(){return"change_payment_method"===this.get_page()},wc_stripe.BaseGateway.prototype.get_selected_payment_method=function(){return o(this.saved_method_selector).val()},wc_stripe.BaseGateway.prototype.needs_shipping=function(){return this.get_gateway_data().needs_shipping},wc_stripe.BaseGateway.prototype.get_currency=function(){return this.get_gateway_data().currency},wc_stripe.BaseGateway.prototype.get_gateway_data=function(){var t=o(this.container).find(".woocommerce_".concat(this.gateway_id,"_gateway_data")).data("gateway");return void 0===t&&this.is_current_page("checkout")&&void 0===(t=o("form.checkout").find(".woocommerce_".concat(this.gateway_id,"_gateway_data")).data("gateway"))&&(t=o(".woocommerce_"+this.gateway_id+"_gateway_data").data("gateway")),t},wc_stripe.BaseGateway.prototype.set_gateway_data=function(t){o(this.container).find(".woocommerce_".concat(this.gateway_id,"_gateway_data")).data("gateway",t)},wc_stripe.BaseGateway.prototype.get_customer_name=function(t){return this.fields.get(t+"_first_name")+" "+this.fields.get(t+"_last_name")},wc_stripe.BaseGateway.prototype.get_customer_email=function(){return this.fields.get("billing_email")},wc_stripe.BaseGateway.prototype.get_address_field_hash=function(t){for(var e=["_first_name","_last_name","_address_1","_address_2","_postcode","_city","_state","_country"],i="",s=0;s<e.length;s++)i+=this.fields.get(t+e[s])+"_";return i},wc_stripe.BaseGateway.prototype.block=function(){o().block&&o.blockUI({message:null,overlayCSS:{background:"#fff",opacity:.6}})},wc_stripe.BaseGateway.prototype.unblock=function(){o().block&&o.unblockUI()},wc_stripe.BaseGateway.prototype.get_form=function(){return o(this.token_selector).closest("form")},wc_stripe.BaseGateway.prototype.get_total_price=function(){return this.get_gateway_data().total},wc_stripe.BaseGateway.prototype.get_total_price_cents=function(){return this.get_gateway_data().total_cents},wc_stripe.BaseGateway.prototype.set_total_price=function(t){var e=this.get_gateway_data();e.total=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.set_total_price_cents=function(t){var e=this.get_gateway_data();e.total_cents=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.set_payment_method=function(t){o('[name="payment_method"][value="'+t+'"]').prop("checked",!0).trigger("click")},wc_stripe.BaseGateway.prototype.set_selected_shipping_methods=function(t){if(this.fields.set("shipping_method",t),t&&o('[name^="shipping_method"]').length)for(var e in t){var i=t[e];o('[name="shipping_method['+e+']"][value="'+i+'"]').prop("checked",!0).trigger("change")}},wc_stripe.BaseGateway.prototype.on_token_received=function(t){this.payment_token_received=!0,this.set_nonce(t.id),this.process_checkout()},wc_stripe.BaseGateway.prototype.createPaymentRequest=function(){try{this.payment_request_options=this.get_payment_request_options(),this.paymentRequest=i.paymentRequest(this.payment_request_options),this.payment_request_options.requestShipping&&(this.paymentRequest.on("shippingaddresschange",this.update_shipping_address.bind(this)),this.paymentRequest.on("shippingoptionchange",this.update_shipping_method.bind(this))),this.paymentRequest.on("paymentmethod",this.on_payment_method_received.bind(this))}catch(t){return void this.submit_error(t.message)}},wc_stripe.BaseGateway.prototype.get_payment_request_options=function(){var t={country:this.params.country_code,currency:this.get_currency().toLowerCase(),total:{amount:this.get_total_price_cents(),label:this.params.total_label,pending:!0},requestPayerName:function(){return!this.is_current_page("checkout")||!this.is_valid_address(this.get_address_object("billing"),"billing",["email","phone"])}.bind(this)(),requestPayerEmail:this.fields.requestFieldInWallet("billing_email"),requestPayerPhone:this.fields.requestFieldInWallet("billing_phone"),requestShipping:function(){if(this.needs_shipping()){var t=this.get_shipping_prefix();if(this.is_current_page("checkout")&&!this.is_valid_address(this.get_address_object(t),t,["email","phone"])||!this.is_current_page("checkout"))return!0}return!1}.bind(this)()},e=this.get_display_items(),i=this.get_shipping_options();return e&&(t.displayItems=e),t.requestShipping&&i&&(t.shippingOptions=i),t},wc_stripe.BaseGateway.prototype.get_payment_request_update=function(t){var e={currency:this.get_currency().toLowerCase(),total:{amount:parseInt(this.get_total_price_cents()),label:this.params.total_label,pending:!0}},i=this.get_display_items(),s=this.get_shipping_options();return i&&(e.displayItems=i),this.payment_request_options.requestShipping&&s&&(e.shippingOptions=s),t&&(e=o.extend(!0,{},e,t)),e},wc_stripe.BaseGateway.prototype.get_display_items=function(){return this.get_gateway_data().items},wc_stripe.BaseGateway.prototype.set_display_items=function(t){var e=this.get_gateway_data();e.items=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.get_shipping_options=function(){return this.get_gateway_data().shipping_options},wc_stripe.BaseGateway.prototype.set_shipping_options=function(t){var e=this.get_gateway_data();e.shipping_options=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.map_address=function(t){return{city:t.city,postcode:t.postalCode,state:t.region,country:t.country}},wc_stripe.BaseGateway.prototype.on_payment_method_received=function(t){try{this.payment_response=t,this.populate_checkout_fields(t),t.complete("success"),this.on_token_received(t.paymentMethod)}catch(e){a.alert(e)}},wc_stripe.BaseGateway.prototype.populate_checkout_fields=function(t){this.set_nonce(t.paymentMethod.id),this.update_addresses(t)},wc_stripe.BaseGateway.prototype.update_addresses=function(t){t.payerName&&this.fields.set("name",t.payerName,"billing"),t.payerEmail&&this.fields.set("email",t.payerEmail,"billing"),t.payerPhone&&this.fields.set("phone",t.payerPhone,"billing"),t.shippingAddress&&this.populate_shipping_fields(t.shippingAddress),t.paymentMethod.billing_details.address&&this.populate_billing_fields(t.paymentMethod.billing_details.address)},wc_stripe.BaseGateway.prototype.populate_address_fields=function(t,e){for(var i in t)null!==t[i]&&this.fields.set(i,t[i],e)},wc_stripe.BaseGateway.prototype.populate_billing_fields=function(t){this.populate_address_fields(t,"billing")},wc_stripe.BaseGateway.prototype.populate_shipping_fields=function(t){this.populate_address_fields(t,"shipping")},wc_stripe.BaseGateway.prototype.get_address_fields=function(){return["first_name","last_name","country","address_1","address_2","city","state","postcode","phone","email"]},wc_stripe.BaseGateway.prototype.get_address_object=function(e){var i={};return this.get_address_fields().forEach(function(t){i[t]=this.fields.get(t,e)}.bind(this)),i},wc_stripe.BaseGateway.prototype.is_current_page=function(t){return this.get_page()===t},wc_stripe.BaseGateway.prototype.is_valid_address=function(t,e,i){if(o.isEmptyObject(t))return!1;var s=this.get_address_fields();void 0!==i&&i.forEach(function(t){-1<s.indexOf(t)&&s.splice(s.indexOf(t),1)});for(var a=0;a<s.length;a++){var n=s[a];if(this.fields.required(e+"_"+n)&&(!t[n]||"undefined"==typeof t[n]||!this.fields.isValid(n,t[n],t)))return!1}return!0},wc_stripe.BaseGateway.prototype.ajax_before_send=function(t){0<this.params.user_id&&t.setRequestHeader("X-WP-Nonce",this.params.rest_nonce)},wc_stripe.BaseGateway.prototype.process_checkout=function(){return new Promise(function(){this.block(),o.ajax({url:this.params.routes.checkout,method:"POST",dataType:"json",data:o.extend({},this.serialize_fields(),{payment_method:this.gateway_id,page_id:this.get_page(),currency:this.get_currency()}),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.reload?a.location.reload():"success"===t.result?a.location=t.redirect:(t.messages&&this.submit_error(t.messages),this.unblock())}.bind(this)).fail(function(t,e,i){this.unblock(),this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.BaseGateway.prototype.process_payment=function(t,e){o.ajax({method:"POST",url:this.params.routes.checkout_payment,dataType:"json",data:o.extend({},this.fields.toJson(),{order_id:t,order_key:e}),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){if(t.result&&"success"===t.result)a.location=t.redirect;else{if(t.reload)return a.location.reload();t.messages?this.submit_error(t.messages):this.submit_error(wc_checkout_params.i18n_checkout_error)}}.bind(this)).fail(function(){}.bind(this))},wc_stripe.BaseGateway.prototype.handle_card_action=function(e){try{return this.stripe.handleCardAction(e.client_secret).then(function(t){if(t.error)return this.payment_token_received=!1,this.submit_error(t.error),void this.sync_payment_intent(e.order_id,e.client_secret)["catch"](function(t){this.submit_error(t.message)}.bind(this));this.is_current_page("order_pay")?this.get_form().submit():this.process_payment(e.order_id,e.order_key)}.bind(this))["catch"](function(t){this.submit_error(t.message)}.bind(this)),!1}catch(t){}},wc_stripe.BaseGateway.prototype.hashchange=function(t){var e=t.newURL.match(/response=(.*)/);if(e)try{var i=JSON.parse(a.atob(decodeURIComponent(e[1])));i&&i.hasOwnProperty("client_secret")&&i.gateway_id===this.gateway_id&&(history.pushState({},"",a.location.pathname),this.handle_card_action(i))}catch(s){}return!0},wc_stripe.BaseGateway.prototype.sync_payment_intent=function(t,s){return new Promise(function(e,i){o.when(o.ajax({method:"POST",dataType:"json",url:this.params.routes.sync_intent,data:{order_id:t,client_secret:s},beforeSend:this.ajax_before_send.bind(this)})).done(function(t){(t.code?i:e)(t)}).fail(function(t,e,i){this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.BaseGateway.prototype.serialize_form=function(t){var e,i=t.find("input").filter(function(t,e){return!o(e).is('[name^="add-to-cart"]')}.bind(this)).serializeArray(),s={};for(e in i){var a=i[e];s[a.name]=a.value}return s.payment_method=this.gateway_id,s},wc_stripe.BaseGateway.prototype.serialize_fields=function(){return o.extend({},this.fields.toJson(),o(document.body).triggerHandler("wc_stripe_process_checkout_data",[this,this.fields]))},wc_stripe.BaseGateway.prototype.map_shipping_methods=function(t){var e={};return"default"===t||1<(t=t.match(/^([\w+]):(.+)$/)).length&&(e[t[1]]=t[2]),e},wc_stripe.BaseGateway.prototype.maybe_set_ship_to_different=function(){o('[name="ship_to_different_address"]').length&&o('[name="ship_to_different_address"]').prop("checked",this.get_address_field_hash("billing")!==this.get_address_field_hash("shipping")).trigger("change")},wc_stripe.BaseGateway.prototype.update_shipping_address=function(s){return new Promise(function(e,i){o.ajax({url:this.params.routes.shipping_address,method:"POST",dataType:"json",data:{address:this.map_address(s.shippingAddress),payment_method:this.gateway_id,page_id:this.get_page(),currency:this.get_currency()},beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.code?(s.updateWith(t.data.newData),i(t.data)):(s.updateWith(t.data.newData),this.fields.set("shipping_method",t.data.shipping_method),e(t.data))}.bind(this)).fail(function(){}.bind(this))}.bind(this))},wc_stripe.BaseGateway.prototype.update_shipping_method=function(s){return new Promise(function(e,i){o.ajax({url:this.params.routes.shipping_method,method:"POST",dataType:"json",data:{shipping_method:s.shippingOption.id,payment_method:this.gateway_id,currency:this.get_currency(),page_id:this.get_page()},beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.code?(s.updateWith(t.data.newData),i(t.data)):(this.set_selected_shipping_methods(t.data.shipping_methods),s.updateWith(t.data.newData),e(t.data))}.bind(this)).fail(function(t,e,i){this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.CheckoutGateway=function(){this.message_container="li.payment_method_"+this.gateway_id,this.banner_container="li.banner_payment_method_"+this.gateway_id,o(document.body).on("update_checkout",this.update_checkout.bind(this)),o(document.body).on("updated_checkout",this.updated_checkout.bind(this)),o(document.body).on("updated_checkout",this.container_styles.bind(this)),o(document.body).on("cfw_updated_checkout",this.updated_checkout.bind(this)),o(document.body).on("checkout_error",this.checkout_error.bind(this)),o(this.token_selector).closest("form").on("checkout_place_order_"+this.gateway_id,this.checkout_place_order.bind(this)),o(document.body).on("wc_stripe_new_method_"+this.gateway_id,this.on_show_new_methods.bind(this)),o(document.body).on("wc_stripe_saved_method_"+this.gateway_id,this.on_show_saved_methods.bind(this)),o(document.body).on("wc_stripe_payment_method_selected",this.on_payment_method_selected.bind(this)),this.banner_enabled()&&o(".woocommerce-billing-fields").length&&o(".wc-stripe-banner-checkout").css("max-width",o(".woocommerce-billing-fields").outerWidth(!0)),this.container_styles(),this.hasOrderReviewParams()},wc_stripe.CheckoutGateway.prototype.container_styles=function(){this.params.description||o(this.container).addClass("wc-stripe-no-desc"),o(this.container).find(".wc-stripe-saved-methods").length||o(this.container).find(".payment_box").addClass("wc-stripe-no-methods")},wc_stripe.CheckoutGateway.prototype.hasOrderReviewParams=function(){var t=a.location.search.match(/_stripe_order_review=(.+)/);if(t&&1<t.length)try{var e=JSON.parse(a.atob(decodeURIComponent(t[1])));this.gateway_id===e.payment_method&&(o(function(){this.payment_token_received=!0,this.set_nonce(e.payment_nonce),this.set_use_new_option(!0)}.bind(this)),history.pushState({},"",a.location.pathname))}catch(i){}},wc_stripe.CheckoutGateway.prototype.has3DSecureParams=function(){if((this.is_current_page("order_pay")||this.is_change_payment_method())&&a.location.hash&&"string"==typeof a.location.hash){var t=a.location.hash.match(/response=(.*)/);if(t)try{var e=JSON.parse(a.atob(decodeURIComponent(t[1])));e&&e.hasOwnProperty("client_secret")&&e.gateway_id===this.gateway_id&&(o(function(){this.set_payment_method(this.gateway_id),this.set_use_new_option(!0),this.set_nonce(e.pm),!0===e.save_method&&this.set_save_payment_method(!0),o('[name="terms"]').prop("checked",!0)}.bind(this)),history.pushState({},"",a.location.pathname+a.location.search),this.handle_card_action(e))}catch(i){}}},wc_stripe.CheckoutGateway.prototype.update_shipping_address=function(){return wc_stripe.BaseGateway.prototype.update_shipping_address.apply(this,arguments).then(function(t){this.populate_address_fields(t.address,this.get_shipping_prefix()),this.fields.toFormFields({update_shipping_method:!1})}.bind(this))},wc_stripe.CheckoutGateway.prototype.updated_checkout=function(){},wc_stripe.CheckoutGateway.prototype.update_checkout=function(){},wc_stripe.CheckoutGateway.prototype.checkout_error=function(){this.has_checkout_error()&&(this.payment_token_received=!1,this.payment_response=null,this.show_payment_button(),this.hide_place_order())},wc_stripe.CheckoutGateway.prototype.is_valid_checkout=function(){return!(o('[name="terms"]').length&&!o('[name="terms"]').is(":checked"))},wc_stripe.CheckoutGateway.prototype.get_payment_method=function(){return o('[name="payment_method"]:checked').val()},wc_stripe.CheckoutGateway.prototype.set_use_new_option=function(t){o("#"+this.gateway_id+"_use_new").prop("checked",t).trigger("change")},wc_stripe.CheckoutGateway.prototype.checkout_place_order=function(){return this.is_valid_checkout()?!!this.is_saved_method_selected()||this.payment_token_received:(this.submit_error(this.params.messages.terms),!1)},wc_stripe.CheckoutGateway.prototype.on_token_received=function(t){this.payment_token_received=!0,this.set_nonce(t.id),this.hide_payment_button(),this.show_place_order()},wc_stripe.CheckoutGateway.prototype.block=function(){o().block&&o("form.checkout").block({message:null,overlayCSS:{background:"#fff",opacity:.6}})},wc_stripe.CheckoutGateway.prototype.unblock=function(){o().block&&o("form.checkout").unblock()},wc_stripe.CheckoutGateway.prototype.hide_place_order=function(){o("#place_order").addClass("wc-stripe-hide")},wc_stripe.CheckoutGateway.prototype.show_place_order=function(){o("#place_order").removeClass("wc-stripe-hide")},wc_stripe.CheckoutGateway.prototype.on_show_new_methods=function(){this.payment_token_received?(this.show_place_order(),this.hide_payment_button()):(this.hide_place_order(),this.show_payment_button())},wc_stripe.CheckoutGateway.prototype.on_show_saved_methods=function(){this.hide_payment_button(),this.show_place_order()},wc_stripe.CheckoutGateway.prototype.show_payment_button=function(){this.$button&&this.$button.show()},wc_stripe.CheckoutGateway.prototype.hide_payment_button=function(){this.$button&&this.$button.hide()},wc_stripe.CheckoutGateway.prototype.trigger_payment_method_selected=function(){this.on_payment_method_selected(null,o('[name="payment_method"]:checked').val())},wc_stripe.CheckoutGateway.prototype.on_payment_method_selected=function(t,e){e===this.gateway_id?this.payment_token_received||this.is_saved_method_selected()?(this.hide_payment_button(),this.show_place_order()):(this.show_payment_button(),this.hide_place_order()):(this.hide_payment_button(),e.indexOf("stripe_")<0&&this.show_place_order())},wc_stripe.CheckoutGateway.prototype.banner_enabled=function(){return"1"===this.params.banner_enabled},wc_stripe.CheckoutGateway.prototype.checkout_fields_valid=function(){if(["checkout","order_pay"].indexOf(this.get_page())<0)return!0;var t=!0;return(t=this.fields.validateFields("billing"))?this.needs_shipping()&&o("#ship-to-different-address-checkbox").is(":checked")?(t=this.fields.validateFields("shipping"))||this.submit_error(this.params.messages.required_field):(t=this.is_valid_checkout())||this.submit_error(this.params.messages.terms):this.submit_error(this.params.messages.required_field),t},wc_stripe.CheckoutGateway.prototype.cart_contains_subscription=function(){return"undefined"!=typeof wc_stripe_cart_contains_subscription&&!0===wc_stripe_cart_contains_subscription},wc_stripe.CheckoutGateway.prototype.set_save_payment_method=function(t){o('[name="'+this.gateway_id+'_save_source_key"]').prop("checked",t)},wc_stripe.ProductGateway=function(){this.message_container="div.product",o("form.cart").on("found_variation",this.found_variation.bind(this)),o("form.cart").on("reset_data",this.reset_variation_data.bind(this)),this.buttonWidth=o("form.cart div.quantity").outerWidth(!0)+o(".single_add_to_cart_button").outerWidth();var t=o(".single_add_to_cart_button").css("marginLeft");t&&(this.buttonWidth+=parseInt(t.replace("px",""))),o(this.container).css("max-width",this.buttonWidth+"px")},wc_stripe.ProductGateway.prototype.get_quantity=function(){return parseInt(o('[name="quantity"]').val())},wc_stripe.ProductGateway.prototype.set_rest_nonce=function(t,e){this.params.rest_nonce=e},wc_stripe.ProductGateway.prototype.found_variation=function(t,e){var i=this.get_gateway_data();i.product.price=e.display_price,i.needs_shipping=!e.is_virtual,i.product.variation=e,this.set_gateway_data(i)},wc_stripe.ProductGateway.prototype.reset_variation_data=function(){var t=this.get_product_data();t.variation=!1,this.set_product_data(t),this.disable_payment_button()},wc_stripe.ProductGateway.prototype.disable_payment_button=function(){this.$button&&this.get_button().prop("disabled",!0).addClass("disabled")},wc_stripe.ProductGateway.prototype.enable_payment_button=function(){this.$button&&this.get_button().prop("disabled",!1).removeClass("disabled")},wc_stripe.ProductGateway.prototype.get_button=function(){return this.$button},wc_stripe.ProductGateway.prototype.is_variable_product=function(){return 0<o('[name="variation_id"]').length},wc_stripe.ProductGateway.prototype.variable_product_selected=function(){return!1!==this.get_product_data().variation},wc_stripe.ProductGateway.prototype.get_product_data=function(){return this.get_gateway_data().product},wc_stripe.ProductGateway.prototype.set_product_data=function(t){var e=this.get_gateway_data();e.product=t,this.set_gateway_data(e)},wc_stripe.ProductGateway.prototype.add_to_cart=function(){return new Promise(function(e,i){this.block(),o.ajax({url:this.params.routes.add_to_cart,method:"POST",dataType:"json",data:o.extend({},{product_id:this.get_product_data().id,variation_id:this.is_variable_product()?o('[name="variation_id"]').val():0,qty:o('[name="quantity"]').val(),payment_method:this.gateway_id,currency:this.get_currency(),page_id:this.get_page()},this.get_product_variations()),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){this.unblock(),t.code?(this.submit_error(t.message),i(t)):(this.set_total_price(t.data.total),this.set_total_price_cents(t.data.totalCents),this.set_display_items(t.data.displayItems),e(t.data))}.bind(this)).fail(function(t,e,i){this.unblock(),this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.ProductGateway.prototype.cart_calculation=function(t){return new Promise(function(e,i){o.ajax({url:this.params.routes.cart_calculation,method:"POST",dataType:"json",data:o.extend({},{product_id:this.get_product_data().id,variation_id:this.is_variable_product()&&t?t:0,qty:o('[name="quantity"]').val(),currency:this.get_currency(),payment_method:this.gateway_id},this.get_product_variations()),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.code?(this.cart_calculation_error=!0,i(t)):(this.set_total_price(t.data.total),this.set_total_price_cents(t.data.totalCents),this.set_display_items(t.data.displayItems),e(t.data))}.bind(this)).fail(function(){}.bind(this))}.bind(this))},wc_stripe.ProductGateway.prototype.get_product_variations=function(){var s={};return this.is_variable_product()&&o('.variations [name^="attribute_"]').each(function(t,e){var i=o(e),e=i.data("attribute_name")||i.attr("name");s[e]=i.val()}),s},wc_stripe.CartGateway=function(){this.message_container="div.woocommerce",o(document.body).on("updated_wc_div",this.updated_html.bind(this)),o(document.body).on("updated_cart_totals",this.updated_html.bind(this)),o(document.body).on("wc_cart_emptied",this.cart_emptied.bind(this))},wc_stripe.CartGateway.prototype.submit_error=function(t){this.submit_message(this.get_error_message(t))},wc_stripe.CartGateway.prototype.updated_html=function(t){},wc_stripe.CartGateway.prototype.cart_emptied=function(t){},wc_stripe.CartGateway.prototype.add_cart_totals_class=function(){o(".cart_totals").addClass("stripe_cart_gateway_active")},wc_stripe.GooglePay=function(){};var s={apiVersion:2,apiVersionMinor:0},n={type:"CARD",parameters:{allowedAuthMethods:["PAN_ONLY"],allowedCardNetworks:["AMEX","DISCOVER","INTERAC","JCB","MASTERCARD","VISA"],assuranceDetailsRequired:!0}};wc_stripe.GooglePay.prototype.update_addresses=function(t){var e;t.paymentMethodData.info.billingAddress&&(e=t.paymentMethodData.info.billingAddress,this.is_current_page("checkout")&&this.is_valid_address(this.billing_address_object,"billing",["phone","email"])&&(e={phoneNumber:e.phoneNumber}),this.populate_billing_fields(e)),t.shippingAddress&&this.populate_shipping_fields(t.shippingAddress),t.email&&this.fields.set("email",t.email,"billing")},wc_stripe.GooglePay.prototype.map_address=function(t){return{city:t.locality,postcode:t.postalCode,state:t.administrativeArea,country:t.countryCode}},wc_stripe.GooglePay.prototype.update_payment_data=function(s){return new Promise(function(e,i){var t="default"==s.shippingOptionData.id?null:s.shippingOptionData.id;o.when(o.ajax({url:this.params.routes.payment_data,dataType:"json",method:"POST",data:{address:this.map_address(s.shippingAddress),shipping_method:t,page_id:this.get_page(),currency:this.get_currency()},beforeSend:this.ajax_before_send.bind(this)})).done(function(t){t.code?i(t.data.data):e(t.data)}.bind(this)).fail(function(){i()}.bind(this))}.bind(this))},wc_stripe.GooglePay.prototype.on_payment_data_changed=function(i){return new Promise(function(e){this.update_payment_data(i).then(function(t){e(t.paymentRequestUpdate),this.set_selected_shipping_methods(t.shipping_methods),this.payment_data_updated(t,i)}.bind(this))["catch"](function(t){e(t)}.bind(this))}.bind(this))},wc_stripe.GooglePay.prototype.payment_data_updated=function(t){},wc_stripe.GooglePay.prototype.get_merchant_info=function(){var t={merchantId:this.params.merchant_id,merchantName:this.params.merchant_name};return"TEST"===this.params.environment&&delete t.merchantId,t},wc_stripe.GooglePay.prototype.get_payment_options=function(){var t,e={environment:this.params.environment,merchantInfo:this.get_merchant_info(),paymentDataCallbacks:{onPaymentAuthorized:function(){return new Promise(function(t){t({transactionState:"SUCCESS"})}.bind(this))}}};return this.needs_shipping()&&(t=this.get_shipping_prefix(),(!this.is_current_page("checkout")||this.is_valid_address(this.get_address_object(t),t,["email","phone"]))&&this.is_current_page("checkout")||(e.paymentDataCallbacks.onPaymentDataChanged=this.on_payment_data_changed.bind(this))),e},wc_stripe.GooglePay.prototype.build_payment_request=function(){var t=o.extend({},s,{emailRequired:this.fields.requestFieldInWallet("billing_email"),merchantInfo:this.get_merchant_info(),allowedPaymentMethods:[o.extend({type:"CARD",tokenizationSpecification:{type:"PAYMENT_GATEWAY",parameters:{gateway:"stripe","stripe:version":"2018-10-31","stripe:publishableKey":this.params.api_key}}},n)],shippingAddressRequired:function(){if(this.needs_shipping()){var t=this.get_shipping_prefix();if(this.is_current_page("checkout")&&!this.is_valid_address(this.get_address_object(t),t,["email","phone"])||!this.is_current_page("checkout"))return!0}return!1}.bind(this)(),transactionInfo:{countryCode:this.params.processing_country,currencyCode:this.get_currency(),totalPriceStatus:"ESTIMATED",totalPrice:this.get_total_price().toString(),displayItems:this.get_display_items(),totalPriceLabel:this.params.total_price_label}});return t.allowedPaymentMethods[0].parameters.billingAddressRequired=function(){if(this.is_current_page("checkout")){var t=this.billing_address_object=this.get_address_object("billing");return this.fields.requestFieldInWallet("billing_phone")||!this.is_valid_address(t,"billing",["email"])?!0:!1}return!0}.bind(this)(),t.allowedPaymentMethods[0].parameters.billingAddressRequired&&(t.allowedPaymentMethods[0].parameters.billingAddressParameters={format:"FULL",phoneNumberRequired:this.fields.requestFieldInWallet("billing_phone")}),t.shippingAddressRequired?(t.shippingAddressParameters={},t.shippingOptionRequired=!0,t.shippingOptionParameters={shippingOptions:this.get_shipping_options()},t.callbackIntents=["SHIPPING_ADDRESS","SHIPPING_OPTION","PAYMENT_AUTHORIZATION"]):t.callbackIntents=["PAYMENT_AUTHORIZATION"],this.payment_request_options=t},wc_stripe.GooglePay.prototype.createPaymentsClient=function(){this.paymentsClient=new google.payments.api.PaymentsClient(this.get_payment_options())},wc_stripe.GooglePay.prototype.isReadyToPay=function(){return new Promise(function(t){var e=o.extend({},s);e.allowedPaymentMethods=[n],this.paymentsClient.isReadyToPay(e).then(function(){this.can_pay=!0,this.create_button(),t()}.bind(this))["catch"](function(t){this.submit_error(t)}.bind(this))}.bind(this))},wc_stripe.GooglePay.prototype.create_button=function(){this.$button&&this.$button.remove(),this.$button=o(this.paymentsClient.createButton({onClick:this.start.bind(this),buttonColor:this.params.button_color,buttonType:this.params.button_style})),this.$button.addClass("gpay-button-container")},wc_stripe.GooglePay.prototype.start=function(){this.createPaymentsClient(),this.paymentsClient.loadPaymentData(this.build_payment_request()).then(function(t){var e=JSON.parse(t.paymentMethodData.tokenizationData.token);this.update_addresses(t),this.stripe.createPaymentMethod({type:"card",card:{token:e.id},billing_details:this.get_billing_details()}).then(function(t){if(t.error)return this.submit_error(t.error);this.on_token_received(t.paymentMethod)}.bind(this))}.bind(this))["catch"](function(t){"CANCELED"!==t.statusCode&&(t.statusMessage&&-1<t.statusMessage.indexOf("paymentDataRequest.callbackIntent")?this.submit_error_code("DEVELOPER_ERROR_WHITELIST"):this.submit_error(t.statusMessage))}.bind(this))},wc_stripe.ApplePay=function(){},wc_stripe.ApplePay.prototype.initialize=function(){this.createPaymentRequest(),this.canMakePayment()},wc_stripe.ApplePay.prototype.create_button=function(){this.$button&&this.$button.remove(),this.$button=o(this.params.button),this.$button.on("click",this.start.bind(this)),this.append_button()},wc_stripe.ApplePay.prototype.canMakePayment=function(){return new Promise(function(e){this.paymentRequest.canMakePayment().then(function(t){t&&t.applePay&&(this.can_pay=!0,this.create_button(),o(this.container).show(),e(t))}.bind(this))}.bind(this))},wc_stripe.ApplePay.prototype.start=function(t){t.preventDefault(),this.paymentRequest.update(this.get_payment_request_update({total:{pending:!1}})),this.paymentRequest.show()},wc_stripe.PaymentRequest=function(){},wc_stripe.PaymentRequest.prototype.initialize=function(){this.createPaymentRequest(),this.createPaymentRequestButton(),this.canMakePayment(),this.paymentRequestButton.on("click",this.button_click.bind(this))},wc_stripe.PaymentRequest.prototype.button_click=function(t){},wc_stripe.PaymentRequest.prototype.createPaymentRequestButton=function(){this.paymentRequestButton&&this.paymentRequestButton.destroy(),this.paymentRequestButton=this.elements.create("paymentRequestButton",{paymentRequest:this.paymentRequest,style:{paymentRequestButton:{type:this.params.button.type,theme:this.params.button.theme,height:this.params.button.height}}})},wc_stripe.PaymentRequest.prototype.canMakePayment=function(){return new Promise(function(e){this.paymentRequest.canMakePayment().then(function(t){t&&!t.applePay&&(this.can_pay=!0,this.create_button(),o(this.container).show(),e(t))}.bind(this))}.bind(this))},wc_stripe.PaymentRequest.prototype.create_button=function(){this.paymentRequestButton.mount("#wc-stripe-payment-request-container")},wc_stripe.CheckoutFields=function(t,e){this.params=t,this.page=e,this.session_values=this.supportsSessionStorage()&&sessionStorage.getItem("wc_stripe_checkout_fields")?JSON.parse(sessionStorage.getItem("wc_stripe_checkout_fields")):{},this.fields=new Map(Object.keys(this.params).map(function(t){return null===this.params[t].value&&(t in this.session_values&&null!==this.session_values[t]?this.params[t].value=this.session_values[t]:this.params[t].value=""),[t,this.params[t].value]}.bind(this))),("checkout"===e||"cart"===e&&o(document.body).is(".woocommerce-checkout"))&&(o("form.checkout").on("change",".input-text, select",this.onChange.bind(this)),o("form.checkout").on("change",'[name="ship_to_different_address"]',this.on_ship_to_address_change.bind(this)),this.init_i18n(),o('[name="ship_to_different_address"]').is(":checked")?this.update_required_fields(o("#shipping_country").val(),"shipping_country"):this.update_required_fields(o("#billing_country").val(),"billing_country"))},wc_stripe.CheckoutFields.prototype.supportsSessionStorage=function(){return"sessionStorage"in a&&null!==a.sessionStorage&&["getItem","setItem"].reduce(function(t,e){return t&&e in sessionStorage}.bind(this),!0)},wc_stripe.CheckoutFields.prototype.init_i18n=function(){"undefined"!=typeof wc_address_i18n_params?this.locales=JSON.parse(wc_address_i18n_params.locale.replace(/&quot;/g,'"')):this.locales=null},wc_stripe.CheckoutFields.prototype.onChange=function(t){try{var e=t.currentTarget.name,i=t.currentTarget.value;this.fields.set(e,i),"billing_country"!==e&&"shipping_country"!==e||this.update_required_fields(i,e),this.supportsSessionStorage()&&sessionStorage.setItem("wc_stripe_checkout_fields",JSON.stringify(this.toJson()))}catch(s){console.log(s)}},wc_stripe.CheckoutFields.prototype.update_required_fields=function(t,e){if(this.locales){var i,s=-1<e.indexOf("billing_")?"billing_":"shipping_",t="undefined"!=typeof this.locales[t]?this.locales[t]:this.locales["default"],a=o.extend(!0,{},this.locales["default"],t);for(i in a){var n=s+i;this.params[n]&&(this.params[n]=o.extend(!0,{},this.params[n],a[i]))}}},wc_stripe.CheckoutFields.prototype.on_ship_to_address_change=function(t){o(t.currentTarget).is(":checked")&&this.update_required_fields(o("#shipping_country").val(),"shipping_country")},wc_stripe.CheckoutFields.prototype.requestFieldInWallet=function(t){return"checkout"===this.page?this.required(t)&&this.isEmpty(t):"order_pay"!==this.page&&this.required(t)},wc_stripe.CheckoutFields.prototype.set=function(t,e,i){this[t]&&"function"==typeof this[t]?this[t]().set.call(this,e,i):this.fields.set(t,e)},wc_stripe.CheckoutFields.prototype.get=function(t,e){var i;return this[t]&&"function"==typeof this[t]?i=this[t]().get.call(this,e):null!=(i=this.fields.get(t))&&""!==i||void 0!==e&&(i=e),void 0===i?"":i},wc_stripe.CheckoutFields.prototype.required=function(t){return!(!this.params[t]||"undefined"==typeof this.params[t].required)&&this.params[t].required},wc_stripe.CheckoutFields.prototype.isEmpty=function(t){if(this.fields.has(t)){t=this.fields.get(t);return null==t||"string"==typeof t&&0===t.trim().length}return!0},wc_stripe.CheckoutFields.prototype.isValid=function(t){if(this[t]&&"function"==typeof this[t])return this[t]().isValid.apply(this,Array.prototype.slice.call(arguments,1))},wc_stripe.CheckoutFields.prototype.first_name=function(){return{set:function(t,e){this.fields.set(e+"_first_name",t)},get:function(t){return this.fields.get(t+"_first_name")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.last_name=function(){return{set:function(t,e){this.fields.set(e+"_last_name",t)},get:function(t){return this.fields.get(t+"_last_name")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.address_1=function(){return{set:function(t,e){this.fields.set(e+"_address_1",t)},get:function(t){return this.fields.get(t+"_address_1")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.address_2=function(){return{set:function(t,e){this.fields.set(e+"_address_2",t)},get:function(t){return this.fields.get(t+"_address_2")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.name=function(){return{set:function(t,e){t=t.split(" ");0<t.length&&this.fields.set(e+"_first_name",t[0]),1<t.length&&this.fields.set(e+"_last_name",t[1])},get:function(t){return this.fields.get(t+"_first_name")+" "+this.fields.get(t+"_last_name")}}},wc_stripe.CheckoutFields.prototype.email=function(){return{set:function(t,e){this.fields.set(e+"_email",t)},get:function(t){return this.fields.get(t+"_email")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.phone=function(){return{set:function(t,e){this.fields.set(e+"_phone",t)},get:function(t){return this.fields.get(t+"_phone")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.country=function(){return{set:function(t,e){this.fields.set(e+"_country",t)},get:function(t){return this.fields.get(t+"_country")},isValid:function(t){return"string"==typeof t&&2===t.length}}},wc_stripe.CheckoutFields.prototype.state=function(){return{set:function(i,t){2<(i=i.toUpperCase()).length&&"checkout"===this.page&&o("#"+t+"_state option").each(function(){var t=o(this),e=t.text().toUpperCase();i===e&&(i=t.val())}),this.fields.set(t+"_state",i)},get:function(t){return this.fields.get(t+"_state")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.city=function(){return{set:function(t,e){this.fields.set(e+"_city",t)},get:function(t){return this.fields.get(t+"_city")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.postcode=function(){return{set:function(t,e){this.fields.set(e+"_postcode",t)},get:function(t){return this.fields.get(t+"_postcode")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.recipient=function(){return wc_stripe.CheckoutFields.prototype.name.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.payerName=function(){return wc_stripe.CheckoutFields.prototype.name.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.payerEmail=function(){return wc_stripe.CheckoutFields.prototype.email.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.payerPhone=function(){return wc_stripe.CheckoutFields.prototype.phone.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.phoneNumber=function(){return wc_stripe.CheckoutFields.prototype.phone.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.countryCode=function(){return wc_stripe.CheckoutFields.prototype.country.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.address1=function(){return wc_stripe.CheckoutFields.prototype.address_1.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.address2=function(){return wc_stripe.CheckoutFields.prototype.address_2.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.line1=function(){return wc_stripe.CheckoutFields.prototype.address_1.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.line2=function(){return wc_stripe.CheckoutFields.prototype.address_2.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.addressLine=function(){return{set:function(t,e){0<t.length&&this.fields.set(e+"_address_1",t[0]),1<t.length&&this.fields.set(e+"_address_2",t[1])},get:function(t){return[this.fields.get(t+"_address_1"),this.fields.get(t+"_address_2")]},isValid:function(t){return 0<t.length&&("string"==typeof t[0]&&0<t[0].length)}}},wc_stripe.CheckoutFields.prototype.region=function(){return wc_stripe.CheckoutFields.prototype.state.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.administrativeArea=function(){return wc_stripe.CheckoutFields.prototype.state.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.locality=function(){return wc_stripe.CheckoutFields.prototype.city.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.postal_code=function(){return wc_stripe.CheckoutFields.prototype.postcode.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.postalCode=function(){return wc_stripe.CheckoutFields.prototype.postcode.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.toJson=function(){var i={};return this.fields.forEach(function(t,e){i[e]=t}),i},wc_stripe.CheckoutFields.prototype.toFormFields=function(t){var i=[];this.fields.forEach(function(t,e){e='[name="'+e+'"]';o(e).length&&""!==t&&(o(e).val()!==t&&o(e).is("select")&&i.push(e),o(e).val(t))}),0<i.length&&o(i.join(",")).trigger("change"),void 0!==t&&o(document.body).trigger("update_checkout",t)},wc_stripe.CheckoutFields.prototype.validateFields=function(t){for(var e in this.params){var i=this.params[e];if(-1<e.indexOf(t)&&i.required&&o("#"+e).length&&o("#"+e).is(":visible")){i=o("#"+e).val();if(null==i||0===i.length)return!1}}return!0};try{i=Stripe(wc_stripe_params_v3.api_key,"test"===wc_stripe_params_v3.mode&&""===wc_stripe_params_v3.account?{}:{stripeAccount:wc_stripe_params_v3.account})}catch(t){return a.alert(t),console.log(t)}var r=new wc_stripe.CheckoutFields(wc_stripe_checkout_fields,wc_stripe_params_v3.page)}(window,jQuery);
1
+ !function(a,o){a.wc_stripe={};var i=null;"undefined"==typeof wc_stripe_checkout_fields&&(a.wc_stripe_checkout_fields=[]),wc_stripe.BaseGateway=function(t,e){this.params=t,this.gateway_id=this.params.gateway_id,this.container=void 0===e?"li.payment_method_".concat(this.gateway_id):e,o(this.container).length||(this.container=".payment_method_".concat(this.gateway_id)),this.token_selector=this.params.token_selector,this.saved_method_selector=this.params.saved_method_selector,this.payment_token_received=!1,this.stripe=i,this.elements=i.elements(o.extend({},{locale:"auto"},this.get_element_options())),this.fields=r,this.initialize()},wc_stripe.BaseGateway.prototype.get_page=function(){var t=wc_stripe_params_v3.page;return"cart"===t&&o(document.body).is(".woocommerce-checkout")&&(t="checkout"),t},wc_stripe.BaseGateway.prototype.set_nonce=function(t){this.fields.set(this.gateway_id+"_token_key",t),o(this.token_selector).val(t)},wc_stripe.BaseGateway.prototype.get_element_options=function(){return{}},wc_stripe.BaseGateway.prototype.initialize=function(){},wc_stripe.BaseGateway.prototype.create_button=function(){},wc_stripe.BaseGateway.prototype.is_gateway_selected=function(){return o('[name="payment_method"]:checked').val()===this.gateway_id},wc_stripe.BaseGateway.prototype.is_saved_method_selected=function(){return this.is_gateway_selected()&&"saved"===o('[name="'+this.gateway_id+'_payment_type_key"]:checked').val()},wc_stripe.BaseGateway.prototype.has_checkout_error=function(){return 0<o("#wc_stripe_checkout_error").length&&this.is_gateway_selected()},wc_stripe.BaseGateway.prototype.submit_error=function(t){var e=this.get_error_message(t);e.indexOf("</ul>")<0&&(e='<div class="'+function(){var t="woocommerce-NoticeGroup";return this.is_current_page("checkout")&&(t+=" woocommerce-NoticeGroup-checkout"),t}.bind(this)()+'"><ul class="woocommerce-error"><li>'+e+"</li></ul></div>");t=o(document.body).triggerHandler("wc_stripe_submit_error",[e,t,this]);e=void 0===t?e:t,this.submit_message(e)},wc_stripe.BaseGateway.prototype.submit_error_code=function(t){console.log(t)},wc_stripe.BaseGateway.prototype.get_error_message=function(t){return"object"==typeof t&&t.code&&(t=wc_stripe_messages[t.code]||t.message),t},wc_stripe.BaseGateway.prototype.submit_message=function(t){o(".woocommerce-error, .woocommerce-message, .woocommerce-info").remove();var e=o(this.message_container);e.closest("form").length&&(e=e.closest("form")),e.prepend(t),e.removeClass("processing").unblock(),e.find(".input-text, select, input:checkbox").blur(),o.scroll_to_notices?o.scroll_to_notices(e):o("html, body").animate({scrollTop:e.offset().top-100},1e3)},wc_stripe.BaseGateway.prototype.get_billing_details=function(){var t={name:this.get_customer_name("billing"),address:{city:this.fields.get("billing_city",null),country:this.fields.get("billing_country",null),line1:this.fields.get("billing_address_1",null),line2:this.fields.get("billing_address_2",null),postal_code:this.fields.get("billing_postcode",null),state:this.fields.get("billing_state",null)}};return t.name&&" "!==t.name||delete t.name,""!=this.fields.get("billing_email")&&(t.email=this.fields.get("billing_email")),""!=this.fields.get("billing_phone")&&(t.phone=this.fields.get("billing_phone")),t},wc_stripe.BaseGateway.prototype.get_first_name=function(t){return o("#"+t+"_first_name").val()},wc_stripe.BaseGateway.prototype.get_last_name=function(t){return o("#"+t+"_last_name").val()},wc_stripe.BaseGateway.prototype.get_shipping_prefix=function(){return this.needs_shipping()&&0<o('[name="ship_to_different_address"]').length&&o('[name="ship_to_different_address"]').is(":checked")?"shipping":"billing"},wc_stripe.BaseGateway.prototype.should_save_method=function(){return o("#"+this.gateway_id+"_save_source_key").is(":checked")},wc_stripe.BaseGateway.prototype.is_add_payment_method_page=function(){return"add_payment_method"===this.get_page()||o(document.body).hasClass("woocommerce-add-payment-method")},wc_stripe.BaseGateway.prototype.is_change_payment_method=function(){return"change_payment_method"===this.get_page()},wc_stripe.BaseGateway.prototype.get_selected_payment_method=function(){return o(this.saved_method_selector).val()},wc_stripe.BaseGateway.prototype.needs_shipping=function(){return this.get_gateway_data().needs_shipping},wc_stripe.BaseGateway.prototype.get_currency=function(){return this.get_gateway_data().currency},wc_stripe.BaseGateway.prototype.get_gateway_data=function(){var t=o(this.container).find(".woocommerce_".concat(this.gateway_id,"_gateway_data")).data("gateway");return void 0===t&&this.is_current_page("checkout")&&void 0===(t=o("form.checkout").find(".woocommerce_".concat(this.gateway_id,"_gateway_data")).data("gateway"))&&(t=o(".woocommerce_"+this.gateway_id+"_gateway_data").data("gateway")),t},wc_stripe.BaseGateway.prototype.set_gateway_data=function(t){o(this.container).find(".woocommerce_".concat(this.gateway_id,"_gateway_data")).data("gateway",t)},wc_stripe.BaseGateway.prototype.get_customer_name=function(t){return this.fields.get(t+"_first_name")+" "+this.fields.get(t+"_last_name")},wc_stripe.BaseGateway.prototype.get_customer_email=function(){return this.fields.get("billing_email")},wc_stripe.BaseGateway.prototype.get_address_field_hash=function(t){for(var e=["_first_name","_last_name","_address_1","_address_2","_postcode","_city","_state","_country"],i="",s=0;s<e.length;s++)i+=this.fields.get(t+e[s])+"_";return i},wc_stripe.BaseGateway.prototype.block=function(){o().block&&o.blockUI({message:null,overlayCSS:{background:"#fff",opacity:.6}})},wc_stripe.BaseGateway.prototype.unblock=function(){o().block&&o.unblockUI()},wc_stripe.BaseGateway.prototype.get_form=function(){return o(this.token_selector).closest("form")},wc_stripe.BaseGateway.prototype.get_total_price=function(){return this.get_gateway_data().total},wc_stripe.BaseGateway.prototype.get_total_price_cents=function(){return this.get_gateway_data().total_cents},wc_stripe.BaseGateway.prototype.set_total_price=function(t){var e=this.get_gateway_data();e.total=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.set_total_price_cents=function(t){var e=this.get_gateway_data();e.total_cents=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.set_payment_method=function(t){o('[name="payment_method"][value="'+t+'"]').prop("checked",!0).trigger("click")},wc_stripe.BaseGateway.prototype.set_selected_shipping_methods=function(t){if(this.fields.set("shipping_method",t),t&&o('[name^="shipping_method"]').length)for(var e in t){var i=t[e];o('[name="shipping_method['+e+']"][value="'+i+'"]').prop("checked",!0).trigger("change")}},wc_stripe.BaseGateway.prototype.on_token_received=function(t){this.payment_token_received=!0,this.set_nonce(t.id),this.process_checkout()},wc_stripe.BaseGateway.prototype.createPaymentRequest=function(){try{this.payment_request_options=this.get_payment_request_options(),this.paymentRequest=i.paymentRequest(this.payment_request_options),this.payment_request_options.requestShipping&&(this.paymentRequest.on("shippingaddresschange",this.update_shipping_address.bind(this)),this.paymentRequest.on("shippingoptionchange",this.update_shipping_method.bind(this))),this.paymentRequest.on("paymentmethod",this.on_payment_method_received.bind(this))}catch(t){return void this.submit_error(t.message)}},wc_stripe.BaseGateway.prototype.get_payment_request_options=function(){var t={country:this.params.country_code,currency:this.get_currency().toLowerCase(),total:{amount:this.get_total_price_cents(),label:this.params.total_label,pending:!0},requestPayerName:function(){return!this.is_current_page("checkout")||!this.is_valid_address(this.get_address_object("billing"),"billing",["email","phone"])}.bind(this)(),requestPayerEmail:this.fields.requestFieldInWallet("billing_email"),requestPayerPhone:this.fields.requestFieldInWallet("billing_phone"),requestShipping:function(){if(this.needs_shipping()){var t=this.get_shipping_prefix();if(this.is_current_page("checkout")&&!this.is_valid_address(this.get_address_object(t),t,["email","phone"])||!this.is_current_page("checkout"))return!0}return!1}.bind(this)()},e=this.get_display_items(),i=this.get_shipping_options();return e&&(t.displayItems=e),t.requestShipping&&i&&(t.shippingOptions=i),t},wc_stripe.BaseGateway.prototype.get_payment_request_update=function(t){var e={currency:this.get_currency().toLowerCase(),total:{amount:parseInt(this.get_total_price_cents()),label:this.params.total_label,pending:!0}},i=this.get_display_items(),s=this.get_shipping_options();return i&&(e.displayItems=i),this.payment_request_options.requestShipping&&s&&(e.shippingOptions=s),t&&(e=o.extend(!0,{},e,t)),e},wc_stripe.BaseGateway.prototype.get_display_items=function(){return this.get_gateway_data().items},wc_stripe.BaseGateway.prototype.set_display_items=function(t){var e=this.get_gateway_data();e.items=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.get_shipping_options=function(){return this.get_gateway_data().shipping_options},wc_stripe.BaseGateway.prototype.set_shipping_options=function(t){var e=this.get_gateway_data();e.shipping_options=t,this.set_gateway_data(e)},wc_stripe.BaseGateway.prototype.map_address=function(t){return{city:t.city,postcode:t.postalCode,state:t.region,country:t.country}},wc_stripe.BaseGateway.prototype.on_payment_method_received=function(t){try{this.payment_response=t,this.populate_checkout_fields(t),t.complete("success"),this.on_token_received(t.paymentMethod)}catch(e){a.alert(e)}},wc_stripe.BaseGateway.prototype.populate_checkout_fields=function(t){this.set_nonce(t.paymentMethod.id),this.update_addresses(t)},wc_stripe.BaseGateway.prototype.update_addresses=function(t){t.payerName&&this.fields.set("name",t.payerName,"billing"),t.payerEmail&&this.fields.set("email",t.payerEmail,"billing"),t.payerPhone&&(this.fields.set("phone",t.payerPhone,"billing"),this.fields.exists("shipping_phone")&&this.fields.isEmpty("shipping_phone")&&this.fields.set("shipping_phone",t.payerPhone)),t.shippingAddress&&this.populate_shipping_fields(t.shippingAddress),t.paymentMethod.billing_details.address&&this.populate_billing_fields(t.paymentMethod.billing_details.address)},wc_stripe.BaseGateway.prototype.populate_address_fields=function(t,e){for(var i in t)null!==t[i]&&this.fields.set(i,t[i],e)},wc_stripe.BaseGateway.prototype.populate_billing_fields=function(t){this.populate_address_fields(t,"billing")},wc_stripe.BaseGateway.prototype.populate_shipping_fields=function(t){this.populate_address_fields(t,"shipping")},wc_stripe.BaseGateway.prototype.get_address_fields=function(){return["first_name","last_name","country","address_1","address_2","city","state","postcode","phone","email"]},wc_stripe.BaseGateway.prototype.get_address_object=function(e){var i={};return this.get_address_fields().forEach(function(t){i[t]=this.fields.get(t,e)}.bind(this)),i},wc_stripe.BaseGateway.prototype.is_current_page=function(t){return this.get_page()===t},wc_stripe.BaseGateway.prototype.is_valid_address=function(t,e,i){if(o.isEmptyObject(t))return!1;var s=this.get_address_fields();void 0!==i&&i.forEach(function(t){-1<s.indexOf(t)&&s.splice(s.indexOf(t),1)});for(var a=0;a<s.length;a++){var n=s[a];if(this.fields.required(e+"_"+n)&&(!t[n]||"undefined"==typeof t[n]||!this.fields.isValid(n,t[n],t)))return!1}return!0},wc_stripe.BaseGateway.prototype.ajax_before_send=function(t){0<this.params.user_id&&t.setRequestHeader("X-WP-Nonce",this.params.rest_nonce)},wc_stripe.BaseGateway.prototype.process_checkout=function(){return new Promise(function(){this.block(),o.ajax({url:this.params.routes.checkout,method:"POST",dataType:"json",data:o.extend({},this.serialize_fields(),{payment_method:this.gateway_id,page_id:this.get_page(),currency:this.get_currency()}),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.reload?a.location.reload():"success"===t.result?a.location=t.redirect:(t.messages&&this.submit_error(t.messages),this.unblock())}.bind(this)).fail(function(t,e,i){this.unblock(),this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.BaseGateway.prototype.process_payment=function(t,e){o.ajax({method:"POST",url:this.params.routes.checkout_payment,dataType:"json",data:o.extend({},this.fields.toJson(),{order_id:t,order_key:e}),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){if(t.result&&"success"===t.result)a.location=t.redirect;else{if(t.reload)return a.location.reload();t.messages?this.submit_error(t.messages):this.submit_error(wc_checkout_params.i18n_checkout_error)}}.bind(this)).fail(function(){}.bind(this))},wc_stripe.BaseGateway.prototype.handle_card_action=function(e){try{return this.stripe.handleCardAction(e.client_secret).then(function(t){if(t.error)return this.payment_token_received=!1,this.submit_error(t.error),void this.sync_payment_intent(e.order_id,e.client_secret)["catch"](function(t){this.submit_error(t.message)}.bind(this));this.is_current_page("order_pay")?this.get_form().submit():this.process_payment(e.order_id,e.order_key)}.bind(this))["catch"](function(t){this.submit_error(t.message)}.bind(this)),!1}catch(t){}},wc_stripe.BaseGateway.prototype.hashchange=function(t){var e=t.newURL.match(/response=(.*)/);if(e)try{var i=JSON.parse(a.atob(decodeURIComponent(e[1])));i&&i.hasOwnProperty("client_secret")&&i.gateway_id===this.gateway_id&&(history.pushState({},"",a.location.pathname),this.handle_card_action(i))}catch(s){}return!0},wc_stripe.BaseGateway.prototype.sync_payment_intent=function(t,s){return new Promise(function(e,i){o.when(o.ajax({method:"POST",dataType:"json",url:this.params.routes.sync_intent,data:{order_id:t,client_secret:s},beforeSend:this.ajax_before_send.bind(this)})).done(function(t){(t.code?i:e)(t)}).fail(function(t,e,i){this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.BaseGateway.prototype.serialize_form=function(t){var e,i=t.find("input").filter(function(t,e){return!o(e).is('[name^="add-to-cart"]')}.bind(this)).serializeArray(),s={};for(e in i){var a=i[e];s[a.name]=a.value}return s.payment_method=this.gateway_id,s},wc_stripe.BaseGateway.prototype.serialize_fields=function(){return o.extend({},this.fields.toJson(),o(document.body).triggerHandler("wc_stripe_process_checkout_data",[this,this.fields]))},wc_stripe.BaseGateway.prototype.map_shipping_methods=function(t){var e={};return"default"===t||1<(t=t.match(/^([\w+]):(.+)$/)).length&&(e[t[1]]=t[2]),e},wc_stripe.BaseGateway.prototype.maybe_set_ship_to_different=function(){o('[name="ship_to_different_address"]').length&&o('[name="ship_to_different_address"]').prop("checked",this.get_address_field_hash("billing")!==this.get_address_field_hash("shipping")).trigger("change")},wc_stripe.BaseGateway.prototype.update_shipping_address=function(s){return new Promise(function(e,i){o.ajax({url:this.params.routes.shipping_address,method:"POST",dataType:"json",data:{address:this.map_address(s.shippingAddress),payment_method:this.gateway_id,page_id:this.get_page(),currency:this.get_currency()},beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.code?(s.updateWith(t.data.newData),i(t.data)):(s.updateWith(t.data.newData),this.fields.set("shipping_method",t.data.shipping_method),e(t.data))}.bind(this)).fail(function(){}.bind(this))}.bind(this))},wc_stripe.BaseGateway.prototype.update_shipping_method=function(s){return new Promise(function(e,i){o.ajax({url:this.params.routes.shipping_method,method:"POST",dataType:"json",data:{shipping_method:s.shippingOption.id,payment_method:this.gateway_id,currency:this.get_currency(),page_id:this.get_page()},beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.code?(s.updateWith(t.data.newData),i(t.data)):(this.set_selected_shipping_methods(t.data.shipping_methods),s.updateWith(t.data.newData),e(t.data))}.bind(this)).fail(function(t,e,i){this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.CheckoutGateway=function(){this.message_container="li.payment_method_"+this.gateway_id,this.banner_container="li.banner_payment_method_"+this.gateway_id,o(document.body).on("update_checkout",this.update_checkout.bind(this)),o(document.body).on("updated_checkout",this.updated_checkout.bind(this)),o(document.body).on("updated_checkout",this.container_styles.bind(this)),o(document.body).on("cfw_updated_checkout",this.updated_checkout.bind(this)),o(document.body).on("checkout_error",this.checkout_error.bind(this)),o(this.token_selector).closest("form").on("checkout_place_order_"+this.gateway_id,this.checkout_place_order.bind(this)),o(document.body).on("wc_stripe_new_method_"+this.gateway_id,this.on_show_new_methods.bind(this)),o(document.body).on("wc_stripe_saved_method_"+this.gateway_id,this.on_show_saved_methods.bind(this)),o(document.body).on("wc_stripe_payment_method_selected",this.on_payment_method_selected.bind(this)),this.banner_enabled()&&o(".woocommerce-billing-fields").length&&o(".wc-stripe-banner-checkout").css("max-width",o(".woocommerce-billing-fields").outerWidth(!0)),this.container_styles(),this.hasOrderReviewParams()},wc_stripe.CheckoutGateway.prototype.container_styles=function(){this.params.description||o(this.container).addClass("wc-stripe-no-desc"),o(this.container).find(".wc-stripe-saved-methods").length||o(this.container).find(".payment_box").addClass("wc-stripe-no-methods")},wc_stripe.CheckoutGateway.prototype.hasOrderReviewParams=function(){var t=a.location.search.match(/_stripe_order_review=(.+)/);if(t&&1<t.length)try{var e=JSON.parse(a.atob(decodeURIComponent(t[1])));this.gateway_id===e.payment_method&&(o(function(){this.payment_token_received=!0,this.set_nonce(e.payment_nonce),this.set_use_new_option(!0)}.bind(this)),history.pushState({},"",a.location.pathname))}catch(i){}},wc_stripe.CheckoutGateway.prototype.has3DSecureParams=function(){if((this.is_current_page("order_pay")||this.is_change_payment_method())&&a.location.hash&&"string"==typeof a.location.hash){var t=a.location.hash.match(/response=(.*)/);if(t)try{var e=JSON.parse(a.atob(decodeURIComponent(t[1])));e&&e.hasOwnProperty("client_secret")&&e.gateway_id===this.gateway_id&&(o(function(){this.set_payment_method(this.gateway_id),this.set_use_new_option(!0),this.set_nonce(e.pm),!0===e.save_method&&this.set_save_payment_method(!0),o('[name="terms"]').prop("checked",!0)}.bind(this)),history.pushState({},"",a.location.pathname+a.location.search),this.handle_card_action(e))}catch(i){}}},wc_stripe.CheckoutGateway.prototype.update_shipping_address=function(){return wc_stripe.BaseGateway.prototype.update_shipping_address.apply(this,arguments).then(function(t){this.populate_address_fields(t.address,this.get_shipping_prefix()),this.fields.toFormFields({update_shipping_method:!1})}.bind(this))},wc_stripe.CheckoutGateway.prototype.updated_checkout=function(){},wc_stripe.CheckoutGateway.prototype.update_checkout=function(){},wc_stripe.CheckoutGateway.prototype.checkout_error=function(){this.has_checkout_error()&&(this.payment_token_received=!1,this.payment_response=null,this.show_payment_button(),this.hide_place_order())},wc_stripe.CheckoutGateway.prototype.is_valid_checkout=function(){return!(o('[name="terms"]').length&&!o('[name="terms"]').is(":checked"))},wc_stripe.CheckoutGateway.prototype.get_payment_method=function(){return o('[name="payment_method"]:checked').val()},wc_stripe.CheckoutGateway.prototype.set_use_new_option=function(t){o("#"+this.gateway_id+"_use_new").prop("checked",t).trigger("change")},wc_stripe.CheckoutGateway.prototype.checkout_place_order=function(){return this.is_valid_checkout()?!!this.is_saved_method_selected()||this.payment_token_received:(this.submit_error(this.params.messages.terms),!1)},wc_stripe.CheckoutGateway.prototype.on_token_received=function(t){this.payment_token_received=!0,this.set_nonce(t.id),this.hide_payment_button(),this.show_place_order()},wc_stripe.CheckoutGateway.prototype.block=function(){o().block&&o("form.checkout").block({message:null,overlayCSS:{background:"#fff",opacity:.6}})},wc_stripe.CheckoutGateway.prototype.unblock=function(){o().block&&o("form.checkout").unblock()},wc_stripe.CheckoutGateway.prototype.hide_place_order=function(){o("#place_order").addClass("wc-stripe-hide")},wc_stripe.CheckoutGateway.prototype.show_place_order=function(){o("#place_order").removeClass("wc-stripe-hide")},wc_stripe.CheckoutGateway.prototype.on_show_new_methods=function(){this.payment_token_received?(this.show_place_order(),this.hide_payment_button()):(this.hide_place_order(),this.show_payment_button())},wc_stripe.CheckoutGateway.prototype.on_show_saved_methods=function(){this.hide_payment_button(),this.show_place_order()},wc_stripe.CheckoutGateway.prototype.show_payment_button=function(){this.$button&&this.$button.show()},wc_stripe.CheckoutGateway.prototype.hide_payment_button=function(){this.$button&&this.$button.hide()},wc_stripe.CheckoutGateway.prototype.trigger_payment_method_selected=function(){this.on_payment_method_selected(null,o('[name="payment_method"]:checked').val())},wc_stripe.CheckoutGateway.prototype.on_payment_method_selected=function(t,e){e===this.gateway_id?this.payment_token_received||this.is_saved_method_selected()?(this.hide_payment_button(),this.show_place_order()):(this.show_payment_button(),this.hide_place_order()):(this.hide_payment_button(),e.indexOf("stripe_")<0&&this.show_place_order())},wc_stripe.CheckoutGateway.prototype.banner_enabled=function(){return"1"===this.params.banner_enabled},wc_stripe.CheckoutGateway.prototype.checkout_fields_valid=function(){if(["checkout","order_pay"].indexOf(this.get_page())<0)return!0;var t=!0;return(t=this.fields.validateFields("billing"))?this.needs_shipping()&&o("#ship-to-different-address-checkbox").is(":checked")?(t=this.fields.validateFields("shipping"))||this.submit_error(this.params.messages.required_field):(t=this.is_valid_checkout())||this.submit_error(this.params.messages.terms):this.submit_error(this.params.messages.required_field),t},wc_stripe.CheckoutGateway.prototype.cart_contains_subscription=function(){return"undefined"!=typeof wc_stripe_cart_contains_subscription&&!0===wc_stripe_cart_contains_subscription},wc_stripe.CheckoutGateway.prototype.set_save_payment_method=function(t){o('[name="'+this.gateway_id+'_save_source_key"]').prop("checked",t)},wc_stripe.ProductGateway=function(){this.message_container="div.product",o("form.cart").on("found_variation",this.found_variation.bind(this)),o("form.cart").on("reset_data",this.reset_variation_data.bind(this)),this.buttonWidth=o("form.cart div.quantity").outerWidth(!0)+o(".single_add_to_cart_button").outerWidth();var t=o(".single_add_to_cart_button").css("marginLeft");t&&(this.buttonWidth+=parseInt(t.replace("px",""))),o(this.container).css("max-width",this.buttonWidth+"px")},wc_stripe.ProductGateway.prototype.get_quantity=function(){return parseInt(o('[name="quantity"]').val())},wc_stripe.ProductGateway.prototype.set_rest_nonce=function(t,e){this.params.rest_nonce=e},wc_stripe.ProductGateway.prototype.found_variation=function(t,e){var i=this.get_gateway_data();i.product.price=e.display_price,i.needs_shipping=!e.is_virtual,i.product.variation=e,this.set_gateway_data(i)},wc_stripe.ProductGateway.prototype.reset_variation_data=function(){var t=this.get_product_data();t.variation=!1,this.set_product_data(t),this.disable_payment_button()},wc_stripe.ProductGateway.prototype.disable_payment_button=function(){this.$button&&this.get_button().prop("disabled",!0).addClass("disabled")},wc_stripe.ProductGateway.prototype.enable_payment_button=function(){this.$button&&this.get_button().prop("disabled",!1).removeClass("disabled")},wc_stripe.ProductGateway.prototype.get_button=function(){return this.$button},wc_stripe.ProductGateway.prototype.is_variable_product=function(){return 0<o('[name="variation_id"]').length},wc_stripe.ProductGateway.prototype.variable_product_selected=function(){return!1!==this.get_product_data().variation},wc_stripe.ProductGateway.prototype.get_product_data=function(){return this.get_gateway_data().product},wc_stripe.ProductGateway.prototype.set_product_data=function(t){var e=this.get_gateway_data();e.product=t,this.set_gateway_data(e)},wc_stripe.ProductGateway.prototype.add_to_cart=function(){return new Promise(function(e,i){this.block(),o.ajax({url:this.params.routes.add_to_cart,method:"POST",dataType:"json",data:o.extend({},{product_id:this.get_product_data().id,variation_id:this.is_variable_product()?o('[name="variation_id"]').val():0,qty:o('[name="quantity"]').val(),payment_method:this.gateway_id,currency:this.get_currency(),page_id:this.get_page()},this.get_product_variations()),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){this.unblock(),t.code?(this.submit_error(t.message),i(t)):(this.set_total_price(t.data.total),this.set_total_price_cents(t.data.totalCents),this.set_display_items(t.data.displayItems),e(t.data))}.bind(this)).fail(function(t,e,i){this.unblock(),this.submit_error(i)}.bind(this))}.bind(this))},wc_stripe.ProductGateway.prototype.cart_calculation=function(t){return new Promise(function(e,i){o.ajax({url:this.params.routes.cart_calculation,method:"POST",dataType:"json",data:o.extend({},{product_id:this.get_product_data().id,variation_id:this.is_variable_product()&&t?t:0,qty:o('[name="quantity"]').val(),currency:this.get_currency(),payment_method:this.gateway_id},this.get_product_variations()),beforeSend:this.ajax_before_send.bind(this)}).done(function(t){t.code?(this.cart_calculation_error=!0,i(t)):(this.set_total_price(t.data.total),this.set_total_price_cents(t.data.totalCents),this.set_display_items(t.data.displayItems),e(t.data))}.bind(this)).fail(function(){}.bind(this))}.bind(this))},wc_stripe.ProductGateway.prototype.get_product_variations=function(){var s={};return this.is_variable_product()&&o('.variations [name^="attribute_"]').each(function(t,e){var i=o(e),e=i.data("attribute_name")||i.attr("name");s[e]=i.val()}),s},wc_stripe.CartGateway=function(){this.message_container="div.woocommerce",o(document.body).on("updated_wc_div",this.updated_html.bind(this)),o(document.body).on("updated_cart_totals",this.updated_html.bind(this)),o(document.body).on("wc_cart_emptied",this.cart_emptied.bind(this))},wc_stripe.CartGateway.prototype.submit_error=function(t){this.submit_message(this.get_error_message(t))},wc_stripe.CartGateway.prototype.updated_html=function(t){},wc_stripe.CartGateway.prototype.cart_emptied=function(t){},wc_stripe.CartGateway.prototype.add_cart_totals_class=function(){o(".cart_totals").addClass("stripe_cart_gateway_active")},wc_stripe.GooglePay=function(){};var s={apiVersion:2,apiVersionMinor:0},n={type:"CARD",parameters:{allowedAuthMethods:["PAN_ONLY"],allowedCardNetworks:["AMEX","DISCOVER","INTERAC","JCB","MASTERCARD","VISA"],assuranceDetailsRequired:!0}};wc_stripe.GooglePay.prototype.update_addresses=function(t){var e;t.paymentMethodData.info.billingAddress&&(e=t.paymentMethodData.info.billingAddress,this.is_current_page("checkout")&&this.is_valid_address(this.billing_address_object,"billing",["phone","email"])&&(e={phoneNumber:e.phoneNumber}),this.populate_billing_fields(e),e.phoneNumber&&this.fields.exists("shipping_phone")&&this.fields.isEmpty("shipping_phone")&&this.fields.set("shipping_phone",e.phoneNumber)),t.shippingAddress&&this.populate_shipping_fields(t.shippingAddress),t.email&&this.fields.set("email",t.email,"billing")},wc_stripe.GooglePay.prototype.map_address=function(t){return{city:t.locality,postcode:t.postalCode,state:t.administrativeArea,country:t.countryCode}},wc_stripe.GooglePay.prototype.update_payment_data=function(s){return new Promise(function(e,i){var t="default"==s.shippingOptionData.id?null:s.shippingOptionData.id;o.when(o.ajax({url:this.params.routes.payment_data,dataType:"json",method:"POST",data:{address:this.map_address(s.shippingAddress),shipping_method:t,page_id:this.get_page(),currency:this.get_currency()},beforeSend:this.ajax_before_send.bind(this)})).done(function(t){t.code?i(t.data.data):e(t.data)}.bind(this)).fail(function(){i()}.bind(this))}.bind(this))},wc_stripe.GooglePay.prototype.on_payment_data_changed=function(i){return new Promise(function(e){this.update_payment_data(i).then(function(t){e(t.paymentRequestUpdate),this.set_selected_shipping_methods(t.shipping_methods),this.payment_data_updated(t,i)}.bind(this))["catch"](function(t){e(t)}.bind(this))}.bind(this))},wc_stripe.GooglePay.prototype.payment_data_updated=function(t){},wc_stripe.GooglePay.prototype.get_merchant_info=function(){var t={merchantId:this.params.merchant_id,merchantName:this.params.merchant_name};return"TEST"===this.params.environment&&delete t.merchantId,t},wc_stripe.GooglePay.prototype.get_payment_options=function(){var t,e={environment:this.params.environment,merchantInfo:this.get_merchant_info(),paymentDataCallbacks:{onPaymentAuthorized:function(){return new Promise(function(t){t({transactionState:"SUCCESS"})}.bind(this))}}};return this.needs_shipping()&&(t=this.get_shipping_prefix(),(!this.is_current_page("checkout")||this.is_valid_address(this.get_address_object(t),t,["email","phone"]))&&this.is_current_page("checkout")||(e.paymentDataCallbacks.onPaymentDataChanged=this.on_payment_data_changed.bind(this))),e},wc_stripe.GooglePay.prototype.build_payment_request=function(){var t=o.extend({},s,{emailRequired:this.fields.requestFieldInWallet("billing_email"),merchantInfo:this.get_merchant_info(),allowedPaymentMethods:[o.extend({type:"CARD",tokenizationSpecification:{type:"PAYMENT_GATEWAY",parameters:{gateway:"stripe","stripe:version":"2018-10-31","stripe:publishableKey":this.params.api_key}}},n)],shippingAddressRequired:function(){if(this.needs_shipping()){var t=this.get_shipping_prefix();if(this.is_current_page("checkout")&&!this.is_valid_address(this.get_address_object(t),t,["email","phone"])||!this.is_current_page("checkout"))return!0}return!1}.bind(this)(),transactionInfo:{countryCode:this.params.processing_country,currencyCode:this.get_currency(),totalPriceStatus:"ESTIMATED",totalPrice:this.get_total_price().toString(),displayItems:this.get_display_items(),totalPriceLabel:this.params.total_price_label}});return t.allowedPaymentMethods[0].parameters.billingAddressRequired=function(){if(this.is_current_page("checkout")){var t=this.billing_address_object=this.get_address_object("billing");return this.fields.requestFieldInWallet("billing_phone")||!this.is_valid_address(t,"billing",["email"])?!0:!1}return!0}.bind(this)(),t.allowedPaymentMethods[0].parameters.billingAddressRequired&&(t.allowedPaymentMethods[0].parameters.billingAddressParameters={format:"FULL",phoneNumberRequired:this.fields.requestFieldInWallet("billing_phone")}),t.shippingAddressRequired?(t.shippingAddressParameters={},t.shippingOptionRequired=!0,t.shippingOptionParameters={shippingOptions:this.get_shipping_options()},t.callbackIntents=["SHIPPING_ADDRESS","SHIPPING_OPTION","PAYMENT_AUTHORIZATION"]):t.callbackIntents=["PAYMENT_AUTHORIZATION"],this.payment_request_options=t},wc_stripe.GooglePay.prototype.createPaymentsClient=function(){this.paymentsClient=new google.payments.api.PaymentsClient(this.get_payment_options())},wc_stripe.GooglePay.prototype.isReadyToPay=function(){return new Promise(function(t){var e=o.extend({},s);e.allowedPaymentMethods=[n],this.paymentsClient.isReadyToPay(e).then(function(){this.can_pay=!0,this.create_button(),t()}.bind(this))["catch"](function(t){this.submit_error(t)}.bind(this))}.bind(this))},wc_stripe.GooglePay.prototype.create_button=function(){this.$button&&this.$button.remove(),this.$button=o(this.paymentsClient.createButton({onClick:this.start.bind(this),buttonColor:this.params.button_color,buttonType:this.params.button_style})),this.$button.addClass("gpay-button-container")},wc_stripe.GooglePay.prototype.start=function(){this.createPaymentsClient(),this.paymentsClient.loadPaymentData(this.build_payment_request()).then(function(t){var e=JSON.parse(t.paymentMethodData.tokenizationData.token);this.update_addresses(t),this.stripe.createPaymentMethod({type:"card",card:{token:e.id},billing_details:this.get_billing_details()}).then(function(t){if(t.error)return this.submit_error(t.error);this.on_token_received(t.paymentMethod)}.bind(this))}.bind(this))["catch"](function(t){"CANCELED"!==t.statusCode&&(t.statusMessage&&-1<t.statusMessage.indexOf("paymentDataRequest.callbackIntent")?this.submit_error_code("DEVELOPER_ERROR_WHITELIST"):this.submit_error(t.statusMessage))}.bind(this))},wc_stripe.ApplePay=function(){},wc_stripe.ApplePay.prototype.initialize=function(){this.createPaymentRequest(),this.canMakePayment()},wc_stripe.ApplePay.prototype.create_button=function(){this.$button&&this.$button.remove(),this.$button=o(this.params.button),this.$button.on("click",this.start.bind(this)),this.append_button()},wc_stripe.ApplePay.prototype.canMakePayment=function(){return new Promise(function(e){this.paymentRequest.canMakePayment().then(function(t){t&&t.applePay&&(this.can_pay=!0,this.create_button(),o(this.container).show(),e(t))}.bind(this))}.bind(this))},wc_stripe.ApplePay.prototype.start=function(t){t.preventDefault(),this.paymentRequest.update(this.get_payment_request_update({total:{pending:!1}})),this.paymentRequest.show()},wc_stripe.PaymentRequest=function(){},wc_stripe.PaymentRequest.prototype.initialize=function(){this.createPaymentRequest(),this.createPaymentRequestButton(),this.canMakePayment(),this.paymentRequestButton.on("click",this.button_click.bind(this))},wc_stripe.PaymentRequest.prototype.button_click=function(t){},wc_stripe.PaymentRequest.prototype.createPaymentRequestButton=function(){this.paymentRequestButton&&this.paymentRequestButton.destroy(),this.paymentRequestButton=this.elements.create("paymentRequestButton",{paymentRequest:this.paymentRequest,style:{paymentRequestButton:{type:this.params.button.type,theme:this.params.button.theme,height:this.params.button.height}}})},wc_stripe.PaymentRequest.prototype.canMakePayment=function(){return new Promise(function(e){this.paymentRequest.canMakePayment().then(function(t){t&&!t.applePay&&(this.can_pay=!0,this.create_button(),o(this.container).show(),e(t))}.bind(this))}.bind(this))},wc_stripe.PaymentRequest.prototype.create_button=function(){this.paymentRequestButton.mount("#wc-stripe-payment-request-container")},wc_stripe.CheckoutFields=function(t,e){this.params=t,this.page=e,this.session_values=this.supportsSessionStorage()&&sessionStorage.getItem("wc_stripe_checkout_fields")?JSON.parse(sessionStorage.getItem("wc_stripe_checkout_fields")):{},this.fields=new Map(Object.keys(this.params).map(function(t){return null===this.params[t].value&&(t in this.session_values&&null!==this.session_values[t]?this.params[t].value=this.session_values[t]:this.params[t].value=""),[t,this.params[t].value]}.bind(this))),("checkout"===e||"cart"===e&&o(document.body).is(".woocommerce-checkout"))&&(o("form.checkout").on("change",".input-text, select",this.onChange.bind(this)),o("form.checkout").on("change",'[name="ship_to_different_address"]',this.on_ship_to_address_change.bind(this)),this.init_i18n(),o('[name="ship_to_different_address"]').is(":checked")?this.update_required_fields(o("#shipping_country").val(),"shipping_country"):this.update_required_fields(o("#billing_country").val(),"billing_country"))},wc_stripe.CheckoutFields.prototype.supportsSessionStorage=function(){return"sessionStorage"in a&&null!==a.sessionStorage&&["getItem","setItem"].reduce(function(t,e){return t&&e in sessionStorage}.bind(this),!0)},wc_stripe.CheckoutFields.prototype.init_i18n=function(){"undefined"!=typeof wc_address_i18n_params?this.locales=JSON.parse(wc_address_i18n_params.locale.replace(/&quot;/g,'"')):this.locales=null},wc_stripe.CheckoutFields.prototype.onChange=function(t){try{var e=t.currentTarget.name,i=t.currentTarget.value;this.fields.set(e,i),"billing_country"!==e&&"shipping_country"!==e||this.update_required_fields(i,e),this.supportsSessionStorage()&&sessionStorage.setItem("wc_stripe_checkout_fields",JSON.stringify(this.toJson()))}catch(s){console.log(s)}},wc_stripe.CheckoutFields.prototype.update_required_fields=function(t,e){if(this.locales){var i,s=-1<e.indexOf("billing_")?"billing_":"shipping_",t="undefined"!=typeof this.locales[t]?this.locales[t]:this.locales["default"],a=o.extend(!0,{},this.locales["default"],t);for(i in a){var n=s+i;this.params[n]&&(this.params[n]=o.extend(!0,{},this.params[n],a[i]))}}},wc_stripe.CheckoutFields.prototype.on_ship_to_address_change=function(t){o(t.currentTarget).is(":checked")&&this.update_required_fields(o("#shipping_country").val(),"shipping_country")},wc_stripe.CheckoutFields.prototype.requestFieldInWallet=function(t){return"checkout"===this.page?this.required(t)&&this.isEmpty(t):"order_pay"!==this.page&&this.required(t)},wc_stripe.CheckoutFields.prototype.set=function(t,e,i){this[t]&&"function"==typeof this[t]?this[t]().set.call(this,e,i):this.fields.set(t,e)},wc_stripe.CheckoutFields.prototype.get=function(t,e){var i;return this[t]&&"function"==typeof this[t]?i=this[t]().get.call(this,e):null!=(i=this.fields.get(t))&&""!==i||void 0!==e&&(i=e),void 0===i?"":i},wc_stripe.CheckoutFields.prototype.required=function(t){return!(!this.params[t]||"undefined"==typeof this.params[t].required)&&this.params[t].required},wc_stripe.CheckoutFields.prototype.exists=function(t){return t in this.params},wc_stripe.CheckoutFields.prototype.isEmpty=function(t){if(this.fields.has(t)){t=this.fields.get(t);return null==t||"string"==typeof t&&0===t.trim().length}return!0},wc_stripe.CheckoutFields.prototype.isValid=function(t){if(this[t]&&"function"==typeof this[t])return this[t]().isValid.apply(this,Array.prototype.slice.call(arguments,1))},wc_stripe.CheckoutFields.prototype.first_name=function(){return{set:function(t,e){this.fields.set(e+"_first_name",t)},get:function(t){return this.fields.get(t+"_first_name")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.last_name=function(){return{set:function(t,e){this.fields.set(e+"_last_name",t)},get:function(t){return this.fields.get(t+"_last_name")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.address_1=function(){return{set:function(t,e){this.fields.set(e+"_address_1",t)},get:function(t){return this.fields.get(t+"_address_1")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.address_2=function(){return{set:function(t,e){this.fields.set(e+"_address_2",t)},get:function(t){return this.fields.get(t+"_address_2")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.name=function(){return{set:function(t,e){t=t.split(" ");0<t.length&&this.fields.set(e+"_first_name",t[0]),1<t.length&&this.fields.set(e+"_last_name",t[1])},get:function(t){return this.fields.get(t+"_first_name")+" "+this.fields.get(t+"_last_name")}}},wc_stripe.CheckoutFields.prototype.email=function(){return{set:function(t,e){this.fields.set(e+"_email",t)},get:function(t){return this.fields.get(t+"_email")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.phone=function(){return{set:function(t,e){this.fields.set(e+"_phone",t)},get:function(t){return this.fields.get(t+"_phone")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.country=function(){return{set:function(t,e){this.fields.set(e+"_country",t)},get:function(t){return this.fields.get(t+"_country")},isValid:function(t){return"string"==typeof t&&2===t.length}}},wc_stripe.CheckoutFields.prototype.state=function(){return{set:function(i,t){2<(i=i.toUpperCase()).length&&"checkout"===this.page&&o("#"+t+"_state option").each(function(){var t=o(this),e=t.text().toUpperCase();i===e&&(i=t.val())}),this.fields.set(t+"_state",i)},get:function(t){return this.fields.get(t+"_state")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.city=function(){return{set:function(t,e){this.fields.set(e+"_city",t)},get:function(t){return this.fields.get(t+"_city")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.postcode=function(){return{set:function(t,e){this.fields.set(e+"_postcode",t)},get:function(t){return this.fields.get(t+"_postcode")},isValid:function(t){return"string"==typeof t&&0<t.length}}},wc_stripe.CheckoutFields.prototype.recipient=function(){return wc_stripe.CheckoutFields.prototype.name.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.payerName=function(){return wc_stripe.CheckoutFields.prototype.name.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.payerEmail=function(){return wc_stripe.CheckoutFields.prototype.email.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.payerPhone=function(){return wc_stripe.CheckoutFields.prototype.phone.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.phoneNumber=function(){return wc_stripe.CheckoutFields.prototype.phone.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.countryCode=function(){return wc_stripe.CheckoutFields.prototype.country.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.address1=function(){return wc_stripe.CheckoutFields.prototype.address_1.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.address2=function(){return wc_stripe.CheckoutFields.prototype.address_2.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.line1=function(){return wc_stripe.CheckoutFields.prototype.address_1.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.line2=function(){return wc_stripe.CheckoutFields.prototype.address_2.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.addressLine=function(){return{set:function(t,e){0<t.length&&this.fields.set(e+"_address_1",t[0]),1<t.length&&this.fields.set(e+"_address_2",t[1])},get:function(t){return[this.fields.get(t+"_address_1"),this.fields.get(t+"_address_2")]},isValid:function(t){return 0<t.length&&("string"==typeof t[0]&&0<t[0].length)}}},wc_stripe.CheckoutFields.prototype.region=function(){return wc_stripe.CheckoutFields.prototype.state.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.administrativeArea=function(){return wc_stripe.CheckoutFields.prototype.state.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.locality=function(){return wc_stripe.CheckoutFields.prototype.city.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.postal_code=function(){return wc_stripe.CheckoutFields.prototype.postcode.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.postalCode=function(){return wc_stripe.CheckoutFields.prototype.postcode.apply(this,arguments)},wc_stripe.CheckoutFields.prototype.toJson=function(){var i={};return this.fields.forEach(function(t,e){i[e]=t}),i},wc_stripe.CheckoutFields.prototype.toFormFields=function(t){var i=[];this.fields.forEach(function(t,e){e='[name="'+e+'"]';o(e).length&&""!==t&&(o(e).val()!==t&&o(e).is("select")&&i.push(e),o(e).val(t))}),0<i.length&&o(i.join(",")).trigger("change"),void 0!==t&&o(document.body).trigger("update_checkout",t)},wc_stripe.CheckoutFields.prototype.validateFields=function(t){for(var e in this.params){var i=this.params[e];if(-1<e.indexOf(t)&&i.required&&o("#"+e).length&&o("#"+e).is(":visible")){i=o("#"+e).val();if(null==i||0===i.length)return!1}}return!0};try{i=Stripe(wc_stripe_params_v3.api_key,"test"===wc_stripe_params_v3.mode&&""===wc_stripe_params_v3.account?{}:{stripeAccount:wc_stripe_params_v3.account})}catch(t){return a.alert(t),console.log(t)}var r=new wc_stripe.CheckoutFields(wc_stripe_checkout_fields,wc_stripe_params_v3.page)}(window,jQuery);
i18n/languages/woo-stripe-payment.pot CHANGED
@@ -2,14 +2,14 @@
2
  # This file is distributed under the same license as the Stripe For WooCommerce plugin.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Stripe For WooCommerce 3.2.12\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/woo-stripe-payment\n"
7
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
8
  "Language-Team: LANGUAGE <LL@li.org>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
- "POT-Creation-Date: 2021-02-03T06:59:33+00:00\n"
13
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
14
  "X-Generator: WP-CLI 2.4.0\n"
15
  "X-Domain: woo-stripe-payment\n"
@@ -116,11 +116,11 @@ msgstr ""
116
  msgid " & billing country is <strong>%s</strong>"
117
  msgstr ""
118
 
119
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:407
120
  msgid "Please fill out all required fields."
121
  msgstr ""
122
 
123
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:422
124
  #: includes/controllers/class-wc-stripe-controller-cart.php:134
125
  #: includes/controllers/class-wc-stripe-controller-cart.php:192
126
  #: includes/controllers/class-wc-stripe-controller-googlepay.php:136
@@ -128,138 +128,138 @@ msgstr ""
128
  msgid "Total"
129
  msgstr ""
130
 
131
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:492
132
  msgid "User must be logged in."
133
  msgstr ""
134
 
135
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:517
136
  msgid "Error saving payment method. Reason: %s"
137
  msgstr ""
138
 
139
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:536
140
  #: includes/wc-stripe-webhook-functions.php:217
141
  msgid "Order refunded in Stripe. Amount: %s"
142
  msgstr ""
143
 
144
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:574
145
  msgid "Order amount captured in Stripe. Amount: %s"
146
  msgstr ""
147
 
148
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:584
149
  msgid "Error capturing charge in Stripe. Reason: %s"
150
  msgstr ""
151
 
152
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:605
153
  msgid "Error voiding charge. Reason: %s"
154
  msgstr ""
155
 
156
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:607
157
  msgid "Charge voided in Stripe."
158
  msgstr ""
159
 
160
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:770
161
  msgid "n/a"
162
  msgstr ""
163
 
164
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:798
165
  #: includes/admin/meta-boxes/views/html-order-pay.php:42
166
  msgid "New Card"
167
  msgstr ""
168
 
169
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:802
170
  #: includes/admin/meta-boxes/views/html-order-pay.php:30
171
  msgid "Saved Cards"
172
  msgstr ""
173
 
174
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1009
175
- msgid "Attemp to save payment method failed. Reason: %s"
176
  msgstr ""
177
 
178
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1031
179
  msgid "We were not able to save your payment method. To prevent billing issues with your subscription, please add a payment method to the subscription."
180
  msgstr ""
181
 
182
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1033
183
  msgid "We were not able to save your payment method. Reason: %s"
184
  msgstr ""
185
 
186
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1067
187
  msgid "Payment Method Token"
188
  msgstr ""
189
 
190
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1087
191
  msgid "Recurring payment for order failed. Reason: %s"
192
  msgstr ""
193
 
194
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1100
195
  msgid "Recurring payment captured in Stripe. Payment method: %s"
196
  msgstr ""
197
 
198
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1102
199
  msgid "Recurring payment authorized in Stripe. Payment method: %s"
200
  msgstr ""
201
 
202
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1105
203
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1390
204
  msgid "Customer must manually complete payment for payment method %s"
205
  msgstr ""
206
 
207
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1121
208
- msgid "Error saving payment method for subscription. Reason: %s"
209
- msgstr ""
210
-
211
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1182
212
  #: includes/abstract/abstract-wc-stripe-payment.php:227
213
  msgid "Order %1$s from %2$s"
214
  msgstr ""
215
 
216
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1377
217
  msgid "Pre-order payment for order failed. Reason: %s"
218
  msgstr ""
219
 
220
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1385
221
  msgid "Pre-order payment captured in Stripe. Payment method: %s"
222
  msgstr ""
223
 
224
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1387
225
  msgid "Pre-order payment authorized in Stripe. Payment method: %s"
226
  msgstr ""
227
 
228
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1459
229
  msgid "Cannot process payment"
230
  msgstr ""
231
 
232
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1467
233
  msgid "Increase your conversion rate by offering %1$s on your Product and Cart pages, or at the top of the checkout page. <br/><strong>Note:</strong> you can control which products display %s by going to the product edit page."
234
  msgstr ""
235
 
236
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1581
237
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1612
238
  #: includes/gateways/class-wc-payment-gateway-stripe-klarna.php:192
239
- #: includes/wc-stripe-functions.php:412
240
- #: includes/wc-stripe-functions.php:477
241
  msgid "Shipping"
242
  msgstr ""
243
 
244
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1589
245
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1615
246
  #: includes/gateways/class-wc-payment-gateway-stripe-klarna.php:202
247
- #: includes/wc-stripe-functions.php:429
248
- #: includes/wc-stripe-functions.php:485
249
  msgid "Discount"
250
  msgstr ""
251
 
252
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1592
253
  #: includes/gateways/class-wc-payment-gateway-stripe-klarna.php:220
254
- #: includes/wc-stripe-functions.php:437
255
  msgid "Tax"
256
  msgstr ""
257
 
258
- #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1622
259
- #: includes/wc-stripe-functions.php:496
260
  msgid "Fees"
261
  msgstr ""
262
 
 
 
 
 
263
  #: includes/abstract/abstract-wc-stripe-payment.php:104
264
  msgid "Charge %1$s is pending. Payment Method: %2$s. Payment will be completed once charge.succeeded webhook received from Stripe."
265
  msgstr ""
@@ -333,7 +333,7 @@ msgstr ""
333
  msgid "If enabled, an email receipt will be sent to the customer by Stripe when the order is processed."
334
  msgstr ""
335
 
336
- #: includes/admin/meta-boxes/class-wc-stripe-admin-meta-box-product-data.php:19
337
  msgid "Stripe Settings"
338
  msgstr ""
339
 
@@ -712,10 +712,6 @@ msgstr ""
712
  msgid "Error saving customer. Reason: %s"
713
  msgstr ""
714
 
715
- #: includes/class-wc-stripe-frontend-notices.php:35
716
- msgid "Your payment is being processed and your order status will be updated once the funds are received."
717
- msgstr ""
718
-
719
  #: includes/class-wc-stripe-frontend-scripts.php:87
720
  msgid "No matches found"
721
  msgstr ""
@@ -1704,230 +1700,230 @@ msgstr ""
1704
  msgid "Kind Regards,"
1705
  msgstr ""
1706
 
1707
- #: includes/wc-stripe-functions.php:838
1708
  msgid "Bootstrap form"
1709
  msgstr ""
1710
 
1711
- #: includes/wc-stripe-functions.php:864
1712
  msgid "Simple form"
1713
  msgstr ""
1714
 
1715
- #: includes/wc-stripe-functions.php:887
1716
  msgid "Minimalist form"
1717
  msgstr ""
1718
 
1719
- #: includes/wc-stripe-functions.php:913
1720
  msgid "Inline Form"
1721
  msgstr ""
1722
 
1723
- #: includes/wc-stripe-functions.php:935
1724
  msgid "Rounded Form"
1725
  msgstr ""
1726
 
1727
- #: includes/wc-stripe-functions.php:1153
1728
  msgid "There was an error processing your credit card."
1729
  msgstr ""
1730
 
1731
- #: includes/wc-stripe-functions.php:1154
1732
  msgid "Your card number is incomplete."
1733
  msgstr ""
1734
 
1735
- #: includes/wc-stripe-functions.php:1155
1736
  msgid "Your card's expiration date is incomplete."
1737
  msgstr ""
1738
 
1739
- #: includes/wc-stripe-functions.php:1156
1740
  msgid "Your card's security code is incomplete."
1741
  msgstr ""
1742
 
1743
- #: includes/wc-stripe-functions.php:1157
1744
  msgid "Your card's zip code is incomplete."
1745
  msgstr ""
1746
 
1747
- #: includes/wc-stripe-functions.php:1158
1748
  msgid "The card number is incorrect. Check the card's number or use a different card."
1749
  msgstr ""
1750
 
1751
- #: includes/wc-stripe-functions.php:1159
1752
  msgid "The card's security code is incorrect. Check the card's security code or use a different card."
1753
  msgstr ""
1754
 
1755
- #: includes/wc-stripe-functions.php:1160
1756
  msgid "The card's ZIP code is incorrect. Check the card's ZIP code or use a different card."
1757
  msgstr ""
1758
 
1759
- #: includes/wc-stripe-functions.php:1161
1760
- #: includes/wc-stripe-functions.php:1166
1761
  msgid "The card number is invalid. Check the card details or use a different card."
1762
  msgstr ""
1763
 
1764
- #: includes/wc-stripe-functions.php:1162
1765
  msgid "This value provided to the field contains characters that are unsupported by the field."
1766
  msgstr ""
1767
 
1768
- #: includes/wc-stripe-functions.php:1163
1769
  msgid "The card's security code is invalid. Check the card's security code or use a different card."
1770
  msgstr ""
1771
 
1772
- #: includes/wc-stripe-functions.php:1164
1773
  msgid "The card's expiration month is incorrect. Check the expiration date or use a different card."
1774
  msgstr ""
1775
 
1776
- #: includes/wc-stripe-functions.php:1165
1777
  msgid "The card's expiration year is incorrect. Check the expiration date or use a different card."
1778
  msgstr ""
1779
 
1780
- #: includes/wc-stripe-functions.php:1167
1781
  msgid "The card's address is incorrect. Check the card's address or use a different card."
1782
  msgstr ""
1783
 
1784
- #: includes/wc-stripe-functions.php:1168
1785
  msgid "The card has expired. Check the expiration date or use a different card."
1786
  msgstr ""
1787
 
1788
- #: includes/wc-stripe-functions.php:1169
1789
  msgid "The card has been declined."
1790
  msgstr ""
1791
 
1792
- #: includes/wc-stripe-functions.php:1170
1793
  msgid "Your card's expiration year is in the past."
1794
  msgstr ""
1795
 
1796
- #: includes/wc-stripe-functions.php:1171
1797
  msgid "The bank account number provided is invalid (e.g., missing digits). Bank account information varies from country to country. We recommend creating validations in your entry forms based on the bank account formats we provide."
1798
  msgstr ""
1799
 
1800
- #: includes/wc-stripe-functions.php:1172
1801
  msgid "The specified amount is greater than the maximum amount allowed. Use a lower amount and try again."
1802
  msgstr ""
1803
 
1804
- #: includes/wc-stripe-functions.php:1173
1805
  msgid "The specified amount is less than the minimum amount allowed. Use a higher amount and try again."
1806
  msgstr ""
1807
 
1808
- #: includes/wc-stripe-functions.php:1174
1809
  msgid "The payment requires authentication to proceed. If your customer is off session, notify your customer to return to your application and complete the payment. If you provided the error_on_requires_action parameter, then your customer should try another card that does not require authentication."
1810
  msgstr ""
1811
 
1812
- #: includes/wc-stripe-functions.php:1175
1813
  msgid "The transfer or payout could not be completed because the associated account does not have a sufficient balance available. Create a new transfer or payout using an amount less than or equal to the account's available balance."
1814
  msgstr ""
1815
 
1816
- #: includes/wc-stripe-functions.php:1176
1817
  msgid "The bank account provided can not be used to charge, either because it is not verified yet or it is not supported."
1818
  msgstr ""
1819
 
1820
- #: includes/wc-stripe-functions.php:1177
1821
  msgid "The bank account provided already exists on the specified Customer object. If the bank account should also be attached to a different customer, include the correct customer ID when making the request again."
1822
  msgstr ""
1823
 
1824
- #: includes/wc-stripe-functions.php:1178
1825
  msgid "The bank account provided cannot be used for payouts. A different bank account must be used."
1826
  msgstr ""
1827
 
1828
- #: includes/wc-stripe-functions.php:1179
1829
  msgid "Your Connect platform is attempting to share an unverified bank account with a connected account."
1830
  msgstr ""
1831
 
1832
- #: includes/wc-stripe-functions.php:1180
1833
  msgid "The bank account cannot be verified, either because the microdeposit amounts provided do not match the actual amounts, or because verification has failed too many times."
1834
  msgstr ""
1835
 
1836
- #: includes/wc-stripe-functions.php:1181
1837
  msgid "This card has been declined too many times. You can try to charge this card again after 24 hours. We suggest reaching out to your customer to make sure they have entered all of their information correctly and that there are no issues with their card."
1838
  msgstr ""
1839
 
1840
- #: includes/wc-stripe-functions.php:1182
1841
  msgid "The charge you're attempting to capture has already been captured. Update the request with an uncaptured charge ID."
1842
  msgstr ""
1843
 
1844
- #: includes/wc-stripe-functions.php:1183
1845
  msgid "The charge you're attempting to refund has already been refunded. Update the request to use the ID of a charge that has not been refunded."
1846
  msgstr ""
1847
 
1848
- #: includes/wc-stripe-functions.php:1184
1849
  msgid "The charge you're attempting to refund has been charged back. Check the disputes documentation to learn how to respond to the dispute."
1850
  msgstr ""
1851
 
1852
- #: includes/wc-stripe-functions.php:1185
1853
  msgid "This charge would cause you to exceed your rolling-window processing limit for this source type. Please retry the charge later, or contact us to request a higher processing limit."
1854
  msgstr ""
1855
 
1856
- #: includes/wc-stripe-functions.php:1186
1857
  msgid "The charge cannot be captured as the authorization has expired. Auth and capture charges must be captured within seven days."
1858
  msgstr ""
1859
 
1860
- #: includes/wc-stripe-functions.php:1187
1861
  msgid "One or more provided parameters was not allowed for the given operation on the Charge. Check our API reference or the returned error message to see which values were not correct for that Charge."
1862
  msgstr ""
1863
 
1864
- #: includes/wc-stripe-functions.php:1188
1865
  msgid "The email address is invalid (e.g., not properly formatted). Check that the email address is properly formatted and only includes allowed characters."
1866
  msgstr ""
1867
 
1868
- #: includes/wc-stripe-functions.php:1189
1869
  msgid "The idempotency key provided is currently being used in another request. This occurs if your integration is making duplicate requests simultaneously."
1870
  msgstr ""
1871
 
1872
- #: includes/wc-stripe-functions.php:1190
1873
  msgid "The specified amount is invalid. The charge amount must be a positive integer in the smallest currency unit, and not exceed the minimum or maximum amount."
1874
  msgstr ""
1875
 
1876
- #: includes/wc-stripe-functions.php:1191
1877
  msgid "The source cannot be used because it is not in the correct state (e.g., a charge request is trying to use a source with a pending, failed, or consumed source). Check the status of the source you are attempting to use."
1878
  msgstr ""
1879
 
1880
- #: includes/wc-stripe-functions.php:1192
1881
  msgid "Both a customer and source ID have been provided, but the source has not been saved to the customer. To create a charge for a customer with a specified source, you must first save the card details."
1882
  msgstr ""
1883
 
1884
- #: includes/wc-stripe-functions.php:1193
1885
  msgid "The ZIP code provided was incorrect."
1886
  msgstr ""
1887
 
1888
- #: includes/wc-stripe-functions.php:1194
1889
  msgid "An error occurred while processing the card. Try again later or with a different payment method."
1890
  msgstr ""
1891
 
1892
- #: includes/wc-stripe-functions.php:1195
1893
  msgid "The card does not support this type of purchase."
1894
  msgstr ""
1895
 
1896
- #: includes/wc-stripe-functions.php:1196
1897
- #: includes/wc-stripe-functions.php:1199
1898
- #: includes/wc-stripe-functions.php:1201
1899
  msgid "The card has been declined for an unknown reason."
1900
  msgstr ""
1901
 
1902
- #: includes/wc-stripe-functions.php:1197
1903
  msgid "The customer has exceeded the balance or credit limit available on their card."
1904
  msgstr ""
1905
 
1906
- #: includes/wc-stripe-functions.php:1198
1907
  msgid "The card does not support the specified currency."
1908
  msgstr ""
1909
 
1910
- #: includes/wc-stripe-functions.php:1200
1911
  msgid "The payment has been declined as Stripe suspects it is fraudulent."
1912
  msgstr ""
1913
 
1914
- #: includes/wc-stripe-functions.php:1202
1915
  msgid "The PIN entered is incorrect. "
1916
  msgstr ""
1917
 
1918
- #: includes/wc-stripe-functions.php:1203
1919
  msgid "The card has insufficient funds to complete the purchase."
1920
  msgstr ""
1921
 
1922
- #: includes/wc-stripe-functions.php:1204
1923
  msgid "Please select a payment method before proceeding."
1924
  msgstr ""
1925
 
1926
- #: includes/wc-stripe-functions.php:1205
1927
  msgid "Please enter your IBAN before proceeding."
1928
  msgstr ""
1929
 
1930
- #: includes/wc-stripe-functions.php:1206
1931
  msgid "Please select a bank before proceeding"
1932
  msgstr ""
1933
 
2
  # This file is distributed under the same license as the Stripe For WooCommerce plugin.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Stripe For WooCommerce 3.2.13\n"
6
  "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/woo-stripe-payment\n"
7
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
8
  "Language-Team: LANGUAGE <LL@li.org>\n"
9
  "MIME-Version: 1.0\n"
10
  "Content-Type: text/plain; charset=UTF-8\n"
11
  "Content-Transfer-Encoding: 8bit\n"
12
+ "POT-Creation-Date: 2021-02-12T21:32:31+00:00\n"
13
  "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
14
  "X-Generator: WP-CLI 2.4.0\n"
15
  "X-Domain: woo-stripe-payment\n"
116
  msgid " & billing country is <strong>%s</strong>"
117
  msgstr ""
118
 
119
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:401
120
  msgid "Please fill out all required fields."
121
  msgstr ""
122
 
123
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:416
124
  #: includes/controllers/class-wc-stripe-controller-cart.php:134
125
  #: includes/controllers/class-wc-stripe-controller-cart.php:192
126
  #: includes/controllers/class-wc-stripe-controller-googlepay.php:136
128
  msgid "Total"
129
  msgstr ""
130
 
131
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:486
132
  msgid "User must be logged in."
133
  msgstr ""
134
 
135
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:511
136
  msgid "Error saving payment method. Reason: %s"
137
  msgstr ""
138
 
139
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:530
140
  #: includes/wc-stripe-webhook-functions.php:217
141
  msgid "Order refunded in Stripe. Amount: %s"
142
  msgstr ""
143
 
144
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:568
145
  msgid "Order amount captured in Stripe. Amount: %s"
146
  msgstr ""
147
 
148
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:578
149
  msgid "Error capturing charge in Stripe. Reason: %s"
150
  msgstr ""
151
 
152
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:599
153
  msgid "Error voiding charge. Reason: %s"
154
  msgstr ""
155
 
156
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:601
157
  msgid "Charge voided in Stripe."
158
  msgstr ""
159
 
160
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:764
161
  msgid "n/a"
162
  msgstr ""
163
 
164
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:792
165
  #: includes/admin/meta-boxes/views/html-order-pay.php:42
166
  msgid "New Card"
167
  msgstr ""
168
 
169
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:796
170
  #: includes/admin/meta-boxes/views/html-order-pay.php:30
171
  msgid "Saved Cards"
172
  msgstr ""
173
 
174
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1005
175
+ msgid "Attempt to save payment method failed. Reason: %s"
176
  msgstr ""
177
 
178
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1030
179
  msgid "We were not able to save your payment method. To prevent billing issues with your subscription, please add a payment method to the subscription."
180
  msgstr ""
181
 
182
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1032
183
  msgid "We were not able to save your payment method. Reason: %s"
184
  msgstr ""
185
 
186
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1066
187
  msgid "Payment Method Token"
188
  msgstr ""
189
 
190
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1086
191
  msgid "Recurring payment for order failed. Reason: %s"
192
  msgstr ""
193
 
194
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1099
195
  msgid "Recurring payment captured in Stripe. Payment method: %s"
196
  msgstr ""
197
 
198
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1101
199
  msgid "Recurring payment authorized in Stripe. Payment method: %s"
200
  msgstr ""
201
 
202
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1104
203
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1345
204
  msgid "Customer must manually complete payment for payment method %s"
205
  msgstr ""
206
 
207
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1138
 
 
 
 
208
  #: includes/abstract/abstract-wc-stripe-payment.php:227
209
  msgid "Order %1$s from %2$s"
210
  msgstr ""
211
 
212
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1332
213
  msgid "Pre-order payment for order failed. Reason: %s"
214
  msgstr ""
215
 
216
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1340
217
  msgid "Pre-order payment captured in Stripe. Payment method: %s"
218
  msgstr ""
219
 
220
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1342
221
  msgid "Pre-order payment authorized in Stripe. Payment method: %s"
222
  msgstr ""
223
 
224
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1414
225
  msgid "Cannot process payment"
226
  msgstr ""
227
 
228
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1422
229
  msgid "Increase your conversion rate by offering %1$s on your Product and Cart pages, or at the top of the checkout page. <br/><strong>Note:</strong> you can control which products display %s by going to the product edit page."
230
  msgstr ""
231
 
232
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1536
233
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1567
234
  #: includes/gateways/class-wc-payment-gateway-stripe-klarna.php:192
235
+ #: includes/wc-stripe-functions.php:432
236
+ #: includes/wc-stripe-functions.php:497
237
  msgid "Shipping"
238
  msgstr ""
239
 
240
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1544
241
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1570
242
  #: includes/gateways/class-wc-payment-gateway-stripe-klarna.php:202
243
+ #: includes/wc-stripe-functions.php:449
244
+ #: includes/wc-stripe-functions.php:505
245
  msgid "Discount"
246
  msgstr ""
247
 
248
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1547
249
  #: includes/gateways/class-wc-payment-gateway-stripe-klarna.php:220
250
+ #: includes/wc-stripe-functions.php:457
251
  msgid "Tax"
252
  msgstr ""
253
 
254
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1577
255
+ #: includes/wc-stripe-functions.php:516
256
  msgid "Fees"
257
  msgstr ""
258
 
259
+ #: includes/abstract/abstract-wc-payment-gateway-stripe.php:1765
260
+ msgid "Error saving payment method for subscription. Reason: %s"
261
+ msgstr ""
262
+
263
  #: includes/abstract/abstract-wc-stripe-payment.php:104
264
  msgid "Charge %1$s is pending. Payment Method: %2$s. Payment will be completed once charge.succeeded webhook received from Stripe."
265
  msgstr ""
333
  msgid "If enabled, an email receipt will be sent to the customer by Stripe when the order is processed."
334
  msgstr ""
335
 
336
+ #: includes/admin/meta-boxes/class-wc-stripe-admin-meta-box-product-data.php:20
337
  msgid "Stripe Settings"
338
  msgstr ""
339
 
712
  msgid "Error saving customer. Reason: %s"
713
  msgstr ""
714
 
 
 
 
 
715
  #: includes/class-wc-stripe-frontend-scripts.php:87
716
  msgid "No matches found"
717
  msgstr ""
1700
  msgid "Kind Regards,"
1701
  msgstr ""
1702
 
1703
+ #: includes/wc-stripe-functions.php:858
1704
  msgid "Bootstrap form"
1705
  msgstr ""
1706
 
1707
+ #: includes/wc-stripe-functions.php:884
1708
  msgid "Simple form"
1709
  msgstr ""
1710
 
1711
+ #: includes/wc-stripe-functions.php:907
1712
  msgid "Minimalist form"
1713
  msgstr ""
1714
 
1715
+ #: includes/wc-stripe-functions.php:933
1716
  msgid "Inline Form"
1717
  msgstr ""
1718
 
1719
+ #: includes/wc-stripe-functions.php:955
1720
  msgid "Rounded Form"
1721
  msgstr ""
1722
 
1723
+ #: includes/wc-stripe-functions.php:1173
1724
  msgid "There was an error processing your credit card."
1725
  msgstr ""
1726
 
1727
+ #: includes/wc-stripe-functions.php:1174
1728
  msgid "Your card number is incomplete."
1729
  msgstr ""
1730
 
1731
+ #: includes/wc-stripe-functions.php:1175
1732
  msgid "Your card's expiration date is incomplete."
1733
  msgstr ""
1734
 
1735
+ #: includes/wc-stripe-functions.php:1176
1736
  msgid "Your card's security code is incomplete."
1737
  msgstr ""
1738
 
1739
+ #: includes/wc-stripe-functions.php:1177
1740
  msgid "Your card's zip code is incomplete."
1741
  msgstr ""
1742
 
1743
+ #: includes/wc-stripe-functions.php:1178
1744
  msgid "The card number is incorrect. Check the card's number or use a different card."
1745
  msgstr ""
1746
 
1747
+ #: includes/wc-stripe-functions.php:1179
1748
  msgid "The card's security code is incorrect. Check the card's security code or use a different card."
1749
  msgstr ""
1750
 
1751
+ #: includes/wc-stripe-functions.php:1180
1752
  msgid "The card's ZIP code is incorrect. Check the card's ZIP code or use a different card."
1753
  msgstr ""
1754
 
1755
+ #: includes/wc-stripe-functions.php:1181
1756
+ #: includes/wc-stripe-functions.php:1186
1757
  msgid "The card number is invalid. Check the card details or use a different card."
1758
  msgstr ""
1759
 
1760
+ #: includes/wc-stripe-functions.php:1182
1761
  msgid "This value provided to the field contains characters that are unsupported by the field."
1762
  msgstr ""
1763
 
1764
+ #: includes/wc-stripe-functions.php:1183
1765
  msgid "The card's security code is invalid. Check the card's security code or use a different card."
1766
  msgstr ""
1767
 
1768
+ #: includes/wc-stripe-functions.php:1184
1769
  msgid "The card's expiration month is incorrect. Check the expiration date or use a different card."
1770
  msgstr ""
1771
 
1772
+ #: includes/wc-stripe-functions.php:1185
1773
  msgid "The card's expiration year is incorrect. Check the expiration date or use a different card."
1774
  msgstr ""
1775
 
1776
+ #: includes/wc-stripe-functions.php:1187
1777
  msgid "The card's address is incorrect. Check the card's address or use a different card."
1778
  msgstr ""
1779
 
1780
+ #: includes/wc-stripe-functions.php:1188
1781
  msgid "The card has expired. Check the expiration date or use a different card."
1782
  msgstr ""
1783
 
1784
+ #: includes/wc-stripe-functions.php:1189
1785
  msgid "The card has been declined."
1786
  msgstr ""
1787
 
1788
+ #: includes/wc-stripe-functions.php:1190
1789
  msgid "Your card's expiration year is in the past."
1790
  msgstr ""
1791
 
1792
+ #: includes/wc-stripe-functions.php:1191
1793
  msgid "The bank account number provided is invalid (e.g., missing digits). Bank account information varies from country to country. We recommend creating validations in your entry forms based on the bank account formats we provide."
1794
  msgstr ""
1795
 
1796
+ #: includes/wc-stripe-functions.php:1192
1797
  msgid "The specified amount is greater than the maximum amount allowed. Use a lower amount and try again."
1798
  msgstr ""
1799
 
1800
+ #: includes/wc-stripe-functions.php:1193
1801
  msgid "The specified amount is less than the minimum amount allowed. Use a higher amount and try again."
1802
  msgstr ""
1803
 
1804
+ #: includes/wc-stripe-functions.php:1194
1805
  msgid "The payment requires authentication to proceed. If your customer is off session, notify your customer to return to your application and complete the payment. If you provided the error_on_requires_action parameter, then your customer should try another card that does not require authentication."
1806
  msgstr ""
1807
 
1808
+ #: includes/wc-stripe-functions.php:1195
1809
  msgid "The transfer or payout could not be completed because the associated account does not have a sufficient balance available. Create a new transfer or payout using an amount less than or equal to the account's available balance."
1810
  msgstr ""
1811
 
1812
+ #: includes/wc-stripe-functions.php:1196
1813
  msgid "The bank account provided can not be used to charge, either because it is not verified yet or it is not supported."
1814
  msgstr ""
1815
 
1816
+ #: includes/wc-stripe-functions.php:1197
1817
  msgid "The bank account provided already exists on the specified Customer object. If the bank account should also be attached to a different customer, include the correct customer ID when making the request again."
1818
  msgstr ""
1819
 
1820
+ #: includes/wc-stripe-functions.php:1198
1821
  msgid "The bank account provided cannot be used for payouts. A different bank account must be used."
1822
  msgstr ""
1823
 
1824
+ #: includes/wc-stripe-functions.php:1199
1825
  msgid "Your Connect platform is attempting to share an unverified bank account with a connected account."
1826
  msgstr ""
1827
 
1828
+ #: includes/wc-stripe-functions.php:1200
1829
  msgid "The bank account cannot be verified, either because the microdeposit amounts provided do not match the actual amounts, or because verification has failed too many times."
1830
  msgstr ""
1831
 
1832
+ #: includes/wc-stripe-functions.php:1201
1833
  msgid "This card has been declined too many times. You can try to charge this card again after 24 hours. We suggest reaching out to your customer to make sure they have entered all of their information correctly and that there are no issues with their card."
1834
  msgstr ""
1835
 
1836
+ #: includes/wc-stripe-functions.php:1202
1837
  msgid "The charge you're attempting to capture has already been captured. Update the request with an uncaptured charge ID."
1838
  msgstr ""
1839
 
1840
+ #: includes/wc-stripe-functions.php:1203
1841
  msgid "The charge you're attempting to refund has already been refunded. Update the request to use the ID of a charge that has not been refunded."
1842
  msgstr ""
1843
 
1844
+ #: includes/wc-stripe-functions.php:1204
1845
  msgid "The charge you're attempting to refund has been charged back. Check the disputes documentation to learn how to respond to the dispute."
1846
  msgstr ""
1847
 
1848
+ #: includes/wc-stripe-functions.php:1205
1849
  msgid "This charge would cause you to exceed your rolling-window processing limit for this source type. Please retry the charge later, or contact us to request a higher processing limit."
1850
  msgstr ""
1851
 
1852
+ #: includes/wc-stripe-functions.php:1206
1853
  msgid "The charge cannot be captured as the authorization has expired. Auth and capture charges must be captured within seven days."
1854
  msgstr ""
1855
 
1856
+ #: includes/wc-stripe-functions.php:1207
1857
  msgid "One or more provided parameters was not allowed for the given operation on the Charge. Check our API reference or the returned error message to see which values were not correct for that Charge."
1858
  msgstr ""
1859
 
1860
+ #: includes/wc-stripe-functions.php:1208
1861
  msgid "The email address is invalid (e.g., not properly formatted). Check that the email address is properly formatted and only includes allowed characters."
1862
  msgstr ""
1863
 
1864
+ #: includes/wc-stripe-functions.php:1209
1865
  msgid "The idempotency key provided is currently being used in another request. This occurs if your integration is making duplicate requests simultaneously."
1866
  msgstr ""
1867
 
1868
+ #: includes/wc-stripe-functions.php:1210
1869
  msgid "The specified amount is invalid. The charge amount must be a positive integer in the smallest currency unit, and not exceed the minimum or maximum amount."
1870
  msgstr ""
1871
 
1872
+ #: includes/wc-stripe-functions.php:1211
1873
  msgid "The source cannot be used because it is not in the correct state (e.g., a charge request is trying to use a source with a pending, failed, or consumed source). Check the status of the source you are attempting to use."
1874
  msgstr ""
1875
 
1876
+ #: includes/wc-stripe-functions.php:1212
1877
  msgid "Both a customer and source ID have been provided, but the source has not been saved to the customer. To create a charge for a customer with a specified source, you must first save the card details."
1878
  msgstr ""
1879
 
1880
+ #: includes/wc-stripe-functions.php:1213
1881
  msgid "The ZIP code provided was incorrect."
1882
  msgstr ""
1883
 
1884
+ #: includes/wc-stripe-functions.php:1214
1885
  msgid "An error occurred while processing the card. Try again later or with a different payment method."
1886
  msgstr ""
1887
 
1888
+ #: includes/wc-stripe-functions.php:1215
1889
  msgid "The card does not support this type of purchase."
1890
  msgstr ""
1891
 
1892
+ #: includes/wc-stripe-functions.php:1216
1893
+ #: includes/wc-stripe-functions.php:1219
1894
+ #: includes/wc-stripe-functions.php:1221
1895
  msgid "The card has been declined for an unknown reason."
1896
  msgstr ""
1897
 
1898
+ #: includes/wc-stripe-functions.php:1217
1899
  msgid "The customer has exceeded the balance or credit limit available on their card."
1900
  msgstr ""
1901
 
1902
+ #: includes/wc-stripe-functions.php:1218
1903
  msgid "The card does not support the specified currency."
1904
  msgstr ""
1905
 
1906
+ #: includes/wc-stripe-functions.php:1220
1907
  msgid "The payment has been declined as Stripe suspects it is fraudulent."
1908
  msgstr ""
1909
 
1910
+ #: includes/wc-stripe-functions.php:1222
1911
  msgid "The PIN entered is incorrect. "
1912
  msgstr ""
1913
 
1914
+ #: includes/wc-stripe-functions.php:1223
1915
  msgid "The card has insufficient funds to complete the purchase."
1916
  msgstr ""
1917
 
1918
+ #: includes/wc-stripe-functions.php:1224
1919
  msgid "Please select a payment method before proceeding."
1920
  msgstr ""
1921
 
1922
+ #: includes/wc-stripe-functions.php:1225
1923
  msgid "Please enter your IBAN before proceeding."
1924
  msgstr ""
1925
 
1926
+ #: includes/wc-stripe-functions.php:1226
1927
  msgid "Please select a bank before proceeding"
1928
  msgstr ""
1929
 
includes/abstract/abstract-wc-payment-gateway-stripe.php CHANGED
@@ -152,10 +152,7 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
152
  add_action( 'wc_stripe_payment_token_deleted_' . $this->id, array( $this, 'delete_payment_method' ), 10, 2 );
153
  add_filter( 'woocommerce_subscription_payment_meta', array( $this, 'subscription_payment_meta' ), 10, 2 );
154
  add_action( 'woocommerce_scheduled_subscription_payment_' . $this->id, array( $this, 'scheduled_subscription_payment' ), 10, 2 );
155
- if ( ! is_admin() ) {
156
- add_action( 'woocommerce_subscriptions_pre_update_payment_method', array( $this, 'subscriptions_pre_update_payment_method' ), 10, 3 );
157
- add_action( 'woocommerce_subscription_payment_method_updated_to_' . $this->id, array( $this, 'subscription_payment_method_updated' ) );
158
- }
159
  add_action( 'wc_pre_orders_process_pre_order_completion_payment_' . $this->id, array( $this, 'process_pre_order_payment' ) );
160
 
161
  /**
@@ -344,11 +341,8 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
344
  public function process_payment( $order_id ) {
345
  $order = wc_get_order( $order_id );
346
 
347
- if ( $this->is_change_payment_method_request() ) {
348
- return array(
349
- 'result' => 'success',
350
- 'redirect' => $order->get_view_order_url(),
351
- );
352
  }
353
 
354
  do_action( 'wc_stripe_before_process_payment', $order, $this->id );
@@ -839,10 +833,7 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
839
  public function should_save_payment_method( $order ) {
840
  if ( ! $this->use_saved_source() && ! $this->is_processing_scheduled_payment() ) {
841
  if ( wcs_stripe_active() && $this->supports( 'subscriptions' ) ) {
842
- if ( wcs_order_contains_subscription( $order ) ) {
843
- return true;
844
- }
845
- if ( wcs_order_contains_renewal( $order ) ) {
846
  return true;
847
  }
848
  }
@@ -999,16 +990,22 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
999
  *
1000
  * @param string $id
1001
  * @param WC_Order $order
 
1002
  *
1003
  * @return WP_Error|bool
1004
  */
1005
- public function save_payment_method( $id, $order ) {
1006
- $token = $this->create_payment_method( $id, wc_stripe_get_customer_id( $order->get_customer_id() ) );
1007
- if ( is_wp_error( $token ) ) {
1008
- $this->wp_error = $token;
1009
- $order->add_order_note( sprintf( __( 'Attemp to save payment method failed. Reason: %s', 'woo-stripe-payment' ), $token->get_error_message() ) );
 
 
 
 
1010
 
1011
- return $token;
 
1012
  }
1013
  $token->set_user_id( $order->get_user_id() );
1014
  $token->save();
@@ -1025,6 +1022,8 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
1025
  *
1026
  * @param WC_Order $order
1027
  * @param WP_Error $error
 
 
1028
  */
1029
  public function set_payment_save_error( $order, $error ) {
1030
  if ( wcs_stripe_active() && wcs_order_contains_subscription( $order ) ) {
@@ -1106,49 +1105,6 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
1106
  }
1107
  }
1108
 
1109
- /**
1110
- *
1111
- * @param WC_Subscription $subscription
1112
- * @param string $new_payment_method
1113
- * @param string $old_payment_method
1114
- */
1115
- public function subscriptions_pre_update_payment_method( $subscription, $new_payment_method, $old_payment_method ) {
1116
- if ( $new_payment_method === $this->id ) {
1117
- // customer is using a new payment method so we need to save it.
1118
- if ( ! $this->use_saved_source() ) {
1119
- $result = $this->save_payment_method( $this->get_new_source_token(), $subscription );
1120
- if ( is_wp_error( $result ) ) {
1121
- wc_add_notice( sprintf( __( 'Error saving payment method for subscription. Reason: %s', 'woo-stripe-payment' ), $result->get_error_message() ), 'error' );
1122
- // redirect to change payment method page.
1123
- wp_safe_redirect( $subscription->get_view_order_url() );
1124
- exit();
1125
- }
1126
- } else {
1127
- if ( ! $this->payment_method_token ) {
1128
- // set the payment method token so it can be used downstream.
1129
- $this->payment_method_token = $this->get_payment_source();
1130
- }
1131
- }
1132
- }
1133
- }
1134
-
1135
- /**
1136
- * Update the subscription with the new meta data for the gateway.
1137
- * Save any new method the customer is trying to use.
1138
- *
1139
- * @param WC_Subscription $subscription
1140
- */
1141
- public function subscription_payment_method_updated( $subscription ) {
1142
- $token = $this->get_token( $this->payment_method_token, $subscription->get_user_id() );
1143
-
1144
- // update the meta data needed by the gateway to process a subscription payment.
1145
- $subscription->update_meta_data( WC_Stripe_Constants::PAYMENT_METHOD_TOKEN, $this->payment_method_token );
1146
- if ( $token ) {
1147
- $subscription->set_payment_method_title( $token->get_payment_method_title() );
1148
- }
1149
- $subscription->save();
1150
- }
1151
-
1152
  /**
1153
  * Return true if this request is to change the payment method of a WC Subscription.
1154
  *
@@ -1199,7 +1155,6 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
1199
  $this->payment_method_token = $this->get_saved_source_id();
1200
  }
1201
  $this->save_zero_total_meta( $order );
1202
- $order_status = $this->get_option( 'order_status' );
1203
  if ( 'capture' === $this->get_option( 'charge_type' ) ) {
1204
  $order->payment_complete();
1205
  } else {
@@ -1796,4 +1751,44 @@ abstract class WC_Payment_Gateway_Stripe extends WC_Payment_Gateway {
1796
 
1797
  return parent::get_transaction_url( $order );
1798
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1799
  }
152
  add_action( 'wc_stripe_payment_token_deleted_' . $this->id, array( $this, 'delete_payment_method' ), 10, 2 );
153
  add_filter( 'woocommerce_subscription_payment_meta', array( $this, 'subscription_payment_meta' ), 10, 2 );
154
  add_action( 'woocommerce_scheduled_subscription_payment_' . $this->id, array( $this, 'scheduled_subscription_payment' ), 10, 2 );
155
+ add_action( 'woocommerce_subscription_failing_payment_method_updated_' . $this->id, array( $this, 'update_failing_payment_method' ), 10, 2 );
 
 
 
156
  add_action( 'wc_pre_orders_process_pre_order_completion_payment_' . $this->id, array( $this, 'process_pre_order_payment' ) );
157
 
158
  /**
341
  public function process_payment( $order_id ) {
342
  $order = wc_get_order( $order_id );
343
 
344
+ if ( $this->is_change_payment_method_request() && wcs_is_subscription( $order ) ) {
345
+ return $this->process_change_payment_method_request( $order );
 
 
 
346
  }
347
 
348
  do_action( 'wc_stripe_before_process_payment', $order, $this->id );
833
  public function should_save_payment_method( $order ) {
834
  if ( ! $this->use_saved_source() && ! $this->is_processing_scheduled_payment() ) {
835
  if ( wcs_stripe_active() && $this->supports( 'subscriptions' ) ) {
836
+ if ( wcs_order_contains_subscription( $order ) || wcs_order_contains_renewal( $order ) ) {
 
 
 
837
  return true;
838
  }
839
  }
990
  *
991
  * @param string $id
992
  * @param WC_Order $order
993
+ * @param
994
  *
995
  * @return WP_Error|bool
996
  */
997
+ public function save_payment_method( $id, $order, $payment_details = null ) {
998
+ if ( $payment_details ) {
999
+ $token = $this->get_payment_token( $id, $payment_details );
1000
+ $token->set_customer_id( wc_stripe_get_customer_id( $order->get_customer_id() ) );
1001
+ } else {
1002
+ $token = $this->create_payment_method( $id, wc_stripe_get_customer_id( $order->get_customer_id() ) );
1003
+ if ( is_wp_error( $token ) ) {
1004
+ $this->wp_error = $token;
1005
+ $order->add_order_note( sprintf( __( 'Attempt to save payment method failed. Reason: %s', 'woo-stripe-payment' ), $token->get_error_message() ) );
1006
 
1007
+ return $token;
1008
+ }
1009
  }
1010
  $token->set_user_id( $order->get_user_id() );
1011
  $token->save();
1022
  *
1023
  * @param WC_Order $order
1024
  * @param WP_Error $error
1025
+ *
1026
+ * @deprecated
1027
  */
1028
  public function set_payment_save_error( $order, $error ) {
1029
  if ( wcs_stripe_active() && wcs_order_contains_subscription( $order ) ) {
1105
  }
1106
  }
1107
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1108
  /**
1109
  * Return true if this request is to change the payment method of a WC Subscription.
1110
  *
1155
  $this->payment_method_token = $this->get_saved_source_id();
1156
  }
1157
  $this->save_zero_total_meta( $order );
 
1158
  if ( 'capture' === $this->get_option( 'charge_type' ) ) {
1159
  $order->payment_complete();
1160
  } else {
1751
 
1752
  return parent::get_transaction_url( $order );
1753
  }
1754
+
1755
+ /**
1756
+ * @param WC_Subscription $subscription
1757
+ *
1758
+ * @return array
1759
+ * @since 3.2.13
1760
+ */
1761
+ protected function process_change_payment_method_request( $subscription ) {
1762
+ if ( ! $this->use_saved_source() ) {
1763
+ $result = $this->save_payment_method( $this->get_new_source_token(), $subscription );
1764
+ if ( is_wp_error( $result ) ) {
1765
+ wc_add_notice( sprintf( __( 'Error saving payment method for subscription. Reason: %s', 'woo-stripe-payment' ), $result->get_error_message() ), 'error' );
1766
+
1767
+ return array( 'result' => 'error' );
1768
+ }
1769
+ } else {
1770
+ $this->payment_method_token = $this->get_saved_source_id();
1771
+ }
1772
+ $token = $this->get_token( $this->payment_method_token, $subscription->get_user_id() );
1773
+ // update the meta data needed by the gateway to process a subscription payment.
1774
+ $subscription->update_meta_data( WC_Stripe_Constants::PAYMENT_METHOD_TOKEN, $this->payment_method_token );
1775
+ if ( $token ) {
1776
+ $subscription->set_payment_method_title( $token->get_payment_method_title() );
1777
+ }
1778
+ $subscription->save();
1779
+
1780
+ return array( 'result' => 'success', 'redirect' => wc_get_page_permalink( 'myaccount' ) );
1781
+ }
1782
+
1783
+ /**
1784
+ * @param WC_Subscription $subscription
1785
+ * @param WC_Order $order
1786
+ */
1787
+ public function update_failing_payment_method( $subscription, $order ) {
1788
+ if ( ( $token = $this->get_token( $order->get_meta( WC_Stripe_Constants::PAYMENT_METHOD_TOKEN ), $order->get_customer_id() ) ) ) {
1789
+ $subscription->update_meta_data( WC_Stripe_Constants::PAYMENT_METHOD_TOKEN, $token->get_token() );
1790
+ $subscription->set_payment_method_title( $token->get_payment_method_title( $this->get_option( 'method_format' ) ) );
1791
+ $subscription->save();
1792
+ }
1793
+ }
1794
  }
includes/admin/class-wc-stripe-admin-user-edit.php CHANGED
@@ -41,7 +41,11 @@ class WC_Stripe_Admin_User_Edit {
41
  }
42
  }
43
  }
44
- include stripe_wc()->plugin_path() . 'includes/admin/views/html-user-profile.php';
 
 
 
 
45
  }
46
 
47
  /**
@@ -52,10 +56,12 @@ class WC_Stripe_Admin_User_Edit {
52
  $modes = array( 'test', 'live' );
53
  if ( isset( $_POST['wc_stripe_live_id'] ) ) {
54
  $old_live_id = wc_stripe_get_customer_id( $user_id, 'live' );
 
55
  wc_stripe_save_customer( wc_clean( $_POST['wc_stripe_live_id'] ), $user_id, 'live' );
56
  }
57
  if ( isset( $_POST['wc_stripe_test_id'] ) ) {
58
  $old_test_id = wc_stripe_get_customer_id( $user_id, 'test' );
 
59
  wc_stripe_save_customer( wc_clean( $_POST['wc_stripe_test_id'] ), $user_id, 'test' );
60
  }
61
 
@@ -106,4 +112,5 @@ class WC_Stripe_Admin_User_Edit {
106
  }
107
  }
108
  }
 
109
  WC_Stripe_Admin_User_Edit::init();
41
  }
42
  }
43
  }
44
+
45
+
46
+ if ( current_user_can( 'manage_woocommerce' ) ) {
47
+ include stripe_wc()->plugin_path() . 'includes/admin/views/html-user-profile.php';
48
+ }
49
  }
50
 
51
  /**
56
  $modes = array( 'test', 'live' );
57
  if ( isset( $_POST['wc_stripe_live_id'] ) ) {
58
  $old_live_id = wc_stripe_get_customer_id( $user_id, 'live' );
59
+ wc_stripe_delete_customer( $user_id, 'live', true );
60
  wc_stripe_save_customer( wc_clean( $_POST['wc_stripe_live_id'] ), $user_id, 'live' );
61
  }
62
  if ( isset( $_POST['wc_stripe_test_id'] ) ) {
63
  $old_test_id = wc_stripe_get_customer_id( $user_id, 'test' );
64
+ wc_stripe_delete_customer( $user_id, 'test', true );
65
  wc_stripe_save_customer( wc_clean( $_POST['wc_stripe_test_id'] ), $user_id, 'test' );
66
  }
67
 
112
  }
113
  }
114
  }
115
+
116
  WC_Stripe_Admin_User_Edit::init();
includes/admin/meta-boxes/class-wc-stripe-admin-meta-box-product-data.php CHANGED
@@ -1,92 +1,98 @@
1
- <?php
2
-
3
- namespace PaymentPlugins;
4
-
5
- class WC_Stripe_Admin_Meta_Box_Product_Data {
6
-
7
- private static $_gateways = array();
8
-
9
- private static $_options = array();
10
-
11
- public static function init() {
12
- add_filter( 'woocommerce_product_data_tabs', array( __CLASS__, 'product_data_tabs' ) );
13
- add_action( 'woocommerce_product_data_panels', array( __CLASS__, 'output_panel' ) );
14
- add_action( 'woocommerce_admin_process_product_object', array( __CLASS__, 'save' ) );
15
- }
16
-
17
- public static function product_data_tabs( $tabs ) {
18
- $tabs['stripe'] = array(
19
- 'label' => __( 'Stripe Settings', 'woo-stripe-payment' ),
20
- 'target' => 'stripe_product_data',
21
- 'class' => array(),
22
- 'priority' => 100,
23
- );
24
- return $tabs;
25
- }
26
-
27
- public static function output_panel() {
28
- global $product_object;
29
-
30
- self::init_gateways( $product_object );
31
-
32
- include 'views/html-product-data.php';
33
- }
34
-
35
- private static function init_gateways( $product ) {
36
- $order = $product->get_meta( \WC_Stripe_Constants::PRODUCT_GATEWAY_ORDER );
37
- $order = ! $order ? array() : $order;
38
- foreach ( WC()->payment_gateways()->payment_gateways() as $gateway ) {
39
- if ( $gateway->supports( 'wc_stripe_product_checkout' ) ) {
40
- if ( isset( $order[ $gateway->id ] ) ) {
41
- self::$_gateways[ $order[ $gateway->id ] ] = $gateway;
42
- } else {
43
- self::$_gateways[] = $gateway;
44
- }
45
- self::$_options[ $gateway->id ] = new \WC_Stripe_Product_Gateway_Option( $product, $gateway );
46
- }
47
- }
48
- ksort( self::$_gateways );
49
- }
50
-
51
- private static function get_product_option( $gateway_id ) {
52
- return self::$_options[ $gateway_id ];
53
- }
54
-
55
- private static function get_payment_gateways() {
56
- foreach ( self::$_gateways as $gateway ) {
57
- $gateways[ $gateway->id ] = $gateway;
58
- }
59
- return $gateways;
60
- }
61
-
62
- /**
63
- *
64
- * @param \WC_Product $product
65
- */
66
- public static function save( $product ) {
67
- // only update the settings if something has been changed.
68
- if ( empty( $_POST['wc_stripe_update_product'] ) ) {
69
- return;
70
- }
71
- $loop = 0;
72
- $order = array();
73
- self::init_gateways( $product );
74
- $payment_gateways = self::get_payment_gateways();
75
-
76
- if ( isset( $_POST['stripe_gateway_order'] ) ) {
77
- foreach ( $_POST['stripe_gateway_order'] as $i => $gateway ) {
78
- $order[ $gateway ] = $loop;
79
- if ( isset( $_POST['stripe_capture_type'] ) ) {
80
- self::get_product_option( $gateway )->set_option( 'charge_type', $_POST['stripe_capture_type'][ $i ] );
81
- self::get_product_option( $gateway )->save();
82
- }
83
- $loop++;
84
- }
85
- }
86
- if ( isset( $_POST['_stripe_button_position'] ) ) {
87
- $product->update_meta_data( '_stripe_button_position', wc_clean( $_POST['_stripe_button_position'] ) );
88
- }
89
- $product->update_meta_data( \WC_Stripe_Constants::PRODUCT_GATEWAY_ORDER, $order );
90
- }
91
- }
92
- \PaymentPlugins\WC_Stripe_Admin_Meta_Box_Product_Data::init();
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace PaymentPlugins;
4
+
5
+ class WC_Stripe_Admin_Meta_Box_Product_Data {
6
+
7
+ private static $_gateways = array();
8
+
9
+ private static $_options = array();
10
+
11
+ public static function init() {
12
+ add_filter( 'woocommerce_product_data_tabs', array( __CLASS__, 'product_data_tabs' ) );
13
+ add_action( 'woocommerce_product_data_panels', array( __CLASS__, 'output_panel' ) );
14
+ add_action( 'woocommerce_admin_process_product_object', array( __CLASS__, 'save' ) );
15
+ }
16
+
17
+ public static function product_data_tabs( $tabs ) {
18
+ if ( current_user_can( 'manage_woocommerce' ) ) {
19
+ $tabs['stripe'] = array(
20
+ 'label' => __( 'Stripe Settings', 'woo-stripe-payment' ),
21
+ 'target' => 'stripe_product_data',
22
+ 'class' => array( 'hide_if_external' ),
23
+ 'priority' => 100,
24
+ );
25
+ }
26
+
27
+ return $tabs;
28
+ }
29
+
30
+ public static function output_panel() {
31
+ global $product_object;
32
+
33
+ self::init_gateways( $product_object );
34
+ if ( current_user_can( 'manage_woocommerce' ) ) {
35
+ include 'views/html-product-data.php';
36
+ }
37
+ }
38
+
39
+ private static function init_gateways( $product ) {
40
+ $order = $product->get_meta( \WC_Stripe_Constants::PRODUCT_GATEWAY_ORDER );
41
+ $order = ! $order ? array() : $order;
42
+ foreach ( WC()->payment_gateways()->payment_gateways() as $gateway ) {
43
+ if ( $gateway->supports( 'wc_stripe_product_checkout' ) ) {
44
+ if ( isset( $order[ $gateway->id ] ) ) {
45
+ self::$_gateways[ $order[ $gateway->id ] ] = $gateway;
46
+ } else {
47
+ self::$_gateways[] = $gateway;
48
+ }
49
+ self::$_options[ $gateway->id ] = new \WC_Stripe_Product_Gateway_Option( $product, $gateway );
50
+ }
51
+ }
52
+ ksort( self::$_gateways );
53
+ }
54
+
55
+ private static function get_product_option( $gateway_id ) {
56
+ return self::$_options[ $gateway_id ];
57
+ }
58
+
59
+ private static function get_payment_gateways() {
60
+ foreach ( self::$_gateways as $gateway ) {
61
+ $gateways[ $gateway->id ] = $gateway;
62
+ }
63
+
64
+ return $gateways;
65
+ }
66
+
67
+ /**
68
+ *
69
+ * @param \WC_Product $product
70
+ */
71
+ public static function save( $product ) {
72
+ // only update the settings if something has been changed.
73
+ if ( empty( $_POST['wc_stripe_update_product'] ) ) {
74
+ return;
75
+ }
76
+ $loop = 0;
77
+ $order = array();
78
+ self::init_gateways( $product );
79
+ $payment_gateways = self::get_payment_gateways();
80
+
81
+ if ( isset( $_POST['stripe_gateway_order'] ) ) {
82
+ foreach ( $_POST['stripe_gateway_order'] as $i => $gateway ) {
83
+ $order[ $gateway ] = $loop;
84
+ if ( isset( $_POST['stripe_capture_type'] ) ) {
85
+ self::get_product_option( $gateway )->set_option( 'charge_type', $_POST['stripe_capture_type'][ $i ] );
86
+ self::get_product_option( $gateway )->save();
87
+ }
88
+ $loop ++;
89
+ }
90
+ }
91
+ if ( isset( $_POST['_stripe_button_position'] ) ) {
92
+ $product->update_meta_data( '_stripe_button_position', wc_clean( $_POST['_stripe_button_position'] ) );
93
+ }
94
+ $product->update_meta_data( \WC_Stripe_Constants::PRODUCT_GATEWAY_ORDER, $order );
95
+ }
96
+ }
97
+
98
+ \PaymentPlugins\WC_Stripe_Admin_Meta_Box_Product_Data::init();
includes/class-stripe.php CHANGED
@@ -25,7 +25,7 @@ class WC_Stripe_Manager {
25
  *
26
  * @var string
27
  */
28
- public $version = '3.2.12';
29
 
30
  /**
31
  *
@@ -220,7 +220,6 @@ class WC_Stripe_Manager {
220
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-gateway.php';
221
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-customer-manager.php';
222
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-gateway-conversions.php';
223
- include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-frontend-notices.php';
224
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-redirect-handler.php';
225
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-product-gateway-option.php';
226
 
25
  *
26
  * @var string
27
  */
28
+ public $version = '3.2.13';
29
 
30
  /**
31
  *
220
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-gateway.php';
221
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-customer-manager.php';
222
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-gateway-conversions.php';
 
223
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-redirect-handler.php';
224
  include_once WC_STRIPE_PLUGIN_FILE_PATH . 'includes/class-wc-stripe-product-gateway-option.php';
225
 
includes/class-wc-stripe-field-manager.php CHANGED
@@ -78,7 +78,7 @@ class WC_Stripe_Field_Manager {
78
  *
79
  * @var WC_Payment_Gateway_Stripe $gateway
80
  */
81
- if ( $gateway->supports( 'wc_stripe_product_checkout' ) ) {
82
  $option = new WC_Stripe_Product_Gateway_Option( $product, $gateway );
83
  if ( $option->enabled() ) {
84
  if ( isset( $ordering[ $gateway->id ] ) ) {
78
  *
79
  * @var WC_Payment_Gateway_Stripe $gateway
80
  */
81
+ if ( $gateway->supports( 'wc_stripe_product_checkout' ) && ! $product->is_type( 'external' ) ) {
82
  $option = new WC_Stripe_Product_Gateway_Option( $product, $gateway );
83
  if ( $option->enabled() ) {
84
  if ( isset( $ordering[ $gateway->id ] ) ) {
includes/class-wc-stripe-frontend-notices.php DELETED
@@ -1,58 +0,0 @@
1
- <?php
2
- defined( 'ABSPATH' ) || exit();
3
-
4
- /**
5
- * Class that manages frontend notices for customers.
6
- *
7
- * @author PaymentPlugins
8
- * @package Stripe/Classes
9
- * @since 3.0.0
10
- *
11
- */
12
- class WC_Stripe_Frontend_Notices {
13
-
14
- public static function init() {
15
- add_action( 'wp_enqueue_scripts', array( __CLASS__, 'enqueue_scripts' ) );
16
- }
17
-
18
- public static function enqueue_scripts() {
19
- if ( isset( $wp->query_vars['order-received'] ) ) {
20
- $scripts = stripe_wc()->scripts();
21
- $order_id = absint( $wp->query_vars['order-received'] );
22
- $order = wc_get_order( $order_id );
23
- $notices = array();
24
- if ( ( $message = $order->get_meta( '_wc_stripe_order_error', true ) ) ) {
25
- $notices[] = wc_get_template_html( 'notices/notice.php', array( 'messages' => array( $message ) ) );
26
- }
27
- if ( $order->has_status( 'on-hold' ) ) {
28
- $payment_method = $order->get_payment_method();
29
- $gateway = WC()->payment_gateways()->payment_gateways()[ $payment_method ];
30
- if ( $gateway instanceof WC_Payment_Gateway_Stripe_Local_Payment ) {
31
- $notices[] = wc_get_template_html(
32
- 'notices/notice.php',
33
- array(
34
- 'messages' => array(
35
- __( 'Your payment is being processed and your order status will be updated once the funds are received.', 'woo-stripe-payment' ),
36
- ),
37
- )
38
- );
39
- }
40
- if ( $notices ) {
41
- self::enqueue_notices( $notices );
42
- }
43
- }
44
- }
45
- }
46
-
47
- public static function enqueue_notices( $notices ) {
48
- $scripts->enqueue_script( 'notices', $scripts->assets_url( 'js/frontend/notices.js' ), array( 'jquery' ), stripe_wc()->version(), true );
49
- $scripts->localize_script(
50
- 'notices',
51
- array(
52
- 'container' => '.woocommerce-order',
53
- 'notices' => $notices,
54
- )
55
- );
56
- }
57
- }
58
- WC_Stripe_Frontend_Notices::init();
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
includes/class-wc-stripe-payment-intent.php CHANGED
@@ -57,24 +57,15 @@ class WC_Stripe_Payment_Intent extends WC_Stripe_Payment {
57
 
58
  // the intent was processed.
59
  if ( $intent->status === 'succeeded' || $intent->status === 'requires_capture' ) {
60
-
61
- if ( isset( $intent['setup_future_usage'] ) && 'off_session' === $intent['setup_future_usage'] ) {
62
- $result = $this->payment_method->save_payment_method( $this->payment_method->get_new_source_token(), $order );
63
- if ( is_wp_error( $result ) ) {
64
- $this->payment_method->set_payment_save_error( $order, $result );
65
- }
66
  }
67
 
68
- // payment has been processed.
69
- $charges = $intent->charges;
70
- if ( count( $charges->data ) > 0 ) {
71
- $charge = $charges->data[0];
72
-
73
- return (object) array(
74
- 'complete_payment' => true,
75
- 'charge' => $charge,
76
- );
77
- }
78
  }
79
  if ( in_array( $intent->status, array( 'requires_action', 'requires_payment_method', 'requires_source_action', 'requires_source' ), true ) ) {
80
  return (object) array(
57
 
58
  // the intent was processed.
59
  if ( $intent->status === 'succeeded' || $intent->status === 'requires_capture' ) {
60
+ $charge = $intent->charges->data[0];
61
+ if ( isset( $intent->setup_future_usage, $intent->customer, $charge->payment_method_details ) && 'off_session' === $intent->setup_future_usage ) {
62
+ $this->payment_method->save_payment_method( $intent->payment_method, $order, $charge->payment_method_details );
 
 
 
63
  }
64
 
65
+ return (object) array(
66
+ 'complete_payment' => true,
67
+ 'charge' => $charge,
68
+ );
 
 
 
 
 
 
69
  }
70
  if ( in_array( $intent->status, array( 'requires_action', 'requires_payment_method', 'requires_source_action', 'requires_source' ), true ) ) {
71
  return (object) array(
includes/wc-stripe-functions.php CHANGED
@@ -165,6 +165,20 @@ function wc_stripe_save_customer( $customer_id, $user_id, $mode = '' ) {
165
  update_user_option( $user_id, $key, apply_filters( 'wc_stripe_save_customer', $customer_id, $user_id, $mode ) );
166
  }
167
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
168
  /**
169
  *
170
  * @param int $token_id
165
  update_user_option( $user_id, $key, apply_filters( 'wc_stripe_save_customer', $customer_id, $user_id, $mode ) );
166
  }
167
 
168
+ /**
169
+ * @param int $user_id
170
+ * @param string $mode
171
+ * @param bool $global
172
+ *
173
+ * @since 3.2.13
174
+ */
175
+ function wc_stripe_delete_customer( $user_id, $mode = '', $global = false ) {
176
+ global $wpdb;
177
+ $mode = empty( $mode ) ? wc_stripe_mode() : $mode;
178
+ $key = $key = "wc_stripe_customer_{$mode}";
179
+ delete_user_option( $user_id, $key, $global );
180
+ }
181
+
182
  /**
183
  *
184
  * @param int $token_id
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: stripe, ach, klarna, credit card, apple pay, google pay, ideal, sepa, sofo
4
  Requires at least: 3.0.1
5
  Tested up to: 5.6
6
  Requires PHP: 5.6
7
- Stable tag: 3.2.12
8
  Copyright: Payment Plugins
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
@@ -58,6 +58,15 @@ If you're site is not loading over https, then Stripe won't render the Payment R
58
  8. Edit payment gateways on the product page
59
 
60
  == Changelog ==
 
 
 
 
 
 
 
 
 
61
  = 3.2.12 =
62
  * Added - billing_details property to local payment methods
63
  * Added - Improved support for multisite. Replaced use of get_user_meta with get_user_option
4
  Requires at least: 3.0.1
5
  Tested up to: 5.6
6
  Requires PHP: 5.6
7
+ Stable tag: 3.2.13
8
  Copyright: Payment Plugins
9
  License: GPLv2 or later
10
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
58
  8. Edit payment gateways on the product page
59
 
60
  == Changelog ==
61
+ = 3.2.13 =
62
+ * Added - Save new payment method to subscription when failed renewal order is paid for.
63
+ * Added - Permission check "manage_woocommerce" added to Edit Product page for rendering Stripe settings
64
+ * Added - If shipping phone field exists and is empty, populate using GPay/Apple Pay phone number returned
65
+ * Updated - WC Tested up to 5.0
66
+ * Updated - Stripe PHP SDK 7.72.0
67
+ * Updated - Fix change_payment_method request logic so it's processed in the process_payment function
68
+ * Updated - Adjust cart page buttons so last button doesn't have bottom margin
69
+ * Updated - Performance improvement on checkout page when saving a payment method and processing order
70
  = 3.2.12 =
71
  * Added - billing_details property to local payment methods
72
  * Added - Improved support for multisite. Replaced use of get_user_meta with get_user_option
stripe-payments.php CHANGED
@@ -3,13 +3,13 @@
3
  * Plugin Name: Stripe For WooCommerce
4
  * Plugin URI: https://docs.paymentplugins.com/wc-stripe/config/
5
  * Description: Accept credit cards, Google Pay, Apple Pay, ACH, Klarna and more using Stripe.
6
- * Version: 3.2.12
7
  * Author: Payment Plugins, support@paymentplugins.com
8
  * Text Domain: woo-stripe-payment
9
  * Domain Path: /i18n/languages/
10
  * Tested up to: 5.6
11
  * WC requires at least: 3.0.0
12
- * WC tested up to: 4.9.0
13
  */
14
  defined( 'ABSPATH' ) || exit ();
15
 
3
  * Plugin Name: Stripe For WooCommerce
4
  * Plugin URI: https://docs.paymentplugins.com/wc-stripe/config/
5
  * Description: Accept credit cards, Google Pay, Apple Pay, ACH, Klarna and more using Stripe.
6
+ * Version: 3.2.13
7
  * Author: Payment Plugins, support@paymentplugins.com
8
  * Text Domain: woo-stripe-payment
9
  * Domain Path: /i18n/languages/
10
  * Tested up to: 5.6
11
  * WC requires at least: 3.0.0
12
+ * WC tested up to: 5.0
13
  */
14
  defined( 'ABSPATH' ) || exit ();
15
 
vendor/autoload.php CHANGED
@@ -4,4 +4,4 @@
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
- return ComposerAutoloaderInite75330386e2ebdcb0d6bfb6ef84a7163::getLoader();
4
 
5
  require_once __DIR__ . '/composer/autoload_real.php';
6
 
7
+ return ComposerAutoloaderInit5768cfd8cdeac9b8b5d68cdcb14472ce::getLoader();
vendor/composer/autoload_real.php CHANGED
@@ -2,7 +2,7 @@
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
- class ComposerAutoloaderInite75330386e2ebdcb0d6bfb6ef84a7163
6
  {
7
  private static $loader;
8
 
@@ -22,15 +22,15 @@ class ComposerAutoloaderInite75330386e2ebdcb0d6bfb6ef84a7163
22
  return self::$loader;
23
  }
24
 
25
- spl_autoload_register(array('ComposerAutoloaderInite75330386e2ebdcb0d6bfb6ef84a7163', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader();
27
- spl_autoload_unregister(array('ComposerAutoloaderInite75330386e2ebdcb0d6bfb6ef84a7163', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require_once __DIR__ . '/autoload_static.php';
32
 
33
- call_user_func(\Composer\Autoload\ComposerStaticInite75330386e2ebdcb0d6bfb6ef84a7163::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
2
 
3
  // autoload_real.php @generated by Composer
4
 
5
+ class ComposerAutoloaderInit5768cfd8cdeac9b8b5d68cdcb14472ce
6
  {
7
  private static $loader;
8
 
22
  return self::$loader;
23
  }
24
 
25
+ spl_autoload_register(array('ComposerAutoloaderInit5768cfd8cdeac9b8b5d68cdcb14472ce', 'loadClassLoader'), true, true);
26
  self::$loader = $loader = new \Composer\Autoload\ClassLoader();
27
+ spl_autoload_unregister(array('ComposerAutoloaderInit5768cfd8cdeac9b8b5d68cdcb14472ce', 'loadClassLoader'));
28
 
29
  $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
30
  if ($useStaticLoader) {
31
  require_once __DIR__ . '/autoload_static.php';
32
 
33
+ call_user_func(\Composer\Autoload\ComposerStaticInit5768cfd8cdeac9b8b5d68cdcb14472ce::getInitializer($loader));
34
  } else {
35
  $map = require __DIR__ . '/autoload_namespaces.php';
36
  foreach ($map as $namespace => $path) {
vendor/composer/autoload_static.php CHANGED
@@ -4,7 +4,7 @@
4
 
5
  namespace Composer\Autoload;
6
 
7
- class ComposerStaticInite75330386e2ebdcb0d6bfb6ef84a7163
8
  {
9
  public static $prefixLengthsPsr4 = array (
10
  'S' =>
@@ -23,8 +23,8 @@ class ComposerStaticInite75330386e2ebdcb0d6bfb6ef84a7163
23
  public static function getInitializer(ClassLoader $loader)
24
  {
25
  return \Closure::bind(function () use ($loader) {
26
- $loader->prefixLengthsPsr4 = ComposerStaticInite75330386e2ebdcb0d6bfb6ef84a7163::$prefixLengthsPsr4;
27
- $loader->prefixDirsPsr4 = ComposerStaticInite75330386e2ebdcb0d6bfb6ef84a7163::$prefixDirsPsr4;
28
 
29
  }, null, ClassLoader::class);
30
  }
4
 
5
  namespace Composer\Autoload;
6
 
7
+ class ComposerStaticInit5768cfd8cdeac9b8b5d68cdcb14472ce
8
  {
9
  public static $prefixLengthsPsr4 = array (
10
  'S' =>
23
  public static function getInitializer(ClassLoader $loader)
24
  {
25
  return \Closure::bind(function () use ($loader) {
26
+ $loader->prefixLengthsPsr4 = ComposerStaticInit5768cfd8cdeac9b8b5d68cdcb14472ce::$prefixLengthsPsr4;
27
+ $loader->prefixDirsPsr4 = ComposerStaticInit5768cfd8cdeac9b8b5d68cdcb14472ce::$prefixDirsPsr4;
28
 
29
  }, null, ClassLoader::class);
30
  }
vendor/composer/installed.json CHANGED
@@ -1,17 +1,17 @@
1
  [
2
  {
3
  "name": "stripe/stripe-php",
4
- "version": "v7.62.0",
5
- "version_normalized": "7.62.0.0",
6
  "source": {
7
  "type": "git",
8
  "url": "https://github.com/stripe/stripe-php.git",
9
- "reference": "9c2fc846d5b2719945e825228474f15314c0fed6"
10
  },
11
  "dist": {
12
  "type": "zip",
13
- "url": "https://api.github.com/repos/stripe/stripe-php/zipball/9c2fc846d5b2719945e825228474f15314c0fed6",
14
- "reference": "9c2fc846d5b2719945e825228474f15314c0fed6",
15
  "shasum": ""
16
  },
17
  "require": {
@@ -21,13 +21,13 @@
21
  "php": ">=5.6.0"
22
  },
23
  "require-dev": {
24
- "friendsofphp/php-cs-fixer": "2.16.5",
25
  "php-coveralls/php-coveralls": "^2.1",
26
  "phpunit/phpunit": "^5.7",
27
  "squizlabs/php_codesniffer": "^3.3",
28
  "symfony/process": "~3.4"
29
  },
30
- "time": "2020-11-09T16:57:44+00:00",
31
  "type": "library",
32
  "extra": {
33
  "branch-alias": {
1
  [
2
  {
3
  "name": "stripe/stripe-php",
4
+ "version": "v7.72.0",
5
+ "version_normalized": "7.72.0.0",
6
  "source": {
7
  "type": "git",
8
  "url": "https://github.com/stripe/stripe-php.git",
9
+ "reference": "e502d1e97ec7857038d2131ded3134af964a55c5"
10
  },
11
  "dist": {
12
  "type": "zip",
13
+ "url": "https://api.github.com/repos/stripe/stripe-php/zipball/e502d1e97ec7857038d2131ded3134af964a55c5",
14
+ "reference": "e502d1e97ec7857038d2131ded3134af964a55c5",
15
  "shasum": ""
16
  },
17
  "require": {
21
  "php": ">=5.6.0"
22
  },
23
  "require-dev": {
24
+ "friendsofphp/php-cs-fixer": "2.17.1",
25
  "php-coveralls/php-coveralls": "^2.1",
26
  "phpunit/phpunit": "^5.7",
27
  "squizlabs/php_codesniffer": "^3.3",
28
  "symfony/process": "~3.4"
29
  },
30
+ "time": "2021-02-09T03:22:51+00:00",
31
  "type": "library",
32
  "extra": {
33
  "branch-alias": {
vendor/stripe/stripe-php/.php_cs.dist CHANGED
@@ -13,10 +13,17 @@ return PhpCsFixer\Config::create()
13
  // Additional rules
14
  'fopen_flags' => true,
15
  'linebreak_after_opening_tag' => true,
 
16
  'native_function_invocation' => true,
17
 
18
  // --- Diffs from @PhpCsFixer / @PhpCsFixer:risky ---
19
 
 
 
 
 
 
 
20
  // This is just prettier / easier to read.
21
  'concat_space' => ['spacing' => 'one'],
22
 
13
  // Additional rules
14
  'fopen_flags' => true,
15
  'linebreak_after_opening_tag' => true,
16
+ 'native_constant_invocation' => true,
17
  'native_function_invocation' => true,
18
 
19
  // --- Diffs from @PhpCsFixer / @PhpCsFixer:risky ---
20
 
21
+ // This is the same as the default for the @PhpCsFixer ruleset, minus
22
+ // the following values: ['include', 'include_once', 'require',
23
+ // 'require_once']. We could enable them and remove this line after
24
+ // updating codegen for the `init.php` file to be compliant.
25
+ 'blank_line_before_statement' => ['statements' => ['break', 'case', 'continue', 'declare', 'default', 'exit', 'goto', 'return', 'switch', 'throw', 'try']],
26
+
27
  // This is just prettier / easier to read.
28
  'concat_space' => ['spacing' => 'one'],
29
 
vendor/stripe/stripe-php/CHANGELOG.md CHANGED
@@ -1,5 +1,48 @@
1
  # Changelog
2
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ## 7.62.0 - 2020-11-09
4
  * [#1041](https://github.com/stripe/stripe-php/pull/1041) Add missing constants on `Event`
5
  * [#1038](https://github.com/stripe/stripe-php/pull/1038) Update PHPDocs
1
  # Changelog
2
 
3
+ ## 7.72.0 - 2021-02-08
4
+ * [#1089](https://github.com/stripe/stripe-php/pull/1089) API Updates
5
+ * Add support for `afterpay_clearpay_payments` on `Account.capabilities`
6
+ * Add support for `payment_settings` on `Invoice`
7
+
8
+ ## 7.71.0 - 2021-02-05
9
+ * [#1087](https://github.com/stripe/stripe-php/pull/1087) Update PHPDocs
10
+ * [#1086](https://github.com/stripe/stripe-php/pull/1086) Update CA cert bundle URL
11
+
12
+ ## 7.70.0 - 2021-02-03
13
+ * [#1085](https://github.com/stripe/stripe-php/pull/1085) Update PHPDocs
14
+ * Add support for `nationality` on `Person`
15
+ * Add member `gb_vat` of `TaxID` enum
16
+
17
+
18
+ ## 7.69.0 - 2021-01-21
19
+ * [#1079](https://github.com/stripe/stripe-php/pull/1079) Update PHPDocs
20
+
21
+ ## 7.68.0 - 2021-01-14
22
+ * [#1063](https://github.com/stripe/stripe-php/pull/1063) Multiple API changes
23
+ * [#1061](https://github.com/stripe/stripe-php/pull/1061) Bump phpDocumentor to 3.0.0
24
+
25
+ ## 7.67.0 - 2020-12-09
26
+ * [#1060](https://github.com/stripe/stripe-php/pull/1060) Improve PHPDocs for `Discount`
27
+ * [#1059](https://github.com/stripe/stripe-php/pull/1059) Upgrade PHPStan to 0.12.59
28
+ * [#1057](https://github.com/stripe/stripe-php/pull/1057) Bump PHP-CS-Fixer and update code
29
+
30
+ ## 7.66.1 - 2020-12-01
31
+ * [#1054](https://github.com/stripe/stripe-php/pull/1054) Improve error message for invalid keys in StripeClient
32
+
33
+ ## 7.66.0 - 2020-11-24
34
+ * [#1053](https://github.com/stripe/stripe-php/pull/1053) Update PHPDocs
35
+
36
+ ## 7.65.0 - 2020-11-19
37
+ * [#1050](https://github.com/stripe/stripe-php/pull/1050) Added constants for `proration_behavior` on `Subscription`
38
+
39
+ ## 7.64.0 - 2020-11-18
40
+ * [#1049](https://github.com/stripe/stripe-php/pull/1049) Update PHPDocs
41
+
42
+ ## 7.63.0 - 2020-11-17
43
+ * [#1048](https://github.com/stripe/stripe-php/pull/1048) Update PHPDocs
44
+ * [#1046](https://github.com/stripe/stripe-php/pull/1046) Force IPv4 resolving
45
+
46
  ## 7.62.0 - 2020-11-09
47
  * [#1041](https://github.com/stripe/stripe-php/pull/1041) Add missing constants on `Event`
48
  * [#1038](https://github.com/stripe/stripe-php/pull/1038) Update PHPDocs
vendor/stripe/stripe-php/Makefile CHANGED
@@ -1,5 +1,5 @@
1
- export PHPDOCUMENTOR_VERSION := v3.0.0-rc
2
- export PHPSTAN_VERSION := 0.12.18
3
 
4
  vendor: composer.json
5
  composer install
1
+ export PHPDOCUMENTOR_VERSION := v3.0.0
2
+ export PHPSTAN_VERSION := 0.12.59
3
 
4
  vendor: composer.json
5
  composer install
vendor/stripe/stripe-php/README.md CHANGED
@@ -70,6 +70,9 @@ You can continue to use the legacy integration patterns used prior to version [7
70
 
71
  See the [PHP API docs](https://stripe.com/docs/api/php#intro).
72
 
 
 
 
73
  ## Legacy Version Support
74
 
75
  ### PHP 5.4 & 5.5
@@ -264,3 +267,4 @@ See the "SSL / TLS compatibility issues" paragraph above for full context. If yo
264
  [php-cs-fixer]: https://github.com/FriendsOfPHP/PHP-CS-Fixer
265
  [psr3]: http://www.php-fig.org/psr/psr-3/
266
  [stripe-mock]: https://github.com/stripe/stripe-mock
 
70
 
71
  See the [PHP API docs](https://stripe.com/docs/api/php#intro).
72
 
73
+ See [video demonstrations][youtube-playlist] covering how to use the library.
74
+
75
+
76
  ## Legacy Version Support
77
 
78
  ### PHP 5.4 & 5.5
267
  [php-cs-fixer]: https://github.com/FriendsOfPHP/PHP-CS-Fixer
268
  [psr3]: http://www.php-fig.org/psr/psr-3/
269
  [stripe-mock]: https://github.com/stripe/stripe-mock
270
+ [youtube-playlist]: https://www.youtube.com/playlist?list=PLy1nL-pvL2M6cUbiHrfMkXxZ9j9SGBxFE
vendor/stripe/stripe-php/VERSION CHANGED
@@ -1 +1 @@
1
- 7.62.0
1
+ 7.72.0
vendor/stripe/stripe-php/lib/Account.php CHANGED
@@ -26,7 +26,7 @@ namespace Stripe;
26
  * @property bool $details_submitted Whether account details have been submitted. Standard accounts cannot receive payouts before this is true.
27
  * @property null|string $email The primary user's email address.
28
  * @property \Stripe\Collection $external_accounts External accounts (bank accounts and debit cards) currently attached to this account
29
- * @property \Stripe\Person $individual <p>This is an object representing a person associated with a Stripe account.</p><p>Related guide: <a href="https://stripe.com/docs/connect/identity-verification-api#person-information">Handling Identity Verification with the API</a>.</p>
30
  * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
31
  * @property bool $payouts_enabled Whether Stripe can send payouts to this account.
32
  * @property \Stripe\StripeObject $requirements
@@ -128,9 +128,9 @@ class Account extends ApiResource
128
  $update = ($v instanceof StripeObject) ? $v->serializeParameters() : $v;
129
 
130
  if ([] !== $update) {
131
- if (!$originalValue ||
132
- !\array_key_exists($i, $originalValue) ||
133
- ($update !== $legalEntity->serializeParamsValue($originalValue[$i], null, false, true))) {
134
  $updateArr[$i] = $update;
135
  }
136
  }
26
  * @property bool $details_submitted Whether account details have been submitted. Standard accounts cannot receive payouts before this is true.
27
  * @property null|string $email The primary user's email address.
28
  * @property \Stripe\Collection $external_accounts External accounts (bank accounts and debit cards) currently attached to this account
29
+ * @property \Stripe\Person $individual <p>This is an object representing a person associated with a Stripe account.</p><p>A platform cannot access a Standard or Express account's persons after the account starts onboarding, such as after generating an account link for the account. See the <a href="https://stripe.com/docs/connect/standard-accounts">Standard onboarding</a> or <a href="https://stripe.com/docs/connect/express-accounts">Express onboarding documentation</a> for information about platform pre-filling and account onboarding steps.</p><p>Related guide: <a href="https://stripe.com/docs/connect/identity-verification-api#person-information">Handling Identity Verification with the API</a>.</p>
30
  * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
31
  * @property bool $payouts_enabled Whether Stripe can send payouts to this account.
32
  * @property \Stripe\StripeObject $requirements
128
  $update = ($v instanceof StripeObject) ? $v->serializeParameters() : $v;
129
 
130
  if ([] !== $update) {
131
+ if (!$originalValue
132
+ || !\array_key_exists($i, $originalValue)
133
+ || ($update !== $legalEntity->serializeParamsValue($originalValue[$i], null, false, true))) {
134
  $updateArr[$i] = $update;
135
  }
136
  }
vendor/stripe/stripe-php/lib/ApiRequestor.php CHANGED
@@ -187,14 +187,19 @@ class ApiRequestor
187
  // no break
188
  case 404:
189
  return Exception\InvalidRequestException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code, $param);
 
190
  case 401:
191
  return Exception\AuthenticationException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code);
 
192
  case 402:
193
  return Exception\CardException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code, $declineCode, $param);
 
194
  case 403:
195
  return Exception\PermissionException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code);
 
196
  case 429:
197
  return Exception\RateLimitException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code, $param);
 
198
  default:
199
  return Exception\UnknownApiErrorException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code);
200
  }
@@ -218,16 +223,22 @@ class ApiRequestor
218
  switch ($errorCode) {
219
  case 'invalid_client':
220
  return Exception\OAuth\InvalidClientException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
 
221
  case 'invalid_grant':
222
  return Exception\OAuth\InvalidGrantException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
 
223
  case 'invalid_request':
224
  return Exception\OAuth\InvalidRequestException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
 
225
  case 'invalid_scope':
226
  return Exception\OAuth\InvalidScopeException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
 
227
  case 'unsupported_grant_type':
228
  return Exception\OAuth\UnsupportedGrantTypeException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
 
229
  case 'unsupported_response_type':
230
  return Exception\OAuth\UnsupportedResponseTypeException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
 
231
  default:
232
  return Exception\OAuth\UnknownOAuthErrorException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
233
  }
187
  // no break
188
  case 404:
189
  return Exception\InvalidRequestException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code, $param);
190
+
191
  case 401:
192
  return Exception\AuthenticationException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code);
193
+
194
  case 402:
195
  return Exception\CardException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code, $declineCode, $param);
196
+
197
  case 403:
198
  return Exception\PermissionException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code);
199
+
200
  case 429:
201
  return Exception\RateLimitException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code, $param);
202
+
203
  default:
204
  return Exception\UnknownApiErrorException::factory($msg, $rcode, $rbody, $resp, $rheaders, $code);
205
  }
223
  switch ($errorCode) {
224
  case 'invalid_client':
225
  return Exception\OAuth\InvalidClientException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
226
+
227
  case 'invalid_grant':
228
  return Exception\OAuth\InvalidGrantException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
229
+
230
  case 'invalid_request':
231
  return Exception\OAuth\InvalidRequestException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
232
+
233
  case 'invalid_scope':
234
  return Exception\OAuth\InvalidScopeException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
235
+
236
  case 'unsupported_grant_type':
237
  return Exception\OAuth\UnsupportedGrantTypeException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
238
+
239
  case 'unsupported_response_type':
240
  return Exception\OAuth\UnsupportedResponseTypeException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
241
+
242
  default:
243
  return Exception\OAuth\UnknownOAuthErrorException::factory($description, $rcode, $rbody, $resp, $rheaders, $errorCode);
244
  }
vendor/stripe/stripe-php/lib/ApiResource.php CHANGED
@@ -39,8 +39,8 @@ abstract class ApiResource extends StripeObject
39
  {
40
  parent::__set($k, $v);
41
  $v = $this->{$k};
42
- if ((static::getSavedNestedResources()->includes($k)) &&
43
- ($v instanceof ApiResource)) {
44
  $v->saveWithParent = true;
45
  }
46
  }
39
  {
40
  parent::__set($k, $v);
41
  $v = $this->{$k};
42
+ if ((static::getSavedNestedResources()->includes($k))
43
+ && ($v instanceof ApiResource)) {
44
  $v->saveWithParent = true;
45
  }
46
  }
vendor/stripe/stripe-php/lib/BaseStripeClient.php CHANGED
@@ -260,7 +260,10 @@ class BaseStripeClient implements StripeClientInterface
260
  // check absence of extra keys
261
  $extraConfigKeys = \array_diff(\array_keys($config), \array_keys($this->getDefaultConfig()));
262
  if (!empty($extraConfigKeys)) {
263
- throw new \Stripe\Exception\InvalidArgumentException('Found unknown key(s) in configuration array: ' . \implode(',', $extraConfigKeys));
 
 
 
264
  }
265
  }
266
  }
260
  // check absence of extra keys
261
  $extraConfigKeys = \array_diff(\array_keys($config), \array_keys($this->getDefaultConfig()));
262
  if (!empty($extraConfigKeys)) {
263
+ // Wrap in single quote to more easily catch trailing spaces errors
264
+ $invalidKeys = "'" . \implode("', '", $extraConfigKeys) . "'";
265
+
266
+ throw new \Stripe\Exception\InvalidArgumentException('Found unknown key(s) in configuration array: ' . $invalidKeys);
267
  }
268
  }
269
  }
vendor/stripe/stripe-php/lib/Checkout/Session.php CHANGED
@@ -29,10 +29,11 @@ namespace Stripe\Checkout;
29
  * @property null|int $amount_total Total of all items after discounts and taxes are applied.
30
  * @property null|string $billing_address_collection Describes whether Checkout should collect the customer's billing address.
31
  * @property string $cancel_url The URL the customer will be directed to if they decide to cancel payment and return to your website.
32
- * @property null|string $client_reference_id A unique string to reference the Checkout Session. This can be a customer ID, a cart ID, or similar, and can be used to reconcile the session with your internal systems.
33
  * @property null|string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
34
- * @property null|string|\Stripe\Customer $customer The ID of the customer for this session. For Checkout Sessions in <code>payment</code> or <code>subscription</code> mode, Checkout will create a new customer object based on information provided during the session unless an existing customer was provided when the session was created.
35
- * @property null|string $customer_email If provided, this value will be used when the Customer object is created. If not provided, customers will be asked to enter their email address. Use this parameter to prefill customer data if you already have an email on file. To access information about the customer once a session is complete, use the <code>customer</code> attribute.
 
36
  * @property \Stripe\Collection $line_items The line items purchased by the customer.
37
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
38
  * @property null|string $locale The IETF language tag of the locale Checkout is displayed in. If blank or <code>auto</code>, the browser's locale is used.
29
  * @property null|int $amount_total Total of all items after discounts and taxes are applied.
30
  * @property null|string $billing_address_collection Describes whether Checkout should collect the customer's billing address.
31
  * @property string $cancel_url The URL the customer will be directed to if they decide to cancel payment and return to your website.
32
+ * @property null|string $client_reference_id A unique string to reference the Checkout Session. This can be a customer ID, a cart ID, or similar, and can be used to reconcile the Session with your internal systems.
33
  * @property null|string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
34
+ * @property null|string|\Stripe\Customer $customer The ID of the customer for this Session. For Checkout Sessions in <code>payment</code> or <code>subscription</code> mode, Checkout will create a new customer object based on information provided during the payment flow unless an existing customer was provided when the Session was created.
35
+ * @property null|\Stripe\StripeObject $customer_details The customer details including the customer's tax exempt status and the customer's tax IDs.
36
+ * @property null|string $customer_email If provided, this value will be used when the Customer object is created. If not provided, customers will be asked to enter their email address. Use this parameter to prefill customer data if you already have an email on file. To access information about the customer once the payment flow is complete, use the <code>customer</code> attribute.
37
  * @property \Stripe\Collection $line_items The line items purchased by the customer.
38
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
39
  * @property null|string $locale The IETF language tag of the locale Checkout is displayed in. If blank or <code>auto</code>, the browser's locale is used.
vendor/stripe/stripe-php/lib/Collection.php CHANGED
@@ -142,8 +142,8 @@ class Collection extends StripeObject implements \Countable, \IteratorAggregate
142
 
143
  while (true) {
144
  $filters = $this->filters ?: [];
145
- if (\array_key_exists('ending_before', $filters) &&
146
- !\array_key_exists('starting_after', $filters)) {
147
  foreach ($page->getReverseIterator() as $item) {
148
  yield $item;
149
  }
142
 
143
  while (true) {
144
  $filters = $this->filters ?: [];
145
+ if (\array_key_exists('ending_before', $filters)
146
+ && !\array_key_exists('starting_after', $filters)) {
147
  foreach ($page->getReverseIterator() as $item) {
148
  yield $item;
149
  }
vendor/stripe/stripe-php/lib/Customer.php CHANGED
@@ -21,7 +21,7 @@ namespace Stripe;
21
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
22
  * @property null|string $currency Three-letter <a href="https://stripe.com/docs/currencies">ISO code for the currency</a> the customer can be charged in for recurring billing purposes.
23
  * @property null|string|\Stripe\Account|\Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source $default_source <p>ID of the default payment source for the customer.</p><p>If you are using payment methods created via the PaymentMethods API, see the <a href="https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method">invoice_settings.default_payment_method</a> field instead.</p>
24
- * @property null|bool $delinquent When the customer's latest invoice is billed by charging automatically, delinquent is true if the invoice's latest charge is failed. When the customer's latest invoice is billed by sending an invoice, delinquent is true if the invoice is not paid by its due date.
25
  * @property null|string $description An arbitrary string attached to the object. Often useful for displaying to users.
26
  * @property null|\Stripe\Discount $discount Describes the current discount active on the customer, if there is one.
27
  * @property null|string $email The customer's email address.
21
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
22
  * @property null|string $currency Three-letter <a href="https://stripe.com/docs/currencies">ISO code for the currency</a> the customer can be charged in for recurring billing purposes.
23
  * @property null|string|\Stripe\Account|\Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source $default_source <p>ID of the default payment source for the customer.</p><p>If you are using payment methods created via the PaymentMethods API, see the <a href="https://stripe.com/docs/api/customers/object#customer_object-invoice_settings-default_payment_method">invoice_settings.default_payment_method</a> field instead.</p>
24
+ * @property null|bool $delinquent <p>When the customer's latest invoice is billed by charging automatically, <code>delinquent</code> is <code>true</code> if the invoice's latest charge failed. When the customer's latest invoice is billed by sending an invoice, <code>delinquent</code> is <code>true</code> if the invoice isn't paid by its due date.</p><p>If an invoice is marked uncollectible by <a href="https://stripe.com/docs/billing/automatic-collection">dunning</a>, <code>delinquent</code> doesn't get reset to <code>false</code>.</p>
25
  * @property null|string $description An arbitrary string attached to the object. Often useful for displaying to users.
26
  * @property null|\Stripe\Discount $discount Describes the current discount active on the customer, if there is one.
27
  * @property null|string $email The customer's email address.
vendor/stripe/stripe-php/lib/Discount.php CHANGED
@@ -6,11 +6,17 @@ namespace Stripe;
6
  * Class Discount.
7
  *
8
  * @property string $object
9
- * @property Coupon $coupon
10
- * @property string $customer
11
- * @property int $end
12
- * @property int $start
13
- * @property string $subscription
 
 
 
 
 
 
14
  */
15
  class Discount extends StripeObject
16
  {
6
  * Class Discount.
7
  *
8
  * @property string $object
9
+ * @property string $checkout_session The Checkout session that this coupon is applied to, if it is applied to a particular session in payment mode. Will not be present for subscription mode.
10
+ * @property \Stripe\Coupon $coupon Hash describing the coupon applied to create this discount.
11
+ * @property string|\Stripe\Customer $customer The ID of the customer associated with this discount.
12
+ * @property int $end If the coupon has a duration of repeating, the date that this discount will end. If the coupon has a duration of once or forever, this attribute will be null.
13
+ * @property string $id The ID of the discount object.
14
+ * @property string $invoice The invoice that the discount’s coupon was applied to, if it was applied directly to a particular invoice.
15
+ * @property string $invoice_item The invoice item id (or invoice line item id for invoice line items of type=‘subscription’) that the discount’s coupon was applied to, if it was applied directly to a particular invoice item or invoice line item.
16
+ * @property string $object String representing the object’s type. Objects of the same type share the same value.
17
+ * @property string $promotion_code The promotion code applied to create this discount.
18
+ * @property int $start Date that the coupon was applied.
19
+ * @property string $subscription The subscription that this coupon is applied to, if it is applied to a particular subscription.
20
  */
21
  class Discount extends StripeObject
22
  {
vendor/stripe/stripe-php/lib/EphemeralKey.php CHANGED
@@ -17,12 +17,12 @@ class EphemeralKey extends ApiResource
17
  {
18
  const OBJECT_NAME = 'ephemeral_key';
19
 
20
- use ApiOperations\Delete;
21
-
22
  use ApiOperations\Create {
23
  create as protected _create;
24
  }
25
 
 
 
26
  /**
27
  * @param null|array $params
28
  * @param null|array|string $opts
17
  {
18
  const OBJECT_NAME = 'ephemeral_key';
19
 
 
 
20
  use ApiOperations\Create {
21
  create as protected _create;
22
  }
23
 
24
+ use ApiOperations\Delete;
25
+
26
  /**
27
  * @param null|array $params
28
  * @param null|array|string $opts
vendor/stripe/stripe-php/lib/File.php CHANGED
@@ -34,6 +34,7 @@ class File extends ApiResource
34
  use ApiOperations\All;
35
  use ApiOperations\Retrieve;
36
 
 
37
  const PURPOSE_ADDITIONAL_VERIFICATION = 'additional_verification';
38
  const PURPOSE_BUSINESS_ICON = 'business_icon';
39
  const PURPOSE_BUSINESS_LOGO = 'business_logo';
34
  use ApiOperations\All;
35
  use ApiOperations\Retrieve;
36
 
37
+ const PURPOSE_ACCOUNT_REQUIREMENT = 'account_requirement';
38
  const PURPOSE_ADDITIONAL_VERIFICATION = 'additional_verification';
39
  const PURPOSE_BUSINESS_ICON = 'business_icon';
40
  const PURPOSE_BUSINESS_LOGO = 'business_logo';
vendor/stripe/stripe-php/lib/HttpClient/CurlClient.php CHANGED
@@ -237,7 +237,7 @@ class CurlClient implements ClientInterface
237
  // add an Idempotency-Key header
238
  if (('post' === $method) && (Stripe::$maxNetworkRetries > 0)) {
239
  if (!$this->hasHeader($headers, 'Idempotency-Key')) {
240
- \array_push($headers, 'Idempotency-Key: ' . $this->randomGenerator->uuid());
241
  }
242
  }
243
 
@@ -253,7 +253,7 @@ class CurlClient implements ClientInterface
253
  // we'll error under that condition. To compensate for that problem
254
  // for the time being, override cURL's behavior by simply always
255
  // sending an empty `Expect:` header.
256
- \array_push($headers, 'Expect: ');
257
 
258
  $absUrl = Util\Util::utf8($absUrl);
259
  $opts[\CURLOPT_URL] = $absUrl;
@@ -271,6 +271,10 @@ class CurlClient implements ClientInterface
271
  $opts[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_2TLS;
272
  }
273
 
 
 
 
 
274
  list($rbody, $rcode, $rheaders) = $this->executeRequestWithRetries($opts, $absUrl);
275
 
276
  return [$rbody, $rcode, $rheaders];
@@ -283,7 +287,6 @@ class CurlClient implements ClientInterface
283
  private function executeRequestWithRetries($opts, $absUrl)
284
  {
285
  $numRetries = 0;
286
- $isPost = \array_key_exists(\CURLOPT_POST, $opts) && 1 === $opts[\CURLOPT_POST];
287
 
288
  while (true) {
289
  $rcode = 0;
@@ -363,6 +366,7 @@ class CurlClient implements ClientInterface
363
  . 'https://twitter.com/stripestatus, or';
364
 
365
  break;
 
366
  case \CURLE_SSL_CACERT:
367
  case \CURLE_SSL_PEER_CERTIFICATE:
368
  $msg = "Could not verify Stripe's SSL certificate. Please make sure "
@@ -371,6 +375,7 @@ class CurlClient implements ClientInterface
371
  . 'If this problem persists,';
372
 
373
  break;
 
374
  default:
375
  $msg = 'Unexpected error communicating with Stripe. '
376
  . 'If this problem persists,';
237
  // add an Idempotency-Key header
238
  if (('post' === $method) && (Stripe::$maxNetworkRetries > 0)) {
239
  if (!$this->hasHeader($headers, 'Idempotency-Key')) {
240
+ $headers[] = 'Idempotency-Key: ' . $this->randomGenerator->uuid();
241
  }
242
  }
243
 
253
  // we'll error under that condition. To compensate for that problem
254
  // for the time being, override cURL's behavior by simply always
255
  // sending an empty `Expect:` header.
256
+ $headers[] = 'Expect: ';
257
 
258
  $absUrl = Util\Util::utf8($absUrl);
259
  $opts[\CURLOPT_URL] = $absUrl;
271
  $opts[\CURLOPT_HTTP_VERSION] = \CURL_HTTP_VERSION_2TLS;
272
  }
273
 
274
+ // Stripe's API servers are only accessible over IPv4. Force IPv4 resolving to avoid
275
+ // potential issues (cf. https://github.com/stripe/stripe-php/issues/1045).
276
+ $opts[\CURLOPT_IPRESOLVE] = \CURL_IPRESOLVE_V4;
277
+
278
  list($rbody, $rcode, $rheaders) = $this->executeRequestWithRetries($opts, $absUrl);
279
 
280
  return [$rbody, $rcode, $rheaders];
287
  private function executeRequestWithRetries($opts, $absUrl)
288
  {
289
  $numRetries = 0;
 
290
 
291
  while (true) {
292
  $rcode = 0;
366
  . 'https://twitter.com/stripestatus, or';
367
 
368
  break;
369
+
370
  case \CURLE_SSL_CACERT:
371
  case \CURLE_SSL_PEER_CERTIFICATE:
372
  $msg = "Could not verify Stripe's SSL certificate. Please make sure "
375
  . 'If this problem persists,';
376
 
377
  break;
378
+
379
  default:
380
  $msg = 'Unexpected error communicating with Stripe. '
381
  . 'If this problem persists,';
vendor/stripe/stripe-php/lib/Invoice.php CHANGED
@@ -32,11 +32,11 @@ namespace Stripe;
32
  * amount due for the invoice is less than Stripe's <a
33
  * href="/docs/currencies#minimum-and-maximum-charge-amounts">minimum allowed
34
  * charge per currency</a>, the invoice is automatically marked paid, and we add
35
- * the amount due to the customer's running account balance which is applied to the
36
- * next invoice.
37
  *
38
- * More details on the customer's account balance are <a
39
- * href="https://stripe.com/docs/api/customers/object#customer_object-account_balance">here</a>.
40
  *
41
  * Related guide: <a href="https://stripe.com/docs/billing/invoices/sending">Send
42
  * Invoices to Customers</a>.
@@ -45,6 +45,7 @@ namespace Stripe;
45
  * @property string $object String representing the object's type. Objects of the same type share the same value.
46
  * @property null|string $account_country The country of the business associated with this invoice, most often the business creating the invoice.
47
  * @property null|string $account_name The public name of the business associated with this invoice, most often the business creating the invoice.
 
48
  * @property int $amount_due Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the <code>amount_due</code> may be 0. If there is a positive <code>starting_balance</code> for the invoice (the customer owes money), the <code>amount_due</code> will also take that into account. The charge that gets generated for the invoice will be for the amount specified in <code>amount_due</code>.
49
  * @property int $amount_paid The amount, in %s, that was paid.
50
  * @property int $amount_remaining The amount remaining, in %s, that is due.
@@ -68,7 +69,7 @@ namespace Stripe;
68
  * @property null|\Stripe\StripeObject[] $customer_tax_ids The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as <code>customer.tax_ids</code>. Once the invoice is finalized, this field will no longer be updated.
69
  * @property null|string|\Stripe\PaymentMethod $default_payment_method ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
70
  * @property null|string|\Stripe\Account|\Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source $default_source ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
71
- * @property null|\Stripe\TaxRate[] $default_tax_rates The tax rates applied to this invoice, if any.
72
  * @property null|string $description An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
73
  * @property null|\Stripe\Discount $discount Describes the current discount applied to this invoice, if there is one. Not populated if there are multiple discounts.
74
  * @property null|(string|\Stripe\Discount)[] $discounts The discounts applied to the invoice. Line item discounts are applied before invoice discounts. Use <code>expand[]=discounts</code> to expand each discount.
@@ -85,6 +86,7 @@ namespace Stripe;
85
  * @property null|string $number A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified.
86
  * @property bool $paid Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance.
87
  * @property null|string|\Stripe\PaymentIntent $payment_intent The PaymentIntent associated with this invoice. The PaymentIntent is generated when the invoice is finalized, and can then be used to pay the invoice. Note that voiding an invoice will cancel the PaymentIntent.
 
88
  * @property int $period_end End of the usage period during which invoice items were added to this invoice.
89
  * @property int $period_start Start of the usage period during which invoice items were added to this invoice.
90
  * @property int $post_payment_credit_notes_amount Total amount of all post-payment credit notes issued for this invoice.
@@ -101,7 +103,7 @@ namespace Stripe;
101
  * @property \Stripe\StripeObject $threshold_reason
102
  * @property int $total Total after discounts and taxes.
103
  * @property null|\Stripe\StripeObject[] $total_discount_amounts The aggregate amounts calculated per discount across all line items.
104
- * @property null|\Stripe\StripeObject[] $total_tax_amounts The aggregate amounts calculated per tax rate for all line items.
105
  * @property null|int $webhooks_delivered_at Invoices are automatically paid or sent 1 hour after webhooks are delivered, or until all webhook delivery attempts have <a href="https://stripe.com/docs/billing/webhooks#understand">been exhausted</a>. This field tracks the time when webhooks for this invoice were successfully delivered. If the invoice had no webhooks to deliver, this will be set while the invoice is being created.
106
  */
107
  class Invoice extends ApiResource
32
  * amount due for the invoice is less than Stripe's <a
33
  * href="/docs/currencies#minimum-and-maximum-charge-amounts">minimum allowed
34
  * charge per currency</a>, the invoice is automatically marked paid, and we add
35
+ * the amount due to the customer's credit balance which is applied to the next
36
+ * invoice.
37
  *
38
+ * More details on the customer's credit balance are <a
39
+ * href="https://stripe.com/docs/billing/customer/balance">here</a>.
40
  *
41
  * Related guide: <a href="https://stripe.com/docs/billing/invoices/sending">Send
42
  * Invoices to Customers</a>.
45
  * @property string $object String representing the object's type. Objects of the same type share the same value.
46
  * @property null|string $account_country The country of the business associated with this invoice, most often the business creating the invoice.
47
  * @property null|string $account_name The public name of the business associated with this invoice, most often the business creating the invoice.
48
+ * @property null|(string|\Stripe\TaxId)[] $account_tax_ids The account tax IDs associated with the invoice. Only editable when the invoice is a draft.
49
  * @property int $amount_due Final amount due at this time for this invoice. If the invoice's total is smaller than the minimum charge amount, for example, or if there is account credit that can be applied to the invoice, the <code>amount_due</code> may be 0. If there is a positive <code>starting_balance</code> for the invoice (the customer owes money), the <code>amount_due</code> will also take that into account. The charge that gets generated for the invoice will be for the amount specified in <code>amount_due</code>.
50
  * @property int $amount_paid The amount, in %s, that was paid.
51
  * @property int $amount_remaining The amount remaining, in %s, that is due.
69
  * @property null|\Stripe\StripeObject[] $customer_tax_ids The customer's tax IDs. Until the invoice is finalized, this field will contain the same tax IDs as <code>customer.tax_ids</code>. Once the invoice is finalized, this field will no longer be updated.
70
  * @property null|string|\Stripe\PaymentMethod $default_payment_method ID of the default payment method for the invoice. It must belong to the customer associated with the invoice. If not set, defaults to the subscription's default payment method, if any, or to the default payment method in the customer's invoice settings.
71
  * @property null|string|\Stripe\Account|\Stripe\AlipayAccount|\Stripe\BankAccount|\Stripe\BitcoinReceiver|\Stripe\Card|\Stripe\Source $default_source ID of the default payment source for the invoice. It must belong to the customer associated with the invoice and be in a chargeable state. If not set, defaults to the subscription's default source, if any, or to the customer's default source.
72
+ * @property \Stripe\TaxRate[] $default_tax_rates The tax rates applied to this invoice, if any.
73
  * @property null|string $description An arbitrary string attached to the object. Often useful for displaying to users. Referenced as 'memo' in the Dashboard.
74
  * @property null|\Stripe\Discount $discount Describes the current discount applied to this invoice, if there is one. Not populated if there are multiple discounts.
75
  * @property null|(string|\Stripe\Discount)[] $discounts The discounts applied to the invoice. Line item discounts are applied before invoice discounts. Use <code>expand[]=discounts</code> to expand each discount.
86
  * @property null|string $number A unique, identifying string that appears on emails sent to the customer for this invoice. This starts with the customer's unique invoice_prefix if it is specified.
87
  * @property bool $paid Whether payment was successfully collected for this invoice. An invoice can be paid (most commonly) with a charge or with credit from the customer's account balance.
88
  * @property null|string|\Stripe\PaymentIntent $payment_intent The PaymentIntent associated with this invoice. The PaymentIntent is generated when the invoice is finalized, and can then be used to pay the invoice. Note that voiding an invoice will cancel the PaymentIntent.
89
+ * @property \Stripe\StripeObject $payment_settings
90
  * @property int $period_end End of the usage period during which invoice items were added to this invoice.
91
  * @property int $period_start Start of the usage period during which invoice items were added to this invoice.
92
  * @property int $post_payment_credit_notes_amount Total amount of all post-payment credit notes issued for this invoice.
103
  * @property \Stripe\StripeObject $threshold_reason
104
  * @property int $total Total after discounts and taxes.
105
  * @property null|\Stripe\StripeObject[] $total_discount_amounts The aggregate amounts calculated per discount across all line items.
106
+ * @property \Stripe\StripeObject[] $total_tax_amounts The aggregate amounts calculated per tax rate for all line items.
107
  * @property null|int $webhooks_delivered_at Invoices are automatically paid or sent 1 hour after webhooks are delivered, or until all webhook delivery attempts have <a href="https://stripe.com/docs/billing/webhooks#understand">been exhausted</a>. This field tracks the time when webhooks for this invoice were successfully delivered. If the invoice had no webhooks to deliver, this will be set while the invoice is being created.
108
  */
109
  class Invoice extends ApiResource
vendor/stripe/stripe-php/lib/InvoiceLineItem.php CHANGED
@@ -23,8 +23,8 @@ namespace Stripe;
23
  * @property null|int $quantity The quantity of the subscription, if the line item is a subscription or a proration.
24
  * @property null|string $subscription The subscription that the invoice item pertains to, if any.
25
  * @property string $subscription_item The subscription item that generated this invoice item. Left empty if the line item is not an explicit result of a subscription.
26
- * @property null|\Stripe\StripeObject[] $tax_amounts The amount of tax calculated per tax rate for this line item
27
- * @property null|\Stripe\TaxRate[] $tax_rates The tax rates which apply to the line item.
28
  * @property string $type A string identifying the type of the source of this line item, either an <code>invoiceitem</code> or a <code>subscription</code>.
29
  */
30
  class InvoiceLineItem extends ApiResource
23
  * @property null|int $quantity The quantity of the subscription, if the line item is a subscription or a proration.
24
  * @property null|string $subscription The subscription that the invoice item pertains to, if any.
25
  * @property string $subscription_item The subscription item that generated this invoice item. Left empty if the line item is not an explicit result of a subscription.
26
+ * @property \Stripe\StripeObject[] $tax_amounts The amount of tax calculated per tax rate for this line item
27
+ * @property \Stripe\TaxRate[] $tax_rates The tax rates which apply to the line item.
28
  * @property string $type A string identifying the type of the source of this line item, either an <code>invoiceitem</code> or a <code>subscription</code>.
29
  */
30
  class InvoiceLineItem extends ApiResource
vendor/stripe/stripe-php/lib/Issuing/Dispute.php CHANGED
@@ -15,10 +15,10 @@ namespace Stripe\Issuing;
15
  *
16
  * @property string $id Unique identifier for the object.
17
  * @property string $object String representing the object's type. Objects of the same type share the same value.
18
- * @property int $amount Disputed amount. Usually the amount of the <code>disputed_transaction</code>, but can differ (usually because of currency fluctuation).
19
  * @property null|\Stripe\BalanceTransaction[] $balance_transactions List of balance transactions associated with the dispute.
20
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
21
- * @property string $currency The currency the <code>disputed_transaction</code> was made in.
22
  * @property \Stripe\StripeObject $evidence
23
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
24
  * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
15
  *
16
  * @property string $id Unique identifier for the object.
17
  * @property string $object String representing the object's type. Objects of the same type share the same value.
18
+ * @property int $amount Disputed amount. Usually the amount of the <code>transaction</code>, but can differ (usually because of currency fluctuation).
19
  * @property null|\Stripe\BalanceTransaction[] $balance_transactions List of balance transactions associated with the dispute.
20
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
21
+ * @property string $currency The currency the <code>transaction</code> was made in.
22
  * @property \Stripe\StripeObject $evidence
23
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
24
  * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
vendor/stripe/stripe-php/lib/LineItem.php CHANGED
@@ -9,12 +9,12 @@ namespace Stripe;
9
  *
10
  * @property string $id Unique identifier for the object.
11
  * @property string $object String representing the object's type. Objects of the same type share the same value.
12
- * @property null|int $amount_subtotal Total before any discounts or taxes is applied.
13
- * @property null|int $amount_total Total after discounts and taxes.
14
  * @property string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
15
  * @property string $description An arbitrary string attached to the object. Often useful for displaying to users. Defaults to product name.
16
  * @property \Stripe\StripeObject[] $discounts The discounts applied to the line item.
17
- * @property \Stripe\Price $price <p>Prices define the unit cost, currency, and (optional) billing cycle for both recurring and one-time purchases of products. <a href="https://stripe.com/docs/api#products">Products</a> help you track inventory or provisioning, and prices help you track payment terms. Different physical goods or levels of service should be represented by products, and pricing options should be represented by prices. This approach lets you change prices without having to change your provisioning scheme.</p><p>For example, you might have a single &quot;gold&quot; product that has prices for $10/month, $100/year, and €9 once.</p><p>Related guides: <a href="https://stripe.com/docs/billing/subscriptions/set-up-subscription">Set up a subscription</a>, <a href="https://stripe.com/docs/billing/invoices/create">create an invoice</a>, and more about <a href="https://stripe.com/docs/billing/prices-guide">products and prices</a>.</p>
18
  * @property null|int $quantity The quantity of products being purchased.
19
  * @property \Stripe\StripeObject[] $taxes The taxes applied to the line item.
20
  */
9
  *
10
  * @property string $id Unique identifier for the object.
11
  * @property string $object String representing the object's type. Objects of the same type share the same value.
12
+ * @property int $amount_subtotal Total before any discounts or taxes are applied.
13
+ * @property int $amount_total Total after discounts and taxes.
14
  * @property string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
15
  * @property string $description An arbitrary string attached to the object. Often useful for displaying to users. Defaults to product name.
16
  * @property \Stripe\StripeObject[] $discounts The discounts applied to the line item.
17
+ * @property null|\Stripe\Price $price The price used to generate the line item.
18
  * @property null|int $quantity The quantity of products being purchased.
19
  * @property \Stripe\StripeObject[] $taxes The taxes applied to the line item.
20
  */
vendor/stripe/stripe-php/lib/PaymentIntent.php CHANGED
@@ -24,12 +24,12 @@ namespace Stripe;
24
  * @property int $amount_capturable Amount that can be captured from this PaymentIntent.
25
  * @property int $amount_received Amount that was collected by this PaymentIntent.
26
  * @property null|string|\Stripe\StripeObject $application ID of the Connect application that created the PaymentIntent.
27
- * @property null|int $application_fee_amount The amount of the application fee (if any) requested for the resulting payment. See the PaymentIntents <a href="https://stripe.com/docs/payments/connected-accounts">use case for connected accounts</a> for details.
28
  * @property null|int $canceled_at Populated when <code>status</code> is <code>canceled</code>, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
29
  * @property null|string $cancellation_reason Reason for cancellation of this PaymentIntent, either user-provided (<code>duplicate</code>, <code>fraudulent</code>, <code>requested_by_customer</code>, or <code>abandoned</code>) or generated by Stripe internally (<code>failed_invoice</code>, <code>void_invoice</code>, or <code>automatic</code>).
30
  * @property string $capture_method Controls when the funds will be captured from the customer's account.
31
  * @property \Stripe\Collection $charges Charges that were created by this PaymentIntent, if any.
32
- * @property null|string $client_secret <p>The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key.</p><p>The client secret can be used to complete a payment from your frontend. It should not be stored, logged, embedded in URLs, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.</p><p>Refer to our docs to <a href="https://stripe.com/docs/payments/accept-a-payment">accept a payment</a> and learn about how <code>client_secret</code> should be handled.</p>
33
  * @property string $confirmation_method
34
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
35
  * @property string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
24
  * @property int $amount_capturable Amount that can be captured from this PaymentIntent.
25
  * @property int $amount_received Amount that was collected by this PaymentIntent.
26
  * @property null|string|\Stripe\StripeObject $application ID of the Connect application that created the PaymentIntent.
27
+ * @property null|int $application_fee_amount The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner's Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents <a href="https://stripe.com/docs/payments/connected-accounts">use case for connected accounts</a>.
28
  * @property null|int $canceled_at Populated when <code>status</code> is <code>canceled</code>, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
29
  * @property null|string $cancellation_reason Reason for cancellation of this PaymentIntent, either user-provided (<code>duplicate</code>, <code>fraudulent</code>, <code>requested_by_customer</code>, or <code>abandoned</code>) or generated by Stripe internally (<code>failed_invoice</code>, <code>void_invoice</code>, or <code>automatic</code>).
30
  * @property string $capture_method Controls when the funds will be captured from the customer's account.
31
  * @property \Stripe\Collection $charges Charges that were created by this PaymentIntent, if any.
32
+ * @property null|string $client_secret <p>The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key.</p><p>The client secret can be used to complete a payment from your frontend. It should not be stored, logged, embedded in URLs, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.</p><p>Refer to our docs to <a href="https://stripe.com/docs/payments/accept-a-payment?integration=elements">accept a payment</a> and learn about how <code>client_secret</code> should be handled.</p>
33
  * @property string $confirmation_method
34
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
35
  * @property string $currency Three-letter <a href="https://www.iso.org/iso-4217-currency-codes.html">ISO currency code</a>, in lowercase. Must be a <a href="https://stripe.com/docs/currencies">supported currency</a>.
vendor/stripe/stripe-php/lib/PaymentMethod.php CHANGED
@@ -30,6 +30,7 @@ namespace Stripe;
30
  * @property \Stripe\StripeObject $eps
31
  * @property \Stripe\StripeObject $fpx
32
  * @property \Stripe\StripeObject $giropay
 
33
  * @property \Stripe\StripeObject $ideal
34
  * @property \Stripe\StripeObject $interac_present
35
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
30
  * @property \Stripe\StripeObject $eps
31
  * @property \Stripe\StripeObject $fpx
32
  * @property \Stripe\StripeObject $giropay
33
+ * @property \Stripe\StripeObject $grabpay
34
  * @property \Stripe\StripeObject $ideal
35
  * @property \Stripe\StripeObject $interac_present
36
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
vendor/stripe/stripe-php/lib/Person.php CHANGED
@@ -7,6 +7,14 @@ namespace Stripe;
7
  /**
8
  * This is an object representing a person associated with a Stripe account.
9
  *
 
 
 
 
 
 
 
 
10
  * Related guide: <a
11
  * href="https://stripe.com/docs/connect/identity-verification-api#person-information">Handling
12
  * Identity Verification with the API</a>.
@@ -30,6 +38,7 @@ namespace Stripe;
30
  * @property null|string $last_name_kanji The Kanji variation of the person's last name (Japan only).
31
  * @property null|string $maiden_name The person's maiden name.
32
  * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
 
33
  * @property null|string $phone The person's phone number.
34
  * @property string $political_exposure Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
35
  * @property \Stripe\StripeObject $relationship
7
  /**
8
  * This is an object representing a person associated with a Stripe account.
9
  *
10
+ * A platform cannot access a Standard or Express account's persons after the
11
+ * account starts onboarding, such as after generating an account link for the
12
+ * account. See the <a
13
+ * href="https://stripe.com/docs/connect/standard-accounts">Standard onboarding</a>
14
+ * or <a href="https://stripe.com/docs/connect/express-accounts">Express onboarding
15
+ * documentation</a> for information about platform pre-filling and account
16
+ * onboarding steps.
17
+ *
18
  * Related guide: <a
19
  * href="https://stripe.com/docs/connect/identity-verification-api#person-information">Handling
20
  * Identity Verification with the API</a>.
38
  * @property null|string $last_name_kanji The Kanji variation of the person's last name (Japan only).
39
  * @property null|string $maiden_name The person's maiden name.
40
  * @property \Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
41
+ * @property null|string $nationality The country where the person is a national.
42
  * @property null|string $phone The person's phone number.
43
  * @property string $political_exposure Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction.
44
  * @property \Stripe\StripeObject $relationship
vendor/stripe/stripe-php/lib/Stripe.php CHANGED
@@ -58,7 +58,7 @@ class Stripe
58
  /** @var float Initial delay between retries, in seconds */
59
  private static $initialNetworkRetryDelay = 0.5;
60
 
61
- const VERSION = '7.62.0';
62
 
63
  /**
64
  * @return string the API key used for requests
58
  /** @var float Initial delay between retries, in seconds */
59
  private static $initialNetworkRetryDelay = 0.5;
60
 
61
+ const VERSION = '7.72.0';
62
 
63
  /**
64
  * @return string the API key used for requests
vendor/stripe/stripe-php/lib/StripeObject.php CHANGED
@@ -397,7 +397,7 @@ class StripeObject implements \ArrayAccess, \Countable, \JsonSerializable
397
  // Sequential array, i.e. a list
398
  $update = [];
399
  foreach ($value as $v) {
400
- \array_push($update, $this->serializeParamsValue($v, null, true, $force));
401
  }
402
  // This prevents an array that's unchanged from being resent.
403
  if ($update !== $this->serializeParamsValue($original, null, true, $force, $key)) {
397
  // Sequential array, i.e. a list
398
  $update = [];
399
  foreach ($value as $v) {
400
+ $update[] = $this->serializeParamsValue($v, null, true, $force);
401
  }
402
  // This prevents an array that's unchanged from being resent.
403
  if ($update !== $this->serializeParamsValue($original, null, true, $force, $key)) {
vendor/stripe/stripe-php/lib/Subscription.php CHANGED
@@ -58,6 +58,10 @@ class Subscription extends ApiResource
58
  const PAYMENT_BEHAVIOR_ERROR_IF_INCOMPLETE = 'error_if_incomplete';
59
  const PAYMENT_BEHAVIOR_PENDING_IF_INCOMPLETE = 'pending_if_incomplete';
60
 
 
 
 
 
61
  const STATUS_ACTIVE = 'active';
62
  const STATUS_CANCELED = 'canceled';
63
  const STATUS_INCOMPLETE = 'incomplete';
58
  const PAYMENT_BEHAVIOR_ERROR_IF_INCOMPLETE = 'error_if_incomplete';
59
  const PAYMENT_BEHAVIOR_PENDING_IF_INCOMPLETE = 'pending_if_incomplete';
60
 
61
+ const PRORATION_BEHAVIOR_ALWAYS_INVOICE = 'always_invoice';
62
+ const PRORATION_BEHAVIOR_CREATE_PRORATIONS = 'create_prorations';
63
+ const PRORATION_BEHAVIOR_NONE = 'none';
64
+
65
  const STATUS_ACTIVE = 'active';
66
  const STATUS_CANCELED = 'canceled';
67
  const STATUS_INCOMPLETE = 'incomplete';
vendor/stripe/stripe-php/lib/TaxId.php CHANGED
@@ -18,7 +18,7 @@ namespace Stripe;
18
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
19
  * @property null|string|\Stripe\Customer $customer ID of the customer.
20
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
21
- * @property string $type Type of the tax ID, one of <code>ae_trn</code>, <code>au_abn</code>, <code>br_cnpj</code>, <code>br_cpf</code>, <code>ca_bn</code>, <code>ca_qst</code>, <code>ch_vat</code>, <code>cl_tin</code>, <code>es_cif</code>, <code>eu_vat</code>, <code>hk_br</code>, <code>id_npwp</code>, <code>in_gst</code>, <code>jp_cn</code>, <code>jp_rn</code>, <code>kr_brn</code>, <code>li_uid</code>, <code>mx_rfc</code>, <code>my_frp</code>, <code>my_itn</code>, <code>my_sst</code>, <code>no_vat</code>, <code>nz_gst</code>, <code>ru_inn</code>, <code>ru_kpp</code>, <code>sa_vat</code>, <code>sg_gst</code>, <code>sg_uen</code>, <code>th_vat</code>, <code>tw_vat</code>, <code>us_ein</code>, or <code>za_vat</code>. Note that some legacy tax IDs have type <code>unknown</code>
22
  * @property string $value Value of the tax ID.
23
  * @property null|\Stripe\StripeObject $verification Tax ID verification information.
24
  */
@@ -38,6 +38,7 @@ class TaxId extends ApiResource
38
  const TYPE_CL_TIN = 'cl_tin';
39
  const TYPE_ES_CIF = 'es_cif';
40
  const TYPE_EU_VAT = 'eu_vat';
 
41
  const TYPE_HK_BR = 'hk_br';
42
  const TYPE_ID_NPWP = 'id_npwp';
43
  const TYPE_IN_GST = 'in_gst';
18
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
19
  * @property null|string|\Stripe\Customer $customer ID of the customer.
20
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
21
+ * @property string $type Type of the tax ID, one of <code>ae_trn</code>, <code>au_abn</code>, <code>br_cnpj</code>, <code>br_cpf</code>, <code>ca_bn</code>, <code>ca_qst</code>, <code>ch_vat</code>, <code>cl_tin</code>, <code>es_cif</code>, <code>eu_vat</code>, <code>gb_vat</code>, <code>hk_br</code>, <code>id_npwp</code>, <code>in_gst</code>, <code>jp_cn</code>, <code>jp_rn</code>, <code>kr_brn</code>, <code>li_uid</code>, <code>mx_rfc</code>, <code>my_frp</code>, <code>my_itn</code>, <code>my_sst</code>, <code>no_vat</code>, <code>nz_gst</code>, <code>ru_inn</code>, <code>ru_kpp</code>, <code>sa_vat</code>, <code>sg_gst</code>, <code>sg_uen</code>, <code>th_vat</code>, <code>tw_vat</code>, <code>us_ein</code>, or <code>za_vat</code>. Note that some legacy tax IDs have type <code>unknown</code>
22
  * @property string $value Value of the tax ID.
23
  * @property null|\Stripe\StripeObject $verification Tax ID verification information.
24
  */
38
  const TYPE_CL_TIN = 'cl_tin';
39
  const TYPE_ES_CIF = 'es_cif';
40
  const TYPE_EU_VAT = 'eu_vat';
41
+ const TYPE_GB_VAT = 'gb_vat';
42
  const TYPE_HK_BR = 'hk_br';
43
  const TYPE_ID_NPWP = 'id_npwp';
44
  const TYPE_IN_GST = 'in_gst';
vendor/stripe/stripe-php/lib/TaxRate.php CHANGED
@@ -18,6 +18,7 @@ namespace Stripe;
18
  * @property string $id Unique identifier for the object.
19
  * @property string $object String representing the object's type. Objects of the same type share the same value.
20
  * @property bool $active Defaults to <code>true</code>. When set to <code>false</code>, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
 
21
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
22
  * @property null|string $description An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
23
  * @property string $display_name The display name of the tax rates as it will appear to your customer on their receipt email, PDF, and the hosted invoice page.
@@ -26,6 +27,7 @@ namespace Stripe;
26
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
27
  * @property null|\Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
28
  * @property float $percentage This represents the tax rate percent out of 100.
 
29
  */
30
  class TaxRate extends ApiResource
31
  {
18
  * @property string $id Unique identifier for the object.
19
  * @property string $object String representing the object's type. Objects of the same type share the same value.
20
  * @property bool $active Defaults to <code>true</code>. When set to <code>false</code>, this tax rate cannot be used with new applications or Checkout Sessions, but will still work for subscriptions and invoices that already have it set.
21
+ * @property null|string $country Two-letter country code (<a href="https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2">ISO 3166-1 alpha-2</a>).
22
  * @property int $created Time at which the object was created. Measured in seconds since the Unix epoch.
23
  * @property null|string $description An arbitrary string attached to the tax rate for your internal use only. It will not be visible to your customers.
24
  * @property string $display_name The display name of the tax rates as it will appear to your customer on their receipt email, PDF, and the hosted invoice page.
27
  * @property bool $livemode Has the value <code>true</code> if the object exists in live mode or the value <code>false</code> if the object exists in test mode.
28
  * @property null|\Stripe\StripeObject $metadata Set of <a href="https://stripe.com/docs/api/metadata">key-value pairs</a> that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
29
  * @property float $percentage This represents the tax rate percent out of 100.
30
+ * @property null|string $state <a href="https://en.wikipedia.org/wiki/ISO_3166-2:US">ISO 3166-2 subdivision code</a>, without country prefix. For example, &quot;NY&quot; for New York, United States.
31
  */
32
  class TaxRate extends ApiResource
33
  {
vendor/stripe/stripe-php/lib/Util/RequestOptions.php CHANGED
@@ -161,7 +161,7 @@ class RequestOptions
161
  $redactedLast = \strlen($last) > 4
162
  ? (\str_repeat('*', \strlen($last) - 4) . \substr($last, -4))
163
  : $last;
164
- \array_push($pieces, $redactedLast);
165
 
166
  return \implode('_', $pieces);
167
  }
161
  $redactedLast = \strlen($last) > 4
162
  ? (\str_repeat('*', \strlen($last) - 4) . \substr($last, -4))
163
  : $last;
164
+ $pieces[] = $redactedLast;
165
 
166
  return \implode('_', $pieces);
167
  }
vendor/stripe/stripe-php/lib/Util/Util.php CHANGED
@@ -47,7 +47,7 @@ abstract class Util
47
  if (self::isList($resp)) {
48
  $mapped = [];
49
  foreach ($resp as $i) {
50
- \array_push($mapped, self::convertToStripeObject($i, $opts));
51
  }
52
 
53
  return $mapped;
@@ -138,7 +138,7 @@ abstract class Util
138
  if (static::isList($h)) {
139
  $results = [];
140
  foreach ($h as $v) {
141
- \array_push($results, static::objectsToIds($v));
142
  }
143
 
144
  return $results;
@@ -169,7 +169,7 @@ abstract class Util
169
  $pieces = [];
170
  foreach ($flattenedParams as $param) {
171
  list($k, $v) = $param;
172
- \array_push($pieces, self::urlEncode($k) . '=' . self::urlEncode($v));
173
  }
174
 
175
  return \implode('&', $pieces);
47
  if (self::isList($resp)) {
48
  $mapped = [];
49
  foreach ($resp as $i) {
50
+ $mapped[] = self::convertToStripeObject($i, $opts);
51
  }
52
 
53
  return $mapped;
138
  if (static::isList($h)) {
139
  $results = [];
140
  foreach ($h as $v) {
141
+ $results[] = static::objectsToIds($v);
142
  }
143
 
144
  return $results;
169
  $pieces = [];
170
  foreach ($flattenedParams as $param) {
171
  list($k, $v) = $param;
172
+ $pieces[] = self::urlEncode($k) . '=' . self::urlEncode($v);
173
  }
174
 
175
  return \implode('&', $pieces);
vendor/stripe/stripe-php/lib/WebhookSignature.php CHANGED
@@ -116,7 +116,7 @@ abstract class WebhookSignature
116
  foreach ($items as $item) {
117
  $itemParts = \explode('=', $item, 2);
118
  if (\trim($itemParts[0]) === $scheme) {
119
- \array_push($signatures, $itemParts[1]);
120
  }
121
  }
122
 
116
  foreach ($items as $item) {
117
  $itemParts = \explode('=', $item, 2);
118
  if (\trim($itemParts[0]) === $scheme) {
119
+ $signatures[] = $itemParts[1];
120
  }
121
  }
122
 
vendor/stripe/stripe-php/phpstan.neon.dist CHANGED
@@ -4,7 +4,8 @@ includes:
4
  parameters:
5
  level: 1
6
 
7
- bootstrap: tests/bootstrap.php
 
8
 
9
  ignoreErrors:
10
  - '#Unsafe usage of new static\(\).#'
4
  parameters:
5
  level: 1
6
 
7
+ bootstrapFiles:
8
+ - tests/bootstrap.php
9
 
10
  ignoreErrors:
11
  - '#Unsafe usage of new static\(\).#'
vendor/stripe/stripe-php/update_certs.php CHANGED
@@ -9,7 +9,7 @@ $fp = \fopen(__DIR__ . '/data/ca-certificates.crt', 'w+b');
9
  $options = [
10
  \CURLOPT_FILE => $fp,
11
  \CURLOPT_TIMEOUT => 3600,
12
- \CURLOPT_URL => 'https://curl.haxx.se/ca/cacert.pem',
13
  ];
14
 
15
  $ch = \curl_init();
9
  $options = [
10
  \CURLOPT_FILE => $fp,
11
  \CURLOPT_TIMEOUT => 3600,
12
+ \CURLOPT_URL => 'https://curl.se/ca/cacert.pem',
13
  ];
14
 
15
  $ch = \curl_init();