Skip to content

Commit a5ec761

Browse files
committed
More clarifiction of how attributes are parsed.
1 parent 134378a commit a5ec761

2 files changed

Lines changed: 18 additions & 1 deletion

File tree

css3-values/Overview.html

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1673,6 +1673,15 @@ <h3 id=attr-notation><span class=secno>8.3. </span> Attribute References:
16731673
&lsquo;<code class=css>inset</code>&rsquo; keyword.
16741674
</div>
16751675

1676+
<p> If the specified attribute exists on the element, the value of the
1677+
attribute must be trimmed of leading and trailing white space and then
1678+
parsed against the <code>any</code> production in the Core Grammar defined
1679+
by CSS 2.1 <a href="#CSS21" rel=biblioentry>[CSS21]<!--{{!CSS21}}--></a>
1680+
If it is successfully parsed as required by the
1681+
<var>&lt;type-or-unit></var> argument (as defined in the list below), the
1682+
resulting value is the attr() expression's value. Otherwise, the attr()
1683+
expression's value is its fallback value.
1684+
16761685
<p>The <var>&lt;type-or-unit></var> keywords are:
16771686

16781687
<dl>

css3-values/Overview.src.html

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1191,7 +1191,15 @@ <h3 id="attr-notation">
11911191
with either a ''px'' length <em>or</em> the ''inset'' keyword.
11921192
</div>
11931193

1194-
1194+
<p>
1195+
If the specified attribute exists on the element,
1196+
the value of the attribute must be trimmed of leading and trailing white space
1197+
and then parsed against the <code>any</code> production
1198+
in the Core Grammar defined by CSS 2.1 [[!CSS21]]
1199+
If it is successfully parsed as required by the <var>&lt;type-or-unit></var> argument
1200+
(as defined in the list below),
1201+
the resulting value is the attr() expression's value.
1202+
Otherwise, the attr() expression's value is its fallback value.
11951203

11961204
<p>The <var>&lt;type-or-unit></var> keywords are:</p>
11971205

0 commit comments

Comments
 (0)