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 card feature

Simone 170

@Giulo25

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

T
Grace 29,490

@grace-snow

Posted

Hello

This looks good

Here are some small suggestions:

/* style.css | https://giulo25.github.io/Four-card-feature-section/style.css */

main {
  /* padding: 8rem 16rem; */
  padding: 1rem;
}

.text {
  /* max-width: 50rem; */
  max-width: 50ch;
  note: good to put max width in ch for text content like this where the purpose is to prevent line length getting too long for readability
}

.cards {
  /* grid-template-rows: 1fr 1fr; */
  /* max-width: 120rem; */
  grid-template-rows: auto;
  max-width: 100rem; // or whatever the grid max width should be
  margin: auto;
}

.img img {
  note: decorative images should have empty alt value;
  note: img in html should have width and height attributes for better performance;
}

Marked as helpful

0

Simone 170

@Giulo25

Posted

@grace-snow

Hi Grace, thanks for your feedback. I didn't understand why I have to set padding 1rem in the main. With padding 1rem it's different from the design.

I set vertical padding 8rem now and it looks ok to me.

0
T
Grace 29,490

@grace-snow

Posted

@Giulo25 ah I also removed the 62.5% html font size hack as I hate introducing potential accessibility issues like that

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