Add oxxo logo and do not render icon if not exist

This commit is contained in:
Emili Castells Guasch 2025-01-24 15:39:30 +01:00
parent f5be7481fa
commit 3a5e748bc4
2 changed files with 7 additions and 5 deletions

View file

@ -14,10 +14,12 @@ const PaymentMethodItemBlock = ( {
<SettingsBlock className="ppcp-r-settings-block__payment-methods__item">
<div className="ppcp-r-settings-block__payment-methods__item__inner">
<div className="ppcp-r-settings-block__payment-methods__item__title-wrapper">
<PaymentMethodIcon
icons={ [ paymentMethod.icon ] }
type={ paymentMethod.icon }
/>
{ paymentMethod?.icon && (
<PaymentMethodIcon
icons={ [ paymentMethod.icon ] }
type={ paymentMethod.icon }
/>
) }
<span className="ppcp-r-settings-block__payment-methods__item__title">
{ paymentMethod.itemTitle }
</span>

View file

@ -576,7 +576,7 @@ class PaymentRestEndpoint extends RestEndpoint {
'OXXO is a Mexican chain of convenience stores. *Get PayPal account permission to use OXXO payment functionality by contacting us at (+52) 8009250304',
'woocommerce-paypal-payments'
),
'icon' => '',
'icon' => 'payment-method-oxxo',
'itemTitle' => __( 'OXXO', 'woocommerce-paypal-payments' ),
'itemDescription' => __(
'OXXO is a Mexican chain of convenience stores. *Get PayPal account permission to use OXXO payment functionality by contacting us at (+52) 8009250304',