diff --git a/baselines/dom.generated.d.ts b/baselines/dom.generated.d.ts index c3b4e3afd..4909e5b14 100644 --- a/baselines/dom.generated.d.ts +++ b/baselines/dom.generated.d.ts @@ -6044,6 +6044,12 @@ interface HTMLDocument extends Document { removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void; } +/** @deprecated */ +declare var HTMLDocument: { + prototype: HTMLDocument; + new(): HTMLDocument; +}; + interface HTMLElementEventMap extends ElementEventMap, DocumentAndElementEventHandlersEventMap, GlobalEventHandlersEventMap { } @@ -16000,7 +16006,6 @@ interface WindowEventMap extends GlobalEventHandlersEventMap, WindowEventHandler /** A window containing a DOM document; the document property points to the DOM document loaded in that window. */ interface Window extends EventTarget, AnimationFrameProvider, GlobalEventHandlers, WindowEventHandlers, WindowLocalStorage, WindowOrWorkerGlobalScope, WindowSessionStorage { - HTMLDocument: Document; /** @deprecated This is a legacy alias of `navigator`. */ readonly clientInformation: Navigator; /** Returns true if the window has been closed, false otherwise. */ @@ -17035,7 +17040,6 @@ declare var Image: { declare var Option: { new(text?: string, value?: string, defaultSelected?: boolean, selected?: boolean): HTMLOptionElement; }; -declare var HTMLDocument: Document; /** @deprecated This is a legacy alias of `navigator`. */ declare var clientInformation: Navigator; /** Returns true if the window has been closed, false otherwise. */ diff --git a/inputfiles/addedTypes.jsonc b/inputfiles/addedTypes.jsonc index 4cdfe0cd8..486dfb8f0 100644 --- a/inputfiles/addedTypes.jsonc +++ b/inputfiles/addedTypes.jsonc @@ -330,7 +330,6 @@ "HTMLDocument": { "name": "HTMLDocument", "extends": "Document", - "noInterfaceObject": true, "deprecated": "use Document", "exposed": "Window" }, @@ -366,14 +365,6 @@ } } }, - "properties": { - "property": { - "HTMLDocument": { - "name": "HTMLDocument", - "type": "Document" - } - } - }, "overrideIndexSignatures": [ "[index: number]: Window" ], diff --git a/unittests/files/htmldocument.ts b/unittests/files/htmldocument.ts new file mode 100644 index 000000000..8c64cf1c7 --- /dev/null +++ b/unittests/files/htmldocument.ts @@ -0,0 +1 @@ +document instanceof HTMLDocument