Skip to main content

Input with Icon

This is similar to the "Icon Button" widget; however, it offers a unique and specific UI appearance.


Input (Icon) Properties

PropertyDescription
Icon TypeChoose the icon that you want displayed on the widget.
There are two icons to choose from - (Edit) and (Delete).
(Edit)
IconInput
Edit Icon: Highlights the button-click that makes a field "Editable".
(Delete)
IconInput
Delete Icon: Highlights the button-click that "Deletes" the value in a field.
Icon ColorChoose the color of the icon.
Icon SizeSets the size of the icon.

API Methods

setVisibility

Sets the Visibility flag for this component.

setVisibility(visible: boolean): void

setVisibilityCondition

Sets the visibility condition for this component.

setVisibilityCondition(condition: string): void

Event Handlers

Event handlers allow you to set triggers for various actions based on the fired events. They are as follows:

onClick

onClick - Triggers an action, such as calling for a service or function when the widget is clicked.


Example:

When you want to disable the "Read Only" status of a text field (in other words: make it editable), you can::

IconInput

Use the following code on the (onChange) event handler of the text field.

onChange
a8.forms.Textarea("iconInputId).setReadOnly(false)

//Where "iconInputId" is the ID of the "Icon Input" component.