development #10

Merged
DaviKlein merged 18 commits from development into main 2022-12-19 02:48:45 +00:00
17 changed files with 3219 additions and 485 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 338 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 267 B

View File

@ -31,10 +31,7 @@ export default class CheckoutUI {
toggleFooterDropdown(event) {
event.target.classList.toggle("closed");
event.target.nextElementSibling.classList.toggle(
"dropdown__content--closed"
);
event.target.nextElementSibling.classList.toggle("dropdown__content--closed");
}
init() {
@ -56,14 +53,7 @@ export default class CheckoutUI {
resizeImages() {
$(".product-image img").each((i, el) => {
const $el = $(el);
$el.attr(
"src",
alterarTamanhoImagemSrcVtex(
$el.attr("src"),
this.width,
this.height
)
);
$el.attr("src", alterarTamanhoImagemSrcVtex($el.attr("src"), this.width, this.height));
});
}
}

View File

@ -7,34 +7,276 @@ export default class Footer {
async init() {
await this.selectors();
// this.onUpdate();
this.events();
this.onUpdate();
this.createPaymentsIcons();
this.createVtexpciIcon();
this.createDevIcons();
// await this.addCarrossel();
}
events() {
window.addEventListener("hashchange", () => {
this.onUpdate();
if (window.location.hash != "#/cart") {
if (document.querySelector(".footerTitle") != null) {
document.querySelector(".footerTitle").style.display = "none";
}
this.cartTitle.style.display = "none";
}
if (window.location.hash == "#/cart" && this.checkoutVazio.style.display == "none") {
if (document.querySelector(".footerTitle") != null) {
document.querySelector(".footerTitle").style.display = "block";
}
this.cartTitle.style.display = "block";
}
console.log("HASHCHANGE FOOTER");
if (window.location.hash == "#/cart" && this.checkoutVazio.style.display == "none") {
this.list.style.display = "flex";
}
if (window.location.hash != "#/cart") {
this.list.style.display = "none";
}
});
addEventListener("resize", () => {
this.addCarrossel();
});
}
async selectors() {
//Para verificar se o carrinho está vazio e remover a prateleira de produtos:
// vocês devem olhar a doc fornecida no Desafio para aprender a usar o waitElement
this.list = await waitElement(".footerCheckout__prateleira", {
timeout: 5000,
interval: 1000,
});
// this.slick = await waitElement(".slick-test");
// this.footerTitle = await waitElement(".footerTitle", {
// timeout: 5000,
// interval: 1000,
// });
this.allList = await waitElement(".footerCheckout");
this.checkoutVazio = await waitElement(".empty-cart-content");
this.payments = await waitElement(".footerCheckout__payments");
this.vtexpci = await waitElement(".footerCheckout__vtexpci");
this.iconsFooter = await waitElement(".footerCheckout__developedBy");
this.listaPrateleira = await waitElement(".footerCheckout__prateleira");
this.cartTitle = await waitElement("#cart-title");
}
onUpdate() {
//Função qeu fará a verificação se o carrinho está vazio para remover a prateleira de produtos:
// vocês devem olhar a doc fornecida no Desafio para aprender a usar a MutationObserver
// sempre que o carrinho estiver vazio o elemento chcekoutVazio fica display: none e isso pode ser usado como atributo para a MutationObserver
let target = this.checkoutVazio;
let lista = this.list;
let cartTitle = this.cartTitle;
console.log("title:", cartTitle);
if (target.style.display == "none" && window.location.hash == "#/cart") {
lista.style.display = "flex";
cartTitle.style.display = "block";
if (!this.list.classList.contains("fetch")) {
console.log("PRIMEIRO NAO TEM FETCH");
this.fetchApiData();
}
} else {
lista.style.display = "none";
cartTitle.style.display = "none";
}
let config = { childList: true, attributes: true };
let observer = new MutationObserver((mutations) => {
if (window.location.hash == "#/cart") {
console.log("listairai", this.list.classList);
if (!lista.classList.contains("fetch")) {
console.log("SEGUNDO NAO TEM FETCH");
this.fetchApiData();
}
mutations.forEach(function (mutation) {
if (target.style.display != "none") {
if (document.querySelector(".footerTitle") != null) {
document.querySelector(".footerTitle").style.display = "none";
}
cartTitle.style.display = "none";
lista.style.display = "none";
} else {
if (document.querySelector(".footerTitle") != null) {
document.querySelector(".footerTitle").style.display = "block";
}
lista.style.display = "flex";
cartTitle.style.display = "block";
}
console.log(mutation.type);
});
}
});
observer.observe(target, config);
}
async addCarrossel() {
const elemento = await waitElement("#my-element");
$(elemento).slick({
console.log("start slick");
const elemento = await waitElement(".slick-test");
if ($(elemento).hasClass("slick-initialized")) {
$(elemento).slick("unslick");
}
if (window.innerWidth > 1024) {
$(elemento).not(".slick-initialized").slick({
slidesToShow: 4,
slidesToScroll: 1,
});
} else if (window.innerWidth > 375) {
$(elemento).not(".slick-initialized").slick({
slidesToShow: 3,
slidesToScroll: 1,
});
} else if (window.innerWidth <= 375) {
$(elemento).not(".slick-initialized").slick({
slidesToShow: 2,
slidesToScroll: 1,
});
}
console.log("end slick");
}
fetchApiData() {
console.log("COMEÇO FETCH");
fetch(
"https://m3academy.myvtex.com/api/catalog_system/pub/products/search/?fq=productClusterIds:319"
)
.then((response) => response.json())
.then((data) => {
console.log(data);
const ul = document.createElement("ul");
ul.classList.add("slick-test");
this.list.appendChild(ul);
const footerCheckout = document.querySelector(".footerCheckout");
const footerTitle = document.createElement("p");
footerTitle.classList.add("footerTitle");
footerTitle.innerText = "Você também pode gostar:";
footerCheckout.insertBefore(footerTitle, this.list);
data.map((item) => {
let colors = "";
for (let i = 0; i < item.items.length; i++) {
console.log(colors);
colors += `<p>${item.items[i].name}</p>`;
}
const li = document.createElement("li");
li.setAttribute("name", item.itemId);
li.classList.add("itemList");
li.innerHTML = `<img class="productImg" src="${item.items[0].images[0].imageUrl}">
<p class="productName">${item.productName}</p>
<div class="itemSku">
${colors}
</div>
<a class="productLink" type="button" href="${item.link}">VER PRODUTO</a>`;
console.log(item.productName, colors);
console.log("adiciona li");
ul.appendChild(li);
this.list.classList.add("fetch");
console.log(this.list);
ul.style.width = "100%";
});
})
.then(() => {
this.addCarrossel();
});
console.log("FIM FETCH");
}
createPaymentsIcons() {
this.payments.innerHTML = `
<ul class="payments-icons-wrapper">
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/masterCardM3Academy.png"
alt=""
/>
</figure>
</li>
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/visaM3Academy.png"
alt=""
/>
</figure>
</li>
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/amexM3Academy.png"
alt=""
/>
</figure>
</li>
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/eloM3Academy.png"
alt=""
/>
</figure>
</li>
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/hiperCardM3Academy.png"
alt=""
/>
</figure>
</li>
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/payPalM3Academy.png"
alt=""
/>
</figure>
</li>
<li>
<figure>
<img
src="https://agenciamagma.vteximg.com.br/arquivos/boletoM3Academy.png"
alt=""
/>
</figure>
</li>
</ul>
`;
}
createVtexpciIcon() {
this.vtexpci.innerHTML = `
<figure class="vtex-icon">
<img
src="https://agenciamagma.vteximg.com.br/arquivos/vtexPCIM3Academy.png"
alt=""
/>
</figure>
`;
}
createDevIcons() {
this.iconsFooter.innerHTML = `
<li>
<a href="https://vtex.com/br-pt/">
<span>Powered By</span>
<figure>
<img class="vtex-icon" src="https://agenciamagma.vteximg.com.br/arquivos/logoVTEXM3Academy.png" alt="">
</figure>
</a>
</li>
<li>
<a href="https://agenciam3.com/">
<span>Developed By</span>
<figure>
<img class="m3-icon" src="https://agenciamagma.vteximg.com.br/arquivos/logoM3M3Academy.png" alt="">
</figure>
</a>
</li>
`;
}
}

View File

@ -8,14 +8,174 @@ export default class Header {
async init() {
await this.selectors();
console.log(this.item);
this.events();
this.createProgressBar();
await this.progressBarProgress();
}
async selectors() {
this.item = await waitElement("#my-element", {
this.item = await waitElement("#progressBar", {
//#my-element pode ser a class ou o id do elemento html qeu vocÊ quer pegar
timeout: 5000, // vai esperar 5 segundos antes de rejeitar a promise
interval: 1000, // vai verificar a cada 1 segundo se o elemento existe
});
this.header = await waitElement(".headerCheckout");
this.progressBar = await waitElement("#progressBar");
}
events() {
addEventListener("resize", () => {
this.createProgressBar();
this.progressBarProgress();
});
}
createProgressBar() {
if (this.progressBar && window.innerWidth > 1024) {
this.progressBar.innerHTML = `
<ul class="">
<li>
<div class="containerLi">
<div>
<p class="progress-bar-text">Meu Carrinho</p>
<p id="progress-bar-circle-1" class="progress-bar-circle-1"></p>
<p class="progress-bar-line-1"></p>
</div>
</div>
</li>
<li class="central">
<div class="containerLi">
<div>
<p class="progress-bar-text">Dados Pessoais</p>
<p id="progress-bar-circle-2" class="progress-bar-circle-2"></p>
</div>
</div>
</li>
<li>
<div class="containerLi">
<div>
<p class="progress-bar-text">Pagamento</p>
<p id="progress-bar-circle-3" class="progress-bar-circle-3"></p>
<p class="progress-bar-line-2"></p>
</div>
</div>
</li>
</ul>
`;
}
if (this.progressBar && window.innerWidth <= 1024) {
this.progressBar.innerHTML = ``;
}
}
async progressBarProgress() {
this.circle1 = await waitElement(".progress-bar-circle-1");
this.circle2 = await waitElement(".progress-bar-circle-2");
this.circle3 = await waitElement(".progress-bar-circle-3");
if (this.progressBar && window.innerWidth > 1024) {
const progressBarList = document.querySelectorAll("#progressBar ul li");
progressBarList.forEach((li) => {
if (window.location.href === "https://m3academy.myvtex.com/checkout/#/cart") {
if (this.circle1) {
this.circle1.classList.add("active");
}
if (this.circle2) {
if (this.circle2.classList.contains("active")) {
this.circle2.classList.remove("active");
}
}
if (this.circle3) {
if (this.circle3.classList.contains("active")) {
this.circle3.classList.remove("active");
}
}
} else if (
window.location.href === "https://m3academy.myvtex.com/checkout/#/email" ||
window.location.href === "https://m3academy.myvtex.com/checkout/#/profile" ||
window.location.href === "https://m3academy.myvtex.com/checkout/#/shipping"
) {
if (this.circle1) {
if (this.circle1.classList.contains("active")) {
this.circle1.classList.remove("active");
}
console.log("email shipping");
console.log(this.circle1);
if (this.circle2) {
this.circle2.classList.add("active");
console.log("teste dados");
}
console.log(this.circle2);
console.log(this.circle3);
if (this.circle3) {
if (this.circle3.classList.contains("active")) {
this.circle3.classList.remove("active");
}
}
}
} else if (
window.location.href === "https://m3academy.myvtex.com/checkout/#/payment"
) {
if (this.circle1) {
if (this.circle1.classList.contains("active")) {
this.circle1.classList.remove("active");
}
}
if (this.circle2) {
if (this.circle2.classList.contains("active")) {
this.circle2.classList.remove("active");
}
}
if (this.circle3) {
this.circle3.classList.add("active");
}
}
window.addEventListener("hashchange", () => {
if (window.location.hash == "#/cart") {
if (this.circle1) {
this.circle1.classList.add("active");
}
if (this.circle2) {
if (this.circle2.classList.contains("active")) {
this.circle2.classList.remove("active");
}
}
if (this.circle3) {
if (this.circle3.classList.contains("active")) {
this.circle3.classList.remove("active");
}
}
} else if (
window.location.hash == "#/email" ||
window.location.hash == "#/profile" ||
window.location.hash == "#/shipping"
) {
if (this.circle1) {
if (this.circle1.classList.contains("active")) {
this.circle1.classList.remove("active");
}
}
if (this.circle2) {
this.circle2.classList.add("active");
}
if (this.circle3) {
if (this.circle3.classList.contains("active")) {
this.circle3.classList.remove("active");
}
}
} else if (window.location.hash == "#/payment") {
if (this.circle1) {
if (this.circle1.classList.contains("active")) {
this.circle1.classList.remove("active");
}
}
if (this.circle2) {
if (this.circle2.classList.contains("active")) {
this.circle2.classList.remove("active");
}
}
if (this.circle3) {
this.circle3.classList.add("active");
}
}
});
});
}
}
}

View File

@ -2,4 +2,5 @@
@import "./lib/slick";
@import "./partials/header";
@import "./partials/footer";
@import "./partials/prateleira.scss";
@import "./checkout/checkout.scss";

File diff suppressed because it is too large Load Diff

View File

@ -1,11 +1,361 @@
body .container-main.container-order-form .orderform-template.active {
// .mini-cart {
// width: 32.3242%;
// margin-left: unset;
// margin-right: 0;
// float: right;
// }
// .orderform-template-holder {
// width: 66.1132%;
// }
.shipping-data {
.shipping-container {
.shipping-method-toggle-delivery {
background: $color-white;
}
.shp-method-option-text {
text-shadow: none;
}
}
}
.mini-cart {
border-radius: 8px;
width: 32.3242%;
margin-left: unset;
margin-right: 0;
float: right;
border: 1px solid #e5e5e5;
.cart-items {
li {
.product-name {
font-family: "Tenor Sans";
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 14px;
white-space: unset;
@include mq(xxl, min) {
font-weight: 400;
font-size: 24px;
line-height: 28px;
}
}
.price {
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-size: 12px;
line-height: 16px;
@include mq(xxl, min) {
font-weight: 400;
font-size: 24px;
line-height: 33px;
}
}
}
}
.cart-fixed {
height: auto !important;
@media (max-width: 1024px) {
display: flex;
flex-direction: column;
}
h2 {
font-family: "Tenor Sans";
font-style: normal;
font-weight: 400;
font-size: 16px;
line-height: 19px;
color: #292929;
text-align: left;
padding: 24px 0px 35px 17px;
@include mq(xxl, min) {
font-weight: 400;
font-size: 32px;
line-height: 37px;
}
}
#go-to-cart-button {
margin-right: 17px;
}
.summary-cart-template-holder {
.summary-totalizers {
margin: 0;
}
.cart {
border: none;
padding: 0px 17px;
margin: 0 0 19px;
}
}
.accordion-group {
table {
margin: 0px 17px;
width: calc(100% - 34px);
tr {
border-top: 1px solid #e0e0e0;
}
td {
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-size: 14px;
line-height: 19px;
color: #7d7d7d;
}
td[data-i18n="global.total"] {
font-weight: 700;
font-size: 18px;
line-height: 25px;
color: #292929;
float: left;
@media (min-width: 2500px) {
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-size: 36px;
line-height: 49px;
}
}
td[data-bind="text: totalLabel"] {
font-weight: 700;
font-size: 18px;
line-height: 25px;
color: #292929;
@media (min-width: 2500px) {
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-size: 36px;
line-height: 49px;
}
}
.info,
.monetary {
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-size: 14px;
line-height: 19px;
@include mq(xxl, min) {
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-size: 28px;
line-height: 38px;
}
}
}
}
}
@media (max-width: 1024px) {
width: 97.2%;
margin-left: 6px;
}
}
.orderform-template-holder {
width: 66.1132%;
@media (max-width: 1024px) {
width: 100% !important;
}
}
}
.box-step {
.box-step-content {
.form-step {
.link-gift-card {
left: 0;
top: -66px;
margin: 0;
a {
pointer-events: none;
font-size: 0 !important;
&:after {
font-weight: 400;
font-size: 14px;
line-height: 24px;
letter-spacing: -0.01em;
color: #7d7d7d;
content: "Solicitamos apenas informações necessárias para realização da sua compra, sem compromenter seus dados";
}
}
}
.steps-view {
width: 56.456%;
@include mq(c, max) {
margin-left: 0 !important;
}
@include mq(l, max) {
margin: 12px 18px 36.75px 16px;
width: 93%;
}
.payment-method {
}
}
.payment-group {
margin: 0;
width: 32.505%;
@include mq(l, max) {
width: 100%;
}
.payment-group-list-btn {
display: flex;
flex-direction: column;
gap: 12px;
width: 100%;
a {
display: none;
border: 1px solid rgb(0, 0, 0, 0.3);
border-radius: 6px;
background: #f0f0f0;
align-items: center;
text-align: center;
padding: 0 8px;
width: 91.39%;
margin: 0;
span {
width: 100%;
padding: 11px 0;
font-weight: 400;
font-size: 14px;
line-height: 24px;
letter-spacing: -0.01em;
color: #58595b;
}
}
#payment-group-custom201PaymentGroupPaymentGroup {
display: block;
@include mq(l, max) {
width: 98%;
}
span {
font-size: 0 !important;
&::after {
font-family: "Open Sans";
font-weight: 400;
font-size: 14px;
line-height: 24px;
letter-spacing: -0.01em;
content: "Boleto Faturado";
@media (min-width: 2500px) {
font-style: normal;
font-weight: 400;
font-size: 28px;
line-height: 24px;
color: #58595b;
}
}
}
}
#payment-group-custom204PaymentGroupPaymentGroup {
display: block;
@include mq(l, max) {
width: 98%;
}
span {
font-size: 0 !important;
&:after {
font-family: "Open Sans";
font-weight: 400;
font-size: 14px;
line-height: 24px;
letter-spacing: -0.01em;
content: "Cartão de Débito";
@media (min-width: 2500px) {
font-style: normal;
font-weight: 400;
font-size: 28px;
line-height: 24px;
color: #58595b;
}
}
}
}
#payment-group-creditCardPaymentGroup {
display: block;
@include mq(l, max) {
width: 98%;
}
span {
background-image: none !important;
font-size: 0 !important;
text-decoration: none;
&:after {
font-family: "Open Sans";
font-weight: 400;
font-size: 14px;
line-height: 24px;
letter-spacing: -0.01em;
content: "Cartão de Crédito";
@media (min-width: 2500px) {
font-style: normal;
font-weight: 400;
font-size: 28px;
line-height: 24px;
color: #58595b;
}
}
}
}
#payment-group-bankInvoicePaymentGroup {
display: block;
@include mq(l, max) {
width: 98%;
}
span {
background-image: none !important;
font-size: 0 !important;
&:after {
font-family: "Open Sans";
font-weight: 400;
font-size: 14px;
line-height: 24px;
letter-spacing: -0.01em;
content: "Boleto à Vista";
@media (min-width: 2500px) {
font-style: normal;
font-weight: 400;
font-size: 28px;
line-height: 24px;
color: #58595b;
}
}
}
}
.payment-group-item.active {
background: rgba(220, 221, 227, 0.3);
mix-blend-mode: normal;
border: 1px solid $color-orange;
border-radius: 6px;
span {
color: $color-orange;
&:after {
color: $color-orange !important;
}
}
}
}
}
}
}
}
.PaymentCardHolderDocument {
display: block !important;
}

View File

@ -1,37 +1,104 @@
.empty-cart {
font-family: $font-family;
&-content {
margin-top: 170px;
color: $color-black;
text-align: center;
@include mq(md, max) {
padding: 0 16px;
}
.empty-cart-message {
display: none;
}
}
&-title {
font-size: 20px;
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-size: 24px;
line-height: 33px;
text-align: center;
text-transform: uppercase;
color: $color-black-000;
margin-bottom: 32px;
@include mq(dt, max) {
font-size: 18px;
line-height: 25px;
text-transform: uppercase;
margin-bottom: 22px;
}
@include mq(tv, min) {
font-weight: 700;
font-size: 48px;
line-height: 65px;
}
}
&-btn {
padding: 250px !important;
}
&-links {
.link-choose-products {
background: $color-black;
border: none;
border-radius: 5px;
background: $white;
transition: ease-in 0.22s all;
outline: none;
font-family: $font-family;
font-family: $font-family-secundary;
font-style: normal;
font-weight: 500;
color: $black;
text-align: center;
letter-spacing: 0.05em;
color: $black;
font-size: 0px;
text-transform: uppercase;
border: 1px solid #000000;
border-radius: 0%;
padding: 16px 64px 16px 65px;
height: 16px;
margin: 0;
&::after {
font-family: "Tenor Sans";
font-style: normal;
font-weight: 400;
font-size: 14px;
line-height: 16px;
text-align: center;
letter-spacing: 0.05em;
color: $color-white;
text-transform: uppercase;
content: "Continuar comprando";
}
&:hover {
background: lighten($color-black, 5);
background: $white;
}
@media screen and (max-width: 354px) {
height: 32px !important;
}
@include mq(dt, max) {
height: 16px;
padding: 16px 26px;
&::after {
font-family: "Tenor Sans";
font-style: normal;
font-weight: 400;
font-size: 14px;
line-height: 16px;
text-align: center;
text-transform: uppercase;
}
}
@include mq(tv, min) {
height: 33.52px;
padding: 16px 121px;
&::after {
font-style: normal;
font-weight: 400;
font-size: 28px;
line-height: 33px;
text-align: center;
text-transform: uppercase;
}
}
}
}

View File

@ -9,11 +9,11 @@ html {
}
footer .footerCheckout__wrapper {
width: 94.9734%;
width: 100%;
// width: 94.9734%;
margin: auto auto 0 auto;
}
footer .footerCheckout__prateleira,
header {
footer .footerCheckout__prateleira {
width: 79.53125%;
margin: 0 auto;
}
@ -49,37 +49,61 @@ body {
}
.container-order-form,
.container-cart {
//margin-top: 170px;
width: 80%;
@include mq(l, max) {
max-width: 1024px;
width: 100%;
}
}
}
.btn-success {
background: $color-black;
background: $color-black2;
padding: 15px 64px 17px 65px;
text-shadow: none;
&:hover {
background: lighten($color-black, 15%);
background: lighten($color-black2, 15%);
}
}
.emailInfo h3 {
color: $color-black !important;
color: $color-black2 !important;
}
#orderform-title {
margin-bottom: 28px !important;
}
#cart-title,
#orderform-title {
color: $color-gray2;
color: $color-black2;
font-family: $font-family;
font-weight: 500;
font-size: 36px;
line-height: 42px;
margin: 40px 0 30px;
letter-spacing: 0.1em;
height: 33px;
line-height: 33px;
margin: 17px 0 16px;
font-weight: 700;
font-size: 24px;
letter-spacing: 0.05em;
text-transform: uppercase;
@include mq(xxl, min) {
height: 65px;
font-weight: 700;
font-size: 48px;
line-height: 65px;
letter-spacing: 0.05em;
}
@include mq(md, max) {
margin-left: 30px;
}
@include mq(l, max) {
margin-left: 16px;
}
}
.dropdown {

View File

@ -18,7 +18,7 @@
position: relative;
overflow: hidden;
display: block;
margin: 0;
margin: 0 -16px;
padding: 0;
&:focus {
@ -65,6 +65,7 @@
float: left;
height: 100%;
min-height: 1px;
margin: 0 8px 56px 8px;
outline: none;
[dir="rtl"] & {
float: right;
@ -95,6 +96,9 @@
height: auto;
border: 1px solid transparent;
}
@media (max-width: 1024px) {
margin: 0px 7.5px 56px 7.5px;
}
}
.slick-arrow {
font-size: 0;
@ -104,11 +108,31 @@
background: url("https://agenciamagma.vteximg.com.br/arquivos/arrow-left-mini-M3Academy.svg")
no-repeat center center;
z-index: 4;
top: 167px;
border: none;
left: 10px;
@include mq(tv, min) {
background: url("https://agenciamagma.vteximg.com.br/arquivos/arrow-left-M3Academy.svg")
no-repeat center center;
top: 313px;
width: 26px;
height: 58px;
}
}
.slick-next {
background: url("https://agenciamagma.vteximg.com.br/arquivos/arrow-right-mini-M3Academy.svg")
no-repeat center center;
top: 167px;
z-index: 4;
border: none;
right: 10px;
@include mq(tv, min) {
background: url("https://agenciamagma.vteximg.com.br/arquivos/arrow-right-M3Academy.svg")
no-repeat center center;
top: 313px;
width: 26px;
height: 58px;
}
}
.slick-arrow.slick-hidden {
display: none;

View File

@ -1,47 +1,134 @@
/* _footer.scss */
.footerCheckout {
border-top: none;
color: $color-gray2;
margin-top: auto;
//border-top: 1px solid #000;
.container {
display: flex;
flex-direction: column;
width: 100%;
padding: 7px 0;
margin: 0;
@include mq(dt, min) {
flex-direction: row;
align-items: center;
justify-content: space-between;
padding: 15px 0 15px 0;
}
@include mq(tv, min) {
padding: 26px 0 26px 0;
}
}
&__wrapper {
align-items: center;
display: flex;
justify-content: space-between;
border-top: 1px solid $black;
@media screen and (max-width: 490px) {
padding: 7px 0;
}
}
&__address {
color: $color-gray2;
color: $gray-500;
font-family: $font-family;
font-style: normal;
font-weight: normal;
font-weight: 400;
line-height: 14px;
font-size: 10px;
line-height: 12px;
text-transform: capitalize;
max-width: 40%;
@include mq(md, max) {
margin-bottom: 24px;
max-width: 100%;
@include mq(dt, max) {
display: flex;
width: 100%;
order: 2;
margin-top: 17px;
span {
margin-left: 16px;
}
}
@include mq(dt, min) {
min-width: 269px;
margin-left: 32px;
}
@include mq(tv, min) {
font-size: 20px;
line-height: 27px;
min-width: 537px;
margin-left: 0;
}
}
&__stamps {
align-items: center;
display: flex;
justify-self: center;
height: 33px;
align-items: center;
list-style: none;
margin: 0 0 0 5px;
@include mq(md, max) {
align-self: center;
margin-bottom: 12px;
li {
height: 33px;
}
&__divider {
background-color: $color-gray4;
display: inline-block;
height: 24px;
margin: 0 8px;
width: 1px;
@include mq(dt, min) {
justify-content: center;
min-width: 404px;
margin: 0;
}
@include mq(tv, min) {
min-width: 690.52px;
}
.payments-icons-wrapper {
display: flex;
width: 100%;
list-style: none;
gap: 13.35px;
margin: 0;
@include mq(dt, max) {
gap: 4.35px;
}
figure {
padding: 6px 0 7px;
width: 35.65px;
height: 20px;
margin: 0;
@include mq(tv, min) {
width: 69.63px;
}
@include mq(Gf, max) {
width: 24px;
}
}
}
.footerCheckout__stamps__divider {
border-left: 1px solid $gray;
margin: 0 10px;
height: 33px;
padding: 0 0 9px;
@include mq(dt, min) {
margin-left: 11.35px;
}
}
.footerCheckout__vtexpci {
.vtex-icon {
width: 53px;
margin: 0;
}
@include mq(tv, min) {
.vtex-icon {
width: 103.52px;
height: 64.46px;
}
}
}
}
@ -51,18 +138,43 @@
list-style-type: none;
margin: 0;
li:last-child {
@include mq(dt, max) {
display: flex;
width: 100%;
order: 3;
margin-top: 17px;
}
@include mq(dt, min) {
min-width: 217px;
margin-right: 22.5px;
}
li {
margin-left: 16px;
figure {
margin: 0;
}
}
.vtex-icon {
width: 44.92px;
margin: 0;
}
.m3-icon {
width: 28.66px;
margin: 0;
}
a {
align-items: center;
color: $color-gray2;
color: $gray-500;
display: flex;
font-family: $font-family;
font-style: normal;
font-weight: normal;
font-size: 10px;
font-weight: 400;
font-size: 9px;
line-height: 12px;
text-decoration: none;
@ -70,5 +182,38 @@
margin-right: 8px;
}
}
@include mq(tv, min) {
min-width: 388.98px;
margin-right: 0;
a {
font-size: 18px;
line-height: 25px;
}
li {
margin-left: 10px;
}
.vtex-icon {
width: 87.73px;
}
.m3-icon {
width: 55.98px;
}
}
}
.footerCheckout::after,
::before {
display: none;
content: none;
}
.footerCheckout::before,
::after {
display: none;
content: none;
}
}

View File

@ -1,36 +1,172 @@
/* _header.scss */
.headerCheckout {
.container {
width: auto !important;
}
&__wrapper {
align-items: center;
display: flex;
justify-content: space-between;
align-items: center;
justify-content: space-around;
padding: 16px;
border-bottom: 1px solid $black;
@media (min-width: 1025px) {
padding: 33.5px 0;
}
@media (min-width: 2500px) {
padding: 33.5px 0;
}
}
.progress-bar {
display: flex;
flex-direction: column;
right: 31.5%;
top: 33%;
@media (max-width: 1024px) {
display: none;
}
@media (min-width: 2500px) {
right: 41%;
}
.containerLi {
display: flex;
position: relative;
align-items: center;
}
ul {
display: flex;
margin: 0;
gap: 100px;
list-style: none;
}
p {
margin-bottom: 0;
}
&-text {
font-family: $font-family-secundary;
font-weight: 400;
font-size: 12px;
line-height: 14px;
@media (min-width: 2500px) {
font-size: 24px;
line-height: 28px;
}
}
&-line-1,
&-line-2 {
position: absolute;
width: 171px;
top: 82%;
left: 55%;
border: 1px solid $black;
z-index: 0;
@media (min-width: 2500px) {
width: 240px;
top: 79%;
left: 55%;
}
}
&-line-2 {
width: 166px;
left: -223%;
@media (min-width: 2500px) {
width: 230px;
left: -143%;
}
}
&-circle-1,
&-circle-2,
&-circle-3 {
display: flex;
height: 10px;
width: 10px;
align-self: center;
background: $white;
border: 1px solid $black;
border-radius: 50%;
margin-left: 40%;
margin-top: 9px;
padding: 0;
@media (min-width: 2500px) {
height: 22px;
width: 22px;
}
}
.active {
background: $black;
}
}
&__logo {
width: 45.35%;
@media (min-width: 1025px) {
width: 17.059%;
}
@media (min-width: 1025px) {
width: 15.28%;
img {
height: 52px;
width: auto;
width: 100%;
}
}
@media (min-width: 2500px) {
width: 19.22%;
}
}
&__safeBuy {
span {
align-items: center;
justify-content: flex-end;
display: flex;
align-items: center;
@media (min-width: 1025px) {
width: 15.5%;
}
@media (min-width: 2500px) {
width: 20%;
}
span {
min-width: fit-content;
height: 50%;
text-transform: uppercase;
font-family: $font-family;
font-style: normal;
font-weight: normal;
font-size: 12px;
line-height: 14px;
line-height: 16px;
color: $color-gray;
margin-left: 8px;
@media (min-width: 2500px) {
font-style: normal;
font-weight: 400;
font-size: 24px;
line-height: 33px;
}
}
i {
margin-right: 8px;
img {
width: 4.5%;
min-width: 12px;
@media (min-width: 2500px) {
width: 6.1%;
}
}
}
}

View File

@ -1 +1,143 @@
/* _prateleira.scss */
.footerCheckout__prateleira {
//width: 96.88% !important;
margin: 0 132px;
//width: 100% !important;
@media (max-width: 1024px) {
width: auto !important;
margin: 0 16px;
}
}
.footerTitle {
text-align: center;
font-family: "Tenor Sans";
font-style: normal;
font-weight: 400;
font-size: 24px;
line-height: 38px;
color: $black;
margin-bottom: 20px;
@include mq(tv, min) {
font-size: 48px;
line-height: 76px;
}
}
.slick-test {
width: 100%;
gap: 16px;
margin: 0 !important;
& li {
max-width: 97.98%;
@media (max-width: 375px) {
width: 164px !important;
}
@media (max-width: 1024px) {
width: 97.86% !important;
max-width: 100%;
}
@include mq(tv, min) {
min-width: 485.07px;
}
}
}
.itemList {
@media (max-width: 375px) {
width: 164px;
}
}
.itemSku {
display: flex;
gap: 5px;
justify-content: center;
flex-wrap: wrap;
height: 26px;
& p {
background: #00c8ff;
border-radius: 8px;
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-size: 13px;
line-height: 18px;
padding: 5px;
display: flex;
align-items: center;
text-align: center;
height: 18px;
margin: 0;
letter-spacing: 0.05em;
text-transform: uppercase;
color: $white;
@include mq(tv, min) {
font-size: 26px;
line-height: 35px;
height: auto;
}
}
@media (max-width: 375px) {
height: 61px;
justify-content: center;
align-items: center;
}
@media (max-width: 1183px) {
height: 61px;
justify-content: center;
align-items: center;
}
@include mq(tv, min) {
min-height: 45px;
}
}
.productName {
font-family: "Open Sans";
font-style: normal;
font-weight: 400;
font-size: 13px;
line-height: 18px;
margin: 20px 0px;
text-align: center;
height: 18px;
color: $black;
@media (max-width: 375px) {
height: 36px;
}
@include mq(tv, min) {
height: 35px;
font-size: 26px;
line-height: 35px;
}
}
.productImg {
background: #eeeeee;
width: 100%;
}
.productLink {
background: #00c8ff;
border-radius: 8px;
font-family: "Open Sans";
font-style: normal;
font-weight: 700;
font-size: 13px;
line-height: 18px;
padding: 12px 0;
//padding: 12px 71px 12px 72px;
display: flex;
justify-content: center;
letter-spacing: 0.05em;
text-transform: uppercase;
margin: 20px 0px 0px;
color: $white;
&:hover {
color: white;
text-decoration: None;
}
@include mq(tv, min) {
font-size: 26px;
line-height: 35px;
}
}

View File

@ -2,31 +2,61 @@
@import url("https://fonts.googleapis.com/css2?family=Tenor+Sans&display=swap");
@import url("https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700;800&display=swap");
$font-family: "Open Sans", sans-serif;
$font-family-secundary:"Tenor Sans", sans-serif;
$font-family-secundary: "Tenor Sans", sans-serif;
/* Colors */
$black: #000;
$color-black-000: #000000;
$color-black: #292929;
$color-black2: #292929;
$color-white: #fff;
$color-white2: #ededed;
$white: #fff;
$gray: #c4c4c4;
$gray-200: #8d8d8d;
$gray-500: #292929;
$color-gray: #6c6c6c;
$color-gray2: #7d7d7d;
$color-gray3: #f0f0f0;
$color-gray4: #8d8d8d;
$color-gray5: #e5e5e5;
$color-gray6: #c4c4c4;
$color-gray7: #989898;
$color-gray8: #828282;
$color-gray9: #bdbdbd;
$color-gray10: #c4c4c4;
$color-gray11: #ededed;
$color-gray12: #989898;
$color-orange: #f15a31;
$color-blue: #4267b2;
$color-blue2: #00c8ff;
$color-red: #ff0000;
$color-green: #4caf50;
/* Grid breakpoints */
$grid-breakpoints: (
xs: 0,
Gf: 328px,
cstm: 400,
f: 375px,
c: 376px,
m: 491px,
sm: 576px,
md: 768px,
lg: 992px,
xl: 1200px
tb: 1024px,
dt: 1025px,
l: 1025px,
xl: 1200px,
tv: 2500px,
xxl: 2500px,
) !default;
$z-index: (
@ -34,5 +64,5 @@ $z-index: (
level2: 10,
level3: 15,
level4: 20,
level5: 25
level5: 25,
) !default;

2
package-lock.json generated
View File

@ -45,6 +45,7 @@
"jquery": "^3.6.0",
"m3-utils": "^0.1.0",
"sass": "^1.38.1",
"slick-carousel": "^1.8.1",
"terser-webpack-plugin": "^5.1.4"
},
"devDependencies": {
@ -19345,6 +19346,7 @@
"m3-utils": "^0.1.0",
"prettier": "^2.3.2",
"sass": "^1.38.1",
"slick-carousel": "^1.8.1",
"terser-webpack-plugin": "^5.1.4",
"webpack": "^5.51.1",
"webpack-merge": "^5.8.0"