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 Unused CSS Stages Transitions and Transforms Transitions - WebKit Only

Alexander Fisher
Alexander Fisher
4,943 Points

Transitions Part 2: Create a border-radius transition for box, with 2s duration, 1s delay, and linear timing function

Create a border-radius transition for box, with 2s duration, 1s delay, and linear timing function.

I believe I have all the right code, but I may have them in the wrong areas, could anyone help me with this?

.box { border-radius: 15px; background: #4682B4; transition-delay: 1s; }

.box:hover { background: #F08080; border-radius: 50%; transition-property: border-radius; transition-timing-function: linear; transition-duration: 2s; }

2 Answers

Jonathan Grieve
MOD
Jonathan Grieve
Treehouse Moderator 91,253 Points

I believe you need to include transition duration values in both the original and the hover state of your box element,

So something like this,

.box { border-radius: 15px;  transition-duration: 2s; background: #4682B4; transition-delay: 1s; }

.box:hover { background: #F08080; border-radius: 50%; transition-property: border-radius; transition-timing-function: linear; transition-duration: 2s; }
Brian Becker
Brian Becker
11,023 Points

Here we are!

.box {
    border-radius: 15px;
    background: #4682B4;
     -webkit-transition: border-radius 2s linear 1s;
 }

.box:hover {
    background: #F08080;
    border-radius: 50%;
}