We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I have the same issue described in Cannot set the locator strategy for the list in the dropdown component for iOS #124, I tried the code you provided, but the dropdown items are still grouped together. What I need is each individual item accessed separately. My react-native-element-dropdown package version is V2.12.1
Your example code" import React, { useState } from 'react';
import { Dropdown } from 'react-native-element-dropdown'; import { StyleSheet, scale } from 'react-native-size-scaling';
const data = [ { label: 'Item 1', value: '1', itemAccessibility: 'item1' }, { label: 'Item 2', value: '2', itemAccessibility: 'item2' }, { label: 'Item 3', value: '3', itemAccessibility: 'item3' }, { label: 'Item 4', value: '4', itemAccessibility: 'item4' }, { label: 'Item 5', value: '5', itemAccessibility: 'item5' }, { label: 'Item 6', value: '6', itemAccessibility: 'item6' }, { label: 'Item 7', value: '7', itemAccessibility: 'item7' }, { label: 'Item 8', value: '8', itemAccessibility: 'item8' }, ];
const DropdownComponent = () => { const [value, setValue] = useState(null);
return ( <Dropdown style={styles.dropdown} placeholderStyle={styles.placeholderStyle} selectedTextStyle={styles.selectedTextStyle} inputSearchStyle={styles.inputSearchStyle} iconStyle={styles.iconStyle} data={data} search maxHeight={scale(200)} labelField="label" valueField="value" placeholder="Select item" searchPlaceholder="Search..." value={value} accessibilityLabel={'dropdown'} itemAccessibilityLabelField="itemAccessibility" onChange={item => { setValue(item.value); }} /> ); };
export default DropdownComponent;
const styles = StyleSheet.create({ dropdown: { marginTop: 36, height: 50, borderBottomColor: 'gray', borderBottomWidth: 0.5, }, icon: { marginRight: 5, }, placeholderStyle: { fontSize: 16, }, selectedTextStyle: { fontSize: 16, }, iconStyle: { width: 20, height: 20, }, inputSearchStyle: { height: 40, fontSize: 16, }, });
The text was updated successfully, but these errors were encountered:
I have the same issues, itemTestIDField is pretty useless, just doesn't work for iOS
itemTestIDField
Sorry, something went wrong.
No branches or pull requests
I have the same issue described in Cannot set the locator strategy for the list in the dropdown component for iOS
#124,
I tried the code you provided, but the dropdown items are still grouped together. What I need is each individual item accessed separately. My react-native-element-dropdown package version is V2.12.1
Your example code"
import React, { useState } from 'react';
import { Dropdown } from 'react-native-element-dropdown';
import { StyleSheet, scale } from 'react-native-size-scaling';
const data = [
{ label: 'Item 1', value: '1', itemAccessibility: 'item1' },
{ label: 'Item 2', value: '2', itemAccessibility: 'item2' },
{ label: 'Item 3', value: '3', itemAccessibility: 'item3' },
{ label: 'Item 4', value: '4', itemAccessibility: 'item4' },
{ label: 'Item 5', value: '5', itemAccessibility: 'item5' },
{ label: 'Item 6', value: '6', itemAccessibility: 'item6' },
{ label: 'Item 7', value: '7', itemAccessibility: 'item7' },
{ label: 'Item 8', value: '8', itemAccessibility: 'item8' },
];
const DropdownComponent = () => {
const [value, setValue] = useState(null);
return (
<Dropdown
style={styles.dropdown}
placeholderStyle={styles.placeholderStyle}
selectedTextStyle={styles.selectedTextStyle}
inputSearchStyle={styles.inputSearchStyle}
iconStyle={styles.iconStyle}
data={data}
search
maxHeight={scale(200)}
labelField="label"
valueField="value"
placeholder="Select item"
searchPlaceholder="Search..."
value={value}
accessibilityLabel={'dropdown'}
itemAccessibilityLabelField="itemAccessibility"
onChange={item => {
setValue(item.value);
}}
/>
);
};
export default DropdownComponent;
const styles = StyleSheet.create({
dropdown: {
marginTop: 36,
height: 50,
borderBottomColor: 'gray',
borderBottomWidth: 0.5,
},
icon: {
marginRight: 5,
},
placeholderStyle: {
fontSize: 16,
},
selectedTextStyle: {
fontSize: 16,
},
iconStyle: {
width: 20,
height: 20,
},
inputSearchStyle: {
height: 40,
fontSize: 16,
},
});
The text was updated successfully, but these errors were encountered: