File

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

Description

The wmText component defines the text widget.

Index

Methods
Inputs

Methods

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

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

Parameters :
Name Type Optional Description
$event Event No

DOM event on which call back is triggered

widget any No

Instance of the text widget

Returns : void
onChange
onChange($event: Event, widget: any, newVal: string | number, oldVal: string | number)

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

Parameters :
Name Type Optional Description
$event Event No

DOM event on which call back is triggered

widget any No

Instance of the text widget

newVal string | number No

datavalue of the text widget

oldVal string | number No

previously selected datavalue of the text 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 text widget

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

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

Parameters :
Name Type Optional Description
$event Event No

DOM event on which call back is triggered

widget any No

Instance of the text 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 text 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 text 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 text 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 text 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 text 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 text widget

Returns : void

Inputs

autocomplete

Enabling this property turns on auto-completion in the editor.

Type : boolean

Default value : false

autofocus

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

Type : boolean

Default value : false

class

Class of the widget.

Type : string

datavalue

This is the default value to display value for an editor widget. Note that the display value is just what the user sees initially, and is not always the dataValue returned by the widget.

Bindable: true

Type : string

disabled

This property will be used to disable/enable the text widget on the web page.

Bindable: true

Type : boolean

displayformat

This property sets the format for the values displayed in the widget.

Bindable: true

Type : string

hint

Hint text is shown for the text widget on hover.

Bindable: true

Type : string

maxchars

Defines the maximum number of characters that can be entered in the editor.

Bindable: true

Type : number

maxvalue

Bind or enter a maximum value to the text when the type is set to numeric.

Bindable: true

Type : number

minvalue

Bind or enter a minimum value to the text when the type is set to numeric.

Bindable: true

Type : number

name

Name of the text widget.

Type : string

placeholder

A placeholder is text to show in the editor when there is no value.

Bindable: true

Type : string

Default value : 'Enter text'

readonly

Selecting this property prevents the user from being able to change the data value of a widget.

Bindable: true

Type : boolean

Default value : false

regexp

Enter any regular expression to be used for client-side input validation.

Type : string

Default value : '.*'

required

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

Bindable: true

Type : boolean

Default value : false

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 text widget on the web page.

Bindable: true

Type : boolean

Default value : true

step

Use the stepper to increment/decrement the input value by the specified step interval, when the type is set to numeric.

Type : number

tabindex

This property specifies the tab order of the text Widget.

Type : number

Default value : 0

type

Type of the text widget.

Allowed Values: color, date, datetime-local, email, month, number, password, search, tel, text, time, url, week

Type : string

Default value : 'text'

updatedelay

The amount of delay in milliseconds to update the datavalue.

Bindable: true

Type : number

Default value : 0

updateon

Updates the datavalue as selected.

Allowed Values: blur, keypress

blur: Datavalue will be updated on blur event.

keypress: Datavalue will be updated on keypress.

Type : string

Default value : 'blur'

result-matching ""

    No results matching ""