@@ -27,6 +27,8 @@ Default Highlight: css
27
27
<pre class=link-defaults>
28
28
spec:css-color-4; type:property; text:color
29
29
spec:html; type:element; text:link
30
+ spec:css-namespaces-3; type:dfn; text:namespace prefix
31
+ spec:css-namespaces-3; type:dfn; text:CSS qualified name
30
32
</pre>
31
33
32
34
<h2 id="introduction">Introduction</h2>
@@ -134,14 +136,36 @@ for some properties in [[CSS3-TRANSITIONS]] and
134
136
<h2 id="contents-of">
135
137
Contents of conditional group rules</h2>
136
138
137
- All [=conditional rules=] are defined to take a <<stylesheet>> in their block,
139
+ All [=conditional group rules=] are defined to take a <<stylesheet>> in their block,
138
140
which means they can accept any rule that is normally allowed at the top-level of a stylesheet,
139
141
and not otherwise restricted.
140
142
(For example, an ''@import'' rule must appear at the actual beginning of a stylesheet,
141
143
and so is not valid inside of another rule.)
142
144
143
145
Invalid or unknown rules inside the <<stylesheet>> must be considered invalid and ignored,
144
- but do not invalidate the [=conditional rule=] .
146
+ but do not invalidate the [=conditional group rule=] .
147
+
148
+ Any namespace prefixes used in a [=conditional group rule=]
149
+ must have been declared,
150
+ otherwise they are invalid.
151
+
152
+ <div class="example" id=ex-declared-ns> For example, this rule
153
+ containing a [=CSS qualified name=] is valid,
154
+ because the [=namespace prefix=] has been bound to a namespace url:
155
+ <pre>
156
+ @namespace x url(http://www.w3.org/1999/xlink);
157
+ @supports (content: attr(x|href)) {
158
+ // do something }
159
+ </pre>
160
+ </div>
161
+
162
+ <div class="example"> For example, to determine whether this rule is valid:
163
+ <pre>
164
+ @supports (content: attr(n|tooltip)) {
165
+ // do something }
166
+ </pre>
167
+ The user agent will consult the namespace map to see whether a namespace url exists corresponding to the "n" prefix.
168
+ </div>
145
169
146
170
<h2 id="use">
147
171
Placement of conditional group rules</h2>
0 commit comments