SVGElement

abstract external class SVGElement : 
    Element,
    ElementCSSInlineStyle,
    GlobalEventHandlers,
    SVGElementInstance
(source)

Platform and version requirements: JS

Exposes the JavaScript SVGElement to Kotlin

Constructors

<init>

SVGElement()

Exposes the JavaScript SVGElement to Kotlin

Properties

dataset

open val dataset: DOMStringMap

ownerSVGElement

open val ownerSVGElement: SVGSVGElement?

tabIndex

open var tabIndex: Int

viewportElement

open val viewportElement: SVGElement?

Inherited Properties

attributes

open val attributes: NamedNodeMap

classList

open val classList: DOMTokenList

className

open var className: String

clientHeight

open val clientHeight: Int

clientLeft

open val clientLeft: Int

clientTop

open val clientTop: Int

clientWidth

open val clientWidth: Int

correspondingElement

abstract val correspondingElement: SVGElement?

correspondingUseElement

abstract val correspondingUseElement: SVGUseElement?

id

open var id: String

innerHTML

open var innerHTML: String

localName

open val localName: String

namespaceURI

open val namespaceURI: String?

onabort

abstract var onabort: (Event) -> dynamic

onblur

abstract var onblur: (Event) -> dynamic

oncancel

abstract var oncancel: (Event) -> dynamic

oncanplay

abstract var oncanplay: (Event) -> dynamic

oncanplaythrough

abstract var oncanplaythrough: (Event) -> dynamic

onchange

abstract var onchange: (Event) -> dynamic

onclick

abstract var onclick: (Event) -> dynamic

onclose

abstract var onclose: (Event) -> dynamic

oncontextmenu

abstract var oncontextmenu: (Event) -> dynamic

oncuechange

abstract var oncuechange: (Event) -> dynamic

ondblclick

abstract var ondblclick: (Event) -> dynamic

ondrag

abstract var ondrag: (Event) -> dynamic

ondragend

abstract var ondragend: (Event) -> dynamic

ondragenter

abstract var ondragenter: (Event) -> dynamic

ondragexit

abstract var ondragexit: (Event) -> dynamic

ondragleave

abstract var ondragleave: (Event) -> dynamic

ondragover

abstract var ondragover: (Event) -> dynamic

ondragstart

abstract var ondragstart: (Event) -> dynamic

ondrop

abstract var ondrop: (Event) -> dynamic

ondurationchange

abstract var ondurationchange: (Event) -> dynamic

onemptied

abstract var onemptied: (Event) -> dynamic

onended

abstract var onended: (Event) -> dynamic

onerror

abstract var onerror: (dynamic, String, Int, Int, Any?) -> dynamic

onfocus

abstract var onfocus: (Event) -> dynamic

oninput

abstract var oninput: (Event) -> dynamic

oninvalid

abstract var oninvalid: (Event) -> dynamic

onkeydown

abstract var onkeydown: (Event) -> dynamic

onkeypress

abstract var onkeypress: (Event) -> dynamic

onkeyup

abstract var onkeyup: (Event) -> dynamic

onload

abstract var onload: (Event) -> dynamic

onloadeddata

abstract var onloadeddata: (Event) -> dynamic

onloadedmetadata

abstract var onloadedmetadata: (Event) -> dynamic

onloadend

abstract var onloadend: (Event) -> dynamic

onloadstart

abstract var onloadstart: (Event) -> dynamic

onmousedown

abstract var onmousedown: (Event) -> dynamic

onmouseenter

abstract var onmouseenter: (Event) -> dynamic

onmouseleave

abstract var onmouseleave: (Event) -> dynamic

onmousemove

abstract var onmousemove: (Event) -> dynamic

onmouseout

abstract var onmouseout: (Event) -> dynamic

onmouseover

abstract var onmouseover: (Event) -> dynamic

onmouseup

abstract var onmouseup: (Event) -> dynamic

onpause

abstract var onpause: (Event) -> dynamic

onplay

