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

[css-align] 'auto' values in align-items/align-content/justify-items/justify-content

From: fantasai <fantasai.lists@inkedblade.net>
Date: Thu, 3 Dec 2015 18:28:02 -0500
To: "www-style@w3.org" <www-style@w3.org>
Message-ID: <5660D002.2010007@inkedblade.net>
Tab and I were going through the keyword computation rules in
the Box Alignment spec, e.g.
   http://www.w3.org/TR/2014/WD-css-align-3-20141218/#justify-items-property

In particular, we noticed that the 'auto' value on align-self
and justify-self is a "get value from this other property"
keyword, whereas on align/justify-content and when preserved
through from align/justify-items, it is a "do some automagic"
value.

We had this exact situation with flex-basis: auto, and that
was a problem we resolved by adding the 'content' keyword to
represent the "do some automagic" behavior.

We decided that we should avoid this problem in Alignment as
well. Our proposal is:

   1. Rename 'auto' to 'normal' on align/justify-items/content
      and add it as a possible value for align/justify-self.
      This becomes the "do the right default thing per display
      type" keyword.

   2. Remove the "auto computes to stretch for flex containers
      and grid containers and start for everything else" rule
      from align-items/justify-items, and apply that logic at
      used-time to 'normal' on align-self/justify-self.

The values then become (abbreviatedly):
     align/justify-self: auto | normal | start | end | etc.
     align/justify-items: normal | start | end | etc.
     align/justify-content: normal | start | end | etc.

Please let us know what you think~

~fantasai and TJ
Received on Thursday, 3 December 2015 23:28:39 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:52:31 UTC