Triangles – part 2: Stars

Now that we know how triangles work, lets see something fun: stars! I started with three triangles to create a five-pointed star. HTML: <div class=”star”> <div class=”star-body”></div> <div class=”star-left”></div> <div class=”star-right”></div> </div> I adjusted the length of the sides of the triangle by changing the border-width property. The top border being longer and the right/left […]

Triangles

Today we are going to take a quick look at CSS triangles. They can be used for various visual elements. Menu indicators, speech bubbles, and so much more. Plus, they are so cute and really fun to play with!   This is the goal object, a little purple CSS triangle: First I started by setting […]