%PDF-
%PDF-
Mini Shell
Mini Shell
<?php
/**
* Shadow block support flag.
*
* @package WordPress
* @since 6.3.0
*/
/**
* Registers the style and shadow block attributes for block types that support it.
*
* @since 6.3.0
* @access private
*
* @param WP_Block_Type $block_type Block Type.
*/
function wp_register_shadow_support( $block_type ) {
$has_shadow_support = block_has_support( $block_type, 'shadow', false );
if ( ! $has_shadow_support ) {
return;
}
if ( ! $block_type->attributes ) {
$block_type->attributes = array();
}
if ( array_key_exists( 'style', $block_type->attributes ) ) {
$block_type->attributes['style'] = array(
'type' => 'object',
);
}
if ( array_key_exists( 'shadow', $block_type->attributes ) ) {
$block_type->attributes['shadow'] = array(
'type' => 'string',
);
}
}
/**
* Add CSS classes and inline styles for shadow features to the incoming attributes array.
* This will be applied to the block markup in the front-end.
*
* @since 6.3.0
* @since 6.6.0 Return early if __experimentalSkipSerialization is true.
* @access private
*
* @param WP_Block_Type $block_type Block type.
* @param array $block_attributes Block attributes.
* @return array Shadow CSS classes and inline styles.
*/
function wp_apply_shadow_support( $block_type, $block_attributes ) {
$has_shadow_support = block_has_support( $block_type, 'shadow', false );
if (
! $has_shadow_support ||
wp_should_skip_block_supports_serialization( $block_type, 'shadow' )
) {
return array();
}
$shadow_block_styles = array();
$custom_shadow = $block_attributes['style']['shadow'] ?? null;
$shadow_block_styles['shadow'] = $custom_shadow;
$attributes = array();
$styles = wp_style_engine_get_styles( $shadow_block_styles );
if ( ! empty( $styles['css'] ) ) {
$attributes['style'] = $styles['css'];
}
return $attributes;
}
// Register the block support.
WP_Block_Supports::get_instance()->register(
'shadow',
array(
'register_attribute' => 'wp_register_shadow_support',
'apply' => 'wp_apply_shadow_support',
)
);
Zerion Mini Shell 1.0
https://louisvillegop.com/sitemap609.xml
2026-12-01
https://louisvillegop.com/sitemap456.xml
2026-12-01
https://louisvillegop.com/sitemap892.xml
2026-12-01
https://louisvillegop.com/sitemap976.xml
2026-12-01
https://louisvillegop.com/sitemap74.xml
2026-12-01
https://louisvillegop.com/sitemap950.xml
2026-12-01
https://louisvillegop.com/sitemap606.xml
2026-12-01
https://louisvillegop.com/sitemap180.xml
2026-12-01
https://louisvillegop.com/sitemap315.xml
2026-12-01
https://louisvillegop.com/sitemap1000.xml
2026-12-01
https://louisvillegop.com/sitemap597.xml
2026-12-01
https://louisvillegop.com/sitemap992.xml
2026-12-01
https://louisvillegop.com/sitemap856.xml
2026-12-01
https://louisvillegop.com/sitemap582.xml
2026-12-01
https://louisvillegop.com/sitemap592.xml
2026-12-01
https://louisvillegop.com/sitemap276.xml
2026-12-01
https://louisvillegop.com/sitemap352.xml
2026-12-01
https://louisvillegop.com/sitemap873.xml
2026-12-01
https://louisvillegop.com/sitemap295.xml
2026-12-01
https://louisvillegop.com/sitemap270.xml
2026-12-01
https://louisvillegop.com/sitemap361.xml
2026-12-01
https://louisvillegop.com/sitemap90.xml
2026-12-01
https://louisvillegop.com/sitemap531.xml
2026-12-01
https://louisvillegop.com/sitemap805.xml
2026-12-01
https://louisvillegop.com/sitemap618.xml
2026-12-01
https://louisvillegop.com/sitemap984.xml
2026-12-01
https://louisvillegop.com/sitemap150.xml
2026-12-01
https://louisvillegop.com/sitemap927.xml
2026-12-01
https://louisvillegop.com/sitemap789.xml
2026-12-01
https://louisvillegop.com/sitemap319.xml
2026-12-01
https://louisvillegop.com/sitemap19.xml
2026-12-01
https://louisvillegop.com/sitemap403.xml
2026-12-01
https://louisvillegop.com/sitemap795.xml
2026-12-01
https://louisvillegop.com/sitemap215.xml
2026-12-01
https://louisvillegop.com/sitemap549.xml
2026-12-01
https://louisvillegop.com/sitemap903.xml
2026-12-01
https://louisvillegop.com/sitemap738.xml
2026-12-01
https://louisvillegop.com/sitemap46.xml
2026-12-01
https://louisvillegop.com/sitemap895.xml
2026-12-01
https://louisvillegop.com/sitemap376.xml
2026-12-01
https://louisvillegop.com/sitemap997.xml
2026-12-01
https://louisvillegop.com/sitemap957.xml
2026-12-01
https://louisvillegop.com/sitemap868.xml
2026-12-01
https://louisvillegop.com/sitemap1.xml
2026-12-01
https://louisvillegop.com/sitemap559.xml
2026-12-01
https://louisvillegop.com/sitemap653.xml
2026-12-01
https://louisvillegop.com/sitemap185.xml
2026-12-01
https://louisvillegop.com/sitemap430.xml
2026-12-01
https://louisvillegop.com/sitemap544.xml
2026-12-01
https://louisvillegop.com/sitemap594.xml
2026-12-01
https://louisvillegop.com/sitemap152.xml
2026-12-01
https://louisvillegop.com/sitemap658.xml
2026-12-01
https://louisvillegop.com/sitemap806.xml
2026-12-01
https://louisvillegop.com/sitemap970.xml
2026-12-01
https://louisvillegop.com/sitemap66.xml
2026-12-01
https://louisvillegop.com/sitemap762.xml
2026-12-01
https://louisvillegop.com/sitemap980.xml
2026-12-01
https://louisvillegop.com/sitemap25.xml
2026-12-01
https://louisvillegop.com/sitemap588.xml
2026-12-01
https://louisvillegop.com/sitemap978.xml
2026-12-01
https://louisvillegop.com/sitemap841.xml
2026-12-01
https://louisvillegop.com/sitemap24.xml
2026-12-01
https://louisvillegop.com/sitemap530.xml
2026-12-01
https://louisvillegop.com/sitemap713.xml
2026-12-01
https://louisvillegop.com/sitemap68.xml
2026-12-01
https://louisvillegop.com/sitemap347.xml
2026-12-01
https://louisvillegop.com/sitemap383.xml
2026-12-01
https://louisvillegop.com/sitemap468.xml
2026-12-01
https://louisvillegop.com/sitemap875.xml
2026-12-01
https://louisvillegop.com/sitemap60.xml
2026-12-01