You are here

tablesaw-responsive.css in Responsive Tables Filter 8

/*! Tablesaw - v3.1.2 - 2019-03-19
* https://github.com/filamentgroup/tablesaw
* Copyright (c) 2019 Filament Group; Licensed MIT */

/* Mobile first styles: Begin with the stacked presentation at narrow widths */

/* Support note IE9+: @media only all */

@media only all {
  /* Show the table cells as a block level element */

  .tablesaw-stack {
    clear: both;
  }

  .tablesaw-stack td,
  .tablesaw-stack th {
    text-align: left;
    display: block;
  }

  .tablesaw-stack tr {
    clear: both;
    display: table-row;
  }

  /* Make the label elements a percentage width */

  .tablesaw-stack td .tablesaw-cell-label,
  .tablesaw-stack th .tablesaw-cell-label {
    display: inline-block;
    padding: 0 .6em 0 0;
    width: 30%;
  }

  /* For grouped headers, have a different style to visually separate the levels by classing the first label in each col group */

  .tablesaw-stack th .tablesaw-cell-label-top,
  .tablesaw-stack td .tablesaw-cell-label-top {
    display: block;
    padding: .4em 0;
    margin: .4em 0;
  }

  .tablesaw-cell-label {
    display: block;
  }

  /* Avoid double strokes when stacked */

  .tablesaw-stack tbody th.group {
    margin-top: -1px;
  }

  /* Avoid double strokes when stacked */

  .tablesaw-stack th.group b.tablesaw-cell-label {
    display: none !important;
  }
}

@media (max-width: 39.9375em) {
  /* Table rows have a gray bottom stroke by default */

  .tablesaw-stack tbody tr {
    display: block;
    width: 100%;
    border-bottom: 1px solid #dfdfdf;
  }

  .tablesaw-stack thead td,
  .tablesaw-stack thead th {
    display: none;
  }

  .tablesaw-stack tbody td,
  .tablesaw-stack tbody th {
    display: block;
    float: left;
    clear: left;
    width: 100%;
  }

  .tablesaw-cell-label {
    vertical-align: top;
  }

  .tablesaw-cell-content {
    display: inline-block;
    max-width: 67%;
  }

  .tablesaw-stack .tablesaw-stack-block .tablesaw-cell-label,
  .tablesaw-stack .tablesaw-stack-block .tablesaw-cell-content {
    display: block;
    width: 100%;
    max-width: 100%;
    padding: 0;
  }

  .tablesaw-stack td:empty,
  .tablesaw-stack th:empty {
    display: none;
  }
}

/* Media query to show as a standard table at 560px (35em x 16px) or wider */

@media (min-width: 40em) {
  .tablesaw-stack tr {
    display: table-row;
  }

  /* Show the table header rows */

  .tablesaw-stack td,
  .tablesaw-stack th,
  .tablesaw-stack thead td,
  .tablesaw-stack thead th {
    display: table-cell;
    margin: 0;
  }

  /* Hide the labels in each cell */

  .tablesaw-stack td .tablesaw-cell-label,
  .tablesaw-stack th .tablesaw-cell-label {
    display: none !important;
  }
}

.tablesaw-fix-persist {
  table-layout: fixed;
}

/* Hide all prioritized columns by default */

@media only all {
  .tablesaw-columntoggle th.tablesaw-priority-6,
  .tablesaw-columntoggle td.tablesaw-priority-6,
  .tablesaw-columntoggle th.tablesaw-priority-5,
  .tablesaw-columntoggle td.tablesaw-priority-5,
  .tablesaw-columntoggle th.tablesaw-priority-4,
  .tablesaw-columntoggle td.tablesaw-priority-4,
  .tablesaw-columntoggle th.tablesaw-priority-3,
  .tablesaw-columntoggle td.tablesaw-priority-3,
  .tablesaw-columntoggle th.tablesaw-priority-2,
  .tablesaw-columntoggle td.tablesaw-priority-2,
  .tablesaw-columntoggle th.tablesaw-priority-1,
  .tablesaw-columntoggle td.tablesaw-priority-1,
  .tablesaw-columntoggle th.tablesaw-priority-0,
  .tablesaw-columntoggle td.tablesaw-priority-0 {
    display: none;
  }
}

/* Preset breakpoints if "" class added to table */

/* Show priority 1 at 320px (20em x 16px) */

@media (min-width: 20em) {
  .tablesaw-columntoggle th.tablesaw-priority-1,
  .tablesaw-columntoggle td.tablesaw-priority-1 {
    display: table-cell;
  }
}

/* Show priority 2 at 480px (30em x 16px) */

@media (min-width: 30em) {
  .tablesaw-columntoggle th.tablesaw-priority-2,
  .tablesaw-columntoggle td.tablesaw-priority-2 {
    display: table-cell;
  }
}

/* Show priority 3 at 640px (40em x 16px) */

@media (min-width: 40em) {
  .tablesaw-columntoggle th.tablesaw-priority-3,
  .tablesaw-columntoggle td.tablesaw-priority-3 {
    display: table-cell;
  }

  .tablesaw-columntoggle tbody td {
    line-height: 2;
  }
}

File

