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

qr-code-component-main

Michał 110

@xXkosziarzXx

Desktop design screenshot for the QR code component coding challenge

This is a solution for...

  • HTML
  • CSS
1newbie
View challenge

Design comparison


SolutionDesign

Community feedback

Lucas 👾 104,420

@correlucas

Posted

👾Hello Michal, congratulations for your solution!

I saw that you've tried to align this component with margins, but was a little bit tricky, my advice for you is to use instead flexbox.

I did some fixes to the body and main in order to align, see how you can align it below:

body {
    background-color: hsl(220, 15%, 55%);
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    /* max-width: 1440px; */
    /* min-height: 100vh; */
    min-height: 100vh;
    /* padding: 0; */
    /* margin: 0 auto; */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

main {
    display: flex;
    align-items: center;
    justify-content: center;
}

Hope it helps, happy coding!

Marked as helpful

1

Michał 110

@xXkosziarzXx

Posted

@correlucas already corrected thank you very much thanks to you i understand "flex" more

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