Re: [css3-values] RE: CSSStyleDeclaration#length and shorthands.

On 1/31/12 2:21 PM, Alexis Menard wrote:
>> Example C:
>> <span style="border: 7px dashed red;">s<div style="border: inherit;">D</div>s</span>

> Which WebKit does today for example. But on example C do you expect to
> have DIV.style.length to report 1 or the same length as the SPAN.

I would expect the latter.

>> In example D, I would expect OM queries for style on the DIV to report one of the following depending upon which "less than CR" specs you want to incorporate:
>> a. ""
>> b. "border: -prefix-initial"
>> c. "border: medium none currentColor"
>> d. "border: medium"
>>
>> a: most compatible with 2.1
>> b: one interpretation of Values
>> c: another interpretation of Values, ignoring OM
>> d: same as c, but respecting minimization rules of OM
>
> Right now I'm unfamiliar with -prefix-initial so I will read about it.

It's just "initial".  I would likewise expect that to report the same 
length as the <span> above, since it's explicitly setting all the 
subproperties of "border".

> Given this example :<div style="border-width: 1px 2px 3px
> 4px;"></div>. What would be the length of the style for the div?

4, imo.

-Boris

Received on Tuesday, 31 January 2012 19:31:59 UTC