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

I Must Be Missing Something on This Code Challenge...

Most of the time I can scan what I've written when it doesn't work and tell immediately what i've done wrong... Usually its a missed semi-colon, colon, comma, or some other syntax error... An easy fix. In this case on this code challenge I really can't tell what it is exactly that I am doing wrong... Almost think the code editors broke though I know that's unlikely... Unless they are just looking for the shorthand...

The code challenge question is:

"Using the prefix for WebKit-based browsers, create a transition for the border-radius property of '.box'. Give the transition a duration of 2 seconds, a delay of 1 second, and a timing function that maintains a linear motion."

My answer is:

.box { border-radius: 15px; background: #4682B4; }

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

}

All I see it asking for is the border-radius transition, a 2 second duration, a 1 second delay, and a linear timing function. Am I missing something? Anyone see anything off on my syntax? I ran it a couple of times but it says that there is an error... been looking at it and I can't figure out what the error is. I'll try the shorthand but if any of you see something wrong please let me know. Of course it could just be that I'm tired:) I'll check it out with fresh eyes tomorrow.

Thanks!

3 Answers

Oh boy chuckles you're gonna kick yourself. Rather than spoil it, have a quick think about where you need to place the code to describe a transition.

And yeah, shorthand will work just fine too.

Rhys Park
Rhys Park
8,323 Points

You really are going to kick yourself :P

.box { border-radius: 15px; background: #4682B4; 
*// Maybe Something should go here ? //*
}

lol... Yeah. I was nearly seeing double last night.My mistake...haha. Thanks guys:)