我在CSS网格上做了一个三列网格,并与justify-content: space-between
对齐,但是项目的高度小于没有正当内容的高度。在其他浏览器中也可以。
是功能还是错误?我该怎么办?
use justify-content: space-between
without justify-content: space-between
配置:
.container {
display: grid;
grid-template-columns: repeat(3, 8em);
grid-template-rows: auto;
justify-content: space-between;
}
<div class="container">
<div class="items">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s.</div>
<div class="items">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s.</div>
<div class="items">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s.</div>
</div>