diff --git a/checkout/src/arquivos/js/checkout.js b/checkout/src/arquivos/js/checkout.js index 4559dcd..c8162e9 100644 --- a/checkout/src/arquivos/js/checkout.js +++ b/checkout/src/arquivos/js/checkout.js @@ -3,7 +3,6 @@ import { Container } from "m3-utils"; import "slick-carousel"; import Header from "./components/Header"; import Footer from "./components/Footer"; -import Content from "./components/content"; const m3Checkout = new Container({ appName: "m3-checkout", diff --git a/checkout/src/arquivos/js/components/Content.js b/checkout/src/arquivos/js/components/Content.js deleted file mode 100644 index 0dc6648..0000000 --- a/checkout/src/arquivos/js/components/Content.js +++ /dev/null @@ -1,43 +0,0 @@ -import { hasData } from "jquery"; -import { waitElement } from "m3-utils"; - -export default class Content { - constructor() { - this.init(); - } - - async selectors() { - this.titleMyCart = await waitElement("#cart-title"); - this.h2CartEmpty = await waitElement(".empty-cart-title", { - timeout: 5000, - interval: 1000, - }); - this.btnCartEmpty = await waitElement("#cart-choose-products", { - timeout: 5000, - interval: 1000, - }); - this.cartContent = await waitElement(".cart"); - } - - async init() { - await this.selectors(); - await this.insertHTML(); - await this.modificadedHTML(); - } - - async insertHTML() { - this.h2CartEmpty.innerHTML = `Seu carrinho está vazio`; - this.btnCartEmpty.innerHTML = `Continuar Comprando`; - } - - // async modificadedHTML() { - // let monitorDisplay = this.cartContent.style.display; - // window.sty - // if (this.cartContent.style.display === "none") { - // console.log("oioioi"); - // this.titleMyCart.classList.add("cartTitleInvisible"); - // } else if (this.titleMyCart.classList.contains("cartTitleInvisible")) { - // this.titleMyCart.classList.remove("cartTitleInvisible"); - // } - // } -} diff --git a/checkout/src/arquivos/js/components/Footer.js b/checkout/src/arquivos/js/components/Footer.js index 66e8a02..b0a1c2e 100644 --- a/checkout/src/arquivos/js/components/Footer.js +++ b/checkout/src/arquivos/js/components/Footer.js @@ -33,14 +33,19 @@ export default class Footer { if (window.location.href != "https://m3academy.myvtex.com/checkout/#/cart") { pratileira.classList.add("elementInvisible"); + } else { + pratileira.classList.remove("elementInvisible"); } window.addEventListener("hashchange", () => { - if (window.location.hash == "#/cart") { - this.pratileira.classList.remove("elementInvisible"); + if (window.location.hash == "#/cart" && target.style.display === "block") { + this.pratileira.classList.add("elementInvisible"); + titleCart.classList.add("elementInvisible"); this.api(); - } else { + } else if (window.location.hash != "#/cart") { pratileira.classList.add("elementInvisible"); + } else { + pratileira.classList.remove("elementInvisible"); } }); @@ -108,9 +113,11 @@ export default class Footer {

${dataItem.productName}

    - ${dataItem.items.map((variableItem) => { - return `
  1. ${variableItem.name}
  2. `; - })} + ${dataItem.items + .map((variableItem) => { + return `
  3. ${variableItem.name}
  4. `; + }) + .join("")}
`; diff --git a/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss b/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss index d95a78f..518b7ab 100644 --- a/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss +++ b/checkout/src/arquivos/sass/checkout/_checkout-autenticacao.scss @@ -1235,10 +1235,6 @@ box-shadow: none; color: #303030; padding: 14px 12px; - - // svg path { - // fill: #d8c8ac; - // } } label.vtex-omnishipping-1-x-leanShippingOption { diff --git a/checkout/src/arquivos/sass/checkout/_checkout-carrinho.scss b/checkout/src/arquivos/sass/checkout/_checkout-carrinho.scss index b946138..658a8a7 100644 --- a/checkout/src/arquivos/sass/checkout/_checkout-carrinho.scss +++ b/checkout/src/arquivos/sass/checkout/_checkout-carrinho.scss @@ -1212,10 +1212,6 @@ color: $color-black-neutra; text-decoration: none; } - - @media screen and (max-width: 1024px) { - // margin-top: 48px; - } } .coupon-column { diff --git a/checkout/src/arquivos/sass/checkout/_checkout.scss b/checkout/src/arquivos/sass/checkout/_checkout.scss index 0bd9df4..53867b2 100644 --- a/checkout/src/arquivos/sass/checkout/_checkout.scss +++ b/checkout/src/arquivos/sass/checkout/_checkout.scss @@ -40,10 +40,6 @@ body { @media screen and (max-width: 1024px) { width: 100%; } - - .checkout-container { - // padding-top: 11px; - } } @media screen and (max-width: 1024px) { diff --git a/checkout/src/arquivos/sass/partials/_footer.scss b/checkout/src/arquivos/sass/partials/_footer.scss index 70fe70d..5824fe4 100644 --- a/checkout/src/arquivos/sass/partials/_footer.scss +++ b/checkout/src/arquivos/sass/partials/_footer.scss @@ -324,6 +324,24 @@ font-size: 0; + @media (min-width: 1025px) and (max-width: 1220px) { + .card-list-pratileira { + .wrapper-list-variables { + width: 100%; + height: 61px; + display: inline-block; + text-align: center; + + .variable-pratileira { + display: inherit; + word-wrap: normal; + max-height: auto; + min-width: max-content; + } + } + } + } + @media (max-width: 1024px) { width: 100%; padding: 0 8px;