gpt4 book ai didi

html - 如何在选定字段之间添加水平线

转载 作者:行者123 更新时间:2023-11-28 17:26:38 25 4
gpt4 key购买 nike

如何在选择的字段之间添加水平线,如下所示:

enter image description here

请检查彼此之间的水平线:

enter image description here

最佳答案

试试这个

.line {
position: relative;
padding-left: 10px;
}
.line:first-child {
padding-left: 0;
}
.line select {
position: relative;
}
.line:before {
content: "";
display: block;
position: absolute;
top: 50%;
left: 0;
width: 100%;
height: 1px;
background: red;
}
<span class="line">
<select>
<option>lorem</option>
</select>
</span>
<span class="line">
<select>
<option>lorem</option>
</select>
</span>
<span class="line">
<select>
<option>lorem</option>
</select>
</span>

关于html - 如何在选定字段之间添加水平线,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39550558/

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