2021-09-21 10:47:20 +00:00
|
|
|
/**
|
|
|
|
* External dependencies
|
|
|
|
*/
|
|
|
|
import { useBlockProps } from '@wordpress/block-editor';
|
2021-11-26 14:47:37 +00:00
|
|
|
import Noninteractive from '@woocommerce/base-components/noninteractive';
|
2021-09-21 10:47:20 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Internal dependencies
|
|
|
|
*/
|
|
|
|
import Block from './block';
|
|
|
|
|
2021-10-25 15:31:22 +00:00
|
|
|
export const Edit = ( {
|
|
|
|
attributes,
|
|
|
|
}: {
|
|
|
|
attributes: { className: string };
|
|
|
|
} ): JSX.Element => {
|
|
|
|
const { className } = attributes;
|
2021-09-24 13:44:05 +00:00
|
|
|
const blockProps = useBlockProps();
|
2021-09-21 10:47:20 +00:00
|
|
|
|
|
|
|
return (
|
|
|
|
<div { ...blockProps }>
|
2021-11-26 14:47:37 +00:00
|
|
|
<Noninteractive>
|
2021-10-25 15:31:22 +00:00
|
|
|
<Block className={ className } />
|
2021-11-26 14:47:37 +00:00
|
|
|
</Noninteractive>
|
2021-09-21 10:47:20 +00:00
|
|
|
</div>
|
|
|
|
);
|
|
|
|
};
|
|
|
|
|
|
|
|
export const Save = (): JSX.Element => {
|
|
|
|
return <div { ...useBlockProps.save() } />;
|
|
|
|
};
|