Editor: Add is block theme setting to get_block_editor_settings().

The block editor's iframe needs to know if the theme is a block theme. This changeset adds a setting to `get_block_editor_settings()`.

Reference:
* https://github.com/WordPress/gutenberg/pull/46212

Props ellatrix, alexstine, costdev, dgwyer, glendaviesnz, scruffian.
Fixes #57549.

git-svn-id: https://develop.svn.wordpress.org/trunk@55147 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Tonya Mork 2023-01-26 19:59:16 +00:00
parent 1df9b8acf4
commit e2b5177e7c

View File

@ -495,6 +495,7 @@ function get_block_editor_settings( array $custom_settings, $block_editor_contex
}
$editor_settings['__unstableResolvedAssets'] = _wp_get_iframed_editor_assets();
$editor_settings['__unstableIsBlockBasedTheme'] = wp_is_block_theme();
$editor_settings['localAutosaveInterval'] = 15;
$editor_settings['disableLayoutStyles'] = current_theme_supports( 'disable-layout-styles' );
$editor_settings['__experimentalDiscussionSettings'] = array(