woocommerce/plugins/woocommerce-blocks/assets/js/base/components
Thomas Roberts 6b8ef2773a Try move shipping related dat to a `@wordpress/data` store (https://github.com/woocommerce/woocommerce-blocks/pull/5896)
* Add address-related items to wc/store/cart data store

* Add useUpdateCustomerData hook

This allows us to have a single hook responsible for updating the customer information on the server.

* Add useUpdateCustomerData hook in Checkout block

* Remove shippingAsBilling from previousCustomerData ref type

* Add useShippingAsBillingCheckbox hook

* Remove checkbox handling from useCheckoutAddress

* Merge with woocommerce/woocommerce-blocks#5810 changes

* Move shipping as billing to checkout state context provider

* Subscribe to changes

* Cache customerDataToUpdate

* Combine customerDataType and customerDataContextType

* Fix notice context

* Clean up inline docs for push changes

* Add useShippingData hook

* Add shipping related selectors to cart store

* Update useShippingDataContext to useCustomerData hook

* Update uses of useShippingDataContext to get data from hook instead

* Remove rogue linebreak

* Re-add linebreak

* Re-add linebreak, remove shippingAsBilling

* Re-add linebreak

* Use useShippingData and useCustomerData instead of context

* Fix fromEntriesPolyfill to use number or undefined as an index option

* Convert derive-selected-shipping-rates to TS

* Add SelectShippingRateType

* Get needsShipping from new hook and not context

* Get address data from useCustomerData instead of useShippingDataContext

* Move selectedRates, selectShippingRate and isSelectingRate

* Remove items from ShippingDatacontext that are available in data stores

* Get shipping data from stores, not context in payment method interface

* Consider shipping rates to be loading if customer data is updating

* Get rates from useShippingData hook instead of context

* Fix incorrect TypeScript types and incorrectly named destructure

* Move useShippingData into shipping folder

* Update tests to mock useShippingData instead of context

* Remove empty string fallback from shipping phone

* Get types from Cart declaration instead of Picking them

Co-authored-by: Mike Jolley <mike.jolley@me.com>
2022-03-04 17:43:45 +00:00
..
block-error-boundary Prevent third party blocks from breaking the entire checkout/cart block (https://github.com/woocommerce/woocommerce-blocks/pull/5297) 2022-01-25 12:01:19 +00:00
button Fix/cart button focus hover states (https://github.com/woocommerce/woocommerce-blocks/pull/5712) 2022-02-09 18:32:05 +01:00
cart-checkout Try move shipping related dat to a `@wordpress/data` store (https://github.com/woocommerce/woocommerce-blocks/pull/5896) 2022-03-04 17:43:45 +00:00
checkbox-list More ts conversions (https://github.com/woocommerce/woocommerce-blocks/pull/5263) 2021-12-03 17:23:25 +00:00
chip Remove custom `Icon` component in favour of `@wordpress/icons` where possible (https://github.com/woocommerce/woocommerce-blocks/pull/5599) 2022-02-01 16:54:38 +00:00
combobox Storybook migration of `CountryInput` component (https://github.com/woocommerce/woocommerce-blocks/pull/5312) 2021-12-07 16:07:21 +01:00
country-input Storybook migration of `CountryInput` component (https://github.com/woocommerce/woocommerce-blocks/pull/5312) 2021-12-07 16:07:21 +01:00
drawer Mini Cart block: add footer (subtotal, cart & checkout buttons and payment method icons) (https://github.com/woocommerce/woocommerce-blocks/pull/4982) 2021-10-28 22:48:39 +07:00
dropdown-selector Attribute Filter block: Enable global style (https://github.com/woocommerce/woocommerce-blocks/pull/5557) 2022-02-02 18:41:39 +01:00
filter-element-label Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
filter-submit-button Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
form Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
formatted-monetary-amount Filter Products By Price block: don't allow to insert negative values on inputs (https://github.com/woocommerce/woocommerce-blocks/pull/5123) 2022-01-06 15:30:34 +01:00
label Export `Button` and `Label` from `wc-blocks-checkout` package (https://github.com/woocommerce/woocommerce-blocks/pull/4406) 2021-07-02 10:24:07 +01:00
load-more-button Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
loading-mask Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
noninteractive Fix: Mini Cart block button should be disabled in the editor (https://github.com/woocommerce/woocommerce-blocks/pull/5308) 2021-12-07 21:29:56 +07:00
pagination Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
price-slider Filter Products By Price block: don't allow to insert negative values on inputs (https://github.com/woocommerce/woocommerce-blocks/pull/5123) 2022-01-06 15:30:34 +01:00
product-list Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
product-name Storybook and TS migration of some cart checkout components (https://github.com/woocommerce/woocommerce-blocks/pull/5324) 2021-12-15 17:30:17 +01:00
product-price Migrate storybook entries of ProductPrice component (https://github.com/woocommerce/woocommerce-blocks/pull/5371) 2021-12-15 19:07:49 +01:00
quantity-selector Add minimum quantity, maximum quantity, and step (multiple_of) to the Cart Block and Store API (https://github.com/woocommerce/woocommerce-blocks/pull/5406) 2022-01-11 11:09:59 +00:00
radio-control Remove `useSelectShippingRate` hook and adjust how local state works for `PackageRates` (https://github.com/woocommerce/woocommerce-blocks/pull/5802) 2022-02-10 11:59:43 +00:00
radio-control-accordion Update Dependencies to Latest Versions supporting React 16x (https://github.com/woocommerce/woocommerce-blocks/pull/4532) 2021-08-05 10:26:00 +01:00
read-more Fix ReadMore component maxLines prop reactivity (https://github.com/woocommerce/woocommerce-blocks/pull/5673) 2022-01-31 13:56:19 +01:00
reviews Fix inconsistent HTML of rating section (https://github.com/woocommerce/woocommerce-blocks/pull/5552) 2022-01-14 18:32:28 +07:00
sidebar-layout Add custom className support to Checkout Inner Blocks (https://github.com/woocommerce/woocommerce-blocks/pull/4978) 2021-10-20 17:18:13 +01:00
sort-select Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00
spinner Loading animation (https://github.com/woocommerce/woocommerce-blocks/pull/5362) 2021-12-13 13:57:59 +00:00
state-input Validate state on options change (https://github.com/woocommerce/woocommerce-blocks/pull/4761) 2021-09-21 11:48:39 +01:00
summary Summary Product block: Add support for global style (https://github.com/woocommerce/woocommerce-blocks/pull/5524) 2022-01-12 16:31:25 +01:00
tabs Update Dependencies to Latest Versions supporting React 16x (https://github.com/woocommerce/woocommerce-blocks/pull/4532) 2021-08-05 10:26:00 +01:00
text-input Use text indent in input fields instead of padding (https://github.com/woocommerce/woocommerce-blocks/pull/5947) 2022-02-28 17:16:31 +00:00
textarea Fix checkbox and textarea styles in Twenty Twenty One when it has dark controls (https://github.com/woocommerce/woocommerce-blocks/pull/3450) 2020-11-23 15:20:31 -05:00
title Add word-break: break-word to components title (https://github.com/woocommerce/woocommerce-blocks/pull/4049) 2021-04-09 16:01:34 +01:00
README.md clarify intentions / purpose of different component folders in docs (https://github.com/woocommerce/woocommerce-blocks/pull/3025) 2020-08-27 08:15:16 +12:00
tsconfig.json Ts blocks (https://github.com/woocommerce/woocommerce-blocks/pull/5668) 2022-02-07 09:34:30 +00:00

README.md

WooCommerce Blocks - General Purpose Components

These are shared components used in WooCommerce blocks, and may be used in the store front end (shopper experience) as well as the editor or admin dashboard.

See Components & Storybook doc for more information.