refactor: removendo arquivos do componente InstallmentProduct

This commit is contained in:
Ana Carolina Duarte Cavalcante 2023-02-06 18:46:22 -03:00
parent 9459e48d97
commit 348a4a0981
3 changed files with 0 additions and 37 deletions

View File

@ -1,3 +0,0 @@
import InstallmentProduct from "./components/InstallmentProduct/InstallmentProduct";
export default InstallmentProduct;

View File

@ -1,27 +0,0 @@
import React from "react";
import { useProduct } from "vtex.product-context";
import styles from "./styles.css";
const InstallmentProduct = () => {
const product = useProduct();
const productWithInstallments = {
numberOfInstallments:
product?.selectedItem?.sellers[0].commertialOffer.Installments[3]
.NumberOfInstallments,
value:
product?.selectedItem?.sellers[0].commertialOffer.Installments[3].Value,
};
return (
<p className={styles.PriceContent}>
<span style={{fontWeight: "700"}}>{productWithInstallments.numberOfInstallments}x&nbsp;</span>
de&nbsp;
<span style={{fontWeight: "700"}}>
R$&nbsp;
{productWithInstallments.value?.toFixed(2).toString().replace(".", ",")}
</span>{" "}
sem juros
</p>
);
};
export default InstallmentProduct;

View File

@ -1,7 +0,0 @@
.PriceContent {
margin: 0;
font-weight: 400;
font-size: 16px;
line-height: 22px;
color: #929292;
}