A hexagon badge
Du skriver inn
- Form
- hexagon
Du får
- CSS
- .my-element { clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%); }
The six pairs of numbers are the corners of the hexagon, written as percentages of the element's width and height. They start at the top left corner of the flat top edge and go clockwise.
Kjørt med verktøyets egen kode.