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

Profile card component using flexbox

@henrikkudesu

Desktop design screenshot for the Profile card component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Solution retrospective


I learned that I should avoid manually setting the height of the elements, as it can break the responsiveness of the website. But I had a little problem: there's a big gap between the profile picture and the name that I couldn't figure out how to resolve.

Community feedback

@mixchex

Posted

Hi Leonardo,

This is a great effort and very close to looking just like the design.

That space you've found has been caused by your transform property. By using this, the space has been left, but if you use a negative margin-top it will help move the lower content up at the same time.

I hope this resolves your issue. Great work.

Mike

Marked as helpful

1

@henrikkudesu

Posted

@mixchex Yeaaah, it worked. Now is looking the very same as the original project. Thank you!

0

@mixchex

Posted

@henrikkudesu Great to hear and glad it worked.

1
Hassia Issah 50,670

@Hassiai

Posted

To center .profile-card on the page using flexbox, replace the height in the main with min-height: 100vh.

Use the colors that were given in the styleguide.md found in the zip folder you downloaded.

For a responsive content, replace the width in .profile-card with max-width.

Give . personal-info a fixed margin-top and bottom value, instead of margin: auto; margin: 16px 0; and add a text align-center to it.

Use relative units like rem or em as unit for the padding, margin, width values and preferably rem for the font-size values, instead of using px which is an absolute unit. For more on CSS units Click here

Hope am helpful.

Well done for completing this challenge. HAPPY CODING

Marked as helpful

1

@henrikkudesu

Posted

@Hassiai Thank you for your tips. I've done these adjustments and worked fine!

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