Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Card Product em HTML e CSS

@freitas-anderson

Desktop design screenshot for the Product preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Avaliem meu desempenho.

Community feedback

@Kelf1729

Posted

Ficou ótimo cara, acho que você só esqueceu do icone de carrinho de compras do lado do texto do botão mas fora isso ficou ótimo. Uma dúvida, o preço maior verde e o menor em cinza você deixou eles lado a lado nivelado como? usou um display flex nos dois e depois um align-items: center? Parabéns, continue assim.

Marked as helpful

0

@lucaspicinini

Posted

Você pode usar o pseudo elemento ::before pra acrescentar o svg com a imagem do carrinho antes do botao "Add to Cart":

botaoaddtocart::before {
content: ""; /*essa propriedade é usada com os pseudoelementos ::before e ::after para gerar conteúdo em um elemento*/
background-image: url("../images/icon-cart.svg");
width: 15px; /*defina o tamanho do ícone*/
height: 15px; 
/*depois que a imagem aparecer é só usar outras declarações de formatação que você preferir para posicioná-la melhor.*/

Marked as helpful

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join our Discord community

Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!

Join our Discord