Skip to content
This repository has been archived by the owner on Feb 23, 2024. It is now read-only.

Commit

Permalink
Reference Mini Cart drawer preview dynamically (#9912)
Browse files Browse the repository at this point in the history
* Reference Mini Cart drawer preview dynamically

* Update assets/js/blocks/mini-cart/edit.tsx

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>

---------

Co-authored-by: Albert Juhé Lluveras <contact@albertjuhe.com>
  • Loading branch information
nielslange and Aljullu authored Jun 20, 2023
1 parent 4fd521e commit d7652f3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions assets/js/blocks/mini-cart/edit.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import { select } from '@wordpress/data';
import classNames from 'classnames';
import { cartOutline, bag, bagAlt } from '@woocommerce/icons';
import { Icon } from '@wordpress/icons';
import { WC_BLOCKS_IMAGE_URL } from '@woocommerce/block-settings';

/**
* Internal dependencies
Expand Down Expand Up @@ -237,8 +238,8 @@ const Edit = ( {
className="wc-block-editor-mini-cart__drawer-image"
src={
isRTL()
? '/wp-content/plugins/woocommerce-blocks/images/blocks/mini-cart/cart-drawer-rtl.svg'
: '/wp-content/plugins/woocommerce-blocks/images/blocks/mini-cart/cart-drawer.svg'
? `${ WC_BLOCKS_IMAGE_URL }blocks/mini-cart/cart-drawer-rtl.svg`
: `${ WC_BLOCKS_IMAGE_URL }blocks/mini-cart/cart-drawer.svg`
}
alt=""
/>
Expand Down

0 comments on commit d7652f3

Please sign in to comment.