figureone
    Preparing search index...

    Rotation animation step

    The rotation animation step animates the first Rotation transform in the FigureElement's Transform.

    By default, the rotation will start with the element's current rotation.

    Use either delta or target to define it's end point

    To test examples, append them to the boilerplate

    // Using duration
    p.animations.new()
    .rotation({ target: Math.PI, duration: 2 })
    .start();
    // Using velocity
    p.animations.new()
    .rotation({ target: Math.PI, velocity: Math.PI / 2 })
    .start();
    // Different ways to create a stand-alone step
    const step1 = p.animations.rotation({ target: Math.PI, duration: 2 });
    const step2 = new Fig.Animation.RotationAnimationStep({
    element: p,
    target: 0,
    duration: 2,
    });

    p.animations.new()
    .then(step1)
    .then(step2)
    .start();

    Hierarchy (View Summary)

    Index

    Methods