JQuery Plug-in Interface Animate

About Interface
Interface is a collection of rich interface components which utilizes the lightweight JavaScript library jQuery. With this components you can build rich client web applications and interfaces with the same simplicity as writing JavaScript with jQuery.
关于 Interface
Interface 以轻量级 JavaScript 工具为基础开发而来的富界面组件集合。利用他,你可以像使用 Jquery 创建 JavaScript 一样创建富界面客户端 Web 程序和界面。
Document 文档部分
Animate
Interface overwrites the default 'animate' function with an extended one. The new 'animate' function brings several enhancements:
Interface 覆盖了原有的 animate 方法,并加强了他的功能;
·        Animates a collection of properties using one timer instead of using separate timers per property
·        Handles color properties like 'backgroundColor', 'borderColor' etc.
·        Animates styles and CSS classes
使用一个计时器控制一个动画的集合,而不是分别为每一个成员属性都分配一个计时器;
像处理“ backgroundcolor ”,“ borderColor ”属性一样处理颜色属性。
使样式和 CSS 类拥有动画效果;
Code sample:
$('#test').animate(
        {
               left: 100,
               style: 'padding: 20px 30px; margin: 10px;',
               className: 'greenBorders',
               opacity: 0.4,
               backgroundColor: 'olive'
        },
        'slow'
);
Also, Interface offfers new functions to handle animations:
当然, Interface 也提供了许多新的方法处理动画;
stop
Stop an animation at any time.
使动画暂定;
Options:
gotolaststep
Boolean
optional
Whatever to go to the last step in animation
Code sample:
$('#test').stop();
stopAll
Stop current animation and clear all queued animations.
停止当前的所有动画,并清空所有等待队列中的动画;
Options:
gotolaststep
Boolean
optional
Whatever to go to the last step in current animation
Code sample:
$('#test').stopAll();
pause
Add a pause between animations. The selection is not animated till the pausing time expires.
动画播放的过程中停止动画。选中区知道暂停时间结束之前不会停止动画的播放;
Options:
speed
String|Number
optional
A string representing one of the three predefined speeds ("slow", "normal", or "fast") or the number of milliseconds to pause (e.g. 1000).
callback
Function
optional
A function to be executed whenever the pausing completes.
Code sample:
$('#test').pause(2000);

你可能感兴趣的:(JavaScript,jquery,Web,css,Go)