godaddy-wordpress / wc-plugin-framework

The official SkyVerge WooCommerce plugin framework
Other
138 stars 42 forks source link

Update Express Payment buttons to match incoming WooCommerce standard #655

Closed peterwilsoncc closed 4 months ago

peterwilsoncc commented 6 months ago

As documented in https://github.com/woocommerce/woocommerce-gateway-payfast/issues/183 and https://github.com/Automattic/woocommerce-payments/pull/6985, WooCommerce is in the process of updating the design requirements for the addition of Express Payment buttons.

On product pages:

On cart pages:

For the cart pages, the buttons only need to be moved on the shortcode page. The block cart has sots for the placement of Express Pay buttons.

Backward compatibility

For third party extensions that combine adding buttons via their own code base and adding buttons via this framework, there will need to be a technique of managing backward compatibility to allow plugins to opt in to the new button placement.

This will avoid the situation in which a single extension adds some Express Payment options above the add/proceed buttons, and some Express Payment options below the add/proceed buttons.

This could either be achieved via a filter or a property and the relevant classes.

unfulvio-godaddy commented 6 months ago

hey @peterwilsoncc thanks for opening this issue

We are aware of the changes and we are in the process of adding support to Cart/Checkout blocks in our plugins starting from Payment Gateways. Release 5.12.0 shipped last week added support for gateways, to provide block registration and base classes for individual plugins to extend when adding support (we released Authorize.Net with support contextually), but we haven't implemented support for "express" gateways such as Apple Pay or Google Pay (including in Authorize.Net for the moment). We plan to, of course.

Right now plugins that implement the FW need to implement block support for express checkout need to add their own JS code so maybe you could implement the changes in your own plugin while additional support is provided at FW level. If you have any relevant code that you'd like to submit as PR please be welcome to raise one.

I'll get back to this issue once we have made any relevant updates.

Thank you and happy holidays

Fulvio