Skip to content

Upgrade to [email protected] #1344

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 8, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions baselines/audioworklet.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -512,6 +512,19 @@ declare var PromiseRejectionEvent: {
new(type: string, eventInitDict: PromiseRejectionEventInit): PromiseRejectionEvent;
};

interface ReadableByteStreamController {
readonly byobRequest: ReadableStreamBYOBRequest | null;
readonly desiredSize: number | null;
close(): void;
enqueue(chunk: ArrayBufferView): void;
error(e?: any): void;
}

declare var ReadableByteStreamController: {
prototype: ReadableByteStreamController;
new(): ReadableByteStreamController;
};

/** This Streams API interface represents a readable stream of byte data. The Fetch API offers a concrete instance of a ReadableStream through the body property of a Response object. */
interface ReadableStream<R = any> {
readonly locked: boolean;
Expand All @@ -527,6 +540,27 @@ declare var ReadableStream: {
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
read(view: ArrayBufferView): Promise<ReadableStreamReadResult<ArrayBufferView>>;
releaseLock(): void;
}

declare var ReadableStreamBYOBReader: {
prototype: ReadableStreamBYOBReader;
new(stream: ReadableStream): ReadableStreamBYOBReader;
};

interface ReadableStreamBYOBRequest {
readonly view: ArrayBufferView | null;
respond(bytesWritten: number): void;
respondWithNewView(view: ArrayBufferView): void;
}

declare var ReadableStreamBYOBRequest: {
prototype: ReadableStreamBYOBRequest;
new(): ReadableStreamBYOBRequest;
};

interface ReadableStreamDefaultController<R = any> {
readonly desiredSize: number | null;
close(): void;
Expand Down
42 changes: 40 additions & 2 deletions baselines/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2175,6 +2175,7 @@ declare var AudioBufferSourceNode: {
/** An audio-processing graph built from audio modules linked together, each represented by an AudioNode. */
interface AudioContext extends BaseAudioContext {
readonly baseLatency: number;
readonly outputLatency: number;
close(): Promise<void>;
createMediaElementSource(mediaElement: HTMLMediaElement): MediaElementAudioSourceNode;
createMediaStreamDestination(): MediaStreamAudioDestinationNode;
Expand Down Expand Up @@ -3279,6 +3280,8 @@ interface CSSStyleSheet extends StyleSheet {
insertRule(rule: string, index?: number): number;
/** @deprecated */
removeRule(index?: number): void;
replace(text: string): Promise<CSSStyleSheet>;
replaceSync(text: string): void;
}

declare var CSSStyleSheet: {
Expand Down Expand Up @@ -4718,6 +4721,7 @@ interface DocumentOrShadowRoot {
* Similarly, when the focused element is in a different node tree than documentOrShadowRoot, the element returned will be the host that's located in the same node tree as documentOrShadowRoot if documentOrShadowRoot is a shadow-including inclusive ancestor of the focused element, and null if not.
*/
readonly activeElement: Element | null;
adoptedStyleSheets: CSSStyleSheet[];
/** Returns document's fullscreen element. */
readonly fullscreenElement: Element | null;
readonly pictureInPictureElement: Element | null;
Expand Down Expand Up @@ -11344,6 +11348,19 @@ declare var Range: {
toString(): string;
};

interface ReadableByteStreamController {
readonly byobRequest: ReadableStreamBYOBRequest | null;
readonly desiredSize: number | null;
close(): void;
enqueue(chunk: ArrayBufferView): void;
error(e?: any): void;
}

declare var ReadableByteStreamController: {
prototype: ReadableByteStreamController;
new(): ReadableByteStreamController;
};

/** This Streams API interface represents a readable stream of byte data. The Fetch API offers a concrete instance of a ReadableStream through the body property of a Response object. */
interface ReadableStream<R = any> {
readonly locked: boolean;
Expand All @@ -11359,6 +11376,27 @@ declare var ReadableStream: {
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
read(view: ArrayBufferView): Promise<ReadableStreamReadResult<ArrayBufferView>>;
releaseLock(): void;
}

declare var ReadableStreamBYOBReader: {
prototype: ReadableStreamBYOBReader;
new(stream: ReadableStream): ReadableStreamBYOBReader;
};

interface ReadableStreamBYOBRequest {
readonly view: ArrayBufferView | null;
respond(bytesWritten: number): void;
respondWithNewView(view: ArrayBufferView): void;
}

declare var ReadableStreamBYOBRequest: {
prototype: ReadableStreamBYOBRequest;
new(): ReadableStreamBYOBRequest;
};

interface ReadableStreamDefaultController<R = any> {
readonly desiredSize: number | null;
close(): void;
Expand Down Expand Up @@ -16552,7 +16590,7 @@ interface Window extends EventTarget, AnimationFrameProvider, GlobalEventHandler
/** Returns true if the toolbar is visible; otherwise, returns false. */
readonly toolbar: BarProp;
readonly top: WindowProxy | null;
readonly visualViewport: VisualViewport;
readonly visualViewport: VisualViewport | null;
readonly window: Window & typeof globalThis;
alert(message?: any): void;
blur(): void;
Expand Down Expand Up @@ -17625,7 +17663,7 @@ declare var statusbar: BarProp;
/** Returns true if the toolbar is visible; otherwise, returns false. */
declare var toolbar: BarProp;
declare var top: WindowProxy | null;
declare var visualViewport: VisualViewport;
declare var visualViewport: VisualViewport | null;
declare var window: Window & typeof globalThis;
declare function alert(message?: any): void;
declare function blur(): void;
Expand Down
34 changes: 34 additions & 0 deletions baselines/serviceworker.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2576,6 +2576,19 @@ declare var PushSubscriptionOptions: {
new(): PushSubscriptionOptions;
};

interface ReadableByteStreamController {
readonly byobRequest: ReadableStreamBYOBRequest | null;
readonly desiredSize: number | null;
close(): void;
enqueue(chunk: ArrayBufferView): void;
error(e?: any): void;
}

declare var ReadableByteStreamController: {
prototype: ReadableByteStreamController;
new(): ReadableByteStreamController;
};

/** This Streams API interface represents a readable stream of byte data. The Fetch API offers a concrete instance of a ReadableStream through the body property of a Response object. */
interface ReadableStream<R = any> {
readonly locked: boolean;
Expand All @@ -2591,6 +2604,27 @@ declare var ReadableStream: {
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
read(view: ArrayBufferView): Promise<ReadableStreamReadResult<ArrayBufferView>>;
releaseLock(): void;
}

declare var ReadableStreamBYOBReader: {
prototype: ReadableStreamBYOBReader;
new(stream: ReadableStream): ReadableStreamBYOBReader;
};

interface ReadableStreamBYOBRequest {
readonly view: ArrayBufferView | null;
respond(bytesWritten: number): void;
respondWithNewView(view: ArrayBufferView): void;
}

declare var ReadableStreamBYOBRequest: {
prototype: ReadableStreamBYOBRequest;
new(): ReadableStreamBYOBRequest;
};

interface ReadableStreamDefaultController<R = any> {
readonly desiredSize: number | null;
close(): void;
Expand Down
34 changes: 34 additions & 0 deletions baselines/sharedworker.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2455,6 +2455,19 @@ declare var PushSubscriptionOptions: {
new(): PushSubscriptionOptions;
};

interface ReadableByteStreamController {
readonly byobRequest: ReadableStreamBYOBRequest | null;
readonly desiredSize: number | null;
close(): void;
enqueue(chunk: ArrayBufferView): void;
error(e?: any): void;
}

declare var ReadableByteStreamController: {
prototype: ReadableByteStreamController;
new(): ReadableByteStreamController;
};

/** This Streams API interface represents a readable stream of byte data. The Fetch API offers a concrete instance of a ReadableStream through the body property of a Response object. */
interface ReadableStream<R = any> {
readonly locked: boolean;
Expand All @@ -2470,6 +2483,27 @@ declare var ReadableStream: {
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
read(view: ArrayBufferView): Promise<ReadableStreamReadResult<ArrayBufferView>>;
releaseLock(): void;
}

declare var ReadableStreamBYOBReader: {
prototype: ReadableStreamBYOBReader;
new(stream: ReadableStream): ReadableStreamBYOBReader;
};

interface ReadableStreamBYOBRequest {
readonly view: ArrayBufferView | null;
respond(bytesWritten: number): void;
respondWithNewView(view: ArrayBufferView): void;
}

declare var ReadableStreamBYOBRequest: {
prototype: ReadableStreamBYOBRequest;
new(): ReadableStreamBYOBRequest;
};

interface ReadableStreamDefaultController<R = any> {
readonly desiredSize: number | null;
close(): void;
Expand Down
34 changes: 34 additions & 0 deletions baselines/webworker.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2674,6 +2674,19 @@ declare var RTCEncodedVideoFrame: {
new(): RTCEncodedVideoFrame;
};

interface ReadableByteStreamController {
readonly byobRequest: ReadableStreamBYOBRequest | null;
readonly desiredSize: number | null;
close(): void;
enqueue(chunk: ArrayBufferView): void;
error(e?: any): void;
}

declare var ReadableByteStreamController: {
prototype: ReadableByteStreamController;
new(): ReadableByteStreamController;
};

/** This Streams API interface represents a readable stream of byte data. The Fetch API offers a concrete instance of a ReadableStream through the body property of a Response object. */
interface ReadableStream<R = any> {
readonly locked: boolean;
Expand All @@ -2689,6 +2702,27 @@ declare var ReadableStream: {
new<R = any>(underlyingSource?: UnderlyingSource<R>, strategy?: QueuingStrategy<R>): ReadableStream<R>;
};

interface ReadableStreamBYOBReader extends ReadableStreamGenericReader {
read(view: ArrayBufferView): Promise<ReadableStreamReadResult<ArrayBufferView>>;
releaseLock(): void;
}

declare var ReadableStreamBYOBReader: {
prototype: ReadableStreamBYOBReader;
new(stream: ReadableStream): ReadableStreamBYOBReader;
};

interface ReadableStreamBYOBRequest {
readonly view: ArrayBufferView | null;
respond(bytesWritten: number): void;
respondWithNewView(view: ArrayBufferView): void;
}

declare var ReadableStreamBYOBRequest: {
prototype: ReadableStreamBYOBRequest;
new(): ReadableStreamBYOBRequest;
};

interface ReadableStreamDefaultController<R = any> {
readonly desiredSize: number | null;
close(): void;
Expand Down
17 changes: 17 additions & 0 deletions inputfiles/overridingTypes.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -2420,6 +2420,23 @@
}
}
},
"ReadableStreamBYOBReader": {
"methods": {
"method": {
"read": {
"signature": {
"0": {
"subtype": {
"subtype": {
"type": "ArrayBufferView"
}
}
}
}
}
}
}
},
"ReadableStreamDefaultReader": {
"typeParameters": [
{
Expand Down
Loading