_table.scss 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  1. .table {
  2. color: $font-color;
  3. margin-bottom: 0;
  4. }
  5. table.dataTable thead tr {
  6. background: transparent;
  7. }
  8. .table th {
  9. padding: .9rem;
  10. text-transform: capitalize;
  11. font-size: .95rem!important;
  12. }
  13. table.dataTable thead th, table.dataTable thead td, table.dataTable tfoot th, table.dataTable tfoot td {
  14. font-size: .95rem!important;
  15. }
  16. // data-list-view 表格
  17. table.data-list-view.dataTable tbody tr, table.data-thumb-view.dataTable tbody tr {
  18. box-shadow: $shadow;
  19. }
  20. table.data-list-view.dataTable thead th:first-child, table.data-thumb-view.dataTable thead th:first-child {
  21. padding-left: 1rem;
  22. }
  23. table.data-list-view.dataTable thead th, table.data-thumb-view.dataTable thead th {
  24. padding: 0.714rem .51rem;
  25. }
  26. table.dataTable:not(.table-bordered) thead tr th {
  27. text-transform: uppercase;
  28. }
  29. table.dataTable {
  30. border: 0;
  31. }
  32. table.data-list-view.dataTable, table.data-thumb-view.dataTable {
  33. border-spacing: 0 .9rem;
  34. padding: 0;
  35. }
  36. table.data-list-view.dataTable tbody tr:hover, table.data-thumb-view.dataTable tbody tr:hover, .table-hover tbody tr:hover {
  37. transform: none;
  38. background: lighten($dark30, 1%);
  39. }
  40. .table td {
  41. padding: .55rem;
  42. height: 62px;
  43. line-height: 1.42857;
  44. }
  45. table.data-list-view.dataTable tbody td, table.data-thumb-view.dataTable tbody td {
  46. height: 46px;
  47. padding: .55rem;
  48. line-height: 1.42857;
  49. }
  50. .table tr td:first-child, .table tr th:first-child {
  51. padding-left: 1.4rem;
  52. }
  53. // 快捷搜索
  54. .data-list-view-header .table-responsive .top .dataTables_filter .form-control, .data-thumb-view-header .table-responsive .top .dataTables_filter .form-control {
  55. padding: 1.23rem 2.8rem !important;
  56. border-radius: 1.4rem;
  57. border: 0;
  58. box-shadow: $shadow;
  59. }
  60. .card-header.data-list-view-header .table-responsive .top .dataTables_filter .form-control {
  61. box-shadow: $shadow-100;
  62. }
  63. .data-list-view-header .table-responsive .top .dataTables_filter label:after, .data-thumb-view-header .table-responsive .top .dataTables_filter label:after {
  64. top: 0.58rem;
  65. font-size: 1rem;
  66. left: 1.2rem;
  67. }
  68. .quick-search-clear {
  69. margin-left:-1.45rem;
  70. position: relative;
  71. color: $white;
  72. }
  73. // 解决 rwd-table 下拉选框显示bug
  74. .table-responsive {
  75. border: 0!important;
  76. margin-bottom: 0!important;
  77. }
  78. .data-list-view-header .table-responsive {
  79. overflow: visible!important;
  80. padding-bottom: 0!important;
  81. }
  82. .sticky-table-header {
  83. z-index: 45!important;
  84. }
  85. // 解决 rwd-table 下拉选框显示bug
  86. table.table-bordered.dataTable:not(.complex-headers) tbody th, table.table-bordered.dataTable tbody td {
  87. border-bottom-width: 1px
  88. }
  89. table.table-bordered.dataTable th:not(.complex-headers), table.table-bordered.dataTable td {
  90. border-left-width: 1px;
  91. }
  92. table.table-bordered.dataTable th:last-child, table.table-bordered.dataTable th:last-child, table.table-bordered.dataTable td:last-child, table.table-bordered.dataTable td:last-child {
  93. border-right-width: 1px;
  94. }
  95. table.dataTable.complex-headers {
  96. border-color: #eee;
  97. }
  98. table.dataTable.complex-headers thead th, table.dataTable.complex-headers thead td, table.dataTable.complex-headers tfoot th, table.dataTable.complex-headers tfoot td {
  99. border-bottom: 1px solid #eee;
  100. border-right: 1px solid #eee;
  101. }
  102. .dataTable.table-bordered:not(.complex-headers) thead th {
  103. border-right: 1px solid darken($border-color, 3%);
  104. border-bottom: 1px solid darken($border-color, 3%);
  105. }
  106. .dataTable.table-bordered:not(.complex-headers) tr:first-child th {
  107. border-top: 1px solid darken($border-color, 3%);
  108. }
  109. .dataTable.table-bordered:not(.complex-headers) thead tr th:first-child {
  110. border-left: 1px solid darken($border-color, 3%);
  111. }