We're looking for a user researcher to understand the needs of developers and designers. Is this you or someone you know? Check out the post: https://mzl.la/2IGzdXS

这篇翻译不完整。请帮忙从英语翻译这篇文章

这是一个实验中的功能
此功能某些浏览器尚在开发中,请参考浏览器兼容性表格以得到在不同浏览器中适合使用的前缀。由于该功能对应的标准文档可能被重新修订,所以在未来版本的浏览器中该功能的语法和行为可能随之改变。

Summary 概要

animation-iteration-count CSS 属性   定义动画在结束前运行的次数 可以是1次 无限循环.

默认属性 animation 默认播放动画循环一次.

初始值1
适用元素all elements, ::before and ::after pseudo-elements
是否是继承属性
适用媒体visual
计算值as specified
Animation typediscrete
正规顺序the unique non-ambiguous order defined by the formal grammar

Syntax

animation-iteration-count: infinite;
animation-iteration-count: 3;
animation-iteration-count: 2.3;

animation-iteration-count: 2, 0, infinite;

Values

infinite
无限循环播放动画.
<number>
动画播放的次数 不可为负值. 可以用小数定义循环(0.5 将播放动画到关键帧的一半(from 0 ~ 50%).

Formal syntax 

<single-animation-iteration-count>#

where
<single-animation-iteration-count> = infinite | <number>

Examples

去看 CSS animations for examples. 点击链接去看栗(例)子

Specifications 说明 用法

Specification Status Comment
CSS Animations
animation-iteration-count
Working Draft Initial definition

Browser compatibility 兼容性

We're converting our compatibility data into a machine-readable JSON format. This compatibility table still uses the old format, because we haven't yet converted the data it contains. Find out how you can help!

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit)
Basic support (Yes)-webkit
43.0
5.0 (5.0)-moz
16.0 (16.0)
10  12 -o
12.10
4.0-webkit
Feature Android Chrome Firefox Mobile (Gecko) IE Phone Opera Mobile Safari Mobile Chrome for Android
Basic support (Yes)-webkit ? 5.0 (5.0)-moz
16.0 (16.0)
? ? ? 43.0
 

See also

文档标签和贡献者

此页面的贡献者: SilenMark, seven-lh
最后编辑者: SilenMark,