File size: 564 Bytes
1e92f2d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import { Button, Gridicon } from '@automattic/components';
import { useTranslate } from 'i18n-calypso';

import './style.scss';

type BackButtonProps = {
	onClick?: ( event?: React.MouseEvent< HTMLButtonElement > ) => void;
};

const BackButton = ( props: BackButtonProps ) => {
	const translate = useTranslate();
	return (
		<div className="back-button">
			<Button borderless compact { ...props }>
				<Gridicon icon="arrow-left" />
				<span className="back-button__label">{ translate( 'Back' ) }</span>
			</Button>
		</div>
	);
};

export default BackButton;