ShadowRoot:fullscreenElement 属性
Limited availability
This feature is not Baseline because it does not work in some of the most widely-used browsers.
ShadowRoot
接口的 fullscreenElement
只读属性返回影子树中当前全屏显示的元素。
值
当前以全屏模式显示的 Element
,若无全屏元素则为 null
。
示例
js
let customElem = document.querySelector("my-shadow-dom-element");
let shadow = customElem.shadowRoot;
let fullscreenElem = shadow.fullscreenElement;
规范
Specification |
---|
Fullscreen API Standard # ref-for-dom-document-fullscreenelement② |
浏览器兼容性
BCD tables only load in the browser