Skip to content
Snippets Groups Projects
header.scss 6.59 KiB
Newer Older
  max-height: 50px;
  height: 50px;
Gaëlle Morin's avatar
Gaëlle Morin committed
  background-color: var(--color-header-background);
  color: var(--color-black);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.09);
  flex-shrink: 0;
  position: fixed;
  z-index: 999;
  width: -webkit-fill-available;
  width: -moz-available;
  @include breakpoint(lg) {
    max-height: 83px;
    height: 83px;
Gaëlle Morin's avatar
Gaëlle Morin committed
  &.is-spaced {
    padding: 0 0.8rem;

    @include breakpoint(lg) {
      padding: 0 2.5rem;
    }
  }
  >*:not(:first-child) {
    margin-left: 2rem;

    @include breakpoint(lg) {
      margin-left: 0;
Gaëlle Morin's avatar
Gaëlle Morin committed
    flex: 1 0 0;
    align-items: stretch;
Gaëlle Morin's avatar
Gaëlle Morin committed
  }

  /* To remove the place taken by this element */
  solid-widget[name='hubl-user-avatar'] {
    display: contents;
  }
/* General styling for both notification and user's panel */
details {
  margin-right: 0;
  @include breakpoint(lg) {
    margin-right: 2.5rem;
  }

  summary {

    &::-moz-list-bullet {
      list-style-type: none; /* To remove the disclosure triangle on Firefox v.<69 */
Gaëlle Morin's avatar
Gaëlle Morin committed
    }
Gaëlle Morin's avatar
Gaëlle Morin committed
solid-notifications {
  color: var(--color-bell);

  @include breakpoint(sm) {
    padding: 0;
  }

Gaëlle Morin's avatar
Gaëlle Morin committed
  .solid-notifications__container {
Gaëlle Morin's avatar
Gaëlle Morin committed
    .solid-notifications__button {
        font-size: 2.5rem;

      @include breakpoint(lg) {
        font-size: 3rem;
      }
        display: none;
Gaëlle Morin's avatar
Gaëlle Morin committed
      .solid-notifications__counter {
        position: absolute;
        top: 1px;

        @include breakpoint(lg) {
          left: 2.1rem;
          top: -3px;
        }
Gaëlle Morin's avatar
Gaëlle Morin committed
    .solid-notifications__list {
      border: none;
      border-radius: 0;
      box-shadow: 0 0 7px 0 rgba(92, 97, 104, 0.24);
Gaëlle Morin's avatar
Gaëlle Morin committed
      position: fixed;
      left: 0;
      top: 4.5rem;
      width: 100vw;

      /* Custom scrollbar */
      overflow: auto;
      -webkit-overflow-scrolling: touch;
      -ms-overflow-style: none;

      scrollbar-width: thin;
      scrollbar-color: var(--color-notification-scrollbar-track) var(--color-notification-scrollbar-background);

      &::-webkit-scrollbar-track {
        background: var(--color-notification-scrollbar-background);
      }

      &::-webkit-scrollbar-thumb {
        background-color: var(--color-notification-scrollbar-track);
        border-radius: 6px;
      }

      &::-webkit-scrollbar {
        width: 6px;
      /* End of custom scrollbar */
Gaëlle Morin's avatar
Gaëlle Morin committed
      @include breakpoint(lg) {
        position: absolute;
        left: auto;
        right: 0;
        width: 347px;
      }

      .solid-notifications__item {
        border-bottom: 1px solid var(--color-notification-item-border);

        .solid-notification {
          padding: 1.2rem 0 1.5rem;

          .solid-notification__avatar {
            margin-left: 1.6rem;
            margin-right: 1.4rem;
          }

          .solid-notification__content {

            .solid-notification__summary {
              color: var(--color-notification-summary);
              font-size: 1.2rem;
              line-height: 1.7rem;
            }

            .solid-notification__date {
              display: none;
            }
          }

          .solid-notification__read {
            read-badge[data-unread='unread'] {
              
            }
          }
        }
#user-controls {
  padding: 0;
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;

  summary {
    cursor: pointer;
    display: block; /* To remove the disclosure triangle on Firefox v.>=69 */

    @include breakpoint(lg) {
      padding: 18px;
    }
    
      background-color: transparent;
      color: var(--color-user-panel-header-text-open);
      outline: none;

      @include breakpoint(lg) {
        background-color: var(--color-user-panel-header-background-open);
      }
    }
  }

  #user-controls__profile {
    div {
      display: flex;
      flex-direction: row-reverse;
      
      > * {
        vertical-align: middle;
      }
        height: 3.3rem;
        margin-right: 0;
        width: 3.3rem;

        @include breakpoint(lg) {
          height: 4.8rem;
          margin-right: 2rem;
          width: 4.8rem;
      solid-display-value[name='first_name'] {
        @include icon('arrow-down');
        align-items: center;
        flex-direction: row-reverse;
        font-size: 1.8rem;
        font-weight: 600;
        @include breakpoint(lg) {
          display: flex;
  }

  #user-controls__panel {
    height: 0;
    position: absolute;
    right: 0;
    z-index: 1;
    /* Quick fix for mobile version */
    width: 215px;
    top: 42px;
    
    @include breakpoint (lg) {
      width: 100%;
      top: 83px;
    }
    
    > nav {
      background-color: var(--color-user-panel-list-background);
      box-shadow: 0 7px 8px 0 rgba(0, 0, 0, 0.16);
      position: absolute;
      right: 0;
          solid-link {
            color: var(--color-grey-4);
            display: block;
            border-bottom: 1px solid var(--color-user-panel-list-border);
            margin-right: 0;
            padding: 1.6rem 1.3rem;

            &:hover {
              color: var(--color-user-panel-list-text-hover);
      }

      button {
        color: var(--color-grey-4);
        padding: 1.6rem 1.3rem;
        text-align: left;
        width: 100%;

        &:hover {
          color: var(--color-user-panel-list-text-hover);
  }

  &[open] {
    background-color: var(--color-user-panel-header-background);
    color: var(--color-user-panel-header-text);

    #user-controls__profile {

      div {

        solid-display-value[name='first_name'] {
          @include icon('close');

          &::before {
            margin-left: 1.5rem;
  display: block;
  padding-left: 0;
  font-size: 24px;
  @include breakpoint(lg) {
    display: none;