Bug 184087

Summary: Negative animation-delay isn't picked before an animation has started
Product: WebKit Reporter: Matias N <matias.niemela>
Component: AnimationsAssignee: Nobody <webkit-unassigned>
Status: RESOLVED INVALID    
Severity: Normal CC: dino, graouts, graouts, jonlee, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   

Description Matias N 2018-03-28 08:58:46 PDT
In addition to the problems with Webkit Negative Animation Delays...
https://bugs.webkit.org/show_bug.cgi?id=141008
https://bugs.webkit.org/show_bug.cgi?id=26150

It would be very helpful is Webkit (Safari in this case) would allow itself to change the negative delay value as much as needed before an animation starts.

Chrome/Firefox allow for this and in turn you can basically scrub a @keyframes animation.

```
// file: index.js

// assign a keyframe to an element
var ANIMATION_DURATION = 1000;
element.style.setProperty('animation', 'myKeyframe ' + ANIMATION_DURATION);

// pause the video before it kicks off
element.style.setProperty('animation-play-state', 'paused');

// change the delay based on some <input type="range"> input

// rangeInput = <input type="range" min="0" max="1" step="0.01">
rangeInput.addEventListener('input', function(e) {

  // this DOES NOT work in Webkit/Safari (Chrome and Firefox are good).
  element.style.setProperty('animation-delay', this.value * ANIMATION_DURATION);
});


```
Comment 1 Radar WebKit Bug Importer 2018-03-28 09:14:28 PDT
<rdar://problem/38958794>
Comment 2 Antoine Quint 2023-05-10 11:46:02 PDT
This bug is not actionable without a test case. I will thus resolve it as INVALID. But I'm fairly confident that whatever may have been wrong here has been fixed in the years since this was filed due to the comprehensive rewrite of the animation code in WebKit to implement Web Animations. If you find this to not be so, please reopen this bug and attach a test case.