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 trialPawel Ellwart
12,993 PointsIt doesn't work on Chrome and I don't know why?
5 Answers
Brian Lund
10,865 PointsHi Pawel,
I just tried your code in Chrome and it was animated for me, but just made a few adjustments so it was doing it correctly.
I added 'px' to your transform-origin:
.badge * {
transform-origin: 180px 180px;
}
Also, removed '.badge' from this line of code:
.outer,
.inner,
.inline {
animation: grow 1s ease-out backwards;
}
Hopefully this helps!
Jason Morrow
16,395 PointsRunning Chrome 68 on Win7, and it doesn't work for me. I see a little bounce in the inline elements, but it basically just shows the star, and then the rest of the animation pops in a second later. I think it is going from 0-100% with no transitions.
I have added the -webkit- tags, but still no joy. I tried coding it by following along, using the 'finish' code, and using the workspace, and I can't seem to get it working. I even tried adding a -webkit- tag and a normal declaration, and I get nothing.
So that's a thing. I am going to blow through this section for now. If anyone has a fix that works, I will come back and work through it.
Rafael silva
23,877 Pointsthis code work well, the unique thing that I made was type the badge together with outer inner e etc, and after I type the vendor -webkit- this still work . /* -------------------------- Keyframes --------------------------- */ @-webkit-keyframes grow { 0% { -webkit-transform: scale(0); } 30% { -webkit-transform: scale(1.1); } 60% { -webkit-transform: scale(0.9); } }
/* -------------------------- SVG Styles --------------------------- */
.badge * { transform-origin: 180px 180px; }
.badge, .outer, .inner, .inline { animation: grow 1s ease-out backwards; }
.inner { animation-delay: .1s; }
.inline { animation-delay: .15s; }
Jan Dudek
Front End Web Development Techdegree Student 16,350 PointsHi, I am having the same issue as mentioned above. I tried webkit prefixes, but with no luck. When I add .badge it works in Chrome, but then acts wierdly in Firefox. Anyone found other solution to this?
Rafael silva
23,877 Pointsyou can use the transform-box: fill-box; istead type tranform-origin:; , this still work too, but this is only expetimental, I tried to put this and it's work for me.
here follow the link: https://developer.mozilla.org/en-US/docs/Web/CSS/transform-box
Evans Owino
24,888 PointsHi, it definitely works - https://jsfiddle.net/vrp2ny0q/
Pawel Ellwart
12,993 PointsHmm... your're right! I have no idea why it was not working....
Eric Salvi
12,128 PointsApparently, in Chrome, I had to add the vendor prefixes to the keyframes and animation declarations. https://stackoverflow.com/questions/24806812/css-keyframes-not-working-in-chrome Then this worked for me running Chrome 65 on a Mac.
Pawel Ellwart
12,993 PointsPawel Ellwart
12,993 PointsThanks Brian for the detailed adjustments and help!