【发布时间】:2021-02-08 09:12:14
【问题描述】:
这是我的代码:
<section style="background-color: red;">
<div>
<div class="row justify-content-center px-4 d-flex flex-column">
<div class="col-lg-4 text-center py-5 rounded" style="background: white">
<p>Let's work together!</p>
<a href="#" target="_blank" class="btn btn-primary mt-4" style="color: #3E7DC0; border-radius: 8px;">
<span style="font-weight: 900;"><mdicon name="whatsapp"/> Contact us now!</a><br>
</div>
<div class="down-triangle align-self-center p-0"></div>
</div>
<div class="col-lg-4">
<img src="image.png">
</div>
</div>
</section>
这是我的小三角形的 CSS
.down-triangle {
width: 0;
height: 0;
border-top: 40px solid transparent;
border-bottom: 40px solid transparent;
border-right:40px solid white;
border-radius: 4px;
transform: rotate(270deg);
}
我的问题是,如何删除这两个 div 之间的间距?我已经尝试过margin bottom 和padding bottom,但它不起作用。非常感谢。
【问题讨论】:
-
嗨,你能提供你的完整代码
-
@Themodmin 完成!
标签: html css bootstrap-4