在相同的TimelineMax时间轴中,如何在补间中指定`repeat`?

时间:2015-09-09 04:09:36

标签: javascript greensock tweenmax gsap

我对 GSAP ' s TimelineMax有疑问。我有一个时间轴和一些动画。

如何在TimelineMax实例内的补间上指定重复,同时仍能继续使用剩余的动画。

以下是我的代码。如果我为$inputicon设置动画,它将无限循环,其他动画不会继续。

var sloganAnimation = new TimelineMax();
sloganAnimation.addLabel('textEffect')
    .staggerFromTo($slogan.find('span'), 0.01,
        { display: 'none' },
        { display: 'inline-block' }, 0.03, 'textEffect')
    .staggerFromTo($inputicon, 0.8,
        { autoAlpha: 0, repeat: -1 },
        { autoAlpha: 1, repeat: -1 }, 0.8, 'textEffect')
    .fromTo($('.quote-side'), .3, { height: 0 }, { height: 145 })
    .from('.blocker', .8, { autoAlpha: 0, y: -20, ease: Power3.easeOut });

0 个答案:

没有答案
相关问题