@xmldom/xmldom
Advanced tools
Comparing version 0.9.1 to 0.9.2
@@ -7,2 +7,15 @@ # Changelog | ||
## [0.9.2](https://github.com/xmldom/xmldom/compare/0.9.1...0.9.2) | ||
### Feature | ||
- add `Element.getElementsByClassName` [`#722`](https://github.com/xmldom/xmldom/pull/722) | ||
### Fixed | ||
- add missing types for `Document.documentElement` and `Element.tagName` [`#721`](https://github.com/xmldom/xmldom/pull/721) [`#720`](https://github.com/xmldom/xmldom/issues/720) | ||
Thank you, [@censujiang](https://github.com/censujiang), [@Mathias-S](https://github.com/Mathias-S), for your contributions | ||
## [0.9.1](https://github.com/xmldom/xmldom/compare/0.9.0...0.9.1) | ||
@@ -20,4 +33,3 @@ | ||
Thank you, [@krystofwoldrich](https://github.com/krystofwoldrich), [@marvinruder](https://github.com/marvinruder), | ||
[@amacneil](https://github.com/amacneil), [@defunctzombie](https://github.com/defunctzombie), | ||
Thank you, [@krystofwoldrich](https://github.com/krystofwoldrich), [@marvinruder](https://github.com/marvinruder), [@amacneil](https://github.com/amacneil), [@defunctzombie](https://github.com/defunctzombie), | ||
[@tjhorner](https://github.com/tjhorner), [@danon](https://github.com/danon), for your contributions | ||
@@ -24,0 +36,0 @@ |
@@ -774,2 +774,9 @@ declare module '@xmldom/xmldom' { | ||
/** | ||
* Returns the HTML-uppercased qualified name. | ||
* | ||
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/tagName) | ||
*/ | ||
readonly tagName: string; | ||
/** | ||
* Returns element's first attribute whose qualified name is qualifiedName, and null if there | ||
@@ -801,3 +808,18 @@ * is no such attribute otherwise. | ||
): Attr | null; | ||
/** [MDN Reference](https://developer.mozilla.org/docs/Web/API/Element/getBoundingClientRect) */ | ||
/** | ||
* Returns a LiveNodeList of all child elements which have **all** of the given class | ||
* name(s). | ||
* | ||
* Returns an empty list if `classNames` is an empty string or only contains HTML white space | ||
* characters. | ||
* | ||
* Warning: This returns a live LiveNodeList. | ||
* Changes in the DOM will reflect in the array as the changes occur. | ||
* If an element selected by this array no longer qualifies for the selector, | ||
* it will automatically be removed. Be aware of this for iteration purposes. | ||
* | ||
* @see https://developer.mozilla.org/en-US/docs/Web/API/Element/getElementsByClassName | ||
* @see https://dom.spec.whatwg.org/#concept-getelementsbyclassname | ||
*/ | ||
getElementsByClassName(classNames: string): LiveNodeList; | ||
@@ -1072,2 +1094,8 @@ /** | ||
readonly doctype: DocumentType | null; | ||
/** | ||
* Gets a reference to the root node of the document. | ||
* | ||
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/Document/documentElement) | ||
*/ | ||
readonly documentElement: Element | null; | ||
@@ -1111,3 +1139,2 @@ /** | ||
createElement(tagName: string): Element; | ||
@@ -1135,6 +1162,3 @@ | ||
*/ | ||
createElementNS( | ||
namespace: string | null, | ||
qualifiedName: string, | ||
): Element; | ||
createElementNS(namespace: string | null, qualifiedName: string): Element; | ||
@@ -1173,9 +1197,9 @@ /** | ||
/** | ||
* The `getElementsByClassName` method of `Document` interface returns an array-like object | ||
* of all child elements which have **all** of the given class name(s). | ||
* Returns a LiveNodeList of all child elements which have **all** of the given class | ||
* name(s). | ||
* | ||
* Returns an empty list if `classeNames` is an empty string or only contains HTML white | ||
* space characters. | ||
* Returns an empty list if `classNames` is an empty string or only contains HTML white space | ||
* characters. | ||
* | ||
* Warning: This is a live LiveNodeList. | ||
* Warning: This returns a live LiveNodeList. | ||
* Changes in the DOM will reflect in the array as the changes occur. | ||
@@ -1185,5 +1209,2 @@ * If an element selected by this array no longer qualifies for the selector, | ||
* | ||
* @param {string} classNames | ||
* Is a string representing the class name(s) to match; multiple class names are separated by | ||
* (ASCII-)whitespace. | ||
* @see https://developer.mozilla.org/en-US/docs/Web/API/Document/getElementsByClassName | ||
@@ -1190,0 +1211,0 @@ * @see https://dom.spec.whatwg.org/#concept-getelementsbyclassname |
{ | ||
"name": "@xmldom/xmldom", | ||
"version": "0.9.1", | ||
"version": "0.9.2", | ||
"description": "A pure JavaScript W3C standard-based (XML DOM Level 2 Core) DOMParser and XMLSerializer module.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
Sorry, the diff of this file is too big to display
351787
8961