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-challenge

Calixx 30

@calixmnt

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

P

@Islandstone89

Posted

Hello, good job on this challenge!

Here are some suggestions for an even better solution - I hope they help :)

HTML:

  • The alt text must also say where it leads(the frontendmentor website). A good alt text would be "QR code leading to the Frontend Mentor website."

CSS:

  • Including a CSS Reset at the top is good practice.

  • Since Outfit is a sans-serif font ,change font-family: "Outfit", serif; to font-family: "Outfit", sans-serif;

  • I recommend adding a bit of padding, for example 16px, on the body, to ensure the card doesn't touch the edges on small screens.

  • I would move the styles on .main to body.

  • Remove the margin on the card, as it is already centered using Flexbox.

  • Remove width and min-width on the card. Instead, give it a max-width of 20rem, so it doesn't get too wide on larger screens.

  • On the image, add display: block and change width to max-width: 100% - the max-width prevents it from overflowing its container. Without this, an image would overflow if its intrinsic size is wider than the container. max-width: 100% makes the image shrink to fit inside its container.

Marked as helpful

1

Calixx 30

@calixmnt

Posted

thanks a lot for your suggestions they help me @Islandstone89

1

@Toye-dev

Posted

Hello @calixmnt,

Great job completing the challenge. The solution is significantly close to the design.

However, I'll like to suggest that the border-radius: 10px; increased to about border-radius:14px could make the solution even look better.

Happy coding!

1

Calixx 30

@calixmnt

Posted

thanks a lot @Toye-dev

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