How to Create a Slanted Edge Effect With Simple CSS Tricks

preview_player
Показать описание
Someone in the Bricks group asked how to create this slanted edge effect. Since it's not super intuitive, I decided to make a tutorial and include a bunch of little pro nuggets as well for better maintainability and scalability.

Enjoy!

*** MY TOOLS ***

*** INNER CIRCLE ***

Step your design/dev game up, make more money, and get the full scoop on scaling your digital agency! When it comes to the Inner Circle, I don't hold back.

⭕ In-depth design & dev trainings
⭕ Business, sales, & marketing trainings
⭕ Agency resources & downloadables
⭕ Vibrant, quality community with zero toxicity
⭕ ...and much more!

*** SOCIAL ***

*** CHAPTERS ***
Рекомендации по теме
Комментарии
Автор

3 trainings in one day, Kevin is BACK! 🔥

odinaka_joshua
Автор

First time watching your tutorials, Kevin. Great stuff, brother. Keep going 💪

MJSWP
Автор

Just brilliant Kevin. Really appreciate you doing these classes

chrisgreen
Автор

Thanks for the great video as always, Kevin! Especially loved the pacing on that one -- not too fast, not too slow, just the right tempo.

bluetheredpanda
Автор

Fantastic stuff: so much information in 20 minutes. Thanks!

bartderuyck
Автор

Great solution for more intricate clip-paths and border designs! I've used this for a "ribbon" effect previously.

This "corner cut" can be solved a bit easier using a normal border on the card, a clip-path, and a pseudo-element line rotated to the corner. This also removes the "limitations" you mentioned, so you can use a gradient or background image on the parent section.

I made a simple CodePen showing the results (posted on the original Bricks question).

jolmstead
Автор

Love this video Kevin - very helpful. I vote for more videos like these! Easy to search and digest to add skills for us. Thanks for all the awesome content. PS> ACSS and Frames owner - very helpful tools and they just keep getting better with age and updates.

kickinapps
Автор

Awesome. Can you please do a follow-up > What if I use border-radius on the card > how to achieve same border-radius on the corners of the slant?🙏🙏🙏

deafdogdesign
Автор

The turn around on this was staggeringly impressive, with so many nugs. Bonus nugget for me is making sure I put more thought into answers I give to people. :P

justinsideris
Автор

Brilliant! Welcome back, Kevin! I missed you!

LupusDesign
Автор

Great explanation. I can always count on you to make complex topics easy to understand.

davidwalls
Автор

Great practical use of pseudo-elements and clip-path. ¿How should I do to add another element to have another shape in the opposite corner of the edge to include a number or an icon inside. Specially the issues regarding negative margin?

osvaldoodon
Автор

Nice effect, thank you Kevin for these CSS tricks 👍

eucalyptech
Автор

Chef's Kiss for sure on this one! 😘

davidnickson
Автор

Peace! Awesome... Thank you very much Kevin.

emadhosen
Автор

a classic geary css firestorm of gold nugs. thanks for sharing

brendanoconnell
Автор

Quod Erat Demonstrandum! Outstanding and broken down into bite size chunks. Quite technical, but easy to understand. What's next?

dahunsi
Автор

How about just using border and adding an SVG shape positioned at the top-right that covers the undesired parts of the border and adds the desired slanting border?

haroonqraja
Автор

This is appreciated. Thanks. You a star

YasienSarlie
Автор

tokenized sashimi. you are indeed bonkers nutz. however, completely logical. in 1997, this is the way we did borders. there was no css. there were no borders. we had tables. we had backgrounds. crazy good knowledge here. back to the basics. pay attention folks, this man knows what is up.

jamorahcito