W3C home > Mailing lists > Public > www-style@w3.org > January 2016

Re: [css3-transitions] Should transition-property: color cause transitions on other properties using currentColor?

From: Daniel Glazman <daniel.glazman@disruptive-innovations.com>
Date: Fri, 8 Jan 2016 18:52:00 +0100
To: www-style@w3.org
Message-ID: <967beee1-c26e-a940-975b-0fbd941e7e7e@disruptive-innovations.com>
On 08/01/2016 18:21, Daniel Tan wrote:

> [1]: https://jsfiddle.net/kpk5debr/
>     div {
>       color: cyan;
>       border: 10px solid;
>       transition: color 3s;
>     }
>     div:hover {
>       color: magenta;
>     }

Excellent question, indeed.
I would rather ask what is the CSS author's intent and the result
seen from the user's perspective? In your case above, the text color
transitions from cyan to magenta in 3s but the border color switches
immediately on hover, right? But the CSS author did specify, in the
stylesheet, that the border color is the current color...  This seems
wrong to me. The author still has the possibility to make the border
switch immediately specifying a color in the border shorthand.
My personal inclination would be to make currentColor transition in 3s
as well.

My 0.02€ only....

Received on Friday, 8 January 2016 17:52:31 UTC

This archive was generated by hypermail 2.4.0 : Monday, 23 January 2023 02:14:56 UTC