From 9760f1c9efda942496d5489db1d2879b542fd274 Mon Sep 17 00:00:00 2001 From: Douglas Nobrega Date: Wed, 7 Dec 2022 21:00:14 -0300 Subject: [PATCH] Cria o header mobile --- src/arquivos/sass/partials/_header.scss | 147 +++++++++++------- src/arquivos/sass/partials/_menu.scss | 17 +- src/arquivos/sass/utils/_variaveis.scss | 1 + src/arquivos/sprite/user-icon.png | Bin 770 -> 822 bytes .../sub-templates/douglas-header.html | 16 +- 5 files changed, 121 insertions(+), 60 deletions(-) diff --git a/src/arquivos/sass/partials/_header.scss b/src/arquivos/sass/partials/_header.scss index 650d0b2..3f03f2c 100644 --- a/src/arquivos/sass/partials/_header.scss +++ b/src/arquivos/sass/partials/_header.scss @@ -2,28 +2,26 @@ padding: 28px 0; background-color: $black-500; + @include mq(lg, max) { + padding: 18px 0 0; + } + &__wrapper { display: grid; grid-template-columns: 2fr 1fr 2fr; align-items: center; + + @include mq(lg, max) { + grid-template-columns: repeat(3, 1fr); + } } &__logo { display: block; margin: 0 auto; - } - .user-items { - display: flex; - align-items: center; - justify-content: flex-end; - - &__search-box { - flex: 1; - max-width: 212px; - @include mq(md, max) { - display: none; - } + @include mq(lg, max) { + max-width: 66px; } } @@ -31,8 +29,6 @@ display: flex; align-items: center; margin: 0; - padding: 8px 0; - border-bottom: 1px solid $white-500; legend, label, @@ -66,55 +62,98 @@ } } - &__account-link { + .user-items { display: flex; align-items: center; - &::before, - &::after { - content: ""; - width: 1px; - height: 19px; - margin: 0 24px; - background: $white-500; - } - } + justify-content: flex-end; - &__minicart-button { - position: relative; - padding: 0; - border: 0; - outline: 0; - background: transparent; - .portal-totalizers-ref { - .title, - .amount-products, - .amount-items strong, - .amount-kits, - .total-cart { + &__search-box { + flex: 1; + max-width: 212px; + + @include mq(lg, max) { display: none; } + + .busca { + padding: 8px 0; + border-bottom: 1px solid $white-500; + } } - .cart-info { - margin: 0; - } - - .amount-items-em { + &__account-link { display: flex; align-items: center; - justify-content: center; - position: absolute; - top: 4px; - right: -4px; - width: 15px; - height: 15px; - border-radius: 50%; - line-height: 11px; - font-size: 9px; - font-weight: bold; - font-style: normal; - color: $white-500; - background: $blue-500; + &::before, + &::after { + content: ""; + width: 1px; + height: 19px; + margin: 0 24px; + background: $white-500; + + @include mq(lg, max) { + margin: 0 16px; + } + } + + &::before { + @include mq(lg, max) { + display: none; + } + } + } + + &__minicart-button { + position: relative; + padding: 0; + border: 0; + outline: 0; + background: transparent; + .portal-totalizers-ref { + .title, + .amount-products, + .amount-items strong, + .amount-kits, + .total-cart { + display: none; + } + } + + .cart-info { + margin: 0; + } + + .amount-items-em { + display: flex; + align-items: center; + justify-content: center; + position: absolute; + top: 4px; + right: -4px; + width: 15px; + height: 15px; + border-radius: 50%; + line-height: 11px; + font-size: 9px; + font-weight: bold; + font-style: normal; + color: $white-500; + background: $blue-500; + } } } + + &__search-box { + margin-top: 18px; + border-top: 1px solid $gray-500; + + @include mq(lg, min) { + display: none; + } + } + + .busca { + padding: 13px 0; + } } diff --git a/src/arquivos/sass/partials/_menu.scss b/src/arquivos/sass/partials/_menu.scss index 24e0e10..577cd86 100644 --- a/src/arquivos/sass/partials/_menu.scss +++ b/src/arquivos/sass/partials/_menu.scss @@ -1,3 +1,16 @@ -.main-menu { - display: none; +.menu { + &__button { + padding: 0; + border: 0; + outline: 0; + background: transparent; + + @include mq(lg, min) { + display: none; + } + } + + .main-menu { + display: none; + } } diff --git a/src/arquivos/sass/utils/_variaveis.scss b/src/arquivos/sass/utils/_variaveis.scss index 9c09345..c99c340 100644 --- a/src/arquivos/sass/utils/_variaveis.scss +++ b/src/arquivos/sass/utils/_variaveis.scss @@ -12,6 +12,7 @@ $font-height: 1.5; $black-500: #000000; $white-500: #ffffff; $blue-500: #00c8ff; +$gray-500: #333333; // Grid breakpoints diff --git a/src/arquivos/sprite/user-icon.png b/src/arquivos/sprite/user-icon.png index 15dc1816171fc082d08d5eac7d5fa2aa42e7790f..f0e96d9d076b8325e1941cfcd6156b737e2f40e0 100644 GIT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