Design comparison
SolutionDesign
Solution retrospective
- Switch from background-image to <img> because it was quite a nightmare to set a white border radius for the QR code image...
Community feedback
- @HassiaiPosted almost 2 years ago
Give .qr a padding value for all the sides, there is no need to style .qr--code. Giver img a max-width of 100% instead of a height value. give .qr--information a padding value for all the side and give h1 a margin bottom value or p a margin top value.
.qr{padding: 1rem;} img{max-width:100%} .qr--ingromation{ padding: 1rem:} p{margin-top: 1rem;}
Hope am helpful.
Well done for completing this challenge. HAPPY CODING
Marked as helpful1@omirasPosted almost 2 years ago@Hassiai I implemented your suggestions: I find it's cleaner and easier code than mine.
To be honest I was not completely ok using height for the image. Thank you very much for your comment!
1
Please log in to post a comment
Log in with GitHubJoin 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