Design comparison
Solution retrospective
I faced dificulty while setting the layout and one thing that troubled me was how to change image when a media query is triggered
Community feedback
- @solracssPosted over 1 year ago
https://fedmentor.dev/posts/html-plan-product-preview/
Check here where Grace expained
<picture>
tag for image.0 - @Aimal-125Posted over 1 year ago
You can change image when media query is triggered by setting the desktop image to: display : none; When mobile media query is triggered. And you can change mobile image to: display : none; When desktop media query is triggered. For example:- .desktop-img { display: block; } .mobile-img { display: none; } @media screen and (max-width: 1100px) { .desktop-img { display: none; } .mobile-img { display: block; } }
0
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