Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

CSS Unused CSS Stages CSS Animations Keyframe Rules and Animation Properties

Sharina V. Jones
Sharina V. Jones
11,459 Points

FireFox prefix extensions

Hi all,

I'm using Firefox 25 on my computer. I'm trying to using the keyframe animations but I can't get them to work.

I've tried adding the -moz prefix to the repeating-linear-gradient, animation-name, and animation duration properties, as well as the @keyframe property but all I get is a screen with a blank box. Please help.

Here's my code:

body {
    background: #303030;
    font: 1.1em sans-serif;
}
.wrap {
    box-sizing: border-box;
    margin: 70px auto;
    padding: 5px;
    width: 600px;
    border-radius: 10px;
    background: #222;
    box-shadow: inset 0 0 1px rgba(0,0,0,.6), 0 1px 0 rgba(255,255,255,.1);
}
.prog-bar {
    height: 60px;
    border-radius: 5px;
    background: -moz-repeating-linear-gradient(-45deg, rgba(255,255,255,.1), rgba(255,255,255,0) 12px), -webkit-linear-gradient(#F5A8A8, #F08080);

  -moz-animation-name: slide;
  -moz-animation-duration: 2s;
} 

/*  Keyframes
------------------------------------------ */
@-moz-keyframe slide {
  from {width: 0%;}
  to {width: 100%;}
}

6 Answers

I fixed it for you. You start with CSS added but end with only the backticks to close. Still close though!

no prob

Sharina V. Jones
Sharina V. Jones
11,459 Points

And I figured it out. I forgot to add the prefix to the other gradient in the background property.

You're on the right track to get your code to show up in the question, but you're just missing the CSS part. (```CSS) <--without the parentheses