Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for __experimentalSkiSerialization to the shadow attribute #6279

Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/wp-includes/block-supports/shadow.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,10 @@ function wp_register_shadow_support( $block_type ) {
function wp_apply_shadow_support( $block_type, $block_attributes ) {
$has_shadow_support = block_has_support( $block_type, 'shadow', false );

if ( ! $has_shadow_support ) {
if (
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be good to add a since note to the docblock above; something like

@since 6.6.0 Return early if __experimentalSkipSerialization is true.

(it should be added just below @since 6.3.0)

! $has_shadow_support ||
wp_should_skip_block_supports_serialization( $block_type, 'shadow' )
) {
return array();
}

Expand Down
Loading