mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-01-31 05:57:35 +00:00
Editor: Remove shadow support via direct attribute.
Shadow block support should always rely on the style attribute instead. Props madhudollu. Fixes #60377. git-svn-id: https://develop.svn.wordpress.org/trunk@57510 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
65be4cd635
commit
ef37e6bf82
@ -58,9 +58,8 @@ function wp_apply_shadow_support( $block_type, $block_attributes ) {
|
||||
|
||||
$shadow_block_styles = array();
|
||||
|
||||
$preset_shadow = array_key_exists( 'shadow', $block_attributes ) ? "var:preset|shadow|{$block_attributes['shadow']}" : null;
|
||||
$custom_shadow = isset( $block_attributes['style']['shadow'] ) ? $block_attributes['style']['shadow'] : null;
|
||||
$shadow_block_styles['shadow'] = $preset_shadow ? $preset_shadow : $custom_shadow;
|
||||
$custom_shadow = $block_attributes['style']['shadow'] ?? null;
|
||||
$shadow_block_styles['shadow'] = $custom_shadow;
|
||||
|
||||
$attributes = array();
|
||||
$styles = wp_style_engine_get_styles( $shadow_block_styles );
|
||||
|
||||
Loading…
Reference in New Issue
Block a user