@@ -165,8 +165,18 @@ steps:
165
165
<h2 id=api>API</h2>
166
166
167
167
<pre class=idl>
168
+ enum <dfn>FullscreenNavigationUI</dfn> {
169
+ "auto",
170
+ "show",
171
+ "hide"
172
+ };
173
+
174
+ dictionary <dfn>FullscreenOptions</dfn> {
175
+ FullscreenNavigationUI navigationUI = "auto";
176
+ };
177
+
168
178
partial interface Element {
169
- Promise<void> requestFullscreen();
179
+ Promise<void> requestFullscreen(optional FullscreenOptions options );
170
180
171
181
attribute EventHandler onfullscreenchange;
172
182
attribute EventHandler onfullscreenerror;
@@ -190,8 +200,15 @@ partial interface DocumentOrShadowRoot {
190
200
interface, which is implemented by Document and HTMLElement, not Element. -->
191
201
192
202
<dl class=domintro>
193
- <dt><code><var> promise</var> = <var> element</var> . {{Element/requestFullscreen()}} </code>
194
- <dd><p> Displays <var> element</var> fullscreen and resolves <var> promise</var> when done.
203
+ <dt><code><var> promise</var> = <var> element</var> . <a method for=Element lt=requestFullscreen()>requestFullscreen([<var>options</var>])</a> </code>
204
+ <dd>
205
+ Displays <var> element</var> fullscreen and resolves <var> promise</var> when done.
206
+
207
+ When supplied, <var> options</var> 's <code> navigationUI</code> member indicates whether showing
208
+ navigation UI while in fullscreen is preferred or not. If set to "<code> show</code> ", navigation
209
+ simplicity is preferred over screen space, and if set to "<code> hide</code> ", more screen space
210
+ is preferred. User agents are always free to honor user preference over the application's. The
211
+ default value "<code> auto</code> " indicates no application preference.
195
212
196
213
<dt><code><var> document</var> . {{Document/fullscreenEnabled}} </code>
197
214
<dd><p> Returns true if <var> document</var> has the ability to display <a>elements</a> fullscreen
@@ -219,8 +236,8 @@ if all of the following are true, and false otherwise:
219
236
<!-- cross-process, recursive -->
220
237
</ul>
221
238
222
- <p> The <dfn method for=Element><code>requestFullscreen()</code></dfn> method, when invoked, must run
223
- these steps:
239
+ <p> The <dfn method for=Element><code>requestFullscreen(<var>options</var> )</code></dfn> method,
240
+ when invoked, must run these steps:
224
241
225
242
<ol>
226
243
<li><p> Let <var> pending</var> be the <a>context object</a> .
@@ -255,11 +272,36 @@ these steps:
255
272
256
273
<li><p> Return <var> promise</var> , and run the remaining steps <a>in parallel</a> .
257
274
258
- <li><p> If <var> error</var> is false: Resize <var> pendingDoc</var> 's
259
- <a>top-level browsing context</a> 's <a>active document</a>' s viewport's dimensions to match the
260
- dimensions of the screen of the output device. Optionally display a message how the end user can
261
- revert this.
262
- <!-- cross-process -->
275
+ <li>
276
+ <p> If <var> error</var> is false: Resize <var> pendingDoc</var> 's
277
+ <a>top-level browsing context</a> 's <a>active document</a>' s viewport's dimensions, optionally
278
+ taking into account <var> options</var> 's <code> navigationUI</code> member:
279
+ <!-- cross-process -->
280
+
281
+ <table>
282
+ <thead>
283
+ <tr>
284
+ <th> value</th>
285
+ <th> viewport dimensions</th>
286
+ </tr>
287
+ </thead>
288
+ <tbody>
289
+ <tr>
290
+ <td> "<code> hide</code> "</td>
291
+ <td> full dimensions of the screen of the output device</td>
292
+ </tr>
293
+ <tr>
294
+ <td> "<code> show</code> "</td>
295
+ <td> dimensions of the screen of the output device clamped to allow the user agent to show page navigation controls</td>
296
+ </tr>
297
+ <tr>
298
+ <td> "<code> auto</code> "</td>
299
+ <td> user-agent defined, but matching one of the above</td>
300
+ </tr>
301
+ </tbody>
302
+ </table>
303
+
304
+ <p> Optionally display a message how the end user can revert this.
263
305
264
306
<li>
265
307
<p> If any of the following conditions are false, then set <var> error</var> to true:
0 commit comments