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

[Feature policy: animations] What does "blocking" an animation mean? #12

Open
birtles opened this issue Aug 20, 2018 · 2 comments
Open

Comments

@birtles
Copy link

birtles commented Aug 20, 2018

  • Do blocked animations still dispatch events?
  • Does calling Element.animate() with a disallowed property throw?
  • If an animation specifies both allowed and disallowed properties, do the allowed ones still run?
@ehsan-karamad
Copy link

Thanks for the issue. A blocked animation is expected to still run but at a very reduced sampling/interpolation rate. From the explainer

... These properties are "animated" by simply jumping from the initial to the final value at the midpoint of the animation.

so potentially the behavior could be an abrupt transition to the final state (perhaps in the middle or at the end of the interval).

Do blocked animations still dispatch events?

Yes, they should; and the behind-the-flag implementation on Chrome seems to support that as expected. In tested this on a demo page here by listening to the animationiteration event.

If an animation specifies both allowed and disallowed properties, do the allowed ones still run?

Good point...maybe just disallow the whole animation (in favor of a more consistent and potentially simpler implementation).

@birtles
Copy link
Author

birtles commented Aug 21, 2018

... These properties are "animated" by simply jumping from the initial to the final value at the midpoint of the animation.

That sentence is in the context of describing how properties with an animation type of "discrete" currently animate. It doesn't define how "blocked" animations are expected to work with this policy.

ehsan-karamad referenced this issue in ehsan-karamad/feature-policy Aug 23, 2018
Revised the animations policy to propose a modified policy that blocks layout inducing animations as opposed to the non-composited animations.

The changed is motivated discussions in issues #202, #203, and #204.
clelland referenced this issue in w3c/webappsec-permissions-policy Sep 20, 2018
Revised the animations policy to propose a modified policy that blocks layout inducing animations as opposed to the non-composited animations.

The changed is motivated discussions in issues #202, #203, and #204.
@clelland clelland transferred this issue from w3c/webappsec-permissions-policy Dec 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants