* buttons * view archive link block * revert font weight change * save draft title * revert * fix * specs * specs * spec * spec * for fcks sake * Change spec for unarchive/archive button from .find to .findByRole * fix help icon * improve a11y on close.jsx * bring back the focus * . * Update cypress/integration/seededFlows/publishingFlows/uploadImage.spec.js Co-authored-by: Suzanne Aitchison <suzanne@forem.com> * drop icons.jsx Co-authored-by: Nick Taylor <nick@dev.to> Co-authored-by: Suzanne Aitchison <suzanne@forem.com>
18 lines
440 B
JavaScript
18 lines
440 B
JavaScript
import { h } from 'preact';
|
|
import { ButtonNew as Button } from '@crayons';
|
|
import CloseIcon from '@images/x.svg';
|
|
|
|
export const Close = ({ displayModal = () => {} }) => {
|
|
return (
|
|
<div className="crayons-article-form__close">
|
|
<Button
|
|
icon={CloseIcon}
|
|
onClick={() => displayModal()}
|
|
title="Close the editor"
|
|
aria-label="Close the editor"
|
|
/>
|
|
</div>
|
|
);
|
|
};
|
|
|
|
Close.displayName = 'Close';
|