From 87a38efddc88930b28033de8e846a2b412954bec Mon Sep 17 00:00:00 2001 From: hellofromTonya Date: Tue, 11 Oct 2022 16:40:14 +0000 Subject: [PATCH] Editor: Fix version in WP_Theme_JSON_Resolver::get_block_data(). Introduced during the WP 6.1 alpha cycle, this commit fixes the version number from `1` to `2`. Follow-up to [54162]. Props oandregal. See #56467. Built from https://develop.svn.wordpress.org/trunk@54491 git-svn-id: http://core.svn.wordpress.org/trunk@54050 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/blocks/navigation-link.php | 2 +- wp-includes/blocks/navigation-submenu.php | 2 +- wp-includes/blocks/page-list.php | 2 +- wp-includes/blocks/search.php | 2 +- wp-includes/class-wp-theme-json-resolver.php | 2 +- wp-includes/version.php | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/wp-includes/blocks/navigation-link.php b/wp-includes/blocks/navigation-link.php index ba8f547b32..f32437b41a 100644 --- a/wp-includes/blocks/navigation-link.php +++ b/wp-includes/blocks/navigation-link.php @@ -100,7 +100,7 @@ function block_core_navigation_link_build_css_font_sizes( $context ) { // Add the custom font size inline style. $font_sizes['inline_styles'] = sprintf( 'font-size: %s;', - gutenberg_get_typography_font_size_value( + wp_get_typography_font_size_value( array( 'size' => $context['style']['typography']['fontSize'], ) diff --git a/wp-includes/blocks/navigation-submenu.php b/wp-includes/blocks/navigation-submenu.php index 40cfae52f1..0ad7ba1d65 100644 --- a/wp-includes/blocks/navigation-submenu.php +++ b/wp-includes/blocks/navigation-submenu.php @@ -100,7 +100,7 @@ function block_core_navigation_submenu_build_css_font_sizes( $context ) { // Add the custom font size inline style. $font_sizes['inline_styles'] = sprintf( 'font-size: %s;', - gutenberg_get_typography_font_size_value( + wp_get_typography_font_size_value( array( 'size' => $context['style']['typography']['fontSize'], ) diff --git a/wp-includes/blocks/page-list.php b/wp-includes/blocks/page-list.php index 9c7602fc40..5ef169fe13 100644 --- a/wp-includes/blocks/page-list.php +++ b/wp-includes/blocks/page-list.php @@ -121,7 +121,7 @@ function block_core_page_list_build_css_font_sizes( $context ) { // Add the custom font size inline style. $font_sizes['inline_styles'] = sprintf( 'font-size: %s;', - gutenberg_get_typography_font_size_value( + wp_get_typography_font_size_value( array( 'size' => $context['style']['typography']['fontSize'], ) diff --git a/wp-includes/blocks/search.php b/wp-includes/blocks/search.php index 851131a5fb..61b2cf2b06 100644 --- a/wp-includes/blocks/search.php +++ b/wp-includes/blocks/search.php @@ -444,7 +444,7 @@ function get_typography_styles_for_block_core_search( $attributes ) { if ( ! empty( $attributes['style']['typography']['fontSize'] ) ) { $typography_styles[] = sprintf( 'font-size: %s;', - gutenberg_get_typography_font_size_value( + wp_get_typography_font_size_value( array( 'size' => $attributes['style']['typography']['fontSize'], ) diff --git a/wp-includes/class-wp-theme-json-resolver.php b/wp-includes/class-wp-theme-json-resolver.php index e97c31a4f5..b1a0d5198d 100644 --- a/wp-includes/class-wp-theme-json-resolver.php +++ b/wp-includes/class-wp-theme-json-resolver.php @@ -272,7 +272,7 @@ class WP_Theme_JSON_Resolver { public static function get_block_data() { $registry = WP_Block_Type_Registry::get_instance(); $blocks = $registry->get_all_registered(); - $config = array( 'version' => 1 ); + $config = array( 'version' => 2 ); foreach ( $blocks as $block_name => $block_type ) { if ( isset( $block_type->supports['__experimentalStyle'] ) ) { $config['styles']['blocks'][ $block_name ] = static::remove_json_comments( $block_type->supports['__experimentalStyle'] ); diff --git a/wp-includes/version.php b/wp-includes/version.php index c6820c6f27..6df5fa8eda 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.1-beta3-54490'; +$wp_version = '6.1-beta3-54491'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.