You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<adata-autolink="link" href="#custom-property">Custom properties</a> are solely for use by authors and users;
155
155
CSS will never give them a meaning beyond what is presented here.
156
156
157
+
</p><pclass="note"> Note: Authors are recommended to choose custom property names
158
+
so that the part after the "var-" is an identifier by itself,
159
+
so that it can be referenced without <ahref="http://www.w3.org/TR/CSS21/syndata.html#escaped-characters">character escaping</a>.
160
+
For example, <adata-autolink="property" class="property" title="var-0">var-0</a> needs to be referenced as <adata-autolink="maybe" class="css">var(\30)</a>,
161
+
because <adata-autolink="maybe" class="css">0</a> isn't a valid identifier.
162
+
(U+0030 is the hexadecimal code for the <adata-autolink="maybe" class="css">0</a> character.)
163
+
157
164
</p><divclass="example">
158
165
Custom properties define variables,
159
166
referenced with the <adata-autolink="maybe" class="css">var()</a> notation,
rather than requiring many edits across all stylesheets in the webpage.
180
187
</p></div>
181
188
182
-
<divclass="example">
183
-
Authors are recommended to choose custom property names
184
-
so that the part after the "var-" is an identifier by itself,
185
-
so that it can be referenced without <ahref="http://www.w3.org/TR/CSS21/syndata.html#escaped-characters">character escaping</a>.
186
-
For example, <adata-autolink="property" class="property" title="var-0">var-0</a> needs to be referenced as <adata-autolink="maybe" class="css">var(\30)</a>,
187
-
because <adata-autolink="maybe" class="css">0</a> isn't a valid identifier.
188
-
(U+0030 is the hexadecimal code for the <adata-autolink="maybe" class="css">0</a> character.)
189
-
</div>
190
-
191
189
<p> Unlike other CSS properties,
192
190
custom property names are <strong>case-sensitive</strong>.
193
191
The "var-" prefix <strong>must</strong> be written in lower-case.
0 commit comments