This repository has been archived by the owner on Feb 23, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 219
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Convert shipping components to typescript (#4135)
* Add type defs for customer Taken from https://github.com/woocommerce/woocommerce-gutenberg-products-block/blob/194ecccf780afe16843a894bb2e988509a0746df/assets/js/type-defs/customer.ts * Convert ShippingCalculatorAddress to TypeScript * Convert ShippingCalculator to TypeScript * Convert ShippingLocation to TypeScript * Allow packageId to be a number or string in useSelectShippingRate(s) * Convert ShippingRatesControl to TypeScript * Convert ShippingOptionsStep to TypeScript * Allow package_id to be a string or number This is because of Subscriptions using strings for package IDs * Change to use CartShippingRateItemShippingRate instead of Rate * Add extra props to PackageProps type * Make ShippingAddress have the correct type * Use CartShippingRateItemShippingRate instead of Rate * Remove Rate type * Set return types to JSX.Element * Change type of props.renderOption in ShippingRatesControl * Remove customer type defs and relocate aliases to default-address-fields * Add EnteredAddress type * Import EnteredAddress from new location * Remove unnecessary eslint ignore * Remove unused variable * Remove confusing use of word Item in Shipping types * Remove confusing use of word Item in Shipping types
- Loading branch information
Showing
18 changed files
with
192 additions
and
159 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.