Class ResizeObserverEntry
- Namespace
- CSharpToJavaScript.APIs.JS
- Assembly
- CSharpToJavaScript.dll
The ResizeObserverEntry interface represents the object passed to the 'ResizeObserver.ResizeObserver' constructor's callback function, which allows you to access the new dimensions of the Element or SVGElement being observed.
[Value("ResizeObserverEntry")]
public class ResizeObserverEntry
- Inheritance
-
ResizeObserverEntry
- Inherited Members
Remarks
Constructors
ResizeObserverEntry()
public ResizeObserverEntry()
Properties
BorderBoxSize
The borderBoxSize read-only property of
the ResizeObserverEntry interface returns an array containing the new
border box size of the observed element when the callback is run.
[Value("borderBoxSize")]
public ResizeObserverSize[] BorderBoxSize { get; }
Property Value
- ResizeObserverSize[]
An array containing objects with the new border box size of the observed element. The
array is necessary to support elements that have multiple fragments, which occur in
multi-column scenarios. Each object in the array contains two properties:NOTE
For more explanation of writing modes and block and inline
dimensions, read Handling different text directions.
Remarks
ContentBoxSize
The contentBoxSize read-only property of
the ResizeObserverEntry interface returns an array containing the new
content box size of the observed element when the callback is run.
[Value("contentBoxSize")]
public ResizeObserverSize[] ContentBoxSize { get; }
Property Value
- ResizeObserverSize[]
An array containing objects with the new content box size of the observed element.
The array is necessary to support elements that have multiple fragments, which occur in multi-column scenarios. Each object in the array contains two properties:NOTE
For more explanation of writing modes and block and inline
dimensions, read Handling different text directions.
Remarks
ContentRect
The contentRect read-only property of the
ResizeObserverEntry interface returns a 'DOMRectReadOnly'
object containing the new size of the observed element when the callback is run. Note
that this is better supported than BorderBoxSize or
ContentBoxSize, but it is left over from an earlier
implementation of the Resize Observer API, is still included in the spec for web compat
reasons, and may be deprecated in future versions.
[Value("contentRect")]
public DOMRectReadOnly ContentRect { get; }
Property Value
- DOMRectReadOnly
A 'DOMRectReadOnly' object containing the new size of the element
indicated by the Target property.If thetargetis an HTML Element, the returnedcontentRectis the element's content box. If thetargetis an
SVGElement, the returnedcontentRectis the SVG's bounding
box.
Remarks
DevicePixelContentBoxSize
The devicePixelContentBoxSize read-only property of
the ResizeObserverEntry interface returns an array containing the size in device pixels of the observed element when the callback is run.
[Value("devicePixelContentBoxSize")]
public ResizeObserverSize[] DevicePixelContentBoxSize { get; }
Property Value
- ResizeObserverSize[]
An array containing objects with the new size of the observed element in device pixels. The
array is necessary to support elements that have multiple fragments, which occur in
multi-column scenarios. Each object in the array contains two properties:NOTE
For more information about writing modes and block and inline
dimensions, read Handling different text directions.
Remarks
Target
The target read-only property of the
ResizeObserverEntry interface returns a reference to the
'Element' or 'SVGElement' that is being observed.
[Value("target")]
public Element Target { get; }
Property Value
- Element
An 'Element' or 'SVGElement' representing the element being
observed.