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

Image may disappear when cropping inside a row/stack #68668

Open
3 of 6 tasks
stokesman opened this issue Jan 15, 2025 · 3 comments · May be fixed by #68666
Open
3 of 6 tasks

Image may disappear when cropping inside a row/stack #68668

stokesman opened this issue Jan 15, 2025 · 3 comments · May be fixed by #68666
Labels
[Block] Image Affects the Image Block [Type] Bug An existing feature does not function as intended

Comments

@stokesman
Copy link
Contributor

Description

When an Image block with no specified size is inside a Row or Stack and the image editing is engaged the image disappears.

Step-by-step reproduction instructions

  1. Insert a Row / Stack
  2. Insert an Image within the Row / Stack
  3. Select local media for the Image
  4. Press "Crop" from the block toolbar

Screenshots, screen recording, code snippet

image-disappears-when-edited-in-flex.mp4

Environment info

  • WP 6.7.1 / Gutenberg plugin trunk
  • Firefox / Chrome
  • MacOS

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

Please confirm which theme type you used for testing.

  • Block
  • Classic
  • Hybrid (e.g. classic with theme.json)
  • Not sure
@stokesman stokesman added [Type] Bug An existing feature does not function as intended [Block] Image Affects the Image Block labels Jan 15, 2025
@stokesman stokesman linked a pull request Jan 15, 2025 that will close this issue
@Infinite-Null
Copy link
Contributor

Hi @stokesman,
Thank you for bringing this up I was successfully able to reproduce the issue by following the steps provided.

Screencast:

Screen.Recording.2025-01-15.at.9.06.13.AM.mov

@himanshupathak95
Copy link
Contributor

Screen.Recording.2025-01-15.at.14.53.18.mov

I observed that after the image disappears after we hit "crop", the elements behave unusually and the image reappears after clicking outside suggesting that the intermediate state might be clearing out the dimensions of the image.

A similar issue was observed in the Media & Text block. Checkout #68609

@stokesman
Copy link
Contributor Author

Thank you for testing this @Infinite-Null and @himanshupathak95. If you would test #68666 for this issue and comment there whether it resolves it I’d appreciate that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Block] Image Affects the Image Block [Type] Bug An existing feature does not function as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants