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

Single price grid component

Mate 350

@Surgetin

Desktop design screenshot for the Single price grid component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I have no clue why my bottom section is not centered equally.. Any suggestion is deeply appreciated :)

Community feedback

Kaasfeetje 190

@Kaasfeetje

Posted

Instead of using 'grid-columns:2;' on your container use 'grid-template-columns: 1fr 1fr;'. This makes it so both columns are the same size.

Marked as helpful

1
P
Luciano Lima 1,290

@LucianoDLima

Posted

Good job on finishing the project!

You can center them equally by using grid-template-columns instead of just grid-columns. Then you can use the fr unit. So if you swap your grid-columns: 2 for grid-template-columns: 1fr 1fr you'll see that each section will take half if that makes sense.

Happy coding

Marked as helpful

1
Mate 350

@Surgetin

Posted

Oh I see now, thank you guys. :) I updated so it seems good now :)

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