Design comparison
SolutionDesign
Solution retrospective
I'have no idea how to implement the triangle in the corner of the menu of the mobile version
Community feedback
- @vitorp4Posted over 2 years ago
For the triangle you can use ::before pseudo-element on the container, using display absolute to positioning it on the top right corner. And for achieve the shape you can use clip-path CSS property clip-path: polygon(100% 0, 100% 100%, 0 100%).
0 - @alosoftPosted over 2 years ago
@AndresHense You can the triangle by using the border property
create a element
<div class="shape"></div>
add css.shape{ border-bottom: 100px solid green; border-left: 100px solid transparent; }
then give it a fixed position
position: fixed
to the top left corner of the mobile menu0
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