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

Four cards feature section

StevenGermanā€¢ 100

@StevenGerman

Desktop design screenshot for the Four card feature section coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Community feedback

@VCarames

Posted

Hey @StevenGerman, some suggestions to improve you code:

Using CSS Grid with Grid-Template-Areas will make things way easier when building the layout. Not only will it reduce the amount of code needed but it will give you full control of the layout.

.card-container {
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(2, 1fr);
    grid-template-areas:
      "supervisor team calculator"
      "supervisor karma calculator";
  }

  .karma-card {
    grid-area: karma;
  }

  .calculator-card {
    grid-area: calculator;
    align-self: center;
  }

  .team-card {
    grid-area: team;
  }

  .supervisor-card {
    grid-area: supervisor;
    align-self: center;
  }

Happy Coding! šŸ‘»šŸŽƒ

Marked as helpful

0
Phoenix243ā€¢ 310

@PhoenixMputu

Posted

Sorry if my English is not correct, I am French -speaking. Very good solutions, but the mobile version is not centered. In the mobile version you did not resize your columns and positions your cards to be centered. You were satisfied with a margin: Auto, which is not a good idea. You could also make it simple with the flexbox. And also uses sematic tags and the BEM convention.

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