develop #1

Merged
SabrinaMiranda merged 24 commits from develop into main 2022-12-19 02:38:03 +00:00
Showing only changes of commit a5030d653b - Show all commits

View File

@ -7,9 +7,10 @@ export default class Footer {
async init() {
await this.selectors();
this.PaymentsIconsHTML();
this.VtexPciIconHTML();
this.paymentsIconsHTML();
this.vtexPciIconHTML();
this.developedByLogoHTML();
this.temptyCartTextBtn();
// this.onUpdate();
}
@ -20,9 +21,10 @@ export default class Footer {
this.payments = await waitElement(".footerCheckout__payments");
this.vtexPCI = await waitElement(".footerCheckout__vtexpci");
this.developedBy = await waitElement(".footerCheckout__developedBy");
this.textBtn = await waitElement("#cart-choose-products");
}
PaymentsIconsHTML() {
paymentsIconsHTML() {
if (this.payments) {
this.payments.innerHTML = `
<picture class="payments-icons">
@ -38,7 +40,7 @@ export default class Footer {
}
}
VtexPciIconHTML() {
vtexPciIconHTML() {
if (this.vtexPCI) {
this.vtexPCI.innerHTML = `
<picture class="vtexpci-icon">
@ -72,6 +74,12 @@ export default class Footer {
}
}
temptyCartTextBtn() {
if (this.textBtn) {
this.textBtn.textContent = "Continuar comprando";
}
}
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