I came across an interesting JSAPI today over at BernieCode.com that handles animation by essentially providing a tweening algorithm that will animate a layer based upon a starting and ending CSS declaration.
The Animator.js library currently requires prototype.js library. It's definitely an interesting approach and allows you to create some really dynamic animations w/very little work. I mean all you need to do is create some CSS that specifies the starting styles and ending styles.
Definitely make sure to check out the examples.