dd

CSS3 animation-delay 属性


实例

等待两秒,然后开始动画:

animation-delay:2s;
-webkit-animation-delay:2s; /* Safari and Chrome */
运行一下 »
在此页底部有更多的例子。

浏览器支持

Internet ExplorerFirefoxOperaGoogle ChromeSafari

Internet Explorer 10, Firefox, 和 Opera都支持animation-delay 属性.

Safari和Chrome通过私有属性-WebKit-animation-delay支持。.

注意: Internet Explorer 9及更早IE版本不支持animation-delay 属性。.

标签定义及使用说明

animation-delay 属性定义动画什么时候开始。

animation-delay 值单位可以是秒(s)或毫秒(ms)。

提示: 允许负值,-2s 使动画马上开始,但跳过 2 秒进入动画。

默认值:0
继承:no
版本:CSS3
JavaScript 语法:object object.style.animationDelay="2s"

语法

animation-delay: time;


描述测试
time可选。定义动画开始前等待的时间,以秒或毫秒计。默认值为0实例 »

在线实例

实例

负值,请注意动画跳过 2 秒进入动画周期:

animation-delay: -2s /* W3C and Opera */
-moz-animation-delay: -2s /* Firefox */
-webkit-animation-delay: -2s /* Safari and Chrome */
运行一下 »