Re: [css-syntax] Duplicate declarations in style rules

Le 12/08/2013 08:22, John Daggett a écrit :
>>     .bar {
>>       margin: 1em;
>>       margin-left: 0;
>>     }
>>
>> Here, even though no two specified declarations have the same name,
>> there is still some duplication in the longhands: the 'margin-left:
>> 1em' declaration implied by the shorthand is ignored.
> Sorry, I'm not seeing the need to distinguish longhand/shorthand here.
> The resulting effect may be that the implied value for 'margin-left'
> is different from what is implied by 'margin: 1em' but the spec
> wording only seems to be talking about multiple declarations of the
> same property, regardless of whether it's a shorthand or a longhand.

Yes, exactly. And I think that wording is incorrect.

Per the wording in the current ED, there is no duplication here because 
the two declarations do not have the same name. But the fact is there is 
some duplication and implementations do drop the "expanded" 
'margin-left: 1em' declaration.

-- 
Simon Sapin

Received on Monday, 12 August 2013 07:33:13 UTC