小编zDo*_*oes的帖子

Bootstrap 4截断移动设备中表格内的长文本

我正在创建一个响应表,以便在台式机和移动设备中都使用它。
问题在于,当表加载长文本时,它会被截断,从而破坏了“响应式”的概念。
我仅在移动平台上遇到了此问题,因此这是该问题的屏幕截图(如果可以帮助...):
在此处输入图片说明

解决此问题的最佳方法是什么?我尝试了许多其他教程,但不幸的是,没有人工作过。

-编辑-表格的HTML:

<table class="table table-hover table-dark">
<thead>
  <tr>
    <th scope="col">Name</th>
    <th scope="col">Email</th>
    <th scope="col">Password</th>
  </tr>
</thead>
<tbody>
  {{#each users}}
  <tr>
    <th scope="row">{{name}}</th>
    <td class="text"><span>{{email}}</span></td>
    <td class="text"><span>{{password}}</span></td>
  </tr>
  {{/each}}
</tbody>
Run Code Online (Sandbox Code Playgroud)

我没有任何自定义css,除了背景颜色的那个。

html5 css3 responsive-design twitter-bootstrap bootstrap-4

1
推荐指数
1
解决办法
7434
查看次数