Skip to content

Commit 85cc50f

Browse files
committed
[css-properties-values-api] Update PropertyDescriptor with
defaults / required members.
1 parent e842bbc commit 85cc50f

File tree

1 file changed

+9
-6
lines changed

1 file changed

+9
-6
lines changed

css-properties-values-api/Overview.bs

+9-6
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,10 @@ Registering custom properties {#registering-custom-properties}
5656

5757
<pre class='idl'>
5858
dictionary PropertyDescriptor {
59-
DOMString name;
60-
DOMString syntax;
61-
boolean inherits;
62-
DOMString initialValue;
59+
required DOMString name;
60+
DOMString syntax = '*';
61+
boolean inherits = false;
62+
DOMString initialValue;
6363
};
6464

6565
partial interface CSS {
@@ -85,7 +85,7 @@ following members:
8585
:: True if this custom property should inherit down the DOM tree; False otherwise.
8686

8787
: <dfn dict-member for=PropertyDescriptor>initialValue</dfn>
88-
:: The initial value of this custom property.
88+
:: The initial value of this custom property.
8989

9090
The {{registerProperty()}} function {#the-registerproperty-function}
9191
--------------------------------------------------------------------
@@ -111,7 +111,10 @@ Note: in future levels we anticipate supporting more sophisticated parse strings
111111

112112
Attempting to call {{registerProperty()}} with an {{PropertyDescriptor/initialValue}} that is
113113
not parseable using the provided {{PropertyDescriptor/syntax}} must cause it to
114-
throw a {{SyntaxError}}.
114+
throw a {{SyntaxError}}. If no {{PropertyDescriptor/initialValue}} is provided and the
115+
{{PropertyDescriptor/syntax}} is '*', then a special initial value used. This initial
116+
value must be considered parseable by {{registerProperty()}} but invalid at computed
117+
value time.
115118

116119
When a custom property is registered with a given type, the process via which specified
117120
values for that property are turned into computed values is defined

0 commit comments

Comments
 (0)