Functiondojo.NodeList.anim

dojo.require("dojo.NodeList-fx");
defined in dojo/NodeList-fx.js

Animate one or more CSS properties for all nodes in this list. The returned animation object will already be playing when it is returned. See the docs for dojo.anim for full details.

Usage

function (/*Object*/ properties, /*Integer?*/ duration, /*Function?*/ easing, /*Function?*/ onEnd, /*Integer?*/ delay) (view source)
parametertypedescription
propertiesObjectthe properties to animate
durationIntegerOptional. Optional. The time to run the animations for
easingFunctionOptional. Optional. The easing function to use.
onEndFunctionOptional. A function to be called when the animation ends
delayIntegerOptional. how long to delay playing the returned animation

Examples

Example 1

Another way to fade out:

dojo.query(".thinger").anim({ opacity: 0 });

Example 2

animate all elements with the "thigner" class to a width of 500 pixels over half a second

dojo.query(".thinger").anim({ width: 500 }, 700);