
Design comparison
Community feedback
- P@Lo-DeckPosted 4 months ago
Hi well done for this challenge,
You can use picture tag to display different image depending on the size. Here a link : MDN.
<picture> <source media="(max-width: 799px)" srcset="your path" > <source media="(min-width: 800px)" srcset="your path" > <img src="your path" alt="your description" > </picture>
And if want to blend different element there is this property which can help you, MDN.
Hope to be helpful.
Marked as helpful1 - P@RahexxPosted 4 months ago
Great job with this challenge! Here is some feedback from me:
Website
- Your website looks great and is close to the design, but for the screen width range of 600px - 800px, it doesn't look ideal. If you could target 768px, it might work better.
HTML
- There is an empty
alt
tag in yourimg
tag. This will cause issues for users with screen readers, as they won't know what is in the image. This is an accessibility concern. - Great use of the BEM methodology! The class names are on point, clean, and readable, so props for that.
CSS
- Great naming of your CSS variables! I immediately understand their purpose.
- If you wanted to make the image closer to the design, you can add a
::before
pseudo-element to the section, hover over the entire section, and apply the backgroundaccent
color with some opacity change. This will give you a similar effect to the design. You could also use thefilter
property: CSS filter. - The 600px breakpoint seems to have been set a bit too early. You could consider a more gradual transition for the range between 600px and 800px. In these challenges, you get both desktop and mobile designs, so feel free to experiment with a design that works well between those ranges.
- Using CSS Grid was okay, but I would suggest using Flexbox when positioning elements on a single axis. Of course, you can use whichever method suits you better, but this advice is especially useful for more complicated projects.
- Your styles are clean and readable.
Good work! You've made quite a lot of progress. Good luck with the next challenge!
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