为什么在 Bootstrap 5 中列不以相等的间距居中?下面是代码和小提琴链接。
https://jsfiddle.net/juantamad/1o59tsqw/3/
<section>
<div class="row text-center mb-5">
<div class="col">Letters</div>
</div>
<div class="row row-cols-1 row-cols-sm-2 row-cols-md-3 g-3 text-center container">
<div class="col">
<h2>A</h2>
<p>B</p>
<p><a class="btn btn-secondary" href="#" role="button">View details »</a></p>
</div>
<div class="col">
<h2>C</h2>
<p>D</p>
<p><a class="btn btn-secondary" href="#" role="button">View details »</a></p>
</div>
<div class="col">
<h2>E</h2>
<p>F</a></p>
<p><a class="btn btn-secondary" href="#" role="button">View details »</a></p>
</div>
<div class="col">
<h2>G</h2>
<p>H</p>
<p><a class="btn btn-secondary" href="#" role="button">View details »</a></p>
</div>
</div>