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

Aspect ratio overridden by featured image link #49017

Closed
djcowan opened this issue Mar 13, 2023 · 4 comments
Closed

Aspect ratio overridden by featured image link #49017

djcowan opened this issue Mar 13, 2023 · 4 comments
Labels
[Block] Post Featured Image Affects the Post Featured Image Block Needs Testing Needs further testing to be confirmed. [Type] Bug An existing feature does not function as intended

Comments

@djcowan
Copy link
Contributor

djcowan commented Mar 13, 2023

Description

Post featured Image aspect-ratio is ignored or overwritten if Post featured image link is enabled.

Step-by-step reproduction instructions

  1. Add a featured image to a post or page.
  2. add post-featured block
    2.1 enable "Link to page" block setting
    2.1. Select an aspect-ratio block setting
    2.3 update page
  3. View published page
    result aspect ratio ignored.
    .wp-block-post-featured-image a { display: block; }

Screenshots, screen recording, code snippet

Screen Shot 2023-03-13 at 2 31 58 pm

Screen Shot 2023-03-13 at 2 32 17 pm

Screen Shot 2023-03-13 at 2 32 40 pm

Screen Shot 2023-03-13 at 2 32 47 pm

Screen Shot 2023-03-13 at 2 18 45 pm

Screen Shot 2023-03-13 at 2 19 01 pm

Environment info

Wordpress 6.1
Gutenberg Version 15.3.1
Themes: Twenty Twenty-One: 1.7 && Twenty Twenty-Three: 1.0
refs #48079

Please confirm that you have searched existing issues in the repo.

Yes

Please confirm that you have tested with all plugins deactivated except Gutenberg.

Yes

@djcowan
Copy link
Contributor Author

djcowan commented Mar 13, 2023

IMHO The child element <a> should inherit an innerblock aspect-ratio property value
.wp-block-post-featured-image **a** { display: block; aspect-ratio: **inherit**; }

@carolinan
Copy link
Contributor

I am able to reproduce this with WP 6.1.1, Gutenberg 15.3.1
I am not able to reproduce it with WordPress 6.2 RC1, Gutenberg 15.3.1.

So I wonder if it could be considered solved?

@kathrynwp kathrynwp added [Type] Bug An existing feature does not function as intended [Block] Post Featured Image Affects the Post Featured Image Block labels Mar 13, 2023
@kathrynwp
Copy link

I was able to replicate with:

WP 6.2-RC1-55510
Twenty Twenty-Three
Gutenberg 15.3.1
No other active plugins

Noting that the bug is only present when "link to page" is toggled on:

Edit_Page_“Featured_Image”_‹_Test_Site_ABC_—_WordPress

As soon as it's toggled off, the selected aspect ratio is respected.

Editor

Edit_Page_“Featured_Image”_‹_Test_Site_ABC_—_WordPress

Front End

Featured_Image_–_Test_Site_ABC

@ndiego ndiego added the Needs Testing Needs further testing to be confirmed. label Mar 14, 2023
@ndiego
Copy link
Member

ndiego commented Mar 14, 2023

Thanks for reporting @djcowan. This issue has been fixed in #48495 and will be included in the next version of Gutenberg.

@ndiego ndiego closed this as completed Mar 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Post Featured Image Affects the Post Featured Image Block Needs Testing Needs further testing to be confirmed. [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

No branches or pull requests

4 participants