Add close button to introduction banner card.
This commit is contained in:
parent
b6eec1e1bf
commit
82db71c94f
|
@ -34,6 +34,13 @@
|
||||||
rgba( 196, 152, 217, 0.12 ) 77.75%
|
rgba( 196, 152, 217, 0.12 ) 77.75%
|
||||||
);
|
);
|
||||||
|
|
||||||
|
.woocommerce-marketing-introduction-banner-close-button {
|
||||||
|
position: absolute;
|
||||||
|
top: $gap-smaller;
|
||||||
|
right: $gap;
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
display: block;
|
display: block;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
|
|
@ -2,8 +2,14 @@
|
||||||
* External dependencies
|
* External dependencies
|
||||||
*/
|
*/
|
||||||
import { __ } from '@wordpress/i18n';
|
import { __ } from '@wordpress/i18n';
|
||||||
import { Card, Flex, FlexItem, FlexBlock } from '@wordpress/components';
|
import { Card, Flex, FlexItem, FlexBlock, Button } from '@wordpress/components';
|
||||||
import { Icon, trendingUp, megaphone } from '@wordpress/icons';
|
import {
|
||||||
|
Icon,
|
||||||
|
trendingUp,
|
||||||
|
megaphone,
|
||||||
|
closeSmall,
|
||||||
|
close,
|
||||||
|
} from '@wordpress/icons';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Internal dependencies
|
* Internal dependencies
|
||||||
|
@ -73,6 +79,15 @@ export const IntroductionBanner = () => {
|
||||||
</Flex>
|
</Flex>
|
||||||
</div>
|
</div>
|
||||||
<div className="woocommerce-marketing-introduction-banner-illustration">
|
<div className="woocommerce-marketing-introduction-banner-illustration">
|
||||||
|
<Button
|
||||||
|
isSmall
|
||||||
|
className="woocommerce-marketing-introduction-banner-close-button"
|
||||||
|
onClick={ () => {
|
||||||
|
// TODO: dismiss this banner and save it into wp_options.
|
||||||
|
} }
|
||||||
|
>
|
||||||
|
<Icon icon={ closeSmall } />
|
||||||
|
</Button>
|
||||||
<img
|
<img
|
||||||
src={ illustrationUrl }
|
src={ illustrationUrl }
|
||||||
alt={ __(
|
alt={ __(
|
||||||
|
|
Loading…
Reference in New Issue