Home>Article>Web Front-end> Can css3 only implement animation once?

Can css3 only implement animation once?

WBOY
WBOY Original
2022-03-29 16:11:39 1822browse

css3 can not only implement animation once; you can use the "animation-iteration-count" attribute to define the number of animation playback times. When the attribute value is set to infinite, the number of playback times is unlimited, and the syntax is "animation- iteration-count:play count".

Can css3 only implement animation once?

The operating environment of this tutorial: Windows 10 system, CSS3&&HTML5 version, Dell G3 computer.

css3 can only achieve one animation

css3 can only achieve one animation.

Just use animation-iteration-count.

The animation-iteration-count property defines how many times the animation should play. The default value is one.

Syntax

animation-iteration-count: value;
  • n A number that defines how many times the animation should be played

  • infinite Specifies that the animation should be played an infinite number of times ( Forever)

Examples are as follows:

   123  

注意: Internet Explorer 9 及更早 IE 版本浏览器不支持 animation-iteration-count 属性。

Output results:

Can css3 only implement animation once?

(Learning video sharing:css video tutorial)

The above is the detailed content of Can css3 only implement animation once?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn