How to avoid gaps using Isotope with Masonry layout [closed]

强颜欢笑 提交于 2019-12-31 02:56:08

问题


How can I fix the gap caused by the element sliding to the next row like in the image below?

I'm using Isotope with the masonry layout mode.

Thank you.


回答1:


I have a similar problem and I'm going to "fix" that by precalculating the order of the elements that way, that there will be no spaces and the boxes will always fit in the grid layout. AFAIK there is no solution by this isotope jQuery plugin for that.




回答2:


At a guess I'd say -

Because the next item in the order is that big block underneath.

Or the following item is the other smaller block bottom left. Even if that was moved up to occupy the white space there would still be a white gap left where it came from.

Maybe masonry favours left edge over right or something. Literally only started using it today so I'm no expert. Found this question while searching for an answer of my own.



来源:https://stackoverflow.com/questions/10738542/how-to-avoid-gaps-using-isotope-with-masonry-layout

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!