diff --git a/fullscreen.bs b/fullscreen.bs index b43e520..123e230 100644 --- a/fullscreen.bs +++ b/fullscreen.bs @@ -110,8 +110,8 @@ and add it to its node document's top layer.

Whenever the removing steps run with an oldNode, run these steps:

    -
  1. Let nodes be oldNode's inclusive descendants that have their - fullscreen flag set, in tree order. +

  2. Let nodes be oldNode's shadow-including inclusive descendants + that have their fullscreen flag set, in shadow-including tree order.

  3. For each node in nodes, run these substeps: @@ -153,7 +153,6 @@ partial interface Element { partial interface Document { [LenientSetter] readonly attribute boolean fullscreenEnabled; - [LenientSetter] readonly attribute Element? fullscreenElement; [LenientSetter] readonly attribute boolean fullscreen; // historical Promise<void> exitFullscreen(); @@ -161,6 +160,10 @@ partial interface Document { attribute EventHandler onfullscreenchange; attribute EventHandler onfullscreenerror; }; + +partial interface DocumentOrShadowRoot { + [LenientSetter] readonly attribute Element? fullscreenElement; +};

    @@ -171,20 +174,22 @@ partial interface Document {

    Returns true if document has the ability to display elements fullscreen and fullscreen is supported, or false otherwise. -

    document . {{Document/fullscreenElement}} -

    Returns document's fullscreen element. -

    promise = document . {{Document/exitFullscreen()}}

    Stops document's fullscreen element from being displayed fullscreen and fulfills promise when done. + +

    document . {{DocumentOrShadowRoot/fullscreenElement}} +

    Returns document's fullscreen element. + +

    shadowroot . {{DocumentOrShadowRoot/fullscreenElement}} +

    Returns shadowroot's fullscreen element.

    A fullscreen element ready check for an element element returns true if all of the following are true, and false otherwise: