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

Css transform code

For some reason the following code doesn't work.

transform: translateY(100%);

The exercise tells me to move the element up by 100% of its original position but when I submit it says "make sure you are putting in the correct value for translateY "

Bogdan Cabaj
Bogdan Cabaj
16,348 Points

Without code snippet or a link to workspaces it's hard to guess but maybe you should try TranslateX instead.

I'm on my phone can't give you guys a link

Just stay here for like 17 hours and I'll be back k?

/* overlay and img transitions ---------- */

.overlay,
img  {
    transition: transform .6s ease-out;
}

/* overlay and img transforms ---------- */

.photo:hover .overlay {
   transform: translated(100%);
}
.photo:hover img {

}

course: css transitions Stage: 1 Challenge: to make .photo:hover .overlay go up 100% when hovered over

1 Answer

Bogdan Cabaj
Bogdan Cabaj
16,348 Points

HI,

It's asking to move the element UP. When it's 100% it's going to go down. When you use negative value of -100% it's going to go UP. Also, in your code you have translated not translateY

It worked! Thanks a lot!