Merge branch 'trunk' into PCP-2347-new-feature-accelerated-checkout

# Conflicts:
#	modules.php
This commit is contained in:
Pedro Silva 2024-04-12 10:22:47 +01:00
commit 9cb63040d8
No known key found for this signature in database
GPG key ID: E2EE20C0669D24B3
129 changed files with 7018 additions and 1124 deletions

View file

@ -70,10 +70,6 @@ class ApplepayButton {
if (this.isEligible) {
this.fetchTransactionInfo().then(() => {
const isSubscriptionProduct = this.ppcpConfig?.data_client_id?.has_subscriptions === true;
if (isSubscriptionProduct) {
return;
}
this.addButton();
const id_minicart = "#apple-" + this.buttonConfig.button.mini_cart_wrapper;
const id = "#apple-" + this.buttonConfig.button.wrapper;
@ -214,6 +210,8 @@ class ApplepayButton {
const paymentRequest = this.paymentRequest();
window.ppcpFundingSource = 'apple_pay'; // Do this on another place like on create order endpoint handler.
// Trigger woocommerce validation if we are in the checkout page.
if (this.context === 'checkout') {
const checkoutFormSelector = 'form.woocommerce-checkout';