Editor: Ensure that the block editor can be used on the page post type.

Additionally, add a notice for when you are editing the "latest posts" page.

Fixes #45537.

Props cameronjonesweb, swissspidy, hannahmalcolm, Fantasy1125, ArnaudBan, grantmkin, youknowriad, knutsp, SergeyBiryukov, audrasjb, whyisjake. 


git-svn-id: https://develop.svn.wordpress.org/trunk@51116 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Jake Spurlock
2021-06-08 22:37:34 +00:00
parent 5001efad74
commit 69d7762ad4
3 changed files with 21 additions and 5 deletions
+4
View File
@@ -313,6 +313,10 @@ $script = sprintf(
);
wp_add_inline_script( 'wp-edit-post', $script );
if ( (int) get_option( 'page_for_posts' ) === (int) $post->ID ) {
add_action( 'admin_enqueue_scripts', '_wp_block_editor_posts_page_notice' );
}
require_once ABSPATH . 'wp-admin/admin-header.php';
?>