css/tablesaw-responsive.css
View source
  1. /*! Tablesaw - v3.1.2 - 2019-03-19
  2. * https://github.com/filamentgroup/tablesaw
  3. * Copyright (c) 2019 Filament Group; Licensed MIT */
  4. /* Mobile first styles: Begin with the stacked presentation at narrow widths */
  5. /* Support note IE9+: @media only all */
  6. @media only all {
  7. /* Show the table cells as a block level element */
  8. .tablesaw-stack {
  9. clear: both;
  10. }
  11. .tablesaw-stack td,
  12. .tablesaw-stack th {
  13. text-align: left;
  14. display: block;
  15. }
  16. .tablesaw-stack tr {
  17. clear: both;
  18. display: table-row;
  19. }
  20. /* Make the label elements a percentage width */
  21. .tablesaw-stack td .tablesaw-cell-label,
  22. .tablesaw-stack th .tablesaw-cell-label {
  23. display: inline-block;
  24. padding: 0 .6em 0 0;
  25. width: 30%;
  26. }
  27. /* For grouped headers, have a different style to visually separate the levels by classing the first label in each col group */
  28. .tablesaw-stack th .tablesaw-cell-label-top,
  29. .tablesaw-stack td .tablesaw-cell-label-top {
  30. display: block;
  31. padding: .4em 0;
  32. margin: .4em 0;
  33. }
  34. .tablesaw-cell-label {
  35. display: block;
  36. }
  37. /* Avoid double strokes when stacked */
  38. .tablesaw-stack tbody th.group {
  39. margin-top: -1px;
  40. }
  41. /* Avoid double strokes when stacked */
  42. .tablesaw-stack th.group b.tablesaw-cell-label {
  43. display: none !important;
  44. }
  45. }
  46. @media (max-width: 39.9375em) {
  47. /* Table rows have a gray bottom stroke by default */
  48. .tablesaw-stack tbody tr {
  49. display: block;
  50. width: 100%;
  51. border-bottom: 1px solid #dfdfdf;
  52. }
  53. .tablesaw-stack thead td,
  54. .tablesaw-stack thead th {
  55. display: none;
  56. }
  57. .tablesaw-stack tbody td,
  58. .tablesaw-stack tbody th {
  59. display: block;
  60. float: left;
  61. clear: left;
  62. width: 100%;
  63. }
  64. .tablesaw-cell-label {
  65. vertical-align: top;
  66. }
  67. .tablesaw-cell-content {
  68. display: inline-block;
  69. max-width: 67%;
  70. }
  71. .tablesaw-stack .tablesaw-stack-block .tablesaw-cell-label,
  72. .tablesaw-stack .tablesaw-stack-block .tablesaw-cell-content {
  73. display: block;
  74. width: 100%;
  75. max-width: 100%;
  76. padding: 0;
  77. }
  78. .tablesaw-stack td:empty,
  79. .tablesaw-stack th:empty {
  80. display: none;
  81. }
  82. }
  83. /* Media query to show as a standard table at 560px (35em x 16px) or wider */
  84. @media (min-width: 40em) {
  85. .tablesaw-stack tr {
  86. display: table-row;
  87. }
  88. /* Show the table header rows */
  89. .tablesaw-stack td,
  90. .tablesaw-stack th,
  91. .tablesaw-stack thead td,
  92. .tablesaw-stack thead th {
  93. display: table-cell;
  94. margin: 0;
  95. }
  96. /* Hide the labels in each cell */
  97. .tablesaw-stack td .tablesaw-cell-label,
  98. .tablesaw-stack th .tablesaw-cell-label {
  99. display: none !important;
  100. }
  101. }
  102. .tablesaw-fix-persist {
  103. table-layout: fixed;
  104. }
  105. /* Hide all prioritized columns by default */
  106. @media only all {
  107. .tablesaw-columntoggle th.tablesaw-priority-6,
  108. .tablesaw-columntoggle td.tablesaw-priority-6,
  109. .tablesaw-columntoggle th.tablesaw-priority-5,
  110. .tablesaw-columntoggle td.tablesaw-priority-5,
  111. .tablesaw-columntoggle th.tablesaw-priority-4,
  112. .tablesaw-columntoggle td.tablesaw-priority-4,
  113. .tablesaw-columntoggle th.tablesaw-priority-3,
  114. .tablesaw-columntoggle td.tablesaw-priority-3,
  115. .tablesaw-columntoggle th.tablesaw-priority-2,
  116. .tablesaw-columntoggle td.tablesaw-priority-2,
  117. .tablesaw-columntoggle th.tablesaw-priority-1,
  118. .tablesaw-columntoggle td.tablesaw-priority-1,
  119. .tablesaw-columntoggle th.tablesaw-priority-0,
  120. .tablesaw-columntoggle td.tablesaw-priority-0 {
  121. display: none;
  122. }
  123. }
  124. /* Preset breakpoints if "" class added to table */
  125. /* Show priority 1 at 320px (20em x 16px) */
  126. @media (min-width: 20em) {
  127. .tablesaw-columntoggle th.tablesaw-priority-1,
  128. .tablesaw-columntoggle td.tablesaw-priority-1 {
  129. display: table-cell;
  130. }
  131. }
  132. /* Show priority 2 at 480px (30em x 16px) */
  133. @media (min-width: 30em) {
  134. .tablesaw-columntoggle th.tablesaw-priority-2,
  135. .tablesaw-columntoggle td.tablesaw-priority-2 {
  136. display: table-cell;
  137. }
  138. }
  139. /* Show priority 3 at 640px (40em x 16px) */
  140. @media (min-width: 40em) {
  141. .tablesaw-columntoggle th.tablesaw-priority-3,
  142. .tablesaw-columntoggle td.tablesaw-priority-3 {
  143. display: table-cell;
  144. }
  145. .tablesaw-columntoggle tbody td {
  146. line-height: 2;
  147. }
  148. }