W3C home > Mailing lists > Public > public-css-archive@w3.org > July 2021

Re: [csswg-drafts] [css-display] Why is display listed as not animatable instead of animation type: discrete? (#6429)

From: Robert Flack via GitHub <sysbot+gh@w3.org>
Date: Wed, 07 Jul 2021 15:47:38 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-875717214-1625672857-sysbot+gh@w3.org>
`display` does affect animations in the same way as animation properties. Specifically from https://www.w3.org/TR/css-animations-1/#animations

> Setting the display property to none will terminate any running animation applied to the element and its descendants. If an element has a display of none, updating display to a value other than none will start all animations applied to the element by the animation-name property, as well as all animations applied to descendants with display other than none.

This means that if a CSS animation animated to `display: none` it would immediately cancel the animation, losing the `display: none` which would restart the animation.

-- 
GitHub Notification of comment by flackr
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/6429#issuecomment-875717214 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Wednesday, 7 July 2021 15:54:49 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:42:39 UTC