Re: [css3-flexbox] getComputedStyle on flex property

On Tue, Apr 3, 2012 at 1:54 PM, Tony Chang <tony@chromium.org> wrote:
> What should getComputedStyle return when called on the flex property?  Here
> are some examples with my guesses:
>
> 1.
> div.style.flex = 'none';
> getComputedStyle(div).flex -> 0 0 auto
>
> 2.
> div.style.flex = '1 2 3px';
> getComputedStyle(div).flex -> 1 2 3px
>
> 3.
> div.style.flex = '1 2 50%';
> getComputedStyle(div).flex -> 1 2 50%
>
> 4.
> div.style.flex = '1 2 1em';
> getComputedStyle(div).flex -> 1 2 16px
>
> 5.
> div.style.flex = '1 2 auto';
> getComputedStyle(div).flex -> 1 2 auto

Yes, these should all be correct.  I've editted the draft to specify
this better.

More interesting question: what is the result when the specified value
is "1 10px"?  With my recent edit, the answer is "1 10px".  Should it
instead be "1 0 10px"?

~TJ

Received on Tuesday, 3 April 2012 21:49:04 UTC