diff --git a/checkout/src/arquivos/js/components/Footer.js b/checkout/src/arquivos/js/components/Footer.js index d8243ce..0a25a82 100644 --- a/checkout/src/arquivos/js/components/Footer.js +++ b/checkout/src/arquivos/js/components/Footer.js @@ -10,15 +10,16 @@ export default class Footer { this.addProductShelf(); this.addIconsFooter(); this.addIconPayment(); + this.onUpdate(); + this.changeText(); this.addCarrossel(); - // this.onUpdate(); - // window.addEventListener("hashchange", () => { - // const isCartRouter = window.location.hash === "#/cart"; - // if (!isCartRouter) { - // document.querySelector(".containerCarousel").style.display = "none"; - // document.querySelector(".title-footer").style.display = "none"; - // } - // }); + window.addEventListener("hashchange", () => { + const isCartRouter = window.location.hash === "#/cart"; + if (!isCartRouter) { + document.querySelector(".containerCarousel").style.display = "none"; + document.querySelector(".title-footer").style.display = "none"; + } + }); } async selectors() { @@ -28,6 +29,8 @@ export default class Footer { this.footerStamps = await waitElement(".footerCheckout__stamps"); this.checkoutVazio = await waitElement(".empty-cart-content"); this.footerCheckoutPayment = await waitElement(".footerCheckout__payments"); + this.footerCheckoutPaymentCard = await waitElement("#show-gift-card-group"); + // this.tituloCarrinho = await waitElement("h2.title-footer"); } onUpdate() { @@ -39,10 +42,11 @@ export default class Footer { mutations.forEach(function (mutation) { const carrousel = document.querySelector(".containerCarousel"); const titleFooter = document.querySelector(".title-footer"); - if (mutation.target.style.display === "none") { + if (mutation.target.style.nodeValue === "flex") { carrousel.style.display = "flex"; titleFooter.style.display = "flex"; - } else { + // this.addCarrossel(); + } else if (mutation.target.style.nodeValue === "none") { carrousel.style.display = "none"; titleFooter.style.display = "none"; } @@ -96,7 +100,6 @@ export default class Footer { `; shelf.children[1].appendChild(li); - // shelf.classList.add("fetch"); }); }); } @@ -166,4 +169,9 @@ export default class Footer { }); } } + + changeText() { + this.footerCheckoutPaymentCard.innerText = + "Solicitamos apenas informações necessárias para realização da sua compra, sem compromenter seus dados"; + } } diff --git a/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss b/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss index 8b76817..7feb612 100644 --- a/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss +++ b/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss @@ -368,4 +368,51 @@ } } } + .payment-group a { + display:flex; + align-items: center; + justify-content: center; + width: 100%; + height: 50px; + background: $color-gray3; + mix-blend-mode: normal; + opacity: 0.3; + border: 1px solid $color-black-full; + border-radius: 6px; + margin-bottom: 12px; + + + .payment-group-item-text { + display:flex; + align-items: center; + justify-content: center; + font-family: $font-family; + font-style: normal; + font-weight: 400; + font-size: 14px; + line-height: 24px; + color:$color-gray11; + background-image:url(none); + } + } + + .icon-credit-card { + display: none; + } + + .link-payment-discounts-cod { + font-family: $font-family; + font-style: normal; + font-weight: 400; + font-size: 14px; + line-height: 24px; + letter-spacing: -0.01em; + color: $color-gray2; + margin-bottom: 16px; + } + + .steps-view { + margin-top: 35px; + } + } diff --git a/checkout/src/arquivos/sass/utils/_variaveis.scss b/checkout/src/arquivos/sass/utils/_variaveis.scss index ab57814..426f54e 100644 --- a/checkout/src/arquivos/sass/utils/_variaveis.scss +++ b/checkout/src/arquivos/sass/utils/_variaveis.scss @@ -19,6 +19,7 @@ $color-gray7: #C4C4C4;; $color-gray8: #ededed; $color-gray9: #BDBDBD; $color-gray10:#808080; +$color-gray11:#58595B;