Design comparison
Solution retrospective
Hey guys,
Here is my solution. On desktop sizes, I used position: absolute to place the cards. If there are any better ways of doing it please let me know.
As always appreciate any feedback.
Community feedback
- @correlucasPosted about 2 years ago
👾Hello Marko Djurdjevic, Congratulations on completing this challenge!
🎨 Here are some tips to improve your component design:
1.Improve the card's overall look by adding the rounded borders to the component and also the image using
border-radius: 15px
2.The box-shadow is a bit too strong, this is due the
opacity
andblur
. The secret to create a perfect and smooth shadow is to have low values foropacity
and increaseblur
try this value instead:box-shadow: 12px 7px 20px 6px rgb(57 75 84 / 8%);
. If you’re not familiar to box-shadow you can use this site to create the shadow design and then just drop the code into the CSS: https://html-css-js.com/css/generator/box-shadow/3.Its really nice that you’ve used some animation and effects! Something to improve the accessibility its to add a media query reducing the motion.The prefers-reduced-motion CSS media feature is used to detect if the user has requested that the system minimize the amount of non-essential motion it uses. Here’s the code for that:
/* Remove all animations, transitions and smooth scroll for people that prefer not to see them */ @media (prefers-reduced-motion: reduce) { html:focus-within { scroll-behavior: auto; } *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; } }
✌️ I hope this helps you and happy coding!
Marked as helpful0@FrozennnPosted about 2 years ago@correlucas Hey,
Thank you, great suggestions! :)
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