Re: [css3-flexbox] ambiguity in flex shorthand?

On Thu, Mar 21, 2013 at 9:05 AM, Christian Biesinger
<cbiesinger@chromium.org> wrote:
> At the end of the section, the spec says "A unitless zero that is not
> already preceded by two flex factors must be interpreted as a flex
> factor. To avoid misinterpretation or invalid declarations, authors
> must specify a zero <flex-basis> component with a unit or precede it
> by two flex factors."
>
> So it will be the first of your options.

Thanks, Christian!  Yes, this is the correct answer - the spec
specifies that "flex: 1 0;" resolves to "flex-grow: 1; flex-shrink: 0;
flex-basis: 0;".

(Note that Daniel's third option isn't possible even without the spec
clarifying things, as "1" isn't a length.)

~TJ

Received on Thursday, 21 March 2013 16:18:15 UTC