wp core update 6.6

This commit is contained in:
Tony Volpe
2024-07-17 03:05:30 +00:00
parent 8f93917880
commit 4950d23a30
912 changed files with 103325 additions and 124480 deletions

View File

@@ -8,6 +8,8 @@
/**
* Renders the `core/post-featured-image` block on the server.
*
* @since 5.8.0
*
* @param array $attributes Block attributes.
* @param string $content Block default content.
* @param WP_Block $block Block instance.
@@ -48,6 +50,13 @@ function render_block_core_post_featured_image( $attributes, $content, $block )
if ( ! empty( $attributes['scale'] ) ) {
$extra_styles .= "object-fit:{$attributes['scale']};";
}
if ( ! empty( $attributes['style']['shadow'] ) ) {
$shadow_styles = wp_style_engine_get_styles( array( 'shadow' => $attributes['style']['shadow'] ) );
if ( ! empty( $shadow_styles['css'] ) ) {
$extra_styles .= $shadow_styles['css'];
}
}
if ( ! empty( $extra_styles ) ) {
$attr['style'] = empty( $attr['style'] ) ? $extra_styles : $attr['style'] . $extra_styles;
@@ -125,6 +134,8 @@ function render_block_core_post_featured_image( $attributes, $content, $block )
/**
* Generate markup for the HTML element that will be used for the overlay.
*
* @since 6.1.0
*
* @param array $attributes Block attributes.
*
* @return string HTML markup in string format.
@@ -191,6 +202,8 @@ function get_block_core_post_featured_image_overlay_element_markup( $attributes
* Generates class names and styles to apply the border support styles for
* the Post Featured Image block.
*
* @since 6.1.0
*
* @param array $attributes The block attributes.
* @return array The border-related classnames and styles for the block.
*/
@@ -241,6 +254,8 @@ function get_block_core_post_featured_image_border_attributes( $attributes ) {
/**
* Registers the `core/post-featured-image` block on the server.
*
* @since 5.8.0
*/
function register_block_core_post_featured_image() {
register_block_type_from_metadata(