- From: Axel D. via GitHub <sysbot+gh@w3.org>
- Date: Sun, 17 May 2020 00:28:20 +0000
- To: public-css-archive@w3.org
SetTrend has just created a new issue for https://github.com/w3c/csswg-drafts:
== [css-transitions]/[css-animations] Have auto be a valid value for transitions and animations ==
Currently, transitions and animations don't work when either the start or the end value is `auto` (see sample below and [JSFiddle sample](https://jsfiddle.net/0r8o9k1z/2/) for steps to reproduce). But `auto` is a value often required for standard layout.
I propose to have CSS Transitions and Animations explicitly accept `auto` as a valid value for transitions and animation key frames.
Applications are supposed to utilize the computed value of a property declared as `auto` for transitioning and animation.
<hr/>
```html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Transition-Test</title>
<style type="text/css">
body
{
font: 12px sans-serif;
color: #334;
}
h1
{
font-size: 130%;
}
div
{
border: 2px solid #caa;
background-color: antiquewhite;
padding: 1em;
margin: 2em auto;
width: 80%;
transition: height 1s;
}
div:hover
{
height: 2em !important;
}
div.manual
{
height: 1.2em;
}
</style>
</head>
<body>
<h1>Use the mouse pointer to hover over any of the two DIVs below to see the transition effect:</h1>
<div class="auto">CSS height value: auto</div>
<div class="manual">CSS height value explicitly set</div>
</body>
</html>
```
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5076 using your GitHub account
Received on Sunday, 17 May 2020 00:28:22 UTC