OnsButton

open class OnsButton(content: String? = null, rich: Boolean = false, align: <Error class: unknown class>? = null, icon: String? = null, buttonType: OnsButtonType? = null, large: Boolean? = null, ripple: Boolean? = null, disabled: Boolean? = null, className: String? = null, init: OnsButton.() -> Unit? = null)

A button component.

Parameters

content

the content of the button.

rich

whether content can contain HTML code

align

text align

icon

an icon placed on the button

buttonType

a type of the button

large

whether the button is large

ripple

specify if the button will have a ripple effect

disabled

specify if the button should be disabled

className

CSS class names

init

an initializer extension function

Constructors

Link copied to clipboard
constructor(content: String? = null, rich: Boolean = false, align: <Error class: unknown class>? = null, icon: String? = null, buttonType: OnsButtonType? = null, large: Boolean? = null, ripple: Boolean? = null, disabled: Boolean? = null, className: String? = null, init: OnsButton.() -> Unit? = null)

Creates a button component.

Properties

Link copied to clipboard

A type of the button.

Link copied to clipboard

Specify if the button should be disabled.

Link copied to clipboard
var icon: String?

The icon placed on the toolbar button.

Link copied to clipboard

A dynamic property returning current state of the component.

Link copied to clipboard

Whether the button is large.

Link copied to clipboard

A modifier attribute to specify custom styles.

Link copied to clipboard

Specify if the button will have a ripple effect.

Functions

Link copied to clipboard
open fun buildAttributeSet(attributeSetBuilder: <Error class: unknown class>)
Link copied to clipboard
open fun buildClassSet(classSetBuilder: <Error class: unknown class>)
Link copied to clipboard
open fun onClick(handler: OnsButton.(<Error class: unknown class>) -> Unit): Int

A convenient helper for easy setting onClick event handler.