html - 在移动 View 中显示模糊的引导响应表

标签 html css twitter-bootstrap-3 laravel-5.7

我正在使用 Bootstrap 3.3.7。当我为表格使用“表格响应”类时,它在桌面 View 中显示清晰且正确,但在移动 View 中,它显示模糊文本。文字显示不清晰。

<div class="table-responsive">
  <table class="table"> 
    <tr>
        <th> Sr.No </th>
        <th> Company Name </th>
        <th> Contact No. </th>
        <th> Address </th>                                    
    </tr>
    <tr>
        <th> 1 </th>
        <th> ABC </th>
        <th> 1234567890 </th>
        <th> India </th>                                    
    </tr>       
    <tr>
        <th> 2 </th>
        <th> XYZ </th>
        <th> 0123456789 </th>
        <th> India </th>                                    
    </tr>                   
  </table>
</div>

我想要那个,它在移动设备中显示表格的清晰 View ,就像桌面 View 一样。

最佳答案

.table-responsive {
    min-height: .01%;
    overflow-x: auto;
    border: 0px !important;
}
<!DOCTYPE html>
<html>
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width">
  <title>JS Bin</title>
  <!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
</head>
<body>
<div class="container">
  <div class="row">
    <div class="col-md-12">
      <div class="table-responsive">
        <table class="table"> 
          <tr>
            <th> Sr.No </th>
            <th> Company Name </th>
            <th> Contact No. </th>
            <th> Address </th>                                    
          </tr>
          <tr>
            <th> 1 </th>
            <th> ABC </th>
            <th> 1234567890 </th>
            <th> India </th>                                    
          </tr>       
          <tr>
            <th> 2 </th>
            <th> XYZ </th>
            <th> 0123456789 </th>
            <th> India </th>                                    
          </tr>                   
        </table>
      </div>
    </div>
  </div>
</div>
</body>
</html>

我不确定它看起来模糊的确切原因,但是当我删除边框形式 .table-responsive 时它起作用了。

关于html - 在移动 View 中显示模糊的引导响应表,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57075026/

相关文章:

php - 用 PHP 读取 Yaml

javascript - 如果隐藏了 parent ,是否可以计算可见的 child ?

html - 使用 Bootstrap 设计注册页面

jquery - 将光标更改为 Bootstrap 图标上的指针有反馈输入

ruby-on-rails-4 - Bootstrap 导航栏折叠菜单不适用于 Turbolinks

html - 如何让这两个 div 水平对齐并保持表单组完整?

javascript - 为什么当我关闭导航时我的转换不起作用?

php - 启动另一个实体时除了 & 符号之外的 htmlspecialchars

javascript - 具有 CSS 动画和过渡效果的 Vue.js Todo 任务

html - 如何保持两张图像响应良好地相互重叠?