Skip to content

Commit fcf8677

Browse files
committed
[css-cascade] Add note about how 'computed value' definitions are *not* serialization definitions. Fixes w3c#4060.
1 parent b878a59 commit fcf8677

File tree

2 files changed

+18
-4
lines changed

2 files changed

+18
-4
lines changed

css-cascade-3/Overview.bs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,13 @@ Computed Values</h3>
376376

377377
Note: The <a>computed value</a> is the value that is transferred from parent to child during <a>inheritance</a>.
378378
For historical reasons,
379-
it is not necessarily the value returned by the <code>getComputedStyle()</code> function.
379+
it is not necessarily the value returned by the {{getComputedStyle()}} function,
380+
which sometimes returns <a>used values</a>. [[CSSOM]]
381+
Furthermore, the <a>computed value</a> is an abstract data representation:
382+
their definitions reflect that data representation,
383+
not how that data is serialized.
384+
For example, serialization rules often allow omitting certain values which are implied during parsing;
385+
but those values are nonetheless part of the <a>computed value</a>.
380386

381387
<div class="example">
382388
A <a>specified value</a> can be either absolute (i.e., not relative to another value, as in ''red'' or ''2mm'')

css-cascade-4/Overview.bs

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -462,9 +462,17 @@ Computed Values</h3>
462462
as defined in the “Computed Value” line of the property definition table,
463463
generally absolutizing it in preparation for <a>inheritance</a>.
464464

465-
Note: The <a>computed value</a> is the value that is transferred from parent to child during <a>inheritance</a>.
466-
For historical reasons,
467-
it is not necessarily the value returned by the <code>getComputedStyle()</code> function.
465+
<div class=note>
466+
The <a>computed value</a> is the value that is transferred from parent to child during <a>inheritance</a>.
467+
For historical reasons,
468+
it is not necessarily the value returned by the {{getComputedStyle()}} function,
469+
which sometimes returns <a>used values</a>. [[CSSOM]]
470+
Furthermore, the <a>computed value</a> is an abstract data representation:
471+
their definitions reflect that data representation,
472+
not how that data is serialized.
473+
For example, serialization rules often allow omitting certain values which are implied during parsing;
474+
but those values are nonetheless part of the <a>computed value</a>.
475+
</div>
468476

469477
<div class="example">
470478
A <a>specified value</a> can be either absolute (i.e., not relative to another value, as in ''red'' or ''2mm'')

0 commit comments

Comments
 (0)