Get help. Give help. A Web Design and Development Community.

Set css animation name with Sass variable? (mixin)

  • # June 4, 2012 at 12:02 am

    yo yo,

    im trying this:

    =hello($thename, $c_1)
    @-webkit-keyframes $thename
    color: #fff
    left: -200%
    color: $c_1
    left: auto

    +hello(one, $c_1)

    and im getting this:

    @-webkit-keyframes $thename {
    0% { color: white; left: -200%; }
    100% { color: #0080ff; left: auto; } }

    is it not possible to assign an animation name with a variable in a mixin?

    # June 4, 2012 at 12:09 am

    This reply has been reported for inappropriate content.

    nevermind…figured it out. I did this:

    @-webkit-keyframes #{$thename}
Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.

We have a pretty good* newsletter.