From bfd5aa358e141d6c86d476d8bb66b104a80a3b96 Mon Sep 17 00:00:00 2001 From: Robert Jaros Date: Thu, 21 May 2020 00:13:50 +0200 Subject: API documentation for KVision 3.10.0 --- .../-spinner-input/get-state.html | 15 ++++++ .../-spinner-input/index.html | 62 +++++++++++++++++++++- .../-spinner-input/observers.html | 14 +++++ .../-spinner-input/subscribe.html | 15 ++++++ 4 files changed, 104 insertions(+), 2 deletions(-) create mode 100644 api/pl.treksoft.kvision.form.spinner/-spinner-input/get-state.html create mode 100644 api/pl.treksoft.kvision.form.spinner/-spinner-input/observers.html create mode 100644 api/pl.treksoft.kvision.form.spinner/-spinner-input/subscribe.html (limited to 'api/pl.treksoft.kvision.form.spinner/-spinner-input') diff --git a/api/pl.treksoft.kvision.form.spinner/-spinner-input/get-state.html b/api/pl.treksoft.kvision.form.spinner/-spinner-input/get-state.html new file mode 100644 index 00000000..cf15e115 --- /dev/null +++ b/api/pl.treksoft.kvision.form.spinner/-spinner-input/get-state.html @@ -0,0 +1,15 @@ + + + +SpinnerInput.getState - kvision + + + +kvision / pl.treksoft.kvision.form.spinner / SpinnerInput / getState
+
+

getState

+(js) +open fun getState(): Number? +

Get current state.

+ + diff --git a/api/pl.treksoft.kvision.form.spinner/-spinner-input/index.html b/api/pl.treksoft.kvision.form.spinner/-spinner-input/index.html index 45faf8d3..a69ec839 100644 --- a/api/pl.treksoft.kvision.form.spinner/-spinner-input/index.html +++ b/api/pl.treksoft.kvision.form.spinner/-spinner-input/index.html @@ -8,7 +8,7 @@ kvision / pl.treksoft.kvision.form.spinner / SpinnerInput

SpinnerInput

-(js) open class SpinnerInput : Widget, FormInput +(js) open class SpinnerInput : Widget, FormInput, ObservableState<Number?>

The basic component for spinner control.

Constructors

@@ -110,6 +110,14 @@ + + + + + + + + + + + +
(js) +

observers

+
+val observers: MutableList<(Number?) -> Unit>
+(js)

placeholder

@@ -240,6 +248,15 @@
(js) +

getState

+
+

Get current state.

+open fun getState(): Number?
+(js)

getValueAsString

@@ -273,6 +290,15 @@

Change value in plus.

fun spinUp(): SpinnerInput
+(js) +

subscribe

+
+

Subscribe for the state change notifications.

+open fun subscribe(observer: (Number?) -> Unit): () -> Unit

Extension Properties

@@ -284,6 +310,7 @@

changeFlow

+

Extension property returning Flow for a change event.

val <T : Widget> T.changeFlow: Flow<T> @@ -292,6 +319,7 @@

clickFlow

+

Extension property returning Flow for a click event.

val <T : Widget> T.clickFlow: Flow<T> @@ -300,8 +328,18 @@

inputFlow

+

Extension property returning Flow for an input event.

val <T : Widget> T.inputFlow: Flow<T> + + +(js) +

stateFlow

+ + +

Extension property returning StateFlow for an ObservableState.

+val <S> ObservableState<S>.stateFlow: StateFlow<S> +

Extension Functions

@@ -350,11 +388,20 @@ (js) +

bind

+ + +

An extension function which binds the widget to the observable state.

+fun <S, W : Widget> W.bind(observableState: ObservableState<S>, factory: W.(S) -> Unit): W + + + +(js)

contextMenu

DSL builder extension function.

-fun Widget.contextMenu(fixedPosition: Boolean = false, classes: Set<String> = setOf(), init: (ContextMenu.() -> Unit)? = null): ContextMenu +fun Widget.contextMenu(fixedPosition: Boolean = false, classes: Set<String>? = null, className: String? = null, init: (ContextMenu.() -> Unit)? = null): ContextMenu @@ -362,14 +409,25 @@

eventFlow

+

Extension property returning Flow<Pair<Widget, Event>> for a given event

fun <T : Widget> T.eventFlow(event: String): Flow<Pair<T, Event>> (js) +

onClick

+ + +

An extension function for defining on click event handlers.

+fun <T : Widget> T.onClick(handler: T.(MouseEvent) -> Unit): Int + + + +(js)

onEvent

+

An extension function for defining event handlers.

fun <T : Widget> T.onEvent(block: SnOn<T>.() -> Unit): Int diff --git a/api/pl.treksoft.kvision.form.spinner/-spinner-input/observers.html b/api/pl.treksoft.kvision.form.spinner/-spinner-input/observers.html new file mode 100644 index 00000000..b9f76c5e --- /dev/null +++ b/api/pl.treksoft.kvision.form.spinner/-spinner-input/observers.html @@ -0,0 +1,14 @@ + + + +SpinnerInput.observers - kvision + + + +kvision / pl.treksoft.kvision.form.spinner / SpinnerInput / observers
+
+

observers

+(js) +protected val observers: MutableList<(Number?) -> Unit> + + diff --git a/api/pl.treksoft.kvision.form.spinner/-spinner-input/subscribe.html b/api/pl.treksoft.kvision.form.spinner/-spinner-input/subscribe.html new file mode 100644 index 00000000..8bb31a6c --- /dev/null +++ b/api/pl.treksoft.kvision.form.spinner/-spinner-input/subscribe.html @@ -0,0 +1,15 @@ + + + +SpinnerInput.subscribe - kvision + + + +kvision / pl.treksoft.kvision.form.spinner / SpinnerInput / subscribe
+
+

subscribe

+(js) +open fun subscribe(observer: (Number?) -> Unit): () -> Unit +

Subscribe for the state change notifications.

+ + -- cgit