Package dev.fritz2.dom.html

Types

A
Link copied to clipboard
js
open class A(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLAnchorElement> , WithText<HTMLAnchorElement>
Exposes the JavaScript HTMLAnchorElement to Kotlin
Area
Link copied to clipboard
js
open class Area(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLAreaElement> , WithText<HTMLAreaElement>
Exposes the JavaScript HTMLAreaElement to Kotlin
Audio
Link copied to clipboard
js
open class Audio(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLAudioElement> , WithText<HTMLAudioElement>
Exposes the JavaScript HTMLAudioElement to Kotlin
Br
Link copied to clipboard
js
open class Br(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLBRElement>
Exposes the JavaScript HTMLBRElement to Kotlin
Button
Link copied to clipboard
js
open class Button(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLButtonElement> , WithText<HTMLButtonElement>
Exposes the JavaScript HTMLButtonElement to Kotlin
Canvas
Link copied to clipboard
js
open class Canvas(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLCanvasElement> , WithText<HTMLCanvasElement>
Exposes the JavaScript HTMLCanvasElement to Kotlin
Caption
Link copied to clipboard
js
open class Caption(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableCaptionElement> , WithText<HTMLTableCaptionElement>
Exposes the JavaScript HTMLTableCaptionElement to Kotlin
Col
Link copied to clipboard
js
open class Col(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableColElement> , WithText<HTMLTableColElement>
Exposes the JavaScript HTMLTableColElement to Kotlin
Colgroup
Link copied to clipboard
js
open class Colgroup(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableColElement> , WithText<HTMLTableColElement>
Exposes the JavaScript HTMLTableColElement to Kotlin
Data
Link copied to clipboard
js
open class Data(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLDataElement> , WithText<HTMLDataElement>
Exposes the JavaScript HTMLDataElement to Kotlin
DataList
Link copied to clipboard
js
open class DataList(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLDataListElement> , WithText<HTMLDataListElement>
Exposes the JavaScript HTMLDataListElement to Kotlin
Del
Link copied to clipboard
js
open class Del(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLModElement> , WithText<HTMLModElement>
Exposes the JavaScript HTMLModElement to Kotlin
Details
Link copied to clipboard
js
open class Details(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLDetailsElement> , WithText<HTMLDetailsElement>
Exposes the JavaScript HTMLDetailsElement to Kotlin
Dialog
Link copied to clipboard
js
open class Dialog(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLDialogElement> , WithText<HTMLDialogElement>
Exposes the JavaScript HTMLDialogElement to Kotlin
Div
Link copied to clipboard
js
open class Div(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLDivElement> , WithText<HTMLDivElement>
Exposes the JavaScript HTMLDivElement to Kotlin
Dl
Link copied to clipboard
js
open class Dl(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLDListElement> , WithText<HTMLDListElement>
Exposes the JavaScript HTMLDListElement to Kotlin
Embed
Link copied to clipboard
js
open class Embed(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLEmbedElement>
Exposes the JavaScript HTMLDivElement to Kotlin
Events
Link copied to clipboard
js
object Events
Contains all javascript event types.
EventType
Link copied to clipboard
js
class EventType<T : Event>(name: String)
Contains the javascript related name and actual type of the Event.
FieldSet
Link copied to clipboard
js
open class FieldSet(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLFieldSetElement>
Exposes the JavaScript HTMLFieldSetElement to Kotlin
Form
Link copied to clipboard
js
open class Form(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLFormElement> , WithText<HTMLFormElement>
Exposes the JavaScript HTMLFormElement to Kotlin
H
Link copied to clipboard
js
open class H(num: Int, id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLHeadingElement> , WithText<HTMLHeadingElement>
Exposes the JavaScript HTMLHeadingElement to Kotlin
Hr
Link copied to clipboard
js
open class Hr(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLHRElement>
Exposes the JavaScript HTMLHRElement to Kotlin
IFrame
Link copied to clipboard
js
open class IFrame(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLIFrameElement> , WithText<HTMLIFrameElement>
Exposes the JavaScript HTMLIFrameElement to Kotlin
Img
Link copied to clipboard
js
open class Img(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLImageElement> , WithText<HTMLImageElement>
Exposes the JavaScript HTMLImageElement to Kotlin
Input
Link copied to clipboard
js
open class Input(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLInputElement>
Exposes the JavaScript HTMLInputElement to Kotlin
Ins
Link copied to clipboard
js
open class Ins(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLModElement> , WithText<HTMLModElement>
Exposes the JavaScript HTMLModElement to Kotlin
Key
Link copied to clipboard
js
class Key(code: String, key: String, ctrl: Boolean, alt: Boolean, shift: Boolean, meta: Boolean)
Key represents a key from KeyboardEventMore info here
Keys
Link copied to clipboard
js
object Keys
Label
Link copied to clipboard
js
open class Label(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLLabelElement> , WithText<HTMLLabelElement>
Exposes the JavaScript HTMLLabelElement to Kotlin
Legend
Link copied to clipboard
js
open class Legend(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLLegendElement> , WithText<HTMLLegendElement>
Exposes the JavaScript HTMLLegendElement to Kotlin
Li
Link copied to clipboard
js
open class Li(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLLIElement> , WithText<HTMLLIElement>
Exposes the JavaScript HTMLLIElement to Kotlin
Map
Link copied to clipboard
js
open class Map(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLMapElement> , WithText<HTMLMapElement>
Exposes the JavaScript HTMLMapElement to Kotlin
Meter
Link copied to clipboard
js
open class Meter(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLMeterElement> , WithText<HTMLMeterElement>
Exposes the JavaScript HTMLMeterElement to Kotlin
MountTargetNotFoundException
Link copied to clipboard
js
class MountTargetNotFoundException(message: String) : Exception
Occurs when the targeted html element is not present in document.
Object
Link copied to clipboard
js
open class Object(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLObjectElement> , WithText<HTMLObjectElement>
Exposes the JavaScript HTMLObjectElement to Kotlin
Ol
Link copied to clipboard
js
open class Ol(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLOListElement> , WithText<HTMLOListElement>
Exposes the JavaScript HTMLOListElement to Kotlin
Optgroup
Link copied to clipboard
js
open class Optgroup(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLOptGroupElement> , WithText<HTMLOptGroupElement>
Exposes the JavaScript HTMLOptGroupElement to Kotlin
Option
Link copied to clipboard
js
open class Option(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLOptionElement> , WithText<HTMLOptionElement>
Exposes the JavaScript HTMLOptionElement to Kotlin
Output
Link copied to clipboard
js
open class Output(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLOutputElement> , WithText<HTMLOutputElement>
Exposes the JavaScript HTMLOutputElement to Kotlin
P
Link copied to clipboard
js
open class P(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLParagraphElement> , WithText<HTMLParagraphElement>
Exposes the JavaScript HTMLParagraphElement to Kotlin
Param
Link copied to clipboard
js
open class Param(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLParamElement> , WithText<HTMLParamElement>
Exposes the JavaScript HTMLParamElement to Kotlin
Picture
Link copied to clipboard
js
open class Picture(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLPictureElement> , WithText<HTMLPictureElement>
Exposes the JavaScript HTMLPictureElement to Kotlin
Pre
Link copied to clipboard
js
open class Pre(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLPreElement> , WithText<HTMLPreElement>
Exposes the JavaScript HTMLPreElement to Kotlin
Progress
Link copied to clipboard
js
open class Progress(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLProgressElement> , WithText<HTMLProgressElement>
Exposes the JavaScript HTMLProgressElement to Kotlin
Quote
Link copied to clipboard
js
open class Quote(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLQuoteElement> , WithText<HTMLQuoteElement>
Exposes the JavaScript HTMLQuoteElement to Kotlin
RenderContext
Link copied to clipboard
js
typealias RenderContext = Tag<HTMLElement>

Type alias for the most generic type of a tag. This type should be preferred for HTML structures without restrictions. This is very useful for sub-structures of a component that a client can freely inject, like the items of a stack or the content of a modal for example.

Scope
Link copied to clipboard
js
class Scope(entries: HashMap<Scope.Key<*>, Any>)
Contains any type of data which consists of a Key and a corresponding value object.
ScopeContext
Link copied to clipboard
js
class ScopeContext(current: Scope)
Context for setting new entries to a Scope object.
Script
Link copied to clipboard
js
open class Script(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLScriptElement> , WithText<HTMLScriptElement>
Exposes the JavaScript HTMLScriptElement to Kotlin
Select
Link copied to clipboard
js
open class Select(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLSelectElement>
Exposes the JavaScript HTMLSelectElement to Kotlin
Span
Link copied to clipboard
js
open class Span(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLSpanElement> , WithText<HTMLSpanElement>
Exposes the JavaScript HTMLSpanElement to Kotlin
Svg
Link copied to clipboard
js
class Svg(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<SVGElement>
Exposes the JavaScript SVGElement to Kotlin
Table
Link copied to clipboard
js
open class Table(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableElement>
Exposes the JavaScript HTMLTableElement to Kotlin
TagContext
Link copied to clipboard
js
interface TagContext : WithJob, WithScope
Context for rendering standard HTML5 Tags
TBody
Link copied to clipboard
js
open class TBody(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableSectionElement>
Exposes the JavaScript HTMLTableSectionElement to Kotlin
Td
Link copied to clipboard
js
open class Td(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableCellElement> , WithText<HTMLTableCellElement>
Exposes the JavaScript HTMLTableCellElement to Kotlin
TextArea
Link copied to clipboard
js
open class TextArea(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTextAreaElement> , WithText<HTMLTextAreaElement>
Exposes the JavaScript HTMLTextAreaElement to Kotlin
TextElement
Link copied to clipboard
js
open class TextElement(tagName: String, id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLElement> , WithText<HTMLElement>
Special Tag for HTML5 with no attributes
TFoot
Link copied to clipboard
js
open class TFoot(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableSectionElement>
Exposes the JavaScript HTMLTableSectionElement to Kotlin
Th
Link copied to clipboard
js
open class Th(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableCellElement> , WithText<HTMLTableCellElement>
Exposes the JavaScript HTMLTableCellElement to Kotlin
THead
Link copied to clipboard
js
open class THead(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableSectionElement>
Exposes the JavaScript HTMLTableSectionElement to Kotlin
Time
Link copied to clipboard
js
open class Time(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTimeElement> , WithText<HTMLTimeElement>
Exposes the JavaScript HTMLTimeElement to Kotlin
Tr
Link copied to clipboard
js
open class Tr(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTableRowElement> , WithText<HTMLTableRowElement>
Exposes the JavaScript HTMLTableRowElement to Kotlin
Track
Link copied to clipboard
js
open class Track(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLTrackElement> , WithText<HTMLTrackElement>
Exposes the JavaScript HTMLTrackElement to Kotlin
Ul
Link copied to clipboard
js
open class Ul(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLUListElement>
Exposes the JavaScript HTMLUListElement to Kotlin
Video
Link copied to clipboard
js
open class Video(id: String?, baseClass: String?, job: Job, scope: Scope) : Tag<HTMLVideoElement> , WithText<HTMLVideoElement>
Exposes the JavaScript HTMLVideoElement to Kotlin
WithJob
Link copied to clipboard
js
interface WithJob
Marks a class that it has a Job to start coroutines with.
WithScope
Link copied to clipboard
js
interface WithScope
Marks a class that it has Scope which can be transferred for adding/receiving additional information.

Functions

keyOf
Link copied to clipboard
js
inline fun <T : Any> keyOf(name: String? = null): Scope.Key<T>
Creates a Scope.Key for using it in Scope.
render
Link copied to clipboard
js
fun render(selector: String, override: Boolean = true, content: RenderContext.() -> Unit)
Creates a RenderContext for Tags and mounts it to a constant element in the static html file which id matches the selector.
fun render(targetElement: HTMLElement? = document.body, override: Boolean = true, content: RenderContext.() -> Unit)
Creates a RenderContext for Tags and mounts it to a targetElement.