Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

Tom Bedford
Tom Bedford
15,645 Points

CSS Heart

Happy Valentine's Day

Guil's recent thread on making a triangle with CSS made me think about the possibilities of CSS shapes made with a single div. I thought this would be appropriate for today!

It's made from one div with :before and :after pseudo elements, you can see the code here.

I'm sure this isn't new at all, but it was fun to make!

3 Answers

A fun thing to do with that is to put it on a key frame loop that adjusts its scaling and box shadow.

James Eden
James Eden
1,539 Points

This is brilliant! I didn't think it would be possible... I'd like to ask a general question about this but I'm new to the forum; and Treehouse. Is there a way I can reference this post/topic directly in a new forum thread?

Thanks!

Tom Bedford
Tom Bedford
15,645 Points

You can make links in topics (or any other url) with the following code:

[text to link](http://www.example.com)

To link to this thread you could do:

[wow look at tom's heart](https://teamtreehouse.com/forum/css-heart)

James Eden
James Eden
1,539 Points

Cheers Tom. I'll give it a go.

J