Skip to content
Snippets Groups Projects
Select Git revision
  • move-gl-dropdown
  • improve-table-pagination-spec
  • move-markdown-preview
  • winh-fix-merge-request-spec
  • master default
  • index-namespaces-lower-name
  • winh-single-karma-test
  • 10-3-stable
  • 36782-replace-team-user-role-with-add_role-user-in-specs
  • winh-modal-internal-state
  • tz-ide-file-icons
  • 38869-milestone-select
  • update-autodevops-template
  • jivl-activate-repo-cookie-preferences
  • qa-add-deploy-key
  • docs-move-article-ldap
  • 40780-choose-file
  • 22643-manual-job-page
  • refactor-cluster-show-page-conservative
  • dm-sidekiq-versioning
  • v10.4.0.pre
  • v10.3.0
  • v10.3.0-rc5
  • v10.3.0-rc4
  • v10.3.0-rc3
  • v10.3.0-rc2
  • v10.2.5
  • v10.3.0-rc1
  • v10.0.7
  • v10.1.5
  • v10.2.4
  • v10.2.3
  • v10.2.2
  • v10.2.1
  • v10.3.0.pre
  • v10.2.0
  • v10.2.0-rc4
  • v10.2.0-rc3
  • v10.1.4
  • v10.2.0-rc2
40 results

sidebar.scss

Forked from GitLab.org / GitLab FOSS
21568 commits behind the upstream repository.
sidebar.scss 3.67 KiB
.page-with-sidebar {
  padding-top: $header-height;
  transition: padding $sidebar-transition-duration;

  .sidebar-wrapper {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    height: 100%;
    overflow: hidden;
    transition: width $sidebar-transition-duration;
  }
}

.sidebar-wrapper {
  z-index: 1000;
  background: $background-color;

  .nicescroll-rails-hr {
    // TODO: Figure out why nicescroll doesn't hide horizontal bar
    display: none!important;
  }
}

.content-wrapper {
  width: 100%;
  transition: padding $sidebar-transition-duration;

  .container-fluid {
    background: #fff;
    padding: 0 $gl-padding;

    &.container-blank {
      background: none;
      padding: 0;
      border: none;
    }
  }
}

.sidebar-user {
  padding: 15px;
  position: absolute;
  left: 0;
  bottom: 0;
  width: $sidebar_width;
  overflow: hidden;
  font-size: 16px;
  line-height: 36px;
  transition: width $sidebar-transition-duration, padding $sidebar-transition-duration;

  @media (min-width: $sidebar-breakpoint) {
    bottom: 50px;
  }
}

.nav-sidebar {
  position: absolute;
  top: 50px;
  bottom: 65px;
  width: $sidebar_width;
  overflow-y: auto;
  overflow-x: hidden;

  @media (min-width: $sidebar-breakpoint) {
    bottom: 115px;
  }

  &.navbar-collapse {
    padding: 0 !important;
  }

  li {
    &.separate-item {
      padding-top: 10px;
      margin-top: 10px;
    }

    .icon-container {
      width: 34px;
      display: inline-block;
      text-align: center;
    }

    a {
      padding: 7px 15px 7px 12px;
      font-size: $gl-font-size;
      line-height: 24px;
      display: block;
      text-decoration: none;
      font-weight: normal;
      outline: none;

      &:hover,
      &:active,
      &:focus {
        text-decoration: none;
      }

      i {
        font-size: 16px;
      }

      i,
      svg {
        margin-right: 13px;
      }
    }
  }

  .count {
    float: right;
    padding: 0 8px;
    @include border-radius(6px);
  }
}

.toggle-nav-collapse {
  width: $sidebar_width;
  position: absolute;
  top: 0;
  left: 0;
  min-height: 50px;
  padding: 5px 0;
  font-size: 18px;
  line-height: 30px;
}

.nav-header-btn {
  padding: 10px 5px;
  color: inherit;
  transition-duration: .3s;

  &:hover,
  &:focus {
    color: $white-light;
    text-decoration: none;
  }
}

.pin-nav-btn {
  display: none;
  position: absolute;
  left: 0;
  bottom: 0;
  height: 50px;
  width: $sidebar_width;
  line-height: 30px;

  @media (min-width: $sidebar-breakpoint) {
    display: block;
  }

  .fa {
    transition: transform .15s;
  }

  &.is-active {
    .fa {
      transform: rotate(90deg);
    }
  }
}

.page-sidebar-collapsed {
  padding-left: 0;

  .sidebar-wrapper {
    width: 0;
  }
}

.page-sidebar-expanded {
  .sidebar-wrapper {
    width: $sidebar_width;
  }
}

.page-sidebar-pinned {
  .content-wrapper,
  .layout-nav {
    @media (min-width: $sidebar-breakpoint) {
      padding-left: $sidebar_width;
    }
  }
}

header.header-pinned-nav {
  @media (min-width: $sidebar-breakpoint) {
    padding-left: ($sidebar_width + $gl-padding);

    .side-nav-toggle {
      display: none;
    }

    .header-content {
      padding-left: 0;
    }
  }
}

.right-sidebar-collapsed {
  padding-right: 0;

  @media (min-width: $screen-sm-min) {
    padding-right: $sidebar_collapsed_width;
  }

  .sidebar-collapsed-icon {
    cursor: pointer;
  }
}

.right-sidebar-expanded {
  padding-right: 0;

  @media (min-width: $screen-sm-min) and (max-width: $screen-sm-max) {
    &:not(.build-sidebar) {
      padding-right: $sidebar_collapsed_width;
    }
  }

  @media (min-width: $screen-md-min) {
    padding-right: $gutter_width;
  }

  &.with-overlay {
    padding-right: $sidebar_collapsed_width;
  }
}