W3C home > Mailing lists > Public > www-style@w3.org > February 2012

Re: [css3-flexbox] ED updated: algorithms and 'flex' property

From: Daniel Holbert <dholbert@mozilla.com>
Date: Tue, 28 Feb 2012 17:58:45 -0800
Message-ID: <4F4D8655.8050706@mozilla.com>
To: Tony Chang <tony@chromium.org>
CC: Alex Mogilevsky <alexmog@microsoft.com>, "Tab Atkins Jr." <jackalmage@gmail.com>, "www-style@w3.org list" <www-style@w3.org>
On 02/28/2012 04:59 PM, Tony Chang wrote:
> I like this idea.  To expand on it further, we would have three separate
> properties (e.g., positive-flex, negative-flex, flex-preferred-size) and
> flex would just be a shorthand.  All would default to 0.  If we're not
> in a flexing context or if positive flex and negative flex are both 0,
> we would use width/height.  We only use flex-preferred-size if we have a
> positive or negative flex value.

I like the sound of this too -- one thing though.  It sounds like with 
your proposed semantics, the 50px here would be ignored:

  <div style="display: flexbox">
    <div style="flex: 0 0 50px"/>
  </div>

That seems undesirable.

(With your proposed semantics, I suppose the correct markup to achieve 
the above would be just "width: 50px" instead of "flex: 0 0 50px".  But 
I bet authors would probably be confused about why "flex: 0 0 50px" 
doesn't work, especially when "flex: 1 0 50px" works...  Not sure how 
much this matters.)

~Daniel
Received on Wednesday, 29 February 2012 01:59:14 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:51 GMT