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 section using only CSS flexbox

@Al-lien

Desktop design screenshot for the Four card feature section coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


Hi ! This one was cool to work on Next time i'm going to try to make it more responsive to screen size changes, any tips ?

Thanks

Community feedback

Vanza Setia 27,795

@vanzasetia

Posted

Excellent work on this challenge, Alexis! Your solution looks great! 👏

For responsiveness, I highly recommend writing the styling using the mobile-first approach. It often leads to shorter and better performance code. Also, mobile users won't be required to process all of the desktop styles.

Use single class selectors for styling whenever possible instead of id. id has high specificity which can lead to a lot of issues on the larger project. Also, it's best to keep the CSS specificity as low and flat as possible. 😉

I recommend swapping the header element inside the main element with a div. It may cause confusion for users of assistive technology (even though it has no corresponding role).

"Reliable, efficient delivery powered by technology" should be wrapped by a single element. This way, it would be read by the screen reader as one sentence which in my opinion makes more sense than as a separate sentence. So, I recommend wrapping it with one h1 element.

I hope this information is useful! Keep up the excellent work! 👍

Marked as helpful

1

@Al-lien

Posted

@vanzasetia

Hello Vanza,

Thanks a lot for taking this much time to help me, I really appreciate

So you recommend that I write the css files for mobile first, then use media queries for desktop ?

"Reliable, efficient delivery powered by technology" , should I use <span> inside <h1> to modify the font style ?

I’m going to follow all your advice and change my code

Once again, thanks so much for your feedback See ya !

0
Vanza Setia 27,795

@vanzasetia

Posted

@Al-lien No problem! 👍

Yes, start writing the styling for the mobile layout first and then use media queries to style larger screen sizes.

Yes, use span to style the text.

Good luck!

Marked as helpful

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