JqueryUI: Effects – Switch Class

Syntax:

.switchClass( removeClassName, addClassName [, duration ] [, easing ] [, complete ] )
ParameterTypeDescription
removeClassNameStringOne or more class names (space separated) to be removed from the class attribute of each matched element.
addClassNameStringOne or more class names (space separated) to be added to the class attribute of each matched element.
duration
Number or StringOptionally provides one of slow, normal, fast, or the duration of the effect in milliseconds. If omitted, the animate() method determines the default. Its default value is 400.
easingStringA string indicating which easing function to use for the transition. Its default value is swing.
completeFuction()This is a callback method called for each element when the effect is complete for this element.

OR

.switchClass( removeClassName, addClassName [, options ] )
ParameterTypeDescription
removeClassNameStringOne or more class names (space separated) to be removed from the class attribute of each matched element.
addClassNameStringOne or more class names (space separated) to be added to the class attribute of each matched element.
optionsNumber or StringAll animation settings. All properties are optional. Possible values are:
duration − A string or number determining how long the animation will run.. Its default value is 400.
easing − A string indicating which easing function to use for the transition. Its default value is swing.
complete − This is a callback method called for each element when the effect is complete for this element.
children − This is a Boolean and represents whether the animation should additionally be applied to all descendants of the matched elements.
queue − This is of type String/Boolean indicating whether to place the animation in the effects queue.

Leave a Reply

Your email address will not be published. Required fields are marked *