Design comparison
Solution retrospective
What do you think about my code?
How can I improve my coding skills?
Please give feedback!
Community feedback
- @hyrongennikePosted about 2 years ago
Hi,
Nice job on desktop mobile still needs a bit of work. You can the following media query to stack the sections.
@media (max-width: 640px) { .card { grid-template-columns: 1fr; max-width: 375px; margin: 2rem; } img.img { height: 300px; object-fit: cover; } }
Also change the
height: 100vh
tomin-height: 100vh
to prevent overflow. Hope this is helpful.1@aatifsohelPosted about 2 years ago@hyrongennike Thank you for the feedback!
I tried what you've said, but for some reason it causes horizontal overflow and the card itself not fitting inside the view? How can I resolve it?
0@hyrongennikePosted about 2 years ago@aatifsohel The above media query should not cause overflow as a max-width is being used I would suggesting using the developer tools see if some of you rules are overwriting it you would then have to make the media query selector more specific.
.picture { width: 100%; height: auto; }
you can also add the above in that media query. Let me know if it still doesn't work
Marked as helpful0
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