在Bootstrap 3,我可以随意应用和调整表格列中col-sm-xx的th标签thead.但是这在bootstrap 4中不起作用.如何在bootstrap 4中实现这样的功能?
<thead>
<th class="col-sm-3">3 columns wide</th>
<th class="col-sm-5">5 columns wide</th>
<th class="col-sm-4">4 columns wide</th>
</thead>
Run Code Online (Sandbox Code Playgroud)
查看codeply,前提是它的大小不正确,特别是如果向表中添加一些数据.看看它是如何运行的:
<div class="container" style="border: 1px solid black;">
<table class="table table-bordered">
<thead>
<tr class="row">
<th class="col-sm-3">3 columns wide</th>
<th class="col-sm-5">5 columns wide</th>
<th class="col-sm-4">4 columns wide</th>
</tr>
</thead>
<tbody>
<tr>
<td>123</td>
<td>456</td>
<td>789</td>
</tr>
</tbody>
</table>
</div>
Run Code Online (Sandbox Code Playgroud)