mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-21 22:15:28 +00:00
Blocks: Add missing apiVersion field when preparing server-registered blocks for the block editor
When working on changes to @wordpress/create-block tool (https://github.com/WordPress/gutenberg/pull/28883) to use register_block_type_from_metadata with block.json file in the templates for scaffolded blocks I run into this issue where apiVersion wasn't exposed from the server. Fixes #52512. Built from https://develop.svn.wordpress.org/trunk@50297 git-svn-id: http://core.svn.wordpress.org/trunk@49942 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
463df820f8
commit
135a35fd04
@ -2240,18 +2240,19 @@ function get_block_editor_server_block_settings() {
|
||||
$block_registry = WP_Block_Type_Registry::get_instance();
|
||||
$blocks = array();
|
||||
$fields_to_pick = array(
|
||||
'api_version' => 'apiVersion',
|
||||
'title' => 'title',
|
||||
'description' => 'description',
|
||||
'icon' => 'icon',
|
||||
'category' => 'category',
|
||||
'keywords' => 'keywords',
|
||||
'parent' => 'parent',
|
||||
'supports' => 'supports',
|
||||
'attributes' => 'attributes',
|
||||
'provides_context' => 'providesContext',
|
||||
'uses_context' => 'usesContext',
|
||||
'supports' => 'supports',
|
||||
'category' => 'category',
|
||||
'styles' => 'styles',
|
||||
'textdomain' => 'textdomain',
|
||||
'parent' => 'parent',
|
||||
'keywords' => 'keywords',
|
||||
'example' => 'example',
|
||||
);
|
||||
|
||||
|
@ -13,7 +13,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '5.7-beta2-50295';
|
||||
$wp_version = '5.7-beta2-50297';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
Loading…
x
Reference in New Issue
Block a user