woocommerce/plugins/woocommerce-blocks/assets/js
Raluca Stan 27600b3309 Update canMakePayment to receive cart as argument and make it react to changes in billingData. (https://github.com/woocommerce/woocommerce-blocks/pull/4776)
* Add 	cartCoupons to canMakePayment argument

* Add cart to the paymentMethodArgument and improve the dependencies for the effect calling refreshCanMakePayments

* Debounce refreshCanMakePayments

The initial approach was to debounce billingData and use this value as a dependency for the useEffect that runs refreshCanMakePayments.
But because the depencies array can always change we decided to debounce the callback instead, ensuring this way that callback is not called multiple times: for example when typing a field in the billing address. Debounced was chosen instead of throttle because we want to call refreshCanMakePayments once the change event has stopped, with the final value.

* Update types and docs related to canMakePaymentArgument

* Mock the /cart call when testing payment methods

* Remove unused cartCoupons key in canMakePaymentArguments' interface
2021-09-23 16:27:02 +01:00
..
atomic Update Checkout to Checkout i2 (https://github.com/woocommerce/woocommerce-blocks/pull/4745) 2021-09-16 13:16:21 +01:00
base Update canMakePayment to receive cart as argument and make it react to changes in billingData. (https://github.com/woocommerce/woocommerce-blocks/pull/4776) 2021-09-23 16:27:02 +01:00
blocks Update canMakePayment to receive cart as argument and make it react to changes in billingData. (https://github.com/woocommerce/woocommerce-blocks/pull/4776) 2021-09-23 16:27:02 +01:00
blocks-registry Add support for extensions to filter express payment methods (https://github.com/woocommerce/woocommerce-blocks/pull/4774) 2021-09-23 10:09:55 +01:00
data Open Mini Cart drawer when adding to cart from the All Products block (https://github.com/woocommerce/woocommerce-blocks/pull/4772) 2021-09-21 15:25:44 +02:00
editor-components Switch to external icon for shipping/payment methods (https://github.com/woocommerce/woocommerce-blocks/pull/4760) 2021-09-21 11:01:12 +01:00
extensions/google-analytics Add camelcase rule to eslint config (https://github.com/woocommerce/woocommerce-blocks/pull/4382) 2021-07-09 17:53:45 +01:00
filters Update minimum required WP version to 5.4 (https://github.com/woocommerce/woocommerce-blocks/pull/3537) 2020-12-10 15:39:04 +01:00
hocs Fix handpicked product selections when a store has over 100 products. (https://github.com/woocommerce/woocommerce-blocks/pull/4534) 2021-08-06 14:25:12 +01:00
icons Cart i2: Toolbar based view switcher (https://github.com/woocommerce/woocommerce-blocks/pull/4811) 2021-09-22 16:00:19 +01:00
legacy Update Dependencies to Latest Versions supporting React 16x (https://github.com/woocommerce/woocommerce-blocks/pull/4532) 2021-08-05 10:26:00 +01:00
middleware Move Block Type Settings into Block Type Classes (https://github.com/woocommerce/woocommerce-blocks/pull/4059) 2021-04-22 12:37:27 +01:00
payment-method-extensions/payment-methods Remove extra padding from payment methods with no description (https://github.com/woocommerce/woocommerce-blocks/pull/3952) 2021-03-12 15:40:09 +01:00
previews Implement memoization in several selectors and hooks (https://github.com/woocommerce/woocommerce-blocks/pull/4548) 2021-08-13 15:28:41 +02:00
settings Update checkout block registration API to consume Block Metadata (https://github.com/woocommerce/woocommerce-blocks/pull/4684) 2021-09-07 17:01:14 +01:00
shared ⚛️ Introduce Product Element Blocks (https://github.com/woocommerce/woocommerce-blocks/pull/2871) 2020-07-22 13:20:54 +01:00
types Update canMakePayment to receive cart as argument and make it react to changes in billingData. (https://github.com/woocommerce/woocommerce-blocks/pull/4776) 2021-09-23 16:27:02 +01:00
utils Remove dead files (https://github.com/woocommerce/woocommerce-blocks/pull/4471) 2021-07-19 10:22:32 +01:00
global.d.ts WIP - Checkout i2 Feature Branch Tracking (https://github.com/woocommerce/woocommerce-blocks/pull/4268) 2021-07-22 12:03:00 +01:00
index.js ⚛️ Introduce Product Element Blocks (https://github.com/woocommerce/woocommerce-blocks/pull/2871) 2020-07-22 13:20:54 +01:00