VisualViewport

data class VisualViewport(offsetX: Double, offsetY: Double, pageX: Double, pageY: Double, clientWidth: Double, clientHeight: Double, scale: Double, zoom: Double?)

Visual viewport position, dimensions, and scale.

Constructors

VisualViewport
Link copied to clipboard
fun VisualViewport(offsetX: Double, offsetY: Double, pageX: Double, pageY: Double, clientWidth: Double, clientHeight: Double, scale: Double, zoom: Double? = null)

Properties

clientHeight
Link copied to clipboard
val clientHeight: Double
Height (CSS pixels), excludes scrollbar if present.
clientWidth
Link copied to clipboard
val clientWidth: Double
Width (CSS pixels), excludes scrollbar if present.
offsetX
Link copied to clipboard
val offsetX: Double
Horizontal offset relative to the layout viewport (CSS pixels).
offsetY
Link copied to clipboard
val offsetY: Double
Vertical offset relative to the layout viewport (CSS pixels).
pageX
Link copied to clipboard
val pageX: Double
Horizontal offset relative to the document (CSS pixels).
pageY
Link copied to clipboard
val pageY: Double
Vertical offset relative to the document (CSS pixels).
scale
Link copied to clipboard
val scale: Double
Scale relative to the ideal viewport (size at width=device-width).
zoom
Link copied to clipboard
val zoom: Double? = null
Page zoom factor (CSS to device independent pixels ratio).

Sources

jvm source
Link copied to clipboard