MCPcopy
hub / github.com/greensock/GSAP / _elapsedCycleDuration

Function _elapsedCycleDuration

esm/gsap-core.js:364–366  ·  view source on GitHub ↗
(animation)

Source from the content-addressed store, hash-verified

362 return !animation || animation._ts && _hasNoPausedAncestors(animation.parent);
363},
364 _elapsedCycleDuration = function _elapsedCycleDuration(animation) {
365 return animation._repeat ? _animationCycle(animation._tTime, animation = animation.duration() + animation._rDelay) * animation : 0;
366},
367 // feed in the totalTime and cycleDuration and it'll return the cycle (iteration minus 1) and if the playhead is exactly at the very END, it will NOT bump up to the next cycle.
368_animationCycle = function _animationCycle(tTime, cycleDuration) {
369 var whole = Math.floor(tTime = _roundPrecise(tTime / cycleDuration));

Callers 1

gsap-core.jsFile · 0.70

Calls 2

durationMethod · 0.80
_animationCycleFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…