Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Can someone explain the practical usage of diagonal CSS borders?


Sure: making geometric shapes and masks.

A varient of diagonal borders is currently used in http://nicolasgallagher.com/pure-css-speech-bubbles/demo/

The trick there is to use the CSS :after pseudo-element to get a triangular shape/mask, but it's a bit of a hack. Having diagonal CSS borders that were properly supported would make doing stuff like this much cleaner and easier to implement.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: