diff --git a/plugins/woocommerce-blocks/assets/js/base/components/cart-checkout/shipping-rates-control/index.tsx b/plugins/woocommerce-blocks/assets/js/base/components/cart-checkout/shipping-rates-control/index.tsx index f8c1bb001eb..d6ba746a8e0 100644 --- a/plugins/woocommerce-blocks/assets/js/base/components/cart-checkout/shipping-rates-control/index.tsx +++ b/plugins/woocommerce-blocks/assets/js/base/components/cart-checkout/shipping-rates-control/index.tsx @@ -10,7 +10,7 @@ import { getShippingRatesPackageCount, getShippingRatesRateCount, } from '@woocommerce/base-utils'; -import { useStoreCart, useEditorContext } from '@woocommerce/base-context'; +import { useStoreCart } from '@woocommerce/base-context'; import { CartResponseShippingRate } from '@woocommerce/types'; import { ReactElement } from 'react'; @@ -166,8 +166,6 @@ const ShippingRatesControl = ( { }, context, }; - const { isEditor } = useEditorContext(); - return ( - { isEditor ? ( + + - ) : ( - <> - - - - - - ) } + ); }; diff --git a/plugins/woocommerce-blocks/assets/js/blocks/cart/edit.js b/plugins/woocommerce-blocks/assets/js/blocks/cart/edit.js index 7d70a0805d2..fceba16508d 100644 --- a/plugins/woocommerce-blocks/assets/js/blocks/cart/edit.js +++ b/plugins/woocommerce-blocks/assets/js/blocks/cart/edit.js @@ -12,6 +12,7 @@ import { import BlockErrorBoundary from '@woocommerce/base-components/block-error-boundary'; import { EditorProvider, CartProvider } from '@woocommerce/base-context'; import { previewCart } from '@woocommerce/resource-previews'; +import { SlotFillProvider } from '@woocommerce/blocks-checkout'; /** * Internal dependencies @@ -86,13 +87,15 @@ export const Edit = ( { className, attributes, setAttributes, clientId } ) => { hasDarkControls, } } > - - - + + + + + diff --git a/plugins/woocommerce-blocks/assets/js/blocks/checkout/edit.tsx b/plugins/woocommerce-blocks/assets/js/blocks/checkout/edit.tsx index d61bce1714d..0dfe422e172 100644 --- a/plugins/woocommerce-blocks/assets/js/blocks/checkout/edit.tsx +++ b/plugins/woocommerce-blocks/assets/js/blocks/checkout/edit.tsx @@ -19,6 +19,7 @@ import { ToggleControl, CheckboxControl, } from '@wordpress/components'; +import { SlotFillProvider } from '@woocommerce/blocks-checkout'; import type { TemplateArray } from '@wordpress/blocks'; import { CartCheckoutFeedbackPrompt } from '@woocommerce/editor-components/feedback-prompt'; @@ -147,38 +148,40 @@ export const Edit = ( { - - - + + - - - - - - + + + + + + + );