50 lines
1.2 KiB
JavaScript
50 lines
1.2 KiB
JavaScript
/**
|
|
* External dependencies
|
|
*/
|
|
import { Button } from '@wordpress/components';
|
|
import { __ } from '@wordpress/i18n';
|
|
|
|
/**
|
|
* Internal dependencies
|
|
*/
|
|
import TimerImage from './timer.svg';
|
|
import { WC_ASSET_URL } from '../../utils/admin-settings';
|
|
|
|
const ShippingHeader = ( { task, goToTask } ) => {
|
|
return (
|
|
<div className="woocommerce-task-header__contents-container">
|
|
<img
|
|
alt={ __( 'Shipping illustration', 'woocommerce' ) }
|
|
src={
|
|
WC_ASSET_URL + 'images/task_list/shipping-illustration.png'
|
|
}
|
|
className="svg-background"
|
|
/>
|
|
<div className="woocommerce-task-header__contents">
|
|
<h1>
|
|
{ __( 'Set up shipping for your store', 'woocommerce' ) }
|
|
</h1>
|
|
<p>
|
|
{ __(
|
|
'Choose where and how you will ship your products, select shipping methods, and add fixed or calculated rates.',
|
|
'woocommerce'
|
|
) }
|
|
</p>
|
|
<Button
|
|
isSecondary={ task.isComplete }
|
|
isPrimary={ ! task.isComplete }
|
|
onClick={ goToTask }
|
|
>
|
|
{ __( 'Add shipping zones', 'woocommerce' ) }
|
|
</Button>
|
|
<p className="woocommerce-task-header__timer">
|
|
<img src={ TimerImage } alt="Timer" />{ ' ' }
|
|
<span>{ task.time }</span>
|
|
</p>
|
|
</div>
|
|
</div>
|
|
);
|
|
};
|
|
|
|
export default ShippingHeader;
|