Make WordPress Core

Opened 17 months ago

Last modified 16 months ago

#58261 new defect (bug)

set_post_thumbnail_size interferes with "Cover Image Block"

Reported by: richwp-felix's profile RichWP - Felix Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version: 6.2
Component: Media Keywords: close
Focuses: Cc:

Description

adding a post thumbnail size on the theme level interferes with the Cover Image Block which will use the "new thumbnail" as its image, resulting in blurry image displays:

add_theme_support( 'post-thumbnails' );
set_post_thumbnail_size( xxx, 9999 );

Change History (3)

#1 @joedolson
17 months ago

  • Keywords close added

In my testing, this is only true if you choose the option to use the featured image for the cover block. If you select an image from the media library (including selecting your featured image), it'll use it as specified.

I'd argue that this is the expected behavior. The featured image refers to a specific image and size, so if you're setting a cover block image by reference to the featured image, you should expect to use that exact image. If you want a different version of the image, you should choose it from the library.

I'm recommending this for close, but if you can confirm that this only happens for you when you choose to use the featured image option in the cover block, that would be appreciated.

#2 @RichWP - Felix
17 months ago

Thanx for your reply and consideration.

A "small" thumbnail image size of the featured image never makes if the image can appear in a large size context and the an src-set should be implemented instead. At least that would be the expected behaviour from the pre-gutenberg era: see <?php the_post_thumbnail(); ?>

The current implementation would not allow the use of the cover block in single post / page templates (theme building) where a cover image would be displayed in the post header. It will only work when within the editable content area of a post or page and the featured image can be switched manually.

Last edited 17 months ago by RichWP - Felix (previous) (diff)

#3 @RichWP - Felix
16 months ago

Any news on this?

Note: See TracTickets for help on using tickets.