3scale/porta

View on GitHub
app/assets/stylesheets/provider/_metrics.scss

Summary

Maintainability
Test Coverage
#header_table {
  margin-top: line-height-times(2);
}

th.collapsible {
  span {
    cursor: pointer;

    i {
      margin-right: line-height-times(1/4);
    }
  }

  &.collapsed {
    i {
      transform: rotate(-90deg);
    }
  }
}

table.contract_table {
    margin-bottom: line-height-times(1/2);

  &#features {
    table-layout: fixed;
  }

  &#metrics,
  &#backend_api_metrics {
    tbody {
      tr {
        &.hidden {
          display: none;
        }
      }
    }
  }

  td.selected strong {
    background: $light-background-color;
    padding: line-height-times(1/8);
  }

  table.usage_table {
    th, td {
      background-color: transparent;
    }

    td {
      border: $border-width solid $border-color;
    }
  }

  table#metrics tr.child td.title {
    background-image: image-url('child_metric_background.png');
    background-position: left center;
    background-repeat: no-repeat;
    color: $font-color;
    padding-left: line-height-times(1);
  }

  td.metrics-subtable-toggle {
    text-align: center;

    &.selected {
      color: $font-color;
      font-weight: $font-weight-bold;
      border-bottom: $border-width solid $background-color-base;
      border-left: $border-width solid $border-color;
      border-right: $border-width solid $border-color;
    }
  }

  td.metric_slot {
    padding: line-height-times(1);

    table {
      thead {
        border-bottom: $border-width solid $border-color;
      }

      tr {
        border: none;

        td {
          border: none;
          border-bottom: $border-width solid $border-color;
        }
      }
    }

  }

  .usage_limits {
    margin: 0;
    padding: 0;
    list-style: none;
    text-align: center;
  }

  .usageHidden {
    position: absolute;
    background: $font-color;
  }

  tbody tr td {
    &:last-child {
      border-top: 1px solid $altoGray;
      padding-right: line-height-times(1);
    }
    &.operations:last-child {
      padding-right: line-height-times(1);
    }
  }

  table.usage_table {
    border: 0;
    border-collapse: collapse;

    thead tr.table_title th {
      position: relative;
    }
  }

  #metrics_container > tr > th.backend_api_metric_title {
    padding-left: line-height-times(1);
  }
}