@webref/idl 3.1.3 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -6,25 +6,27 @@
6
6
  enum PressureState { "nominal", "fair", "serious", "critical" };
7
7
 
8
8
  callback ComputePressureUpdateCallback = undefined (
9
- sequence<ComputePressureEntry> entries,
9
+ sequence<ComputePressureRecord> changes,
10
10
  ComputePressureObserver observer
11
11
  );
12
12
 
13
13
  enum ComputePressureTarget { "cpu" };
14
14
 
15
- [Exposed=Window]
15
+ [Exposed=(DedicatedWorker,SharedWorker,Window), SecureContext]
16
16
  interface ComputePressureObserver {
17
17
  constructor(ComputePressureUpdateCallback callback);
18
18
 
19
19
  undefined observe(ComputePressureTarget target, optional ComputePressureObserverOptions options = {});
20
20
  undefined unobserve(ComputePressureTarget target);
21
21
  undefined disconnect();
22
- sequence<ComputePressureEntry> takeRecords();
22
+ sequence<ComputePressureRecord> takeRecords();
23
23
 
24
24
  [SameObject] static readonly attribute FrozenArray<DOMString> supportedTargetTypes;
25
+
26
+ [Exposed=Window] static Promise<PermissionState> requestPermission();
25
27
  };
26
28
 
