2020-03-19 15:50:36 +00:00
|
|
|
/**
|
|
|
|
* External dependencies
|
|
|
|
*/
|
|
|
|
import { __ } from '@wordpress/i18n';
|
|
|
|
import { SHOP_URL } from '@woocommerce/block-settings';
|
2022-02-01 16:54:38 +00:00
|
|
|
import { cart } from '@woocommerce/icons';
|
|
|
|
import { Icon } from '@wordpress/icons';
|
2020-03-19 15:50:36 +00:00
|
|
|
|
2021-09-16 12:16:21 +00:00
|
|
|
/**
|
|
|
|
* Internal dependencies
|
|
|
|
*/
|
|
|
|
import './style.scss';
|
|
|
|
|
2020-03-19 15:50:36 +00:00
|
|
|
const EmptyCart = () => {
|
|
|
|
return (
|
|
|
|
<div className="wc-block-checkout-empty">
|
|
|
|
<Icon
|
|
|
|
className="wc-block-checkout-empty__image"
|
2022-02-01 16:54:38 +00:00
|
|
|
icon={ cart }
|
2020-03-19 15:50:36 +00:00
|
|
|
size={ 100 }
|
|
|
|
/>
|
|
|
|
<strong className="wc-block-checkout-empty__title">
|
2023-12-12 23:05:20 +00:00
|
|
|
{ __( 'Your cart is currently empty!', 'woocommerce' ) }
|
2020-03-19 15:50:36 +00:00
|
|
|
</strong>
|
|
|
|
<p className="wc-block-checkout-empty__description">
|
|
|
|
{ __(
|
|
|
|
"Checkout is not available whilst your cart is empty—please take a look through our store and come back when you're ready to place an order.",
|
2023-12-09 13:44:54 +00:00
|
|
|
'woocommerce'
|
2020-03-19 15:50:36 +00:00
|
|
|
) }
|
|
|
|
</p>
|
2021-02-17 15:17:54 +00:00
|
|
|
{ SHOP_URL && (
|
|
|
|
<span className="wp-block-button">
|
|
|
|
<a href={ SHOP_URL } className="wp-block-button__link">
|
2023-12-09 13:44:54 +00:00
|
|
|
{ __( 'Browse store', 'woocommerce' ) }
|
2021-02-17 15:17:54 +00:00
|
|
|
</a>
|
|
|
|
</span>
|
|
|
|
) }
|
2020-03-19 15:50:36 +00:00
|
|
|
</div>
|
|
|
|
);
|
|
|
|
};
|
|
|
|
|
|
|
|
export default EmptyCart;
|