Merge branch 'trunk' into PCP-1393-update-to-vault-v-3

This commit is contained in:
Emili Castells Guasch 2023-11-28 12:03:51 +01:00
commit 9e87e93985
8 changed files with 56 additions and 27 deletions

View file

@ -18,7 +18,7 @@
.woocommerce-checkout {
#applepay-container, .ppcp-button-applepay {
margin-top: 0.5em;
margin-top: 0;
--apple-pay-button-border-radius: 4px;
--apple-pay-button-height: 45px;
&.ppcp-button-pill {
@ -31,6 +31,7 @@
.wp-block-woocommerce-checkout {
#applepay-container, .ppcp-button-applepay {
margin: 0;
--apple-pay-button-margin: 0;
--apple-pay-button-height: 48px;
&.ppcp-button-pill {
@ -41,16 +42,10 @@
.wp-block-woocommerce-cart {
#applepay-container, .ppcp-button-applepay {
margin: 0;
--apple-pay-button-margin: 0;
--apple-pay-button-height: 48px;
}
/* Workaround for blocks grid */
.wc-block-components-express-payment__event-buttons {
--apple-pay-button-display: block;
li[id*="express-payment-method-ppcp-"] {
--apple-pay-button-padding-bottom: 0;
}
}
}
}

View file

@ -1272,9 +1272,12 @@ document.querySelector("#payment").before(document.querySelector("#ppcp-messages
}
if ( in_array( $context, array( 'checkout-block', 'cart-block' ), true ) ) {
$disable_funding = array_diff(
array_keys( $this->all_funding_sources ),
array( 'venmo', 'paylater' )
$disable_funding = array_merge(
$disable_funding,
array_diff(
array_keys( $this->all_funding_sources ),
array( 'venmo', 'paylater' )
)
);
}

View file

@ -34,13 +34,6 @@
margin: 0;
height: 48px;
}
/* Workaround for blocks grid */
.wc-block-components-express-payment__event-buttons {
display: block;
li[id*="express-payment-method-ppcp-"] {
padding-bottom: 0;
}
}
}
}

View file

@ -275,8 +275,9 @@ class PayPalGateway extends \WC_Payment_Gateway {
if ( $order &&
( $order->status()->is( OrderStatus::APPROVED ) || $order->status()->is( OrderStatus::COMPLETED ) )
) {
$this->title = $this->funding_source_renderer->render_name( $funding_source );
$this->description = $this->funding_source_renderer->render_description( $funding_source );
$this->title = $this->funding_source_renderer->render_name( $funding_source );
$this->description = $this->funding_source_renderer->render_description( $funding_source );
$this->order_button_text = null;
}
}