{"action":"opened","issue":{"url":"https://api.github.com/repos/w3c/csswg-drafts/issues/2266","repository_url":"https://api.github.com/repos/w3c/csswg-drafts","labels_url":"https://api.github.com/repos/w3c/csswg-drafts/issues/2266/labels{/name}","comments_url":"https://api.github.com/repos/w3c/csswg-drafts/issues/2266/comments","events_url":"https://api.github.com/repos/w3c/csswg-drafts/issues/2266/events","html_url":"https://github.com/w3c/csswg-drafts/issues/2266","id":294010370,"number":2266,"title":"[web-animations] Setting `playbackRate` should probably do a compensatory seek after all","user":{"login":"birtles","id":1232595,"avatar_url":"https://avatars1.githubusercontent.com/u/1232595?v=4","gravatar_id":"","url":"https://api.github.com/users/birtles","html_url":"https://github.com/birtles","followers_url":"https://api.github.com/users/birtles/followers","following_url":"https://api.github.com/users/birtles/following{/other_user}","gists_url":"https://api.github.com/users/birtles/gists{/gist_id}","starred_url":"https://api.github.com/users/birtles/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/birtles/subscriptions","organizations_url":"https://api.github.com/users/birtles/orgs","repos_url":"https://api.github.com/users/birtles/repos","events_url":"https://api.github.com/users/birtles/events{/privacy}","received_events_url":"https://api.github.com/users/birtles/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-02-02T20:15:59Z","updated_at":"2018-02-02T20:15:59Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"In writing the last few tests for the asynchronous playback rate changes (#2059) I noticed an oddity:\r\n\r\n```js\r\nconst animation = div.animate(...);\r\nanimation.currentTime = 100 * 1000;\r\nawait animation.ready;\r\nanimation.playbackRate = 2;\r\n// animation.currentTime =~ 200 * 1000;\r\n```\r\n\r\nHowever:\r\n\r\n```js\r\nconst animation = div.animate(...);\r\nanimation.currentTime = 100 * 1000;\r\nanimation.playbackRate = 2;\r\n// animation.currentTime =~ 100 * 1000;\r\n```\r\n\r\nThe reason is that in the first example the current time is calculated from the start time so changing the playback rate makes it jump. In the second example the current time is calculated from the hold time (the start time is unresolved at this point) so updating the playback rate does not effect the current time.\r\n\r\nThat inconsistency seems really undesirable. I suspect we want to make setting the playback rate do a compensatory seek after all. That means that doing `anim.playbackRate = 2` and `anim.updatePlaybackRate(2)` are quite close in behavior and authors may accidentally doing the former when they really want the latter but I can't think of anything better. We could just make `playbackRate` read-only but that's likely to break content."}}
{"actor":{"display_login":"birtles"}}