Skip to content

Commit 7fb0d4f

Browse files
committed
Merge pull request #3774 from zhengbli/ms_issue3613
Change the return types of several well-known functions to NodeListOf<Element>
2 parents 9f0fd38 + 33df79d commit 7fb0d4f

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/lib/dom.generated.d.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2254,12 +2254,12 @@ interface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEven
22542254
* @param elementId String that specifies the ID value. Case-insensitive.
22552255
*/
22562256
getElementById(elementId: string): HTMLElement;
2257-
getElementsByClassName(classNames: string): NodeList;
2257+
getElementsByClassName(classNames: string): NodeListOf<Element>;
22582258
/**
22592259
* Gets a collection of objects based on the value of the NAME or ID attribute.
22602260
* @param elementName Gets a collection of objects based on the value of the NAME or ID attribute.
22612261
*/
2262-
getElementsByName(elementName: string): NodeList;
2262+
getElementsByName(elementName: string): NodeListOf<Element>;
22632263
/**
22642264
* Retrieves a collection of objects based on the specified element name.
22652265
* @param name Specifies the name of an element.
@@ -2437,8 +2437,8 @@ interface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEven
24372437
getElementsByTagName(tagname: "wbr"): NodeListOf<HTMLElement>;
24382438
getElementsByTagName(tagname: "x-ms-webview"): NodeListOf<MSHTMLWebViewElement>;
24392439
getElementsByTagName(tagname: "xmp"): NodeListOf<HTMLBlockElement>;
2440-
getElementsByTagName(tagname: string): NodeList;
2441-
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeList;
2440+
getElementsByTagName(tagname: string): NodeListOf<Element>;
2441+
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeListOf<Element>;
24422442
/**
24432443
* Returns an object representing the current selection of the document that is loaded into the object displaying a webpage.
24442444
*/
@@ -2892,8 +2892,8 @@ interface Element extends Node, GlobalEventHandlers, ElementTraversal, NodeSelec
28922892
getElementsByTagName(name: "wbr"): NodeListOf<HTMLElement>;
28932893
getElementsByTagName(name: "x-ms-webview"): NodeListOf<MSHTMLWebViewElement>;
28942894
getElementsByTagName(name: "xmp"): NodeListOf<HTMLBlockElement>;
2895-
getElementsByTagName(name: string): NodeList;
2896-
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeList;
2895+
getElementsByTagName(name: string): NodeListOf<Element>;
2896+
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeListOf<Element>;
28972897
hasAttribute(name: string): boolean;
28982898
hasAttributeNS(namespaceURI: string, localName: string): boolean;
28992899
msGetRegionContent(): MSRangeCollection;
@@ -3903,7 +3903,7 @@ interface HTMLElement extends Element {
39033903
contains(child: HTMLElement): boolean;
39043904
dragDrop(): boolean;
39053905
focus(): void;
3906-
getElementsByClassName(classNames: string): NodeList;
3906+
getElementsByClassName(classNames: string): NodeListOf<Element>;
39073907
insertAdjacentElement(position: string, insertedElement: Element): Element;
39083908
insertAdjacentHTML(where: string, html: string): void;
39093909
insertAdjacentText(where: string, text: string): void;
@@ -12487,7 +12487,7 @@ interface NavigatorStorageUtils {
1248712487

1248812488
interface NodeSelector {
1248912489
querySelector(selectors: string): Element;
12490-
querySelectorAll(selectors: string): NodeList;
12490+
querySelectorAll(selectors: string): NodeListOf<Element>;
1249112491
}
1249212492

1249312493
interface RandomSource {

0 commit comments

Comments
 (0)