Skip to content

Commit a068adb

Browse files
committed
Revert "[cssom-view] Kill DOMRectList. Fixes https://www.w3.org/Bugs/Public/show_bug.cgi?id=26200"
This reverts commit ebc0d23. See w3c#1479
1 parent 02e8097 commit a068adb

1 file changed

Lines changed: 7 additions & 9 deletions

File tree

cssom-view/Overview.bs

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1080,7 +1080,7 @@ dictionary ScrollIntoViewOptions : ScrollOptions {
10801080
};
10811081

10821082
partial interface Element {
1083-
sequence<DOMRect> getClientRects();
1083+
DOMRectList getClientRects();
10841084
[NewObject] DOMRect getBoundingClientRect();
10851085
void scrollIntoView();
10861086
void scrollIntoView((boolean or object) arg);
@@ -1103,9 +1103,9 @@ partial interface Element {
11031103

11041104
The <dfn method for=Element>getClientRects()</dfn> method, when invoked, must return the result of the following algorithm:
11051105

1106-
1. If the element on which it was invoked does not have an associated <a>layout box</a> return an empty sequence and stop this algorithm.
1107-
1. If the element has an associated <a>SVG layout box</a> return a sequence containing a single {{DOMRect}} object that describes the bounding box of the element as defined by the SVG specification, applying the <a>transforms</a> that apply to the element and its ancestors.
1108-
1. Return a sequence containing {{DOMRect}} objects in content order, one for each <a spec=css-break>box fragment</a>, describing its border area (including those with a height or width of zero) with the following constraints:
1106+
1. If the element on which it was invoked does not have an associated <a>layout box</a> return an empty {{DOMRectList}} and stop this algorithm.
1107+
1. If the element has an associated <a>SVG layout box</a> return a {{DOMRectList}} object containing a single {{DOMRect}} object that describes the bounding box of the element as defined by the SVG specification, applying the <a>transforms</a> that apply to the element and its ancestors.
1108+
1. Return a {{DOMRectList}} object containing {{DOMRect}} objects in content order, one for each <a spec=css-break>box fragment</a>, describing its border area (including those with a height or width of zero) with the following constraints:
11091109

11101110
* Apply the <a>transforms</a> that apply to the element and its ancestors.
11111111
* If the element on which the method was invoked has a computed value for the 'display' property of ''table'' or ''inline-table'' include both the table box and the caption box, if any, but not the anonymous container box.
@@ -1464,16 +1464,14 @@ first <a>CSS layout box</a> associated with the element, relative to the <a>init
14641464

14651465
<pre class=idl>
14661466
partial interface Range {
1467-
sequence&lt;DOMRect> getClientRects();
1467+
DOMRectList getClientRects();
14681468
[NewObject] DOMRect getBoundingClientRect();
14691469
};
14701470
</pre>
14711471

14721472
The <dfn method for=Range>getClientRects()</dfn> method, when invoked, must return an empty
1473-
sequence if the range is not in the document and
1474-
otherwise a sequence object containing
1475-
{{DOMRect}} objects in content order that matches the
1476-
following constraints:
1473+
{{DOMRectList}} object if the range is not in the document and otherwise a {{DOMRectList}} object
1474+
containing a list of {{DOMRect}} objects in content order that matches the following constraints:
14771475

14781476
* For each element selected by the range, whose parent is not selected by the range, include the border areas returned by invoking {{Element/getClientRects()}} on the element.
14791477
* For each {{Text}} node selected or partially selected by the range (including when the

0 commit comments

Comments
 (0)