8 Replies Latest reply on Dec 12, 2012 9:13 PM by heathrowe

    radial gradient - how to program color change?

    resdesign Adobe Community Professional & MVP

      I have to make an animation about nuclear fusion in the Sun and I need to change the color of the proton as it becomes a neutron. Since it is changing one gradient to another, how can I do that?


      My original gradient is:

      var proton = sym.$('proton ');

      proton .css({background: '-moz-radial-gradient(center, ellipse cover, #ffffff 0%, #A8A6CE 41%, #7c01fb 100%)'});

      The second gradient is:

      proton.css({background: '-moz-radial-gradient(center, ellipse cover, #fffcfc 0%, #a677ce 41%, #7f21d1 58%)'});