Breadcrumb
Select Widget
Allows creating a select widget component with encode/decode support.

Usage
In order to be used, the SelectWidget
has to be imported:
import {SelectWidget} from 'sabre-ngv-UIComponents-inputs/SelectWidget/components/SelectWidget';
Then SelectWidget can be used as you want to:
<SelectWidget domain={Domain.AIRPORT}/>
Properties
The following properties can be defined for select widget component:
Property | Description | ||
---|---|---|---|
id (optional) |
Id of a component. |
||
domain (optional) |
Domain on which the encoding/decoding will be performed. |
||
onValueChange (optional) |
Method that sends chosen values as WidgetResult[] to the parent component. |
||
optionsLimit (optional) |
Number of options that can be selected, by default set to 1. |
||
customDomain (optional) |
Structure that can replace defined domains, defined as an array of CustomDomainUnits:
|
||
defaultValue (optional) |
Default value(s) to be set at the beginning. |
||
nextComponentToFocusRef (optional) |
Reference to another component, to set the focus on it when the limit of selectable options has been reached. It doesn’t have to be another SelectWidget component, it may be any component with 'focus' option like for e.g. html 'input' field. |
||
showError (optional) |
Flag indicating if the component should display an error. |
||
errorMessage (optional) |
Error message, if not given, default message will be displayed. |
||
placeholder (optional) |
Placeholder text for |
||
icon (optional) |
Icon class rendered inside |
||
onFieldBlur (optional) |
Method triggered on component blur. Passes in the latest value of widget.
|