jQuery SsrTimeline Helper
for Superscrollorama

CreateTween and Pin methods support

s

s

r

T

i

m

e

l

i

n

e

Documentation

function ssrTimeline(anims, controller, settings);
@anims: [] Array of animations
   @animation: {
       type: {String} TweenMax method (fromTo, to, from, etc.)
       loopDelay: {Number} specific parameter to ssrTimeline, will add a
                  progressive delay for each targetted elements
       options: {Array} [selector, duration, params] Params for TweenMax method,
                selector will be restrained to parent $(selector, parent) where
                parent is the element which ssrTimeline was called $(parent).ssrTimeline();
   }
   @controller: superscrollorama controller instance ($.superscrollorama({}))
   @settings: {
       pin: {Number} This param will call $ssr.pin method instead of $ssr.addTween
       duration: {Number} duration of the animation in pixels
       offset: {Number} offset of the animation in pixels
   }
$('.documentation').ssrTimeline([
    {
        type: 'fromTo',
        loopDelay
        options: ['code', .5, {
            css: { x: -150, opacity: 0 }
        }, {
            css: { x: 0, opacity: 1 }
        }]
    }
]);
github.com/baptooo/ssrTimeline