DropDownListComponent
Represents the Kendo UI for Angular DropDownList component.
Definition
Package:@progress/kendo-angular-dropdowns
Selector:kendo-dropdownlist
Export Name:Accessible in templates as #kendoDropDownListInstance="kendoDropDownList"
Syntax:
<kendo-dropdownlist [data]="["Item 1", "Item 2", "Item 3"]"></kendo-dropdownlist>
Inputs
Enables or disables the adaptive mode. The adaptive rendering is disabled by default.
'none'
adaptiveSubtitle
string
Sets the subtitle of the ActionSheet rendered instead of the Popup on small screens. By default, the ActionSheet does not render a subtitle.
''
adaptiveTitle
string
Sets the title of the ActionSheet rendered instead of the Popup on small screens.
By default, the ActionSheet title uses the label text of the DropDownListComponent.
''
data
any
Sets the data of the DropDownListComponent.
The data must be an array-like list.
defaultItem
any
Sets the text of the default empty item. The value type must match the data type.
delay
number
Sets the delay before an item search is performed. Use this option when filtration is disabled.
500
disabled
boolean
Sets the disabled state of the component. To disable the component in reactive forms, see Forms Support.
Sets the fillMode of the component. The default value is set by the Kendo theme.
filterable
boolean
Enables the filtering functionality of the DropDownListComponent.
false
ignoreCase
boolean
Enables a case-insensitive search. Use this option when filtration is disabled.
true
Defines a Boolean function executed for each data item in the component. Determines whether the item is disabled. See examples.
listHeight
number
Sets the height of the options list in the popup.
The listHeight property affects only the list of options, not the whole popup container.
To set the height of the popup container, use popupSettings.height.
When using adaptiveMode and the screen size is small or medium, the listHeight property is set to null.
200
loading
boolean
Sets and gets the loading state of the DropDownListComponent.
Configures the popup of the DropDownListComponent.
The available options are:
animate: Boolean—Controls the popup animation. The open and close animations are enabled by default.width: Number | String—Sets the width of the popup container. By default, the width of the host element is used. If set toauto, the component automatically adjusts the width of the popup and no item labels are wrapped. Theautomode is not supported when virtual scrolling is enabled.height: Number—Sets the height of the popup container.popupClass: String—Specifies a list of CSS classes used to style the popup.appendTo: "root" | "component" | ViewContainerRef—Specifies the component to which the popup will be appended.
readonly
boolean
Sets the read-only state of the component.
false
Sets the border radius of the component. The default value is set by the Kendo theme.
showStickyHeader
boolean
Shows or hides the current group sticky header when using grouped data. The sticky header displays by default. see example.
true
Sets the size of the component. The default value is set by the Kendo theme.
textField
string
Sets the data item field that represents the item text. If the data contains only primitive values, do not define this property.
The textField property can point to a nested property value, for example, category.name.
value
any
Sets the value of the DropDownListComponent.
The value can be a primitive (string, number) or a complex object.
Use the valuePrimitive option to define the type.
All selected values not present in the source are ignored.
valueField
string
Sets the data item field that represents the item value. If the data contains only primitive values, do not define this property.
The valueField property can point to a nested property value, for example, category.id.
valuePrimitive
boolean
Specifies the type of the selected value. If set to true, the selected value must be a primitive value.
virtual
boolean | VirtualizationSettings
Enables the virtualization functionality.
Fields
isOpen
boolean
Returns the current open state. Returns true if the popup or actionSheet is open.
Events
blur
EventEmitter<any>
Fires each time the DropDownListComponent gets blurred.
close
EventEmitter<PreventableEvent>
Fires each time the popup is about to close. This event is preventable. If you cancel it, the popup remains open. see example.
closed
EventEmitter<any>
Fires after the popup has been closed.
filterChange
EventEmitter<any>
- Fires each time the user types in the input field. You can filter the source based on the filtration value. When the value is programmatically changed, the
valueChangeevent is not triggered. See example..
focus
EventEmitter<any>
Fires each time the user focuses the DropDownListComponent.
open
EventEmitter<PreventableEvent>
Fires each time the popup is about to open. This event is preventable. If you cancel it, the popup remains closed. see example.
opened
EventEmitter<any>
Fires after the popup has been opened.
Fires each time the item selection changes. see example..
valueChange
EventEmitter<any>
Fires each time the value changes. See example..
Methods
Blurs the DropDownListComponent.
Focuses the DropDownListComponent.
Focuses a specific item of the DropDownListComponent based on the provided index. If there is a default item, it is positioned at index -1. If null or an invalid index is provided, the focus is removed.
Resets the value of the DropDownListComponent. If you use the reset method to clear the value, the model does not update automatically and the selectionChange and valueChange events are not fired.
Toggles the visibility of the Popup or ActionSheet. If you use the toggle method to open or close the Popup, the open and close events are not fired.
The state of the popup.