Not Found
Request path contains unescaped characters
Request path contains unescaped characters
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

I use flex-box and grid

@TkDevk

Desktop design screenshot for the Order summary component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Hi lads, well this time i tried something different. I set it up the width and height with vw and vh, also i sue grid to set the elements in the change part. I checked the output in 1280px width, 800px height, tbh i don't like how it looks i'm still struggling with the output but i guess i need to keep practicing.

Community feedback

@tenze21

Posted

woah... it looks like your order summary component has a lot of work to do. Everything is falling out of place.

0

@TkDevk

Posted

I just checked it and the image looks apart :'c, damn.

I guess that it doesn't matter the default width and height values

0

@Blackpachamame

Posted

@TkDevk This is because you put a height with vh, so it will change depending on each screen, on some it will look good and on others it won't. I tried setting a height: 580px to your #card and it looks fine.

Also, remove the object-fit: contain from your #card-picture img. And the height: 25svh of your #card-picture. This is enough for the image to fit the width of the card.

Marked as helpful

1

@TkDevk

Posted

@Blackpachamame Hi marcos, thank you for your feedback. You are right, i don't the height value for the image.

But i have a question regarding the css units, what do you think that is the better choice when it comes to design something like a card could be better vh or px? i was doing this thing moving numbers with VH but it doesn't look as good as PX, i would like to say that is better px but maybe if you can advise me about the units i will be grateful.

0

@Blackpachamame

Posted

@TkDevk Es buena pregunta, voy a responderte con lo que vi y leí en algún lado y por experiencia propia.

  • El vh se usa para cuando necesitas "jugar" con el viewport de la pantalla, por ejemplo, que en la pantalla se vea una imagen en específico y al scrollear hacia abajo veamos otra imagen distinta y así sucesivamente. Normalmente lo usamos para centrar el contenido del body
  • Los px (Unidades absolutas) por lo general se usan para medidas muy pequeñas, por ejemplo, los border o los border-raidus
  • Los % se usan para las fuentes
  • Por otro lado, los em y rem (Unidades relativas) suelen usarse para el resto porque se adaptan mucho mejor a los cambios en la pantalla que los px

Pero esto es a mi parecer, para profundizar en el tema tendrás que investigar y probar por tu cuenta. Igual te dejo este artículo por ahí te sirve.

Marked as helpful

2

@TkDevk

Posted

@Blackpachamame gracias man 🤗

1

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