github.com/emate/nomad@v0.8.2-wo-binpacking/ui/app/styles/core/table.scss (about)

     1  .table {
     2    color: $text;
     3    border-radius: $radius;
     4    border: 1px solid $grey-blue;
     5    border-collapse: separate;
     6    width: 100%;
     7  
     8    &.is-fixed {
     9      table-layout: fixed;
    10  
    11      td {
    12        text-overflow: ellipsis;
    13        overflow: hidden;
    14      }
    15    }
    16  
    17    &.with-foot {
    18      margin-bottom: 0;
    19      border-bottom-left-radius: 0;
    20      border-bottom-right-radius: 0;
    21  
    22      + .table-foot {
    23        margin-bottom: 1.5rem;
    24      }
    25    }
    26  
    27    &.is-compact {
    28      th,
    29      td {
    30        padding: 0.75em;
    31      }
    32    }
    33  
    34    &.is-darkened {
    35      tbody tr:not(.is-selected) {
    36        background-color: $white-bis;
    37  
    38        &:hover {
    39          background-color: $white-ter;
    40        }
    41      }
    42  
    43      &.is-striped {
    44        tbody tr:not(.is-selected) {
    45          &:nth-child(even) {
    46            background-color: $white-ter;
    47  
    48            &:hover {
    49              background-color: darken($white-ter, 5%);
    50            }
    51          }
    52        }
    53      }
    54    }
    55  
    56    th,
    57    td {
    58      padding: 0.75em 1.5em;
    59      border: none;
    60  
    61      &.is-three-quarters {
    62        width: 75%;
    63      }
    64  
    65      &.is-two-thirds {
    66        width: 66.66%;
    67      }
    68  
    69      &.is-half {
    70        width: 50%;
    71      }
    72  
    73      &.is-one-third {
    74        width: 33.33%;
    75      }
    76  
    77      &.is-one-quarter {
    78        width: 25%;
    79      }
    80  
    81      // Only use px modifiers when text needs to be truncated.
    82      // In this and only this scenario are percentages not effective.
    83      &.is-200px {
    84        width: 200px;
    85        max-width: 200px;
    86      }
    87  
    88      &.is-truncatable {
    89        overflow: hidden;
    90        text-overflow: ellipsis;
    91        white-space: nowrap;
    92      }
    93  
    94      @for $i from 1 through 11 {
    95        &.is-#{$i} {
    96          width: 100% / 12 * $i;
    97          max-width: 100% / 12 * $i;
    98        }
    99      }
   100  
   101      a {
   102        color: $blue;
   103        text-decoration: underline;
   104        font-weight: $weight-normal;
   105  
   106        &.is-primary {
   107          color: $text;
   108          text-decoration: none;
   109          font-weight: $weight-semibold;
   110        }
   111      }
   112    }
   113  
   114    thead {
   115      background: $white-ter;
   116      border: 1px solid $grey-blue;
   117  
   118      tr {
   119        &:hover {
   120          background-color: inherit;
   121        }
   122      }
   123  
   124      td,
   125      th {
   126        color: $grey-light;
   127        font-weight: $weight-normal;
   128        vertical-align: bottom;
   129        border-bottom: 1px solid $grey-blue;
   130  
   131        &.is-selectable {
   132          padding: 0;
   133  
   134          a {
   135            display: block;
   136            padding: 0.75em 1.5em;
   137            width: 100%;
   138            text-decoration: none;
   139  
   140            &:hover {
   141              background-color: darken($white-ter, 5%);
   142            }
   143          }
   144        }
   145  
   146        &.is-active {
   147          position: relative;
   148  
   149          &::after {
   150            content: '';
   151            width: 10px;
   152            right: 1.5em;
   153            top: 0.75em;
   154            bottom: 0.75em;
   155            position: absolute;
   156            display: block;
   157          }
   158  
   159          &.asc::after {
   160            content: '⬇';
   161          }
   162  
   163          &.desc::after {
   164            content: '⬆';
   165          }
   166        }
   167  
   168        a {
   169          color: $grey;
   170        }
   171      }
   172    }
   173  
   174    tbody {
   175      tr {
   176        &.is-interactive {
   177          cursor: pointer;
   178          box-sizing: border-box;
   179        }
   180  
   181        &.is-active {
   182          background: rgba($blue, 0.1);
   183  
   184          td:first-child {
   185            position: relative;
   186  
   187            &::after {
   188              position: absolute;
   189              content: '';
   190              width: 3px;
   191              top: 0;
   192              bottom: 0;
   193              left: -1px;
   194              display: block;
   195              background: $blue;
   196            }
   197          }
   198        }
   199      }
   200  
   201      td.is-subheading {
   202        font-weight: $weight-bold;
   203        background: $white;
   204        color: $blue;
   205      }
   206  
   207      td {
   208        border: 1px solid $grey-blue;
   209        border-width: 0 0 1px;
   210        padding: 1.25em 1.5em;
   211  
   212        &.is-one-line {
   213          white-space: nowrap;
   214        }
   215      }
   216    }
   217  
   218    .is-faded {
   219      color: $grey-light;
   220    }
   221  }
   222  
   223  .table tfoot,
   224  .table-foot {
   225    margin-top: -1px;
   226    background: $white-ter;
   227    border: 1px solid $grey-blue;
   228    border-bottom-right-radius: $radius;
   229    border-bottom-left-radius: $radius;
   230    overflow: hidden;
   231  
   232    .pagination {
   233      padding: 0;
   234      margin: 0;
   235    }
   236  }