title | description | contributors | ||
---|---|---|---|---|
ListPicker |
UI component for selecting a value from a list. |
|
<ListPicker>
is a UI component that lets the user select a value from a pre-configured list.
::: code-group <<< @/../examples/typescript/src/ui/ListPicker/template.xml#example [XML] <<< @/../examples/typescript/src/ui/ListPicker/template.ts#example [TypeScript] :::
::: code-group <<< @/../examples/angular/src/ui/ListPicker/component.html#example [HTML] <<< @/../examples/angular/src/ui/ListPicker/component.ts#example [TypeScript] :::
<<< @/../examples/react/src/components/ui/listpicker.tsx#example
<<< @/../examples/solid/src/ui/listpicker.tsx#example
<<< @/../examples/svelte/app/components/ui/ListPicker.svelte#example
<<< @/../examples/vue/src/ui/ListPicker/component.vue#example
items: Array<string | number>
Gets or sets the items of the ListPicker.
selectedIndex: number
Gets or sets the index of the currently selected item.
For additional inherited properties, refer to the API Reference.
on('selectedIndexChange', (args: PropertyChangeData) => {
const picker = args.object as ListPicker
console.log('selectedIndex changed to', args.value)
// or picker.selectedIndex
})
Emitted when the currently selected item (index) changes.
- Android:
android.widget.NumberPicker
- iOS:
UIPickerView