+ { createInterpolateElement(
+ __( '
Add new post' ),
+ // eslint-disable-next-line jsx-a11y/anchor-has-content
+ { a:
}
+ ) }
+
+ );
+};
+
+export default CreateNewPostLink;
diff --git a/packages/block-library/src/query/hooks.js b/packages/block-library/src/query/hooks.js
deleted file mode 100644
index b2bb32a7be7b4..0000000000000
--- a/packages/block-library/src/query/hooks.js
+++ /dev/null
@@ -1,53 +0,0 @@
-/**
- * WordPress dependencies
- */
-import { __ } from '@wordpress/i18n';
-import { createInterpolateElement } from '@wordpress/element';
-import { addQueryArgs } from '@wordpress/url';
-import { createHigherOrderComponent } from '@wordpress/compose';
-import { InspectorControls } from '@wordpress/block-editor';
-
-const CreateNewPostLink = ( {
- attributes: { query: { postType } = {} } = {},
-} ) => {
- if ( ! postType ) return null;
- const newPostUrl = addQueryArgs( 'post-new.php', {
- post_type: postType,
- } );
- return (
-