Design comparison
Solution retrospective
Definitely still struggling with the sizing issue. Feedback welcome!
Community feedback
- @eby-coderPosted about 2 years ago
Hi Ramita. Congrats on completing this challenge. A simple way of dealing with your sizing issue is to set the width of the card.
.qr-code { width: 400px; }
As you have already set the image width to 100%, reducing the width of the card would also make the image width to reduce.
You should also remove the
height: 400px;
that you set for the image in your HTML file as this would increase the image size.In addition, to further reduce the image size, you can increase the padding of the card:
.qr-code { width: 400px padding: 20px; }
These should solve the problems you're having with the image size. I hope this is helpful.
Marked as helpful1 - @dreyfus92Posted about 2 years ago
If you don't want the image to grow as much you should start by setting a width of the container also a height so you can play with measures, e.g try giving the container a width of 230px, and height of auto.
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