27
- dictionary ComputePressureEntry {
29
+ dictionary ComputePressureRecord {
28
30
  PressureState state;
29
31
  ComputePressureObserverOptions options;
30
32
  };
@@ -0,0 +1,8 @@
1
+ // GENERATED CONTENT - DO NOT EDIT
2
+ // Content was automatically extracted by Reffy into webref
3
+ // (https://github.com/w3c/webref)
4
+ // Source: CSS Containment Module Level 3 (https://drafts.csswg.org/css-contain-3/)
5
+
6
+ [Exposed=Window]
7
+ interface CSSContainerRule : CSSConditionRule {
8
+ };
package/html.idl CHANGED
@@ -1341,7 +1341,7 @@ interface mixin CanvasTransform {
1341
1341
  interface mixin CanvasCompositing {
1342
1342
  // compositing
1343
1343
  attribute unrestricted double globalAlpha; // (default 1.0)
1344
- attribute DOMString globalCompositeOperation; // (default source-over)
1344
+ attribute DOMString globalCompositeOperation; // (default "source-over")
1345
1345
  };
1346
1346
 
1347
1347
  interface mixin CanvasImageSmoothing {
@@ -1480,7 +1480,7 @@ interface mixin CanvasPath {
1480
1480
  undefined bezierCurveTo(unrestricted double cp1x, unrestricted double cp1y, unrestricted double cp2x, unrestricted double cp2y, unrestricted double x, unrestricted double y);
1481
1481
  undefined arcTo(unrestricted double x1, unrestricted double y1, unrestricted double x2, unrestricted double y2, unrestricted double radius);
1482
1482
  undefined rect(unrestricted double x, unrestricted double y, unrestricted double w, unrestricted double h);
1483
- undefined roundRect(unrestricted double x, unrestricted double y, unrestricted double w, unrestricted double h, sequence<(unrestricted double or DOMPointInit)> radii);
1483
+ undefined roundRect(unrestricted double x, unrestricted double y, unrestricted double w, unrestricted double h, optional (unrestricted double or DOMPointInit or sequence<(unrestricted double or DOMPointInit)>) radii = {});
1484
1484
  undefined arc(unrestricted double x, unrestricted double y, unrestricted double radius, unrestricted double startAngle, unrestricted double endAngle, optional boolean counterclockwise = false);
1485
1485
  undefined ellipse(unrestricted double x, unrestricted double y, unrestricted double radiusX, unrestricted double radiusY, unrestricted double rotation, unrestricted double startAngle, unrestricted double endAngle, optional boolean counterclockwise = false);
1486
1486
  };
@@ -2208,53 +2208,6 @@ dictionary EventSourceInit {
2208
2208
  boolean withCredentials = false;
2209
2209
  };
2210
2210
 
2211
- enum BinaryType { "blob", "arraybuffer" };
2212
- [Exposed=(Window,Worker)]
2213
- interface WebSocket : EventTarget {
2214
- constructor(USVString url, optional (DOMString or sequence<DOMString>) protocols = []);
2215
-
2216
- readonly attribute USVString url;
2217
-
2218
- // ready state
2219
- const unsigned short CONNECTING = 0;
2220
- const unsigned short OPEN = 1;
2221
- const unsigned short CLOSING = 2;
2222
- const unsigned short CLOSED = 3;
2223
- readonly attribute unsigned short readyState;
2224
- readonly attribute unsigned long long bufferedAmount;
2225
-
2226
- // networking
2227
- attribute EventHandler onopen;
2228
- attribute EventHandler onerror;
2229
- attribute EventHandler onclose;
2230
- readonly attribute DOMString extensions;
2231
- readonly attribute DOMString protocol;
2232
- undefined close(optional [Clamp] unsigned short code, optional USVString reason);
2233
-
2234
- // messaging
2235
- attribute EventHandler onmessage;
2236
- attribute BinaryType binaryType;
2237
- undefined send(USVString data);
2238
- undefined send(Blob data);
2239
- undefined send(ArrayBuffer data);
2240
- undefined send(ArrayBufferView data);
2241
- };
2242
-
2243
- [Exposed=(Window,Worker)]
2244
- interface CloseEvent : Event {
2245
- constructor(DOMString type, optional CloseEventInit eventInitDict = {});
2246
-
2247
- readonly attribute boolean wasClean;
2248
- readonly attribute unsigned short code;
2249
- readonly attribute USVString reason;
2250
- };
2251
-
2252
- dictionary CloseEventInit : EventInit {
2253
- boolean wasClean = false;
2254
- unsigned short code = 0;
2255
- USVString reason = "";
2256
- };
2257
-
2258
2211
  [Exposed=(Window,Worker)]
2259
2212
  interface MessageChannel {
2260
2213
  constructor();
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@webref/idl",
3
3
  "description": "Web IDL definitions of the web platform",
4
- "version": "3.1.3",
4
+ "version": "3.2.0",
5
5
  "repository": {
6
6
  "type": "git",
7
7
  "url": "https://github.com/w3c/webref.git"
@@ -5,6 +5,7 @@
5
5
 
6
6
  dictionary SecurePaymentConfirmationRequest {
7
7
  required BufferSource challenge;
8
+ required USVString rpId;
8
9
  required FrozenArray<BufferSource> credentialIds;
9
10
  required PaymentCredentialInstrument instrument;
10
11
  unsigned long timeout;
package/webgpu.idl CHANGED
@@ -355,6 +355,7 @@ enum GPUTextureFormat {
355
355
 
356
356
  [Exposed=(Window, DedicatedWorker), SecureContext]
357
357
  interface GPUExternalTexture {
358
+ readonly attribute boolean expired;
358
359
  };
359
360
  GPUExternalTexture includes GPUObjectBase;
360
361
 
package/webnn.idl CHANGED
@@ -16,33 +16,20 @@ enum MLDevicePreference {
16
16
  };
17
17
 
18
18
  enum MLPowerPreference {
19
- // Let the user agent select the most suitable behavior.
20
19
  "default",
21
-
22
- // Prioritizes execution speed over power consumption.
23
20
  "high-performance",
24
-
25
- // Prioritizes power consumption over other considerations such as execution speed.
26
21
  "low-power"
27
22
  };
28
23
 
29
24
  dictionary MLContextOptions {
30
- // Preferred kind of device used
31
25
  MLDevicePreference devicePreference = "default";
32
-
33
- // Preference as related to power consumption
34
26
  MLPowerPreference powerPreference = "default";
35
27
  };
36
28
 
37
29
  [SecureContext, Exposed=(Window, DedicatedWorker)]
38
30
  interface ML {
39
- // Create a context with options
40
31
  MLContext createContext(optional MLContextOptions options = {});
41
-
42
- // Create a context from WebGL rendering context
43
32
  MLContext createContext(WebGLRenderingContext glContext);
44
-
45
- // Create a context from WebGPU device
46
33
  MLContext createContext(GPUDevice gpuDevice);
47
34
  };
48
35
 
package/websockets.idl ADDED
@@ -0,0 +1,48 @@
1
+ // GENERATED CONTENT - DO NOT EDIT
2
+ // Content was automatically extracted by Reffy into webref
3
+ // (https://github.com/w3c/webref)
4
+ // Source: WebSockets Standard (https://websockets.spec.whatwg.org/)
5
+
6
+ enum BinaryType { "blob", "arraybuffer" };
7
+
8
+ [Exposed=(Window,Worker)]
9
+ interface WebSocket : EventTarget {
10
+ constructor(USVString url, optional (DOMString or sequence<DOMString>) protocols = []);
11
+ readonly attribute USVString url;
12
+
13
+ // ready state
14
+ const unsigned short CONNECTING = 0;
15
+ const unsigned short OPEN = 1;
16
+ const unsigned short CLOSING = 2;
17
+ const unsigned short CLOSED = 3;
18
+ readonly attribute unsigned short readyState;
19
+ readonly attribute unsigned long long bufferedAmount;
20
+
21
+ // networking
22
+ attribute EventHandler onopen;
23
+ attribute EventHandler onerror;
24
+ attribute EventHandler onclose;
25
+ readonly attribute DOMString extensions;
26
+ readonly attribute DOMString protocol;
27
+ undefined close(optional [Clamp] unsigned short code, optional USVString reason);
28
+
29
+ // messaging
30
+ attribute EventHandler onmessage;
31
+ attribute BinaryType binaryType;
32
+ undefined send((BufferSource or Blob or USVString) data);
33
+ };
34
+
35
+ [Exposed=(Window,Worker)]
36
+ interface CloseEvent : Event {
37
+ constructor(DOMString type, optional CloseEventInit eventInitDict = {});
38
+
39
+ readonly attribute boolean wasClean;
40
+ readonly attribute unsigned short code;
41
+ readonly attribute USVString reason;
42
+ };
43
+
44
+ dictionary CloseEventInit : EventInit {
45
+ boolean wasClean = false;
46
+ unsigned short code = 0;
47
+ USVString reason = "";
48
+ };
package/webusb.idl CHANGED
@@ -68,6 +68,7 @@ interface USBDevice {
68
68
  readonly attribute boolean opened;
69
69
  Promise<undefined> open();
70
70
  Promise<undefined> close();
71
+ Promise<undefined> forget();
71
72
  Promise<undefined> selectConfiguration(octet configurationValue);
72
73
  Promise<undefined> claimInterface(octet interfaceNumber);
73
74
  Promise<undefined> releaseInterface(octet interfaceNumber);