Skip to content

Commit f9f174d

Browse files
committed
[css-paint-api] Convert the paint function to the correct WebIDL type.
This fixes #743.
1 parent cd6808a commit f9f174d

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

css-paint-api/Overview.bs

+8-5
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,15 @@ Ignored Terms: PaintWorklet
3636
<pre class="link-defaults">
3737
spec:css-break-3; type:dfn; text:fragment
3838
spec:css-display-3; type:dfn; text:box
39+
spec:css-ui-4; type:property; text:cursor
3940
spec:infra; type:dfn; text:list
4041
</pre>
4142

4243
<pre class="anchors">
4344
urlPrefix: https://heycam.github.io/webidl/; type: dfn;
4445
text: InvalidModificationError
46+
urlPrefix: #common-;
47+
text: Function
4548
urlPrefix: #dfn-;
4649
url: throw; text: thrown
4750
urlPrefix: #idl-;
@@ -62,7 +65,6 @@ urlPrefix: https://tc39.github.io/ecma262/#sec-; type: dfn;
6265
text: IsConstructor
6366
url: ecmascript-data-types-and-values; text: type
6467
url: get-o-p; text: Get
65-
url: terms-and-definitions-function; text: function
6668
urlPrefix: native-error-types-used-in-this-standard-
6769
text: TypeError
6870
</pre>
@@ -140,7 +142,8 @@ A <dfn>paint definition</dfn> is a <a>struct</a> which describes the information
140142

141143
- <dfn for="paint definition">class constructor</dfn> which is the class <a>constructor</a>.
142144

143-
- <dfn for="paint definition">paint function</dfn> which is the paint <a>function</a> callback.
145+
- <dfn for="paint definition">paint function</dfn> which is the paint <a>Function</a>
146+
<a>callback function</a> type.
144147

145148
- <dfn for="paint definition">constructor valid flag</dfn>.
146149

@@ -240,10 +243,10 @@ called, the user agent <em>must</em> run the following steps:
240243
16. If the result of <a>Type</a>(|prototype|) is not Object, <a>throw</a> a <a>TypeError</a> and
241244
abort all these steps.
242245

243-
17. Let |paint| be the result of <a>Get</a>(|prototype|, "paint").
246+
17. Let |paintValue| be the result of <a>Get</a>(|prototype|, "paint").
244247

245-
18. If the result of <a>IsCallable</a>(|paint|) is false, <a>throw</a> a <a>TypeError</a> and
246-
abort all these steps.
248+
18. Let |paint| be the result of <a>converting</a> |paintValue| to the <a>Function</a>
249+
<a>callback function</a> type. Rethrow any exceptions from the conversion.
247250

248251
19. Let |definition| be a new <a>paint definition</a> with:
249252

0 commit comments

Comments
 (0)