Open tamarr opened 4 years ago
When providing both label and value in data, setting selectedItemColor will result in all items in the dropdown getting the selectedItemColor
const dropdownOptions = options.map((optionId) => { return { label: this.state.options[optionId]['name'], value: optionId } }); return <Dropdown containerStyle={styles.dropdown} value={currentOptionName} data={dropdownOptions} itemColor={'black'} textColor={'black'} selectedItemColor={'red} onChangeText={(optionId, idx, data) => {this.optionSelected(optionId)}} />
Yep I face this problem too after passing value to Dropdown.
When providing both label and value in data, setting selectedItemColor will result in all items in the dropdown getting the selectedItemColor