Currently the FullscreenElement is implemented only within the Document as follow.
|
partial interface Document { |
|
[LegacyLenientSetter] readonly attribute boolean fullscreenEnabled; |
|
[LegacyLenientSetter] readonly attribute Element? fullscreenElement; |
|
[LegacyLenientSetter] readonly attribute boolean fullscreen; // historical |
|
/// <https://fullscreen.spec.whatwg.org/#dom-document-fullscreenelement> |
|
fn GetFullscreenElement(&self) -> Option<DomRoot<Element>> { |
|
// TODO ShadowRoot |
|
self.fullscreen_element.get() |
|
} |
But it should be implemented in DocumentOrShadowRoot mixin by following the spec (https://fullscreen.spec.whatwg.org/#ref-for-dom-document-fullscreenelement) and putting it in the DocumentOrShadowRoot webidl.
|
interface mixin DocumentOrShadowRoot { |
|
// Selection? getSelection(); |
|
Element? elementFromPoint (double x, double y); |
|
sequence<Element> elementsFromPoint (double x, double y); |
|
// CaretPosition? caretPositionFromPoint (double x, double y); |
|
readonly attribute Element? activeElement; |
|
readonly attribute StyleSheetList styleSheets; |
|
}; |
And, followed by the implementation of getter steps (https://fullscreen.spec.whatwg.org/#dom-document-fullscreenelement).
Currently the
FullscreenElementis implemented only within theDocumentas follow.servo/components/script_bindings/webidls/Document.webidl
Lines 201 to 204 in f1440d3
servo/components/script/dom/document.rs
Lines 6437 to 6441 in f1440d3
But it should be implemented in
DocumentOrShadowRootmixin by following the spec (https://fullscreen.spec.whatwg.org/#ref-for-dom-document-fullscreenelement) and putting it in theDocumentOrShadowRootwebidl.servo/components/script_bindings/webidls/DocumentOrShadowRoot.webidl
Lines 10 to 17 in f1440d3
And, followed by the implementation of getter steps (https://fullscreen.spec.whatwg.org/#dom-document-fullscreenelement).