Site Editor: Load as full screen by default.

To avoid UI jumps when loading the page, the site-editor.php page
is marked as full screen by default. 
This also matches the behavior of the post editor.

See #54337.


git-svn-id: https://develop.svn.wordpress.org/trunk@52071 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Riad Benguella 2021-11-09 09:12:38 +00:00
parent cd2a9d78f2
commit dd9bca79bb

View File

@ -31,6 +31,14 @@ $parent_file = 'themes.php';
$current_screen = get_current_screen();
$current_screen->is_block_editor( true );
// Default to is-fullscreen-mode to avoid jumps in the UI.
add_filter(
'admin_body_class',
static function( $classes ) {
return "$classes is-fullscreen-mode";
}
);
$block_editor_context = new WP_Block_Editor_Context();
$active_global_styles_id = WP_Theme_JSON_Resolver::get_user_custom_post_type_id();