@@ -1605,7 +1605,7 @@ <h3 id=attr><span class=secno>8.3. </span> Attribute References: ‘<a
16051605 http://lists.w3.org/Archives/Member/w3c-css-wg/2002OctDec/0141.html
16061606-->
16071607
1608- < p > The < dfn id =attr-value > attr()</ dfn > function returns the value of an
1608+ < p > The < dfn id =attr-value > attr()</ dfn > function can return the value of an
16091609 attribute on the element for use as a value in a property. If used on a
16101610 pseudo-element, it returns the value of the attribute on the
16111611 pseudo-element's originating element.
@@ -1616,8 +1616,8 @@ <h3 id=attr><span class=secno>8.3. </span> Attribute References: ‘<a
16161616 href ="#attr-value "> < code class =css > attr()</ code > </ a > ’ expression can
16171617 return many different types. The ‘< a href ="#attr-value "> < code
16181618 class =css > attr()</ code > </ a > ’ expression cannot return everything,
1619- for example it cannot do counters, named strings, quotes, or values such
1620- as ‘< code class =css > auto</ code > ’, ‘< code
1619+ for example it cannot do counters, named strings, quotes, or keyword
1620+ values such as ‘< code class =css > auto</ code > ’, ‘< code
16211621 class =css > nowrap</ code > ’, or ‘< code
16221622 class =css > baseline</ code > ’. This is intentional, as the intent of
16231623 the ‘< a href ="#attr-value "> < code class =css > attr()</ code > </ a > ’
@@ -1640,28 +1640,27 @@ <h3 id=attr><span class=secno>8.3. </span> Attribute References: ‘<a
16401640 the value of the attribute with that name on the element, according to the
16411641 rules given below.
16421642
1643- < p > The ‘< code class =css > <type> </ code > ’ argument (which is
1644- optional) is a keyword drawn from the list below that tells the UA how to
1645- interpret the attribute value. If omitted, ‘< code
1646- class =css > string</ code > ’ is implied. If the type is not valid for
1647- where the ‘< a href ="#attr-value "> < code
1648- class =css > attr()</ code > </ a > ’ expression is placed, the whole
1649- ‘< a href ="#attr-value "> < code class =css > attr()</ code > </ a > ’
1650- expression is invalid.
1643+ < p > The optional ‘< code class =css > <type> </ code > ’ argument is
1644+ a keyword drawn from the list below that tells the UA how to interpret the
1645+ attribute value. If omitted, ‘< code class =css > string</ code > ’
1646+ is implied. If the type is not valid for where the ‘< a
1647+ href ="#attr-value "> < code class =css > attr()</ code > </ a > ’ expression is
1648+ placed, the whole ‘< a href ="#attr-value "> < code
1649+ class =css > attr()</ code > </ a > ’ expression is invalid.
16511650
1652- < p > The ‘< code class =css > <value> </ code > ’ argument (which is
1653- optional) is a CSS value which must be valid where the ‘< a
1651+ < p > The optional ‘< code class =css > <value> </ code > ’ argument is
1652+ a CSS value which must be valid where the ‘< a
16541653 href ="#attr-value "> < code class =css > attr()</ code > </ a > ’ expression is
1655- placed. It represents a fallback value to be used if the named attribute
1656- is missing, or its value cannot be parsed into the given type or is
1657- invalid/out-of-range for the property. If the ‘< code
1654+ placed. It represents a fallback value, which is used if the named
1655+ attribute is missing, or its value cannot be parsed into the given type or
1656+ is invalid/out-of-range for the property. If the ‘< code
16581657 class =css > <value> </ code > ’ argument is not valid for the property
16591658 where the ‘< a href ="#attr-value "> < code
16601659 class =css > attr()</ code > </ a > ’ expression is placed, the whole
16611660 ‘< a href ="#attr-value "> < code class =css > attr()</ code > </ a > ’
1662- expression is invalid. The fallback value must not be another ‘ < a
1663- href ="#attr-value "> < code class =css > attr()</ code > </ a > ’ expression; if
1664- it is, the outer ‘< a href ="#attr-value "> < code
1661+ expression is invalid. The fallback value must not contain another
1662+ ‘ < a href ="#attr-value "> < code class =css > attr()</ code > </ a > ’
1663+ expression; if it is, the outer ‘< a href ="#attr-value "> < code
16651664 class =css > attr()</ code > </ a > ’ expression is invalid. If the fallback
16661665 ‘< code class =css > <value> </ code > ’ is absent, the default
16671666 value for the given type (from the list below) is implied.
@@ -1734,7 +1733,8 @@ <h3 id=attr><span class=secno>8.3. </span> Attribute References: ‘<a
17341733 relevant units is not valid for the property. The default should also be
17351734 used if the property in question only accepts values within a certain
17361735 range (e.g. positive lengths or angles from 0 to 90deg) and the attribute
1737- is out of range (e.g. a negative length or 180deg).
1736+ is out of range (e.g. a negative length or 180deg). If the unit is a
1737+ relative length, it must be computed to an absolute length.
17381738
17391739 < dt > ‘< a href ="#em-unit "> < code class =css > em</ code > </ a > ’
17401740
@@ -1781,7 +1781,8 @@ <h3 id=attr><span class=secno>8.3. </span> Attribute References: ‘<a
17811781 unit. The default is ‘< code class =css > 0</ code > ’ in the
17821782 relevant units, or else the property's minimum value if ‘< code
17831783 class =css > 0</ code > ’ in the relevant units is not valid for the
1784- property.
1784+ property. If the unit is a relative length, it must be computed to an
1785+ absolute length.
17851786 </ dl >
17861787
17871788 < div class =example >
0 commit comments