github.com/anuvu/nomad@v0.8.7-atom1/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      &.is-truncatable {
    82        overflow: hidden;
    83        text-overflow: ellipsis;
    84        white-space: nowrap;
    85      }
    86  
    87      &.is-narrow {
    88        padding: 1.25em 0 1.25em 0.5em;
    89  
    90        & + th,
    91        & + td {
    92          padding-left: 0.5em;
    93        }
    94      }
    95  
    96      // Only use px modifiers when text needs to be truncated.
    97      // In this and only this scenario are percentages not effective.
    98      &.is-200px {
    99        width: 200px;
   100        max-width: 200px;
   101      }
   102  
   103      @for $i from 1 through 11 {
   104        &.is-#{$i} {
   105          width: 100% / 12 * $i;
   106          max-width: 100% / 12 * $i;
   107        }
   108      }
   109  
   110      a {
   111        color: $blue;
   112        text-decoration: underline;
   113        font-weight: $weight-normal;
   114  
   115        &.is-primary {
   116          color: $text;
   117          text-decoration: none;
   118          font-weight: $weight-semibold;
   119        }
   120      }
   121    }
   122  
   123    thead {
   124      background: $white-ter;
   125      border: 1px solid $grey-blue;
   126  
   127      tr {
   128        &:hover {
   129          background-color: inherit;
   130        }
   131      }
   132  
   133      td,
   134      th {
   135        color: $grey-light;
   136        font-weight: $weight-normal;
   137        vertical-align: bottom;
   138        border-bottom: 1px solid $grey-blue;
   139  
   140        &.is-selectable {
   141          padding: 0;
   142  
   143          a {
   144            display: block;
   145            padding: 0.75em 1.5em;
   146            width: 100%;
   147            text-decoration: none;
   148  
   149            &:hover {
   150              background-color: darken($white-ter, 5%);
   151            }
   152          }
   153        }
   154  
   155        &.is-active {
   156          position: relative;
   157  
   158          &::after {
   159            content: '';
   160            width: 10px;
   161            right: 1.5em;
   162            top: 0.75em;
   163            bottom: 0.75em;
   164            position: absolute;
   165            display: block;
   166          }
   167  
   168          &.asc::after {
   169            content: '⬇';
   170          }
   171  
   172          &.desc::after {
   173            content: '⬆';
   174          }
   175        }
   176  
   177        a {
   178          color: $grey;
   179        }
   180      }
   181    }
   182  
   183    tbody {
   184      tr {
   185        &.is-interactive {
   186          cursor: pointer;
   187          box-sizing: border-box;
   188        }
   189  
   190        &.is-active {
   191          background: rgba($blue, 0.1);
   192  
   193          td:first-child {
   194            position: relative;
   195  
   196            &::after {
   197              position: absolute;
   198              content: '';
   199              width: 3px;
   200              top: 0;
   201              bottom: 0;
   202              left: -1px;
   203              display: block;
   204              background: $blue;
   205            }
   206          }
   207        }
   208      }
   209  
   210      td.is-subheading {
   211        font-weight: $weight-bold;
   212        background: $white;
   213        color: $blue;
   214      }
   215  
   216      td {
   217        border: 1px solid $grey-blue;
   218        border-width: 0 0 1px;
   219        padding: 1.25em 1.5em;
   220  
   221        &.is-one-line {
   222          white-space: nowrap;
   223        }
   224      }
   225    }
   226  
   227    .is-faded {
   228      color: $grey-light;
   229    }
   230  }
   231  
   232  .table tfoot,
   233  .table-foot {
   234    margin-top: -1px;
   235    background: $white-ter;
   236    border: 1px solid $grey-blue;
   237    border-bottom-right-radius: $radius;
   238    border-bottom-left-radius: $radius;
   239    overflow: hidden;
   240  
   241    .pagination {
   242      padding: 0;
   243      margin: 0;
   244    }
   245  }