Skip to content

Commit eba2dd3

Browse files
lutienemilio
authored andcommitted
[cssom-view-1] Add emulation for "Web-exposed screen information" with WebDriver BiDi.
1 parent fdc08f7 commit eba2dd3

File tree

1 file changed

+16
-7
lines changed

1 file changed

+16
-7
lines changed

cssom-view-1/Overview.bs

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ spec:css-borders-4; type:property; text:border-top-width
5555
spec:css-borders-4; type:property; text:border-left-width
5656
spec:cssom-view-1; type:dictionary; text:MouseEventInit
5757
spec:cssom-view-1; type:dfn; for:MediaQueryList; text:media
58+
spec:webdriver-bidi; type:dfn; text:WebDriver BiDi emulated screen area
5859
</pre>
5960

6061
<style>
@@ -413,16 +414,24 @@ protect the user's privacy. In order to do so in a consistent manner across APIs
413414
defines the following terms, each having a width and a height, the origin being the top left
414415
corner, and the x- and y-coordinates increase rightwards and downwards, respectively.
415416

416-
The <dfn export>Web-exposed screen area</dfn> is one of the following:
417+
The <dfn export>Web-exposed screen area</dfn> must return the result of the following algorithm:
417418

418-
* The area of the output device, in <a lt=px value>CSS pixels</a>.
419-
* The area of the <a>viewport</a>, in <a lt=px value>CSS pixels</a>.
419+
1. Let <var>target</var> be [=this=]'s [=relevant global object=]'s [=Window/browsing context=].
420+
1. Let |emulated screen area| be the <a>WebDriver BiDi emulated screen area</a> for <var>target</var>.
421+
1. If |emulated screen area| is not null, return |emulated screen area|.
422+
1. Otherwise, return one of the following:
423+
* The area of the output device, in <a lt=px value>CSS pixels</a>.
424+
* The area of the <a>viewport</a>, in <a lt=px value>CSS pixels</a>.
420425

421-
The <dfn export>Web-exposed available screen area</dfn> is one of the following:
426+
The <dfn export>Web-exposed available screen area</dfn> must return the result of the following algorithm:
422427

423-
* The available area of the rendering surface of the output device, in <a lt=px value>CSS pixels</a>.
424-
* The area of the output device, in <a lt=px value>CSS pixels</a>.
425-
* The area of the <a>viewport</a>, in <a lt=px value>CSS pixels</a>.
428+
1. Let <var>target</var> be [=this=]'s [=relevant global object=]'s [=Window/browsing context=].
429+
1. Let |emulated screen area| be the <a>WebDriver BiDi emulated screen area</a> for <var>target</var>.
430+
1. If |emulated screen area| is not null, return |emulated screen area|.
431+
1. Otherwise, return one of the following:
432+
* The available area of the rendering surface of the output device, in <a lt=px value>CSS pixels</a>.
433+
* The area of the output device, in <a lt=px value>CSS pixels</a>.
434+
* The area of the <a>viewport</a>, in <a lt=px value>CSS pixels</a>.
426435

427436

428437
<h2 id=common-infrastructure>Common Infrastructure</h2>

0 commit comments

Comments
 (0)