Skip to content

Commit

Permalink
Editor: Add is block theme setting to get_block_editor_settings().
Browse files Browse the repository at this point in the history
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:
* WordPress/gutenberg#46212

Props ellatrix, alexstine, costdev, dgwyer, glendaviesnz, scruffian.
Fixes #57549.
Built from https://develop.svn.wordpress.org/trunk@55147


git-svn-id: https://core.svn.wordpress.org/trunk@54680 1a063a9b-81f0-0310-95a4-ce76da25c4cd
  • Loading branch information
hellofromtonya committed Jan 26, 2023
1 parent 20a344b commit 94c9cc8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions wp-includes/block-editor.php
Original file line number Diff line number Diff line change
Expand Up @@ -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(
Expand Down
2 changes: 1 addition & 1 deletion wp-includes/version.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.2-alpha-55146';
$wp_version = '6.2-alpha-55147';

/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
Expand Down

0 comments on commit 94c9cc8

Please sign in to comment.