
Solution retrospective
In the mobile view, when the side menu opens, the background becomes darker.
I obtained this effect with a ::after element that gets applied to the body when the menu button is pressed (and gave the side menu and the button a higher z-index). Is this the correct way of achieving the desired affect?
Also if i wanted to add a transition (ex. make the darker background fade in and fade out), how would i do that? Do i need another class and attach it to the ::after element or i can do it all throuh js or is there other ways?
I tried but could not figure it out
Any other feedback is appreciated, thanks!
Please log in to post a comment
Log in with GitHubCommunity feedback
No feedback yet. Be the first to give feedback on tyVespA's solution.
Join 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