Re: [csswg-drafts] [scroll-animations-1] Interaction with 'animation-iteration-count' (#8233)

The experimental implementation in Blink currently factors in animation-iteration-count when determining the intrinsic-iteration-duration.   Since effect end is 100% and equal to start delay + end delay + iteration count * iteration duration, we can calculate a duration that makes the end time match up when using duration auto.  Similarly if specifying a time-based iteration duration we can compute the end time and then scale/normalize accordingly to make it align to 100%.  This normalization is useful for example if setting the animation timeline to convert a time-based to a scroll-based animation.

The infinite iteration count implies that iteration-duration is zero.  At present, the spec  handles 0 duration * infinite count by resolving the product to be zero (https://www.w3.org/TR/web-animations-1/#calculating-the-active-duration).  Though using infinite iterations with a scroll-linked animation is not particularly useful, we can at least define sensible behavior.  In this case, the animation collapses to zero active duration. 


-- 
GitHub Notification of comment by kevers-google
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8233#issuecomment-1375890456 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Monday, 9 January 2023 16:14:57 UTC