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

3-column-preview-card-component using Flex

@TaskinSultana

Desktop design screenshot for the 3-column preview card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


This is my first time doing a challenge, and I absolutely love it! I have faced many width and height issue in flexbox...Need some solutions for it....and I'd be greatfull if you can give me some feedbacks to improve 🙏

Community feedback

Lucas 👾 104,420

@correlucas

Posted

👾Hello @TaskinSultana, Congratulations on completing this challenge!

I saw your solution preview site and I think it's already really good. Here’s some tips for you to improve it:

Improve your html markup using meaningful tags to wrap the content, you can replace the div you’ve used for each card with <article>. Remember to wrap big blocks of content with semantic tags and never divs, use divs for small blocks. Your solution seems fine, you did a really good job wrapping the content for these 3 cards. Something you can improve here is to use a single class to manage the content that is mostly the same for the 3 cards (paddings, colors, margins and etc) and another class to manage the characteristics that are different (colors and icon), this way you'll have more control over then and if you need to change something you modify only one class.

✌️ I hope this helps you and happy coding!

Marked as helpful

0

@TaskinSultana

Posted

@correlucas Thank you :)

0
Hyron 5,870

@hyrongennike

Posted

Hi,

Congratulations on completing the challenge

Height issue are most likely being caused by the min-height you set.

.flex {
    min-height: 70vh; 
}

remove the above declaration and the height issue will go away. Because you set a min-height the child elements stretched to the height of the parent which is the default for flexblos.

To center the columns or any card in the middle of the page add the following.

body {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

Hope this is helpful

Marked as helpful

0

@TaskinSultana

Posted

@hyrongennike Thank you so much :)

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