ilscipio/scipio-erp

View on GitHub
themes/bulma/webapp/bulmatheme/src/scss/scipio/_header.scss

Summary

Maintainability
Test Coverage
/*
  Menu
*/
.sidebar-toggle{
  background: $sidebar-toggle-background;
  color: $sidebar-toggle;
  padding: 0.25rem .75rem;
  display: flex;
  justify-content: flex-end;
  cursor:pointer;

  i {
    transition: 0.3s ease-in all;
  }

  &:hover{

    i {
      margin-right:0.25em;
    }
  }

  &.is-active{
    &:hover{

      i {
        margin-right:-0.25em;
      }
    }
  }
}

.navbar-burger {
  margin-right: auto;

  &:focus,
  &:focus-within,
  &:hover,
  &.is-active {
    background-color: $navbar-background-color;
    color: $navbar-item-active-color;
  }
}

.navbar-apps {
  width:400px;
  background-color: $red;
  justify-content: end;
  height:3.25rem;
  transition: 0.3s ease-in all;
  cursor: pointer;

  .navbar-apps-menu {
    height: 3rem;
    width: 3rem;
    position: relative;
    //border: 4px solid $navbar-burger-color;
    //border-radius: 100%;
    -moz-transition: 0.3s;
    -o-transition: 0.3s;
    -webkit-transition: 0.3s;
    transition: 0.3s;
    cursor: pointer;
  }

  .navbar-apps-bar {
    display: block;
    background-color: #fff;
    -moz-transition: 0.4s;
    -o-transition: 0.4s;
    -webkit-transition: 0.4s;
    transition: 0.4s;
    height: 16px;
    width: 16px;
    background: none;
    border-bottom: 3px solid $navbar-burger-color;
    border-right: 3px solid $navbar-burger-color;
    position: absolute;
    -moz-border-radius: 0;
    -webkit-border-radius: 0;
    border-radius: 0;
    transform: rotate(45deg);
    margin: auto;
    top: calc(50% - 10px);
    right: 0;
    left: 0;
  }

  &:hover,
  &.is-active,
  {
    position: fixed;
    z-index:50;

    .navbar-apps-bar {
      top: .5rem;

      &:nth-of-type(2) {
        rotate: 180deg;
        transform-origin: 75% 110% 0;
      }

      &:nth-of-type(3) {display:none;}
    }
  }

}



.app-header {
  height:3.25rem;
}

.navbar-apps-overlay{
  display:flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  position: fixed;
  left: 0;
  top:0; //3.25rem
  width: 100%;
  height: 100%;
  z-index:20;
  background: $navbar-apps-overlay-background;
  transition: opacity 0.5s;
  opacity:0;
  visibility: hidden;
  overflow-y:auto;

  backdrop-filter: blur(4px) grayscale(1);

  .navbar-wrap{
    position: relative;
    top: 25%;
    height: 60%;
    text-align: center;
    font-size: 54px;
    -webkit-transform: translateY(-50%);
    -ms-transform: translateY(-50%);
    transform: translateY(-50%);

    display: grid;
    grid-template-columns: repeat(4, 15vw);
    gap: 5vh;

    .navbar-item{
      display: flex;
      flex-direction: column;
      justify-content: center;

      border: 2px solid #fff;
      background-color: $navbar-apps-overlay-item-background;
      background-image: linear-gradient(to left bottom, $navbar-apps-overlay-item-background, bulmaDarken($navbar-apps-overlay-item-background,10%));
      border-radius: $navbar-apps-overlay-item-radius;
      color: $navbar-apps-overlay-item;
      text-transform: uppercase;
      font-weight: 400;
      font-size: 15px;
      -webkit-transition: all 300ms ease-in-out;
      transition: all 300ms ease-in-out;
      padding:2rem 1.5rem 1.5rem;

      box-shadow: $navbar-apps-box-shadow-size $navbar-apps-box-shadow-color;

      i {font-size:3rem; margin-bottom:1rem;}

      &:focus,
      &:focus-within,
      &:hover,
      &.is-active {
        color: $navbar-apps-overlay-item-hover;
        background-color: $navbar-apps-overlay-item-background-hover;
        background-image: linear-gradient(to left bottom, $navbar-apps-overlay-item-background-hover, bulmaDarken($navbar-apps-overlay-item-background-hover,10%));
        transform: translateY(-5px) scale(1.05) translateZ(0);
      }


    }

  }

  &.is-active {
    opacity: 1;
    visibility: visible;
  }


  .navbar-item{
    @extend .is-child;
  }
}