From c338d57273862779476dffe7da3fe34d407efdf7 Mon Sep 17 00:00:00 2001 From: gziolo Date: Thu, 26 Sep 2024 12:47:16 +0000 Subject: [PATCH] Editor: Default attribute value not used with `get_block_wrapper_attributes` Ensures that the default values defined in the schema for block attributes are used when rendering the output of the block with `get_block_wrapper_attributes` helper. Props gziolo, jonsurrell, youknowriad, ryelle. Fixes #62114. Built from https://develop.svn.wordpress.org/trunk@59093 git-svn-id: http://core.svn.wordpress.org/trunk@58489 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/class-wp-block-supports.php | 2 +- wp-includes/version.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/class-wp-block-supports.php b/wp-includes/class-wp-block-supports.php index c90b5e0c54..71d6b49691 100644 --- a/wp-includes/class-wp-block-supports.php +++ b/wp-includes/class-wp-block-supports.php @@ -104,7 +104,7 @@ class WP_Block_Supports { } $block_attributes = array_key_exists( 'attrs', self::$block_to_render ) && is_array( self::$block_to_render['attrs'] ) - ? self::$block_to_render['attrs'] + ? $block_type->prepare_attributes_for_render( self::$block_to_render['attrs'] ) : array(); $output = array(); diff --git a/wp-includes/version.php b/wp-includes/version.php index 97d30daf0c..d185467ccc 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.7-alpha-59092'; +$wp_version = '6.7-alpha-59093'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.