3scale/porta

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

Summary

Maintainability
Test Coverage
.SettingsBox {
  @include white-box-shadow;
}

#integration-tabs .integration .SettingsBox {
  box-shadow: none;
}

.SettingsBox {
  position: relative;

  &-toggle {
    color: $link-color;
    cursor: pointer;
    display: block !important;
    float: right;
    font-size: $caption-font-size;
    margin-right: line-height-times(1);
    padding: line-height-times(1/4) line-height-times(1/4);
    position: relative;
    text-decoration: underline;
    z-index: 10;

    &:hover {
      color: $link-hover-color;
    }

    &--inline {
      float: none;
    }
  }

  &-summary {
    min-height: line-height-times(2);
    padding: line-height-times(1) line-height-times(1) line-height-times(2);
    position: relative;
    top: -$border-width;

    .u-dl-definition:last-child {
      margin-bottom: line-height-times(-1);
      border-bottom: 0;
    }

    span {
      display: none;
    }
  }

  & + .integration {
    @include white-box-shadow;
    overflow: hidden;
    padding: line-height-times(1);
  }

  &-section + &-section {
    margin-top: line-height-times(3);
  }

  &-section {
    border-bottom: $border-width $border-color solid;
    padding-bottom: line-height-times(1/2);

    &:last-child {
      border-bottom: 0;
      padding-bottom: 0;
    }
  }
}

.Environment,
.Configuration {
  background-color: $body-background;
  position: relative;

  .u-dl-definition:last-child {
    margin-bottom: line-height-times(-1);
    border-bottom: 0;
  }

  &--is-promoted::after {
    border-left: $border-width-lg solid $border-color;
    bottom: -100%;
    content: '';
    left: 50%;
    position: absolute;
    top: 100%;
    z-index: 0;
  }
  &-summary {
    border: $border-width-lg solid $border-color;
    min-height: line-height-times(2);
    padding: line-height-times(1);
    position: relative;
  }

  &-backend-summary {
    border-left: line-height-times(1/4) solid $border-color;
    margin: line-height-times(1) 0 line-height-times(2);
    padding-left: line-height-times(1);
    dt.u-dl-term {
      width: calc(40% - #{line-height-times(3/4)});
    }
    dd.u-dl-definition {
      padding-left: calc(40% - #{line-height-times(3/4)});
    }
  }

  &-promote-button {
    border-top: $border-width solid $border-color;
  }

  &-title {
    margin: 0 !important;
  }
}