W3C home > Mailing lists > Public > public-css-archive@w3.org > September 2016

Re: [csswg-drafts] [css-flexbox][css-align][css-grid] abspos flex/grid item "align-self: auto behaves as start" spec-text is too vague

From: Mats Palmgren via GitHub <sysbot+gh@w3.org>
Date: Tue, 06 Sep 2016 00:14:44 +0000
To: public-css-archive@w3.org
Message-ID: <issue_comment.created-244824005-1473120883-sysbot+gh@w3.org>
Regarding fantasai's suggested solutions.

I think 1) has the same performance problems as we reported here:
That is, the computed value for 'align-self' would depend on
its own computed values of 'position', 'display' etc.

2) would change the meaning of 'inherit', e.g.:

<A style="justify-items:left">
  <B style="justify-items:right">
    <C style="justify-self:inherit">

Currently, this is equivalent to:

<A style="justify-items:left">
  <B style="justify-items:right; justify-self:left">
    <C style="justify-self:left">

With 2) we would instead get the computed values:

<A style="justify-items:left">
  <B style="justify-items:right; justify-self:auto">
    <C style="justify-self:auto">

B would have the used value 'left'.
C would have the used value 'right'.

It seems wrong that B and C ends up having different used values
when the author explicitly specified that C should have the same
justify-self value as B.

I think this solution might work better:
Store an "original-value-was-auto" flag to remember if the value
was 'auto' before it was replaced with its parent's justify-items.

Grid/Flexbox can then use this flag to indicate 'start' for the static
position (and it's only used for that purpose).

I think this would be easy to implement in Gecko (it's similar to
how we retain the original 'display' value for the purposes of
calculating the static position [1]).

"... this hypothetical calculation might require also assuming
a different computed value for 'display'."

GitHub Notification of comment by MatsPalmgren
Please view or discuss this issue at 
using your GitHub account
Received on Tuesday, 6 September 2016 00:14:54 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:02 UTC