Design comparison
Solution retrospective
Hi everyone! 👋 This one took me quite a lot of time because of the overlay which I still haven't managed to get done 🥵 So if you could tell me what to change or what it wrong I would really appreciate it! Also if you have any other suggestions, please let me know. Thanks 🙌 Aneta
Community feedback
- @rsrclabPosted almost 3 years ago
Hi, @anetaanette ~
Congratulate on your solution to the challenge on FM platform. I have studied your work carefully and learned a lot from it.
Here are some of the tips I like to provide.
- On smaller devices, card goes over screen, and I think
max-width: 100%
can solve this issue. - Please try BEM for naming element classes. It will help you a lot on bigger projects.
- Section elements must have at least one heading inside.
- About image overlay,
position: absolute;
will be a great help.
https://www.frontendmentor.io/solutions/my-first-solution-on-chanllenge-V-4IzAivH
Here is my solution to this challenge, and if it can help you even a bit, it would be happy to me.
Cheers ~
Marked as helpful0@anetaanettePosted almost 3 years agoHi @tymren608 Thanks for spending some time on my code. I will keep those things in mind. Concerning image overlay, where exactly should I add the absolute position? Thanks again
0@rsrclabPosted almost 3 years agoHi, @anetaanette ~ You can check my code to find that part. But what I can say here is
- Add overlay on the same level with image, and add
position: relative
to parent,position: absolute
to overlay div. - Set position to fit current image size.
- First, set opacity as 0, and after hover, set it to 1.
This is vague steps. Cheers~
Marked as helpful0 - On smaller devices, card goes over screen, and I think
- @SaraGadAlMawlaPosted almost 3 years ago
Check these two sources out, they have helped me:
1- https://www.w3schools.com/howto/tryit.asp?filename=tryhow_css_image_overlay_opacity 2- https://www.youtube.com/watch?v=XEhR_EfKI7o
Good luck!
Marked as helpful0 - @slothmast3rPosted almost 3 years ago
Hej Aneta! Widzę że nieźle się napracowałaś nad tym czelendżem xd i całkiem nieźle ci poszło. Widzę że już kolega Tymur ci już pomógł, więc mam nadzieje, że uda ci się dokończyć czelendż i to cię zmotywuje do jeszcze większych przygód z frontendem :D
Jeśli potrzebujesz jeszcze jakieś pomocy to śmiało możesz pytać.
0@anetaanettePosted almost 3 years agoHej @slothmast3r . Niestety dalej nie działa :( Zrobiłam wszystko tak, jak kolega powiedział. Zerkniesz na mój kod i powiesz co jest nie tak?
0@slothmast3rPosted almost 3 years ago@anetaanette Polecam poczytać trochę o pseudo-klasach W skrócie korzystasz z
.container:hover {...}
przez to zmieniasz styl klasy.container
a nie docelowego.overlay
I tak przy okazji żeby zaoszczędzić czas stylując polecam ze skorzystania z narzędzi deweloperskich w przeglądarce0
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