abstract var onplay: (Event) -> dynamic

onplaying

abstract var onplaying: (Event) -> dynamic

onprogress

abstract var onprogress: (Event) -> dynamic

onratechange

abstract var onratechange: (Event) -> dynamic

onreset

abstract var onreset: (Event) -> dynamic

onresize

abstract var onresize: (Event) -> dynamic

onscroll

abstract var onscroll: (Event) -> dynamic

onseeked

abstract var onseeked: (Event) -> dynamic

onseeking

abstract var onseeking: (Event) -> dynamic

onselect

abstract var onselect: (Event) -> dynamic

onshow

abstract var onshow: (Event) -> dynamic

onstalled

abstract var onstalled: (Event) -> dynamic

onsubmit

abstract var onsubmit: (Event) -> dynamic

onsuspend

abstract var onsuspend: (Event) -> dynamic

ontimeupdate

abstract var ontimeupdate: (Event) -> dynamic

ontoggle

abstract var ontoggle: (Event) -> dynamic

onvolumechange

abstract var onvolumechange: (Event) -> dynamic

onwaiting

abstract var onwaiting: (Event) -> dynamic

onwheel

abstract var onwheel: (Event) -> dynamic

outerHTML

open var outerHTML: String

prefix

open val prefix: String?

scrollHeight

open val scrollHeight: Int

scrollLeft

open var scrollLeft: Double

scrollTop

open var scrollTop: Double

scrollWidth

open val scrollWidth: Int

shadowRoot

open val shadowRoot: ShadowRoot?

slot

open var slot: String

style

abstract val style: CSSStyleDeclaration

tagName

open val tagName: String

Functions

blur

fun blur()

focus

fun focus()

Inherited Functions

attachShadow

fun attachShadow(init: ShadowRootInit): ShadowRoot

closest

fun closest(selectors: String): Element?

getAttribute

fun getAttribute(qualifiedName: String): String?

getAttributeNS

fun getAttributeNS(
    namespace: String?,
    localName: String
): String?

getAttributeNames

fun getAttributeNames(): Array<String>

getAttributeNode

fun getAttributeNode(qualifiedName: String): Attr?

getAttributeNodeNS

fun getAttributeNodeNS(
    namespace: String?,
    localName: String
): Attr?

getBoundingClientRect

fun getBoundingClientRect(): DOMRect

getClientRects

fun getClientRects(): Array<DOMRect>

getElementsByClassName

fun getElementsByClassName(
    classNames: String
): HTMLCollection

getElementsByTagName

fun getElementsByTagName(
    qualifiedName: String
): HTMLCollection

getElementsByTagNameNS

fun getElementsByTagNameNS(
    namespace: String?,
    localName: String
): HTMLCollection

hasAttribute

fun hasAttribute(qualifiedName: String): Boolean

hasAttributeNS

fun hasAttributeNS(
    namespace: String?,
    localName: String
): Boolean

hasAttributes

fun hasAttributes(): Boolean

insertAdjacentElement

fun insertAdjacentElement(
    where: String,
    element: Element
): Element?

insertAdjacentHTML

fun insertAdjacentHTML(position: String, text: String)

insertAdjacentText

fun insertAdjacentText(where: String, data: String)

matches

fun matches(selectors: String): Boolean

removeAttribute

fun removeAttribute(qualifiedName: String)

removeAttributeNS

fun removeAttributeNS(namespace: String?, localName: String)

removeAttributeNode

fun removeAttributeNode(attr: Attr): Attr

requestFullscreen

fun requestFullscreen(): Promise<Unit>

scroll

fun scroll(options: ScrollToOptions = definedExternally)
fun scroll(x: Double, y: Double)

scrollBy

fun scrollBy(options: ScrollToOptions = definedExternally)
fun scrollBy(x: Double, y: Double)

scrollIntoView

fun scrollIntoView()
fun scrollIntoView(arg: dynamic)

scrollTo

fun scrollTo(options: ScrollToOptions = definedExternally)
fun scrollTo(x: Double, y: Double)

