woocommerce-paypal-payments/modules/ppcp-local-alternative-payment-methods/resources/js/mybank-payment-method.js

19 lines
461 B
JavaScript
Raw Normal View History

2024-08-21 15:05:11 +02:00
import { registerPaymentMethod } from '@woocommerce/blocks-registry';
2024-08-21 15:47:23 +02:00
import { APM } from './apm-block';
2024-08-21 15:05:11 +02:00
const config = wc.wcSettings.getSetting( 'ppcp-mybank_data' );
registerPaymentMethod( {
name: config.id,
label: <div dangerouslySetInnerHTML={ { __html: config.title } } />,
2024-08-21 15:47:23 +02:00
content: <APM config={ config } />,
2024-08-21 15:05:11 +02:00
edit: <div></div>,
ariaLabel: config.title,
canMakePayment: () => {
return true;
},
supports: {
features: config.supports,
},
} );