Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

DocumentOrShadowRoot

interface DocumentOrShadowRoot {
readonly activeElement: Element | null;
adoptedStyleSheets: CSSStyleSheet[];
readonly fullscreenElement: Element | null;
readonly pictureInPictureElement: Element | null;
readonly pointerLockElement: Element | null;
readonly styleSheets: StyleSheetList;
elementFromPoint(x: number, y: number): Element | null;
elementsFromPoint(x: number, y: number): Element[];
getAnimations(): Animation[];
}

§Properties

§
readonly activeElement: Element | null
[src]

Returns the deepest element in the document through which or to which key events are being routed. This is, roughly speaking, the focused element in the document.

For the purposes of this API, when a child browsing context is focused, its container is focused in the parent browsing context. For example, if the user moves the focus to a text control in an iframe, the iframe is the element returned by the activeElement API in the iframe's node document.

Similarly, when the focused element is in a different node tree than documentOrShadowRoot, the element returned will be the host that's located in the same node tree as documentOrShadowRoot if documentOrShadowRoot is a shadow-including inclusive ancestor of the focused element, and null if not.

§
adoptedStyleSheets: CSSStyleSheet[]
[src]
§
readonly fullscreenElement: Element | null
[src]

Returns document's fullscreen element.

§
readonly pictureInPictureElement: Element | null
[src]
§
readonly pointerLockElement: Element | null
[src]
§
readonly styleSheets: StyleSheetList
[src]

Retrieves a collection of styleSheet objects representing the style sheets that correspond to each instance of a link or style object in the document.

§Methods

§
elementFromPoint(x: number, y: number): Element | null
[src]

Returns the element for the specified x coordinate and the specified y coordinate.

@param x

The x-offset

@param y

The y-offset

§
elementsFromPoint(x: number, y: number): Element[]
[src]
§
getAnimations(): Animation[]
[src]