_tables.scss 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129
  1. table,
  2. tbody,
  3. thead {
  4. display: inline-block;
  5. width: 100%;
  6. }
  7. .gpm-details {
  8. width: 100%;
  9. @include flex(auto);
  10. }
  11. td {
  12. border: 0;
  13. }
  14. tr {
  15. @include transition(all 0.2s ease);
  16. @include display(flex);
  17. @include flex-wrap(wrap);
  18. th {
  19. display: block;
  20. @include flex(1);
  21. font-weight: bold;
  22. &:first-child {
  23. padding-left: $padding-default;
  24. }
  25. &:last-child {
  26. padding-right: $padding-default;
  27. }
  28. }
  29. td {
  30. display: block;
  31. @include flex(1);
  32. &.double {
  33. @include flex(2);
  34. }
  35. &.triple {
  36. @include flex(3);
  37. }
  38. &.quadruple {
  39. @include flex(4);
  40. }
  41. &.quintuple {
  42. @include flex(5);
  43. }
  44. &.sextuple {
  45. @include flex(6);
  46. }
  47. &.septuple {
  48. @include flex(7);
  49. }
  50. &.octuple {
  51. @include flex(8);
  52. }
  53. &.nontuple {
  54. @include flex(9);
  55. }
  56. &.dectuple {
  57. @include flex(10);
  58. }
  59. &:first-child {
  60. padding-left: $padding-default;
  61. @include breakpoint(mobile-only) {
  62. padding-left: 1rem;
  63. }
  64. }
  65. &:last-child, &.gpm-actions {
  66. padding-right: $padding-default;
  67. }
  68. &.gpm-actions {
  69. line-height: 1;
  70. text-align: right;
  71. position: relative;
  72. .gpm-details-expand {
  73. position: absolute;
  74. top: 12px;
  75. right: 12px;
  76. }
  77. }
  78. &.gpm-details {
  79. margin: 0;
  80. padding: 0;
  81. @include breakpoint(mobile-only){
  82. word-wrap: break-word;
  83. }
  84. > .table-wrapper {
  85. display: none;
  86. td {
  87. border-bottom: 0;
  88. }
  89. }
  90. tbody {
  91. width: 100%;
  92. }
  93. }
  94. }
  95. &:last-child {
  96. td {
  97. border-bottom: 0;
  98. }
  99. }
  100. }