Skip to content

Commit c996510

Browse files
committed
[cssom] Fix getComputedStyle with over-constrained box-offset properties
When left/right or top/bottom are over-constrained, getComputedStyle needs to return the computed value rather than the used value. Fixes w3c#203.
1 parent 13b38ab commit c996510

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

cssom/Overview.bs

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1460,7 +1460,7 @@ To <dfn>serialize a CSS rule</dfn>, perform one of the following in accordance w
14601460

14611461
<dt>{{CSSNamespaceRule}}
14621462
<dd>The literal string "<code>@namespace</code>", followed by a single SPACE
1463-
(U+0020), followed by the
1463+
(U+0020), followed by the
14641464
<a lt="serialize an identifier">serialization as an identifier</a> of the
14651465
{{CSSNamespaceRule/prefix}} attribute (if
14661466
any), followed by a single SPACE (U+0020) if there is a prefix, followed by the
@@ -2689,11 +2689,9 @@ as follows:
26892689
<dt>'left'
26902690
<dt>'right'
26912691
<dt>'top'
2692-
<dd>If the property applies to a positioned element and the
2693-
<a>resolved value</a> of the 'display' property is not
2694-
''display/none'', the <a>resolved value</a> is the
2695-
<a>used value</a>. Otherwise the <a>resolved value</a> is the
2696-
computed value.
2692+
<dd>If the property applies to a positioned element and the <a>resolved value</a> of the 'display'
2693+
property is not ''display/none'', and the property is not over-constrained, the <a>resolved
2694+
value</a> is the <a>used value</a>. Otherwise the <a>resolved value</a> is the computed value.
26972695

26982696
<dt>Any other property
26992697
<dd>The <a>resolved value</a> is the <a>computed value</a>.
@@ -2810,6 +2808,7 @@ Ian Hickson,
28102808
John Daggett,
28112809
Lachlan Hunt,
28122810
Mike Sherov,
2811+
Myles C. Maxfield,
28132812
Morten Stenshorne,
28142813
Ms2ger,
28152814
Øyvind Stenhaug,

0 commit comments

Comments
 (0)