AnimationEvent: elapsedTime プロパティ

Baseline Widely available

This feature is well established and works across many devices and browser versions. It’s been available across browsers since September 2015.

AnimationEvent.elapsedTime は読み取り専用のプロパティで、アニメーションが開始されてからの秒数を float 型で表します。このイベントが発生したとき、アニメーションが停止した場合を除いて常に設定されます。 animationstart イベントにおいては elapsedTime0.0 になりますが、 animation-delay が負の値の場合は、このイベントは elapsedTime(-1 * 待ち時間 ) であるときに発生します。

float 型で、時間の量を秒単位で指定します。

仕様書

Specification
CSS Animations Level 1
# dom-animationevent-elapsedtime

ブラウザーの互換性

Report problems with this compatibility data on GitHub
desktopmobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
elapsedTime

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support

関連情報