Fx. Style.js

Contains Fx.Style

Author

Valerio Proietti, http://mad4milk.net

License

MIT-style license.

Summary
Fx. Style.jsContains Fx.Style
Fx. StyleThe Style effect; Extends Fx.Base, inherits all its properties.
Properties
hideSame as Fx.Base.set (0)
startdisplays the transition to the value/values passed in
ElementCustom class to allow all of its methods to be used with any DOM element via the dollar function $.
Properties
effectApplies an Fx.Style to the Element; This a shortcut for Fx.Style.

Fx. Style

The Style effect; Extends Fx.Base, inherits all its properties.  Used to transition any css property from one value to another.  Includes colors.  Colors must be in hex format.

Arguments

elthe $(element) to apply the style transition to
propertythe property to transition
optionsthe Fx.Base options (see: Fx.Base)

Example

var marginChange = new Fx.Style('myElement', 'margin-top', {duration:500});
marginChange.start(10, 100);
Summary
Properties
hideSame as Fx.Base.set (0)
startdisplays the transition to the value/values passed in

Properties

hide

Same as Fx.Base.set (0)

start

displays the transition to the value/values passed in

Example

var var marginChange = new Fx.Style('myElement', 'margin-top', {duration:500});
marginChange.start(10); //tries to read current margin top value and goes from current to 10

Element

Custom class to allow all of its methods to be used with any DOM element via the dollar function $.

Summary
Properties
effectApplies an Fx.Style to the Element; This a shortcut for Fx.Style.

Properties

effect

Applies an Fx.Style to the Element; This a shortcut for Fx.Style.

Example

var myEffect = $('myElement').effect('height', {duration: 1000, transition: Fx.Transitions.linear});
myEffect.start(10, 100);
Base class for the Mootools Effects (Moo.Fx) library.
The Style effect; Extends Fx.Base, inherits all its properties.
Immediately sets the value with no transition.
function $(el)
returns the element passed in with all the Element prototypes applied.