首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何在两个表中对齐列宽?

如何在两个表中对齐列宽?
EN

Stack Overflow用户
提问于 2018-06-02 15:59:52
回答 1查看 265关注 0票数 0

我有两个表在语义上是不同的,所以它们应该分开,IMHO。然而,我想对齐他们的列。因此,我发现可以通过在表中设置w--classes来控制表中的列宽。这对于第二张桌子(这是我开始使用的第一张)很好。但是当我把第一张桌子加在上面的时候,亵渎者--不仅他们的列不对齐,甚至列宽的关系--似乎与w--values不相对应。

小提琴这里.

theadof table1:

代码语言:javascript
复制
<thead class="bg-secondary">
  <tr>
    <th class="w-8">Model Name</th>
    <th class="w-8">Y</th>
    <th class="w-15">S</th>
    <th class="w-15">R<sup>2</sup>(%)</th>
    <th class="w-15">R<sup>2</sup>-Adj (%)</th>
    <th class="w-39">&nbsp;</th>
  </tr>
</thead>

和table2:

代码语言:javascript
复制
<thead class="bg-secondary">
  <tr>
    <th class="w-8">Var</th>
    <th class="w-8">Include</th>
    <th class="w-15">Expression</th>
    <th class="w-15">Coefficient</th>
    <th class="w-15">StdErr</th>
    <th class="w-15">T</th>
    <th class="w-15">P</th>
    <th class="w-9">&nbsp;</th>
  </tr>
</thead>
EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2018-06-02 16:02:32

没有w-8w-15等.在第四节。

宽度调整类是w-25w-50w-75w-100w-auto

请参阅docs:http://getbootstrap.com/docs/4.1/utilities/sizing/

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/50658682

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档