Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[css-animation-worklet] The steps of registerAnimator mix types in a weird way #908

Open
bzbarsky opened this issue Jun 27, 2019 · 3 comments
Assignees
Labels
css-animationworklet-1 CSS AnimationWorklet API

Comments

@bzbarsky
Copy link

https://drafts.css-houdini.org/css-animationworklet-1/#dom-animationworkletglobalscope-registeranimator step 5 does:

If SameValue(prototype, StatelessAnimator)

where prototype is the .prototype property of the constructor that was passed in, and StatelessAnimator is ... what exactly? It links to the interface definition. Does it mean the interface object? The interface prototype object? Something that has the interface prototype object on its prototype chain (i.e. checking that the passed-in thing is a subclass of StatelessAnimator)? Something else?

I suspect it means the subclass thing, but that's totally not what it says.

@majido
Copy link
Contributor

majido commented Jun 27, 2019

You suspicion is correct. The intention was to verify "subclassing". I had trouble writing the spec text to do this correctly even after looking and other specs that meant to do similar thing. I have captured the difficulty in issue #850 and the fact that our current approach for using IsSameValue is incorrect.

In the most recent Houdini F2F heycam@ suggested a way we can spec this. But more importantly we resolved to drop these two superclasses anyways so we don't need to check the inheritance chain.

I have not made the changes to the specification yet but Blink implementation does match the most recent resolution (i.e., do not check the superclass). I will edit the spec based on most recent resolution which should also bring Blink implementation in line with the specification.

@bzbarsky
Copy link
Author

Thank you, I'll take another look once the spec updates happen.

@majido
Copy link
Contributor

majido commented Oct 22, 2019

I believe this is fixed by 48d9fe4

We no longer check the prototype of the stateless and stateful animator.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
css-animationworklet-1 CSS AnimationWorklet API
Projects
None yet
Development

No branches or pull requests

2 participants