Skip to content

Update data for Document.getAnimations() - #6061

Merged
Elchi3 merged 3 commits into
mdn:masterfrom
lpd-au:document-getanimations
May 4, 2020
Merged

Elchi3 merged 3 commits into
mdn:masterfrom
lpd-au:document-getanimations

Conversation

@lpd-au

@lpd-au lpd-au commented May 1, 2020

Copy link
Copy Markdown
Contributor

This pull request updates the data for DocumentOrShadowRoot.getAnimations(). Please note that this is a different entry but similar function to Element.getAnimations().

For now, I'm not moving the data from api.Document to api.DocumentOrShadowRoot. This seems like something that should be done later by someone who can also move the page on MDN.

This feature used to exist as AnimationTimeline.getAnimationPlayers, ie on a different interface with an alternative name. This changed several details about the spec in a backwards-incompatible way, that imo isn't worth mentioning in BCD. You can read about the change here: https://lists.w3.org/Archives/Public/public-fx/2015JulSep/0073.html

Tests used are here:

Firefox & Firefox for Android

Firefox data is taken from the relevant bugs below and manual testing. The latest Android version appears to match Firefox 68 for desktop so I mirrored the data up until that release.

Web platform test results:

  • v46: broken
  • v52: 7 pass, 3 fail, 1 timeout
  • v53: 8 pass, 3 fail
  • v72: 11 pass

Relevant bugs:

Chrome & Chrome for Android

Chrome data is taken from the relevant bugs below and manual testing. The only anomaly is despite merging a fix to always flush pending style changes in the 66 branch, I still have intermittent failures until 67. The latest Android version appears to match the latest desktop version so I mirrored the data.

Web platform test results:

  • v61: 3 pass, 7 fail, 1 timeout
  • v67: 5 pass, 5 fail, 1 timeout
  • v74: 6 pass, 5 fail
  • v83: 11 pass

Relevant bugs:

Safari & Safari for iOS

Stable Safari data is taken from manual testing and Technology Preview data is taken from the Web Platform Tests Dashboard here. Unfortunately due to the limitations of browserstack and Apple's bug tracking, I can't narrow down the versions before 13 any further. The latest Technology Preview still fails two web platform tests but these seem minor to me compared to eg Safari 13.1, Chrome 81, etc, so I have marked Safari 14 as supported for the time being.

Web platform test results:

  • v10-10.1: 1 pass, 10 fail
  • v11-11.1: 1 pass, 9 fail, 1 timeout
  • v12-12.1: 6 pass, 5 fail
  • v13: 6 pass, 5 fail
  • v13.1: 6 pass, 5 fail
  • TP105: 9 pass, 2 fail

Relevant bugs:

Edge

Edge 18 does not support the web animations API at all so the Edge data is mirrored from Chrome.

Opera & Opera for Android

Mirrored from Chrome and Chrome for Android. I verified Opera 69 data manually since its engine version data in BCD is out of date.

@ghost ghost added the data:api Compatibility data for Web API features. https://developer.mozilla.org/docs/Web/API label May 1, 2020
@lpd-au

lpd-au commented May 1, 2020

Copy link
Copy Markdown
Contributor Author

@birtles and @graouts you may be good reviewers for the Firefox and Safari data here respectively :)

@birtles birtles left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Firefox data looks correct to me. Thanks for the detailed research!

The firefox_android data should be the same as the desktop data however. I suspect it's simply that we haven't shipped a release version of Firefox for Android based on Gecko 75 yet but any of the recent Firefox Preview builds (which are based on Gecko 75 or later) will ship getAnimations().

@birtles

birtles commented May 2, 2020

Copy link
Copy Markdown
Contributor

Relevant bugs:

* Previous implementation: https://bugzilla.mozilla.org/show_bug.cgi?id=1150810

* Basic + css animation support: https://bugzilla.mozilla.org/show_bug.cgi?id=1212720

* Returns pseudo-element animations: https://bugzilla.mozilla.org/show_bug.cgi?id=1234403

* Rename pref: https://bugzilla.mozilla.org/show_bug.cgi?id=1471814

* Supported on ShadowRoot: https://bugzilla.mozilla.org/show_bug.cgi?id=1590971

* Shipped: https://bugzilla.mozilla.org/show_bug.cgi?id=1619821

This is amazing research!

@lpd-au

lpd-au commented May 2, 2020

Copy link
Copy Markdown
Contributor Author

The firefox_android data should be the same as the desktop data however. I suspect it's simply that we haven't shipped a release version of Firefox for Android based on Gecko 75 yet but any of the recent Firefox Preview builds (which are based on Gecko 75 or later) will ship getAnimations().

It's not a decision I'd take personally, but afaik BCD doesn't accept Firefox Preview data, only regular Firefox for Android data which is stuck on the 68 ESR branch.

@birtles

birtles commented May 2, 2020

Copy link
Copy Markdown
Contributor

In that case whar you have seems perfect!

@Elchi3 Elchi3 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is amazing research! Thanks so much @lpd-au and thanks for the review @birtles 🎉

@Elchi3
Elchi3 merged commit 12d83c4 into mdn:master May 4, 2020
@lpd-au
lpd-au deleted the document-getanimations branch May 4, 2020 10:17
@graouts

graouts commented May 6, 2020

Copy link
Copy Markdown

@lpd-au Would you mind detailing what the remaining failures you saw in STP 105?

@lpd-au

lpd-au commented May 6, 2020 •

Copy link
Copy Markdown
Contributor Author

Would you mind detailing what the remaining failures you saw in STP 105?

@graouts According to the Web Platform Tests Dashboard, the following tests are still failing:

  • Document.getAnimations() returns animations on elements inside same-origin iframes
  • iframe.contentDocument.getAnimations() returns animations on elements inside same-origin Document

Compared to the previous version, it did cause three tests to start passing:

  • ShadowRoot.getAnimations() return all animations in the shadow tree
  • Document.getAnimations() does NOT return animations in shadow trees
  • ShadowRoot.getAnimations() does NOT return animations in parent document

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

data:api Compatibility data for Web API features. https://developer.mozilla.org/docs/Web/API

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants