スタイルanimationNameプロパティ
例
<div>要素のanimationNameプロパティを変更する:
document.getElementById("myDIV").style.animationName = "myNEWmove";
定義と使用法
AnimationNameプロパティは、@ keyframesアニメーションの名前を設定または返します。
ブラウザのサポート
表の数字は、プロパティを完全にサポートする最初のブラウザバージョンを示しています。
Webkit、Moz、またはOが後に続く数字は、プレフィックスで機能した最初のバージョンを指定します。
Property | |||||
---|---|---|---|---|---|
animationName | 43.0 4.0 Webkit |
10.0 | 16.0 5.0 Moz |
9.0 4.0 Webkit |
30.0 15.0 Webkit 12.1 12.0 O |
構文
AnimationNameプロパティを返します。
object.style.animationName
AnimationNameプロパティを設定します。
object.style.animationName = "none|keyframename|initial|inherit"
プロパティ値
Value | Description |
---|---|
none | Default value. Specifies that there will be no animation (can be used to override animations coming from the cascade) |
keyframename | Specifies the name of the keyframe you want to bind to the selector |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
技術的な詳細
デフォルト値: | なし |
---|---|
戻り値: | 要素のanimation-nameプロパティを表す文字列 |
CSSバージョン | CSS3 |
関連ページ
CSSリファレンス:animation-nameプロパティ