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

When the item has an image, it will collapse #9

Closed
ghost opened this issue Apr 11, 2021 · 2 comments
Closed

When the item has an image, it will collapse #9

ghost opened this issue Apr 11, 2021 · 2 comments

Comments

@ghost
Copy link

ghost commented Apr 11, 2021

When the image in the item is loaded slowly, the MiniMasonry will directly calculate the height of the current entity instead of the image, which leads to the inaccurate height of the container

Snipaste_2021-04-11_15-03-34

Effect link refresh more times

@Spope
Copy link
Owner

Spope commented Apr 13, 2021

Hi, thanks for filling this issue. I reproduce and will look if I can add a ResizeObserver to prevent this without interferring with the responsive behaviour.
Right now the best solution (practice) is to set height / width on img tag to avoid size change on image loading.

@ghost
Copy link
Author

ghost commented Apr 13, 2021

Hi, thanks for filling this issue. I reproduce and will look if I can add a ResizeObserver to prevent this without interferring with the responsive behaviour.
Right now the best solution (practice) is to set height / width on img tag to avoid size change on image loading.

Thank you for your reply, I think this feature is more difficult to implement, and the loading time of the image is variable. So I also set the height of each image container to avoid this problem.

@ghost ghost closed this as completed Apr 14, 2021
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant