Skip to content

Change the return types of several well-known functions to NodeListOf<Element> #3774

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 2 commits into from
Jul 9, 2015
Merged
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
16 changes: 8 additions & 8 deletions src/lib/dom.generated.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2254,12 +2254,12 @@ interface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEven
* @param elementId String that specifies the ID value. Case-insensitive.
*/
getElementById(elementId: string): HTMLElement;
getElementsByClassName(classNames: string): NodeList;
getElementsByClassName(classNames: string): NodeListOf<Element>;
/**
* Gets a collection of objects based on the value of the NAME or ID attribute.
* @param elementName Gets a collection of objects based on the value of the NAME or ID attribute.
*/
getElementsByName(elementName: string): NodeList;
getElementsByName(elementName: string): NodeListOf<Element>;
/**
* Retrieves a collection of objects based on the specified element name.
* @param name Specifies the name of an element.
Expand Down Expand Up @@ -2437,8 +2437,8 @@ interface Document extends Node, GlobalEventHandlers, NodeSelector, DocumentEven
getElementsByTagName(tagname: "wbr"): NodeListOf<HTMLElement>;
getElementsByTagName(tagname: "x-ms-webview"): NodeListOf<MSHTMLWebViewElement>;
getElementsByTagName(tagname: "xmp"): NodeListOf<HTMLBlockElement>;
getElementsByTagName(tagname: string): NodeList;
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeList;
getElementsByTagName(tagname: string): NodeListOf<Element>;
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeListOf<Element>;
/**
* Returns an object representing the current selection of the document that is loaded into the object displaying a webpage.
*/
Expand Down Expand Up @@ -2890,8 +2890,8 @@ interface Element extends Node, GlobalEventHandlers, ElementTraversal, NodeSelec
getElementsByTagName(name: "wbr"): NodeListOf<HTMLElement>;
getElementsByTagName(name: "x-ms-webview"): NodeListOf<MSHTMLWebViewElement>;
getElementsByTagName(name: "xmp"): NodeListOf<HTMLBlockElement>;
getElementsByTagName(name: string): NodeList;
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeList;
getElementsByTagName(name: string): NodeListOf<Element>;
getElementsByTagNameNS(namespaceURI: string, localName: string): NodeListOf<Element>;
hasAttribute(name: string): boolean;
hasAttributeNS(namespaceURI: string, localName: string): boolean;
msGetRegionContent(): MSRangeCollection;
Expand Down Expand Up @@ -3903,7 +3903,7 @@ interface HTMLElement extends Element {
contains(child: HTMLElement): boolean;
dragDrop(): boolean;
focus(): void;
getElementsByClassName(classNames: string): NodeList;
getElementsByClassName(classNames: string): NodeListOf<Element>;
insertAdjacentElement(position: string, insertedElement: Element): Element;
insertAdjacentHTML(where: string, html: string): void;
insertAdjacentText(where: string, text: string): void;
Expand Down Expand Up @@ -12487,7 +12487,7 @@ interface NavigatorStorageUtils {

interface NodeSelector {
querySelector(selectors: string): Element;
querySelectorAll(selectors: string): NodeList;
querySelectorAll(selectors: string): NodeListOf<Element>;
}

interface RandomSource {
Expand Down