gpt4 book ai didi

html - 结合装箱大小应用边框

转载 作者:行者123 更新时间:2023-11-28 07:53:29 27 4
gpt4 key购买 nike

是否可以减小边框顶部的宽度?我使用的是装箱尺寸,所以盒子是对齐的。我想要这样:

enter image description here

但是当我将 border-top 应用到 div 时,div 之间仍然有一个空间,但边框不在顶部。 enter image description here

有什么解决办法吗?

最佳答案

根据你的图片看到我做了这个例子。

.main-container{
width:998px;
height:auto;

}

.box{
width:200px;
height:200px;
border-top:2px solid #b40505;
float:left;
background:#fefbdf;
margin:5px;
}
<div class="main-container">
<div class="box"></div>
<div class="box"></div>
<div class="box"></div>

</div>

关于html - 结合装箱大小应用边框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30255946/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com