setAttribute

fun setAttribute(qualifiedName: String, value: String)

setAttributeNS

fun setAttributeNS(
    namespace: String?,
    qualifiedName: String,
    value: String)

setAttributeNode

fun setAttributeNode(attr: Attr): Attr?

setAttributeNodeNS

fun setAttributeNodeNS(attr: Attr): Attr?

webkitMatchesSelector

fun webkitMatchesSelector(selectors: String): Boolean

Extension Properties

isElement

val Node.isElement: Boolean

Gets a value indicating whether this node is an Element.

isText

val Node.isText: Boolean

Gets a value indicating whether this node is a TEXT_NODE or a CDATA_SECTION_NODE.

Extension Functions

addClass

fun Element.addClass(vararg cssClasses: String): Boolean

Adds CSS class to element. Has no effect if all specified classes are already in class attribute of the element

appendElement

fun Element.appendElement(
    name: String,
    init: Element.() -> Unit
): Element

Appends a newly created element with the specified name to this element.

appendText

fun Element.appendText(text: String): Element

Creates text node and append it to the element.

clear

fun Node.clear()

Removes all the children from this node.

hasClass

fun Element.hasClass(cssClass: String): Boolean

Returns true if the element has the given CSS class style in its 'class' attribute

removeClass

fun Element.removeClass(vararg cssClasses: String): Boolean

Removes all cssClasses from element. Has no effect if all specified classes are missing in class attribute of the element

Inheritors

SVGCursorElement

abstract external class SVGCursorElement : 
    SVGElement,
    SVGURIReference

Exposes the JavaScript SVGCursorElement to Kotlin

SVGDescElement

abstract external class SVGDescElement : SVGElement

Exposes the JavaScript SVGDescElement to Kotlin

SVGGradientElement

abstract external class SVGGradientElement : 
    SVGElement,
    SVGURIReference,
    SVGUnitTypes

Exposes the JavaScript SVGGradientElement to Kotlin

SVGGraphicsElement

abstract external class SVGGraphicsElement : 
    SVGElement,
    SVGTests

Exposes the JavaScript SVGGraphicsElement to Kotlin

SVGHatchElement

abstract external class SVGHatchElement : SVGElement

SVGHatchpathElement

abstract external class SVGHatchpathElement : SVGElement

SVGMarkerElement

abstract external class SVGMarkerElement : 
    SVGElement,
    SVGFitToViewBox

SVGMeshpatchElement

abstract external class SVGMeshpatchElement : SVGElement

SVGMeshrowElement

abstract external class SVGMeshrowElement : SVGElement

SVGMetadataElement

abstract external class SVGMetadataElement : SVGElement

Exposes the JavaScript SVGMetadataElement to Kotlin

SVGPatternElement

abstract external class SVGPatternElement : 
    SVGElement,
    SVGFitToViewBox,
    SVGURIReference,
    SVGUnitTypes

Exposes the JavaScript SVGPatternElement to Kotlin

SVGScriptElement

abstract external class SVGScriptElement : 
    SVGElement,
    SVGURIReference,
    HTMLOrSVGScriptElement

Exposes the JavaScript SVGScriptElement to Kotlin

SVGSolidcolorElement

abstract external class SVGSolidcolorElement : SVGElement

Exposes the JavaScript SVGSolidcolorElement to Kotlin

SVGStopElement

abstract external class SVGStopElement : SVGElement

Exposes the JavaScript SVGStopElement to Kotlin

SVGStyleElement

abstract external class SVGStyleElement : 
    SVGElement,
    LinkStyle

Exposes the JavaScript SVGStyleElement to Kotlin

SVGTitleElement

abstract external class SVGTitleElement : SVGElement

Exposes the JavaScript SVGTitleElement to Kotlin

SVGViewElement

abstract external class SVGViewElement : 
    SVGElement,
    SVGFitToViewBox,
    SVGZoomAndPan

Exposes the JavaScript SVGViewElement to Kotlin