W3C home > Mailing lists > Public > www-style@w3.org > December 2014

size property as a shorthand for width/height

From: Marat Tanalin <mtanalin@yandex.ru>
Date: Mon, 01 Dec 2014 18:10:49 +0300
To: www-style@w3.org
Message-Id: <507851417446649@web12g.yandex.ru>
Hello.

What if we add the `size` CSS-property as a shorthand for `width`/`height` pair?

For example:

.foo {size: 10px; }

would set both `width` and `height` properties to `10px`.

And:

.bar {size: 2em 3em; }

would set `width` to `2em` and `height` to `3em`.

This can be (and is) implemented via a preprocessor, but preprocessors exist just to overcome current CSS shortcomings, while it makes sense to overcome them on CSS-itself level to make CSS itself more usable and self-contained in the long term.

Thanks.
Received on Monday, 1 December 2014 15:11:51 UTC

This archive was generated by hypermail 2.4.0 : Friday, 25 March 2022 10:08:49 UTC