@@ -480,9 +480,18 @@ interface RTCEncodedVideoFrameMetadata {
480480 width ?: number ;
481481}
482482
483- interface ReadableStreamReadDoneResult {
483+ interface ReadableStreamGetReaderOptions {
484+ /**
485+ * Creates a ReadableStreamBYOBReader and locks the stream to the new reader.
486+ *
487+ * This call behaves the same way as the no-argument variant, except that it only works on readable byte streams, i.e. streams which were constructed specifically with the ability to handle "bring your own buffer" reading. The returned BYOB reader provides the ability to directly read individual chunks from the stream via its read() method, into developer-supplied buffers, allowing more precise control over allocation.
488+ */
489+ mode ?: ReadableStreamReaderMode ;
490+ }
491+
492+ interface ReadableStreamReadDoneResult < T > {
484493 done : true ;
485- value ?: undefined ;
494+ value ?: T ;
486495}
487496
488497interface ReadableStreamReadValueResult < T > {
@@ -638,6 +647,21 @@ interface Transformer<I = any, O = any> {
638647 writableType ?: undefined ;
639648}
640649
650+ interface UnderlyingByteSource {
651+ autoAllocateChunkSize ?: number ;
652+ cancel ?: UnderlyingSourceCancelCallback ;
653+ pull ?: ( controller : ReadableByteStreamController ) => void | PromiseLike < void > ;
654+ start ?: ( controller : ReadableByteStreamController ) => any ;
655+ type : "bytes" ;
656+ }
657+
658+ interface UnderlyingDefaultSource < R = any > {
659+ cancel ?: UnderlyingSourceCancelCallback ;
660+ pull ?: ( controller : ReadableStreamDefaultController < R > ) => void | PromiseLike < void > ;
661+ start ?: ( controller : ReadableStreamDefaultController < R > ) => any ;
662+ type ?: undefined ;
663+ }
664+
641665interface UnderlyingSink < W = any > {
642666 abort ?: UnderlyingSinkAbortCallback ;
643667 close ?: UnderlyingSinkCloseCallback ;
@@ -647,10 +671,11 @@ interface UnderlyingSink<W = any> {
647671}
648672
649673interface UnderlyingSource < R = any > {
674+ autoAllocateChunkSize ?: number ;
650675 cancel ?: UnderlyingSourceCancelCallback ;
651676 pull ?: UnderlyingSourcePullCallback < R > ;
652677 start ?: UnderlyingSourceStartCallback < R > ;
653- type ?: undefined ;
678+ type ?: ReadableStreamType ;
654679}
655680
656681interface VideoColorSpaceInit {
@@ -736,6 +761,7 @@ declare var AbortSignal: {
736761 prototype : AbortSignal ;
737762 new ( ) : AbortSignal ;
738763 abort ( reason ?: any ) : AbortSignal ;
764+ timeout ( milliseconds : number ) : AbortSignal ;
739765} ;
740766
741767interface AbstractWorkerEventMap {
@@ -1296,6 +1322,13 @@ interface EXT_sRGB {
12961322interface EXT_shader_texture_lod {
12971323}
12981324
1325+ interface EXT_texture_compression_bptc {
1326+ readonly COMPRESSED_RGBA_BPTC_UNORM_EXT : GLenum ;
1327+ readonly COMPRESSED_RGB_BPTC_SIGNED_FLOAT_EXT : GLenum ;
1328+ readonly COMPRESSED_RGB_BPTC_UNSIGNED_FLOAT_EXT : GLenum ;
1329+ readonly COMPRESSED_SRGB_ALPHA_BPTC_UNORM_EXT : GLenum ;
1330+ }
1331+
12991332interface EXT_texture_compression_rgtc {
13001333 readonly COMPRESSED_RED_GREEN_RGTC2_EXT : GLenum ;
13011334 readonly COMPRESSED_RED_RGTC1_EXT : GLenum ;
@@ -1327,6 +1360,7 @@ declare var ErrorEvent: {
13271360interface Event {
13281361 /** Returns true or false depending on how event was initialized. True if event goes through its target's ancestors in reverse tree order, and false otherwise. */
13291362 readonly bubbles : boolean ;
1363+ /** @deprecated */
13301364 cancelBubble : boolean ;
13311365 /** Returns true or false depending on how event was initialized. Its return value does not always carry meaning, but true can indicate that part of the operation during which event was dispatched, can be canceled by invoking the preventDefault() method. */
13321366 readonly cancelable : boolean ;
@@ -2010,13 +2044,13 @@ declare var IDBObjectStore: {
20102044} ;
20112045
20122046interface IDBOpenDBRequestEventMap extends IDBRequestEventMap {
2013- "blocked" : Event ;
2047+ "blocked" : IDBVersionChangeEvent ;
20142048 "upgradeneeded" : IDBVersionChangeEvent ;
20152049}
20162050
20172051/** Also inherits methods from its parents IDBRequest and EventTarget. */
20182052interface IDBOpenDBRequest extends IDBRequest < IDBDatabase > {
2019- onblocked : ( ( this : IDBOpenDBRequest , ev : Event ) => any ) | null ;
2053+ onblocked : ( ( this : IDBOpenDBRequest , ev : IDBVersionChangeEvent ) => any ) | null ;
20202054 onupgradeneeded : ( ( this : IDBOpenDBRequest , ev : IDBVersionChangeEvent ) => any ) | null ;
20212055 addEventListener < K extends keyof IDBOpenDBRequestEventMap > ( type : K , listener : ( this : IDBOpenDBRequest , ev : IDBOpenDBRequestEventMap [ K ] ) => any , options ?: boolean | AddEventListenerOptions ) : void ;
20222056 addEventListener ( type : string , listener : EventListenerOrEventListenerObject , options ?: boolean | AddEventListenerOptions ) : void ;
@@ -2272,6 +2306,7 @@ interface NavigatorID {
22722306 readonly appName : string ;
22732307 /** @deprecated */
22742308 readonly appVersion : string ;
2309+ /** @deprecated */
22752310 readonly platform : string ;
22762311 /** @deprecated */
22772312 readonly product : string ;
@@ -2533,6 +2568,7 @@ interface PermissionStatusEventMap {
25332568}
25342569
25352570interface PermissionStatus extends EventTarget {
2571+ readonly name : string ;
25362572 onchange : ( ( this : PermissionStatus , ev : Event ) => any ) | null ;
25372573 readonly state : PermissionState ;
25382574 addEventListener < K extends keyof PermissionStatusEventMap > ( type : K , listener : ( this : PermissionStatus , ev : PermissionStatusEventMap [ K ] ) => any , options ?: boolean | AddEventListenerOptions ) : void ;
@@ -2644,6 +2680,7 @@ declare var PushSubscription: {
26442680/** Available only in secure contexts. */
26452681interface PushSubscriptionOptions {
26462682 readonly applicationServerKey : ArrayBuffer | null ;
2683+ readonly userVisibleOnly : boolean ;
26472684}
26482685
26492686declare var PushSubscriptionOptions : {
@@ -2691,19 +2728,23 @@ declare var ReadableByteStreamController: {
26912728interface ReadableStream < R = any > {
26922729 readonly locked : boolean ;
26932730 cancel ( reason ?: any ) : Promise < void > ;
2731+ getReader ( options : { mode : "byob" } ) : ReadableStreamBYOBReader ;
26942732 getReader ( ) : ReadableStreamDefaultReader < R > ;
2733+ getReader ( options ?: ReadableStreamGetReaderOptions ) : ReadableStreamReader < R > ;
26952734 pipeThrough < T > ( transform : ReadableWritablePair < T , R > , options ?: StreamPipeOptions ) : ReadableStream < T > ;
26962735 pipeTo ( destination : WritableStream < R > , options ?: StreamPipeOptions ) : Promise < void > ;
26972736 tee ( ) : [ ReadableStream < R > , ReadableStream < R > ] ;
26982737}
26992738
27002739declare var ReadableStream : {
27012740 prototype : ReadableStream ;
2741+ new ( underlyingSource : UnderlyingByteSource , strategy ?: { highWaterMark ?: number } ) : ReadableStream < Uint8Array > ;
2742+ new < R = any > ( underlyingSource : UnderlyingDefaultSource < R > , strategy ?: QueuingStrategy < R > ) : ReadableStream < R > ;
27022743 new < R = any > ( underlyingSource ?: UnderlyingSource < R > , strategy ?: QueuingStrategy < R > ) : ReadableStream < R > ;
27032744} ;
27042745
27052746interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
2706- read ( view : ArrayBufferView ) : Promise < ReadableStreamReadResult < ArrayBufferView > > ;
2747+ read < T extends ArrayBufferView > ( view : T ) : Promise < ReadableStreamReadResult < T > > ;
27072748 releaseLock ( ) : void ;
27082749}
27092750
@@ -2891,6 +2932,7 @@ interface ServiceWorkerGlobalScopeEventMap extends WorkerGlobalScopeEventMap {
28912932 "notificationclick" : NotificationEvent ;
28922933 "notificationclose" : NotificationEvent ;
28932934 "push" : PushEvent ;
2935+ "pushsubscriptionchange" : Event ;
28942936}
28952937
28962938/** This ServiceWorker API interface represents the global execution context of a service worker. */
@@ -2904,6 +2946,7 @@ interface ServiceWorkerGlobalScope extends WorkerGlobalScope {
29042946 onnotificationclick : ( ( this : ServiceWorkerGlobalScope , ev : NotificationEvent ) => any ) | null ;
29052947 onnotificationclose : ( ( this : ServiceWorkerGlobalScope , ev : NotificationEvent ) => any ) | null ;
29062948 onpush : ( ( this : ServiceWorkerGlobalScope , ev : PushEvent ) => any ) | null ;
2949+ onpushsubscriptionchange : ( ( this : ServiceWorkerGlobalScope , ev : Event ) => any ) | null ;
29072950 readonly registration : ServiceWorkerRegistration ;
29082951 readonly serviceWorker : ServiceWorker ;
29092952 skipWaiting ( ) : Promise < void > ;
@@ -3320,8 +3363,8 @@ interface WEBGL_lose_context {
33203363interface WEBGL_multi_draw {
33213364 multiDrawArraysInstancedWEBGL ( mode : GLenum , firstsList : Int32Array | GLint [ ] , firstsOffset : GLuint , countsList : Int32Array | GLsizei [ ] , countsOffset : GLuint , instanceCountsList : Int32Array | GLsizei [ ] , instanceCountsOffset : GLuint , drawcount : GLsizei ) : void ;
33223365 multiDrawArraysWEBGL ( mode : GLenum , firstsList : Int32Array | GLint [ ] , firstsOffset : GLuint , countsList : Int32Array | GLsizei [ ] , countsOffset : GLuint , drawcount : GLsizei ) : void ;
3323- multiDrawElementsInstancedWEBGL ( mode : GLenum , countsList : Int32Array | GLint [ ] , countsOffset : GLuint , type : GLenum , offsetsList : Int32Array | GLsizei [ ] , offsetsOffset : GLuint , instanceCountsList : Int32Array | GLsizei [ ] , instanceCountsOffset : GLuint , drawcount : GLsizei ) : void ;
3324- multiDrawElementsWEBGL ( mode : GLenum , countsList : Int32Array | GLint [ ] , countsOffset : GLuint , type : GLenum , offsetsList : Int32Array | GLsizei [ ] , offsetsOffset : GLuint , drawcount : GLsizei ) : void ;
3366+ multiDrawElementsInstancedWEBGL ( mode : GLenum , countsList : Int32Array | GLsizei [ ] , countsOffset : GLuint , type : GLenum , offsetsList : Int32Array | GLsizei [ ] , offsetsOffset : GLuint , instanceCountsList : Int32Array | GLsizei [ ] , instanceCountsOffset : GLuint , drawcount : GLsizei ) : void ;
3367+ multiDrawElementsWEBGL ( mode : GLenum , countsList : Int32Array | GLsizei [ ] , countsOffset : GLuint , type : GLenum , offsetsList : Int32Array | GLsizei [ ] , offsetsOffset : GLuint , drawcount : GLsizei ) : void ;
33253368}
33263369
33273370interface WebGL2RenderingContext extends WebGL2RenderingContextBase , WebGL2RenderingContextOverloads , WebGLRenderingContextBase {
@@ -4719,35 +4762,39 @@ interface WebGLRenderingContextBase {
47194762 getBufferParameter ( target : GLenum , pname : GLenum ) : any ;
47204763 getContextAttributes ( ) : WebGLContextAttributes | null ;
47214764 getError ( ) : GLenum ;
4765+ getExtension ( extensionName : "ANGLE_instanced_arrays" ) : ANGLE_instanced_arrays | null ;
47224766 getExtension ( extensionName : "EXT_blend_minmax" ) : EXT_blend_minmax | null ;
47234767 getExtension ( extensionName : "EXT_color_buffer_float" ) : EXT_color_buffer_float | null ;
47244768 getExtension ( extensionName : "EXT_color_buffer_half_float" ) : EXT_color_buffer_half_float | null ;
47254769 getExtension ( extensionName : "EXT_float_blend" ) : EXT_float_blend | null ;
4726- getExtension ( extensionName : "EXT_texture_filter_anisotropic" ) : EXT_texture_filter_anisotropic | null ;
47274770 getExtension ( extensionName : "EXT_frag_depth" ) : EXT_frag_depth | null ;
4728- getExtension ( extensionName : "EXT_shader_texture_lod" ) : EXT_shader_texture_lod | null ;
47294771 getExtension ( extensionName : "EXT_sRGB" ) : EXT_sRGB | null ;
4772+ getExtension ( extensionName : "EXT_shader_texture_lod" ) : EXT_shader_texture_lod | null ;
4773+ getExtension ( extensionName : "EXT_texture_compression_bptc" ) : EXT_texture_compression_bptc | null ;
4774+ getExtension ( extensionName : "EXT_texture_compression_rgtc" ) : EXT_texture_compression_rgtc | null ;
4775+ getExtension ( extensionName : "EXT_texture_filter_anisotropic" ) : EXT_texture_filter_anisotropic | null ;
47304776 getExtension ( extensionName : "KHR_parallel_shader_compile" ) : KHR_parallel_shader_compile | null ;
4777+ getExtension ( extensionName : "OES_element_index_uint" ) : OES_element_index_uint | null ;
4778+ getExtension ( extensionName : "OES_fbo_render_mipmap" ) : OES_fbo_render_mipmap | null ;
4779+ getExtension ( extensionName : "OES_standard_derivatives" ) : OES_standard_derivatives | null ;
4780+ getExtension ( extensionName : "OES_texture_float" ) : OES_texture_float | null ;
4781+ getExtension ( extensionName : "OES_texture_float_linear" ) : OES_texture_float_linear | null ;
4782+ getExtension ( extensionName : "OES_texture_half_float" ) : OES_texture_half_float | null ;
4783+ getExtension ( extensionName : "OES_texture_half_float_linear" ) : OES_texture_half_float_linear | null ;
47314784 getExtension ( extensionName : "OES_vertex_array_object" ) : OES_vertex_array_object | null ;
47324785 getExtension ( extensionName : "OVR_multiview2" ) : OVR_multiview2 | null ;
47334786 getExtension ( extensionName : "WEBGL_color_buffer_float" ) : WEBGL_color_buffer_float | null ;
47344787 getExtension ( extensionName : "WEBGL_compressed_texture_astc" ) : WEBGL_compressed_texture_astc | null ;
47354788 getExtension ( extensionName : "WEBGL_compressed_texture_etc" ) : WEBGL_compressed_texture_etc | null ;
47364789 getExtension ( extensionName : "WEBGL_compressed_texture_etc1" ) : WEBGL_compressed_texture_etc1 | null ;
4790+ getExtension ( extensionName : "WEBGL_compressed_texture_s3tc" ) : WEBGL_compressed_texture_s3tc | null ;
47374791 getExtension ( extensionName : "WEBGL_compressed_texture_s3tc_srgb" ) : WEBGL_compressed_texture_s3tc_srgb | null ;
4792+ getExtension ( extensionName : "WEBGL_debug_renderer_info" ) : WEBGL_debug_renderer_info | null ;
47384793 getExtension ( extensionName : "WEBGL_debug_shaders" ) : WEBGL_debug_shaders | null ;
4794+ getExtension ( extensionName : "WEBGL_depth_texture" ) : WEBGL_depth_texture | null ;
47394795 getExtension ( extensionName : "WEBGL_draw_buffers" ) : WEBGL_draw_buffers | null ;
47404796 getExtension ( extensionName : "WEBGL_lose_context" ) : WEBGL_lose_context | null ;
4741- getExtension ( extensionName : "WEBGL_depth_texture" ) : WEBGL_depth_texture | null ;
4742- getExtension ( extensionName : "WEBGL_debug_renderer_info" ) : WEBGL_debug_renderer_info | null ;
4743- getExtension ( extensionName : "WEBGL_compressed_texture_s3tc" ) : WEBGL_compressed_texture_s3tc | null ;
4744- getExtension ( extensionName : "OES_texture_half_float_linear" ) : OES_texture_half_float_linear | null ;
4745- getExtension ( extensionName : "OES_texture_half_float" ) : OES_texture_half_float | null ;
4746- getExtension ( extensionName : "OES_texture_float_linear" ) : OES_texture_float_linear | null ;
4747- getExtension ( extensionName : "OES_texture_float" ) : OES_texture_float | null ;
4748- getExtension ( extensionName : "OES_standard_derivatives" ) : OES_standard_derivatives | null ;
4749- getExtension ( extensionName : "OES_element_index_uint" ) : OES_element_index_uint | null ;
4750- getExtension ( extensionName : "ANGLE_instanced_arrays" ) : ANGLE_instanced_arrays | null ;
4797+ getExtension ( extensionName : "WEBGL_multi_draw" ) : WEBGL_multi_draw | null ;
47514798 getExtension ( name : string ) : any ;
47524799 getFramebufferAttachmentParameter ( target : GLenum , attachment : GLenum , pname : GLenum ) : any ;
47534800 getParameter ( pname : GLenum ) : any ;
@@ -5876,13 +5923,13 @@ type NamedCurve = string;
58765923type OnErrorEventHandler = OnErrorEventHandlerNonNull | null ;
58775924type PerformanceEntryList = PerformanceEntry [ ] ;
58785925type PushMessageDataInit = BufferSource | string ;
5879- type ReadableStreamController < T > = ReadableStreamDefaultController < T > ;
5880- type ReadableStreamReadResult < T > = ReadableStreamReadValueResult < T > | ReadableStreamReadDoneResult ;
5881- type ReadableStreamReader < T > = ReadableStreamDefaultReader < T > ;
5926+ type ReadableStreamController < T > = ReadableStreamDefaultController < T > | ReadableByteStreamController ;
5927+ type ReadableStreamReadResult < T > = ReadableStreamReadValueResult < T > | ReadableStreamReadDoneResult < T > ;
5928+ type ReadableStreamReader < T > = ReadableStreamDefaultReader < T > | ReadableStreamBYOBReader ;
58825929type RequestInfo = Request | string ;
58835930type TexImageSource = ImageBitmap | ImageData | OffscreenCanvas ;
58845931type TimerHandler = string | Function ;
5885- type Transferable = ArrayBuffer | MessagePort | ImageBitmap ;
5932+ type Transferable = OffscreenCanvas | ImageBitmap | MessagePort | ReadableStream | WritableStream | TransformStream | ArrayBuffer ;
58865933type Uint32List = Uint32Array | GLuint [ ] ;
58875934type VibratePattern = number | number [ ] ;
58885935type XMLHttpRequestBodyInit = Blob | BufferSource | FormData | URLSearchParams | string ;
@@ -5916,6 +5963,8 @@ type PredefinedColorSpace = "display-p3" | "srgb";
59165963type PremultiplyAlpha = "default" | "none" | "premultiply" ;
59175964type PushEncryptionKeyName = "auth" | "p256dh" ;
59185965type RTCEncodedVideoFrameType = "delta" | "empty" | "key" ;
5966+ type ReadableStreamReaderMode = "byob" ;
5967+ type ReadableStreamType = "bytes" ;
59195968type ReferrerPolicy = "" | "no-referrer" | "no-referrer-when-downgrade" | "origin" | "origin-when-cross-origin" | "same-origin" | "strict-origin" | "strict-origin-when-cross-origin" | "unsafe-url" ;
59205969type RequestCache = "default" | "force-cache" | "no-cache" | "no-store" | "only-if-cached" | "reload" ;
59215970type RequestCredentials = "include" | "omit" | "same-origin" ;
0 commit comments