File

projects/components/src/widgets/common/select/select.component.doc.ts

Description

The wmSelect component defines the select widget.

Index

Methods
Inputs

Methods

onBlur
onBlur($event: MouseEvent, widget: any)

Callback function which will be triggered when the widget loses focus.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onChange
onChange($event: MouseEvent, widget: any, newVal: any, oldVal: any)

Callback function which will be triggered when the widget is clicked or when datavalue has changed.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

newVal any No

datavalue of the select widget

oldVal any No

previously selected datavalue of the select widget

Returns : void
onClick
onClick($event: MouseEvent, widget: any)

Callback function which will be triggered when the widget is clicked.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onDblclick
onDblclick($event: MouseEvent, widget: any)

Callback function which will be triggered when the widget is double clicked.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onFocus
onFocus($event: MouseEvent, widget: any)

Callback function which will be triggered when the widget gets focused.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onKeydown
onKeydown($event: KeyboardEvent, widget: any)

Callback function which will be triggered whenever a key is pressed down.

Parameters :
Name Type Optional Description
$event KeyboardEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onKeypress
onKeypress($event: KeyboardEvent, widget: any)

Callback function which will be triggered whenever a key is pressed.

Parameters :
Name Type Optional Description
$event KeyboardEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onKeyup
onKeyup($event: KeyboardEvent, widget: any)

Callback function which will be triggered whenever a key is released.

Parameters :
Name Type Optional Description
$event KeyboardEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void

This method does not return anything

onMouseenter
onMouseenter($event: MouseEvent, widget: any)

Callback function which will be triggered when the mouse enters the widget.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onMouseleave
onMouseleave($event: MouseEvent, widget: any)

Callback function which will be triggered when the mouse leaves the widget.

Parameters :
Name Type Optional Description
$event MouseEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void
onTap
onTap($event: TouchEvent, widget: any)

Callback function which will be triggered when the tap event is triggered on a widget.

Parameters :
Name Type Optional Description
$event TouchEvent No

DOM event on which call back is triggered

widget any No

Instance of the select widget

Returns : void

Inputs

autofocus

This property makes the element get focused automatically when the page loads.

Type : boolean

class

Class of the widget.

Type : string

datafield

This property sets the dataValue to be returned by the select widget when the list is populated using the dataSet property.

Type : string

dataset

This property accepts the options to create the select widget. These options can be array of values, array of objects, object containing key-value pairs.

Bindable: true

Type : Array<any> | Object

datavalue

This property defines the initial selected value of the select widget.
Only when multiple is set to true, datavalue accepts array of values.

Bindable: true

Type : any

disabled

This property will be used to disable the select widget. If the disabled property is true (checked), the widget becomes display-only.

Bindable: true

Type : boolean

displayexpression

This is an advanced property that gives more control over what is displayed in the drop-down select list. A Display Expression uses a JavaScript expression to format exactly what is shown

Bindable: true

Type : string

displayfield

This property sets the displayValue to show in the select widget when the list is populated using the dataSet property.

Type : string

hint

Hint text is shown of the select widget on hover.

Bindable: true

Type : string

multiple

When this value is set to true multiple options can be selected from select widget.

Type : boolean

name

Name of the select widget.

Type : string

orderby

Allows to display the data in asc or desc order based on this property

Type : string

placeholder

This property specifies the placeholder for the select.

Bindable: true

Type : string

readonly

This property will be used to make the select widget non-editable.

Bindable: true

Type : boolean

required

This property will be used to validate the state of the select widget when used inside a form widget.

Bindable: true

Type : boolean

shortcutkey

The shortcut key property specifies a shortcut key to activate/focus an element.

Type : string

show

This property will be used to show/hide the select widget.

Bindable: true

Type : boolean

Default value : true

tabindex

This property specifies the tab order of the select widget.

Type : number

Default value : 0

result-matching ""

    No results matching ""