Intent to Prototype: Display and content-visibility animations

134 views
Skip to first unread message

Robert Flack

unread,
Dec 2, 2022, 11:05:21 AM12/2/22
to blink-dev

Contact emails

fla...@chromium.org

Explainer

https://github.com/w3c/csswg-drafts/issues/6429#issuecomment-1318933547

Specification



Summary

Support specifying display and content-visibility in animations. This support allows for developers to create exit animations after which the element automatically becomes display: none or content-visibility: hidden without needing to write any javascript to handle that switch after the animation is finished. This allows exit animations for elements to be added purely in CSS.



Blink component

Blink>Animation

Motivation

It has long been an ergonomic challenge that to animate the removal of some content you had to have a listener clean up the element after the animation finished. Also several new browser features such as <dialog> and popover implicitly switch to display none when they close. Being able to extend the non-none display in a CSS animation or transition allows for easy ergonomic exit animations without adding JS listeners.



Initial public proposal

https://github.com/w3c/csswg-drafts/issues/6429#issuecomment-1318933547

TAG review



TAG review status

Pending

Risks



Interoperability and Compatibility

Developers may have display specified in existing animations which would start being included in their animation after this change.



Gecko: No signal

WebKit: No signal

Web developers: Positive (https://front-end.social/@mia/109433817951030826)

Other signals:

Security

This doesn't extend developer capabilities beyond styles the developer could set via existing CSS or scripts.



WebView application risks

Does this intent deprecate or change behavior of existing APIs, such that it has potentially high risk for Android WebView-based applications?



Debuggability

This feature extends the capabilities of existing css animations, css transitions and web animations and will show amongst other developer animations.



Is this feature fully tested by web-platform-tests?

No

Flag name



Requires code in //chrome?

False

Tracking bug

https://bugs.chromium.org/p/chromium/issues/detail?id=1395394

Estimated milestones

No milestones specified



Link to entry on the Chrome Platform Status

https://chromestatus.com/feature/5154958272364544

This intent message was generated by Chrome Platform Status.

Reply all
Reply to author
Forward
0 new messages