1.0.3 • Published 5 years ago
list-item-picker v1.0.3
ListItemPicker control
This control allows you to select one or more item from list, based in a column value, the control sugest values based on charaters typed
Here
How to use this control in your solutions
- Import the control into your component:
import { ListItemPicker } from 'list-item-picker/lib/listItemPicker';
- Use the
ListItemPicker
control in your code as follows:
<ListItemPicker
listId='da8daf15-d84f-4ab1-9800-7568f82fed3f'
columnInternalName='Title'
itemLimit={2}
onSelectedItem={this.onSelectedItem}
context={this.props.context}
/>
- The
onSelectedItem
change event returns the list items selected and can be implemented as follows:
private onSelectedItem(data: { key: string; name: string }[]) {
for (const item of data) {
console.log(`Item value: ${item.name}`);
}
}
Implementation
The ListItemPicker
control can be configured with the following properties: