- From: François REMY <francois.remy.dev@outlook.com>
- Date: Thu, 17 Apr 2014 17:54:20 +0200
- To: "CSS WG" <www-style@w3.org>
Hi, Just figured out I would have liked to have “cascade” today in the following case: button { background: #aaa; color: black; } button:hover { background: orange; color: white; } <!-- this button won't become orange on hover :( --> <button style="background: red; color: white;">...</button><!-- or #button_id { ... } --> vs :hover { background: var(--hover-background, cascade); color: var(--hover-color, cascade); } button { background: #aaa; --hover-background: orange; color: black; --hover-color: white; } <!-- it will work :-) --> <button style="background: red; color: white;">...</button><!-- or #button_id { ... } --> That's it, this is just for the record and possible later references -- except if you have comments of course! François ______________________ PS: Yes, I know, I can maybe use "button:hover" and accept only "--hover-background" for buttons, for which I know what the fallback should be, but that's maybe not the most elegant option, or is it? What if I don't want to change the background if no hover-background was specified?
Received on Thursday, 17 April 2014 15:54:44 UTC