Not able to drag item in nestable dragable flatlist inside dragable flatslis
I have dragableflatlist and inside nestabledragableflatlist.
"react": "18.0.0", "react-native": "0.69.1", "react-native-draggable-flatlist": "^3.1.2", "react-native-gesture-handler": "^2.5.0", "react-native-linear-gradient": "^2.6.2", "react-native-reanimated": "^2.9.1",
` const renderItem = ({ item, drag, isActive }) => { return ( <ScaleDecorator key={item.id}> <TouchableOpacity activeOpacity={1} onLongPress={drag} disabled={isActive} style={[ styles.item, { backgroundColor: isActive ? "red" : "#fff" }, ]} > <View style={styles.card}> <View style={styles.cardHeader}> <Text style={styles.title}>{item.name}</Text> </View> <NestableScrollContainer> <NestableDraggableFlatList data={data2} extraData={data2} onDragEnd={({ data, from, to }) => setData2(data)} keyExtractor={item => item.id} renderItem={renderItem2} /> </NestableScrollContainer> </View> </TouchableOpacity> </ScaleDecorator> ) };
<DraggableFlatList
data={data.filter(item => item.closed === false)}
extraData={data}
horizontal
onDragEnd={({ data, from, to }) => setDtata(data)}
keyExtractor={item => item.id}
renderItem={renderItem}
/>`
If the TouchableOpacity is disabled when isActive = false, and isActive = false until you're dragging, doesn't that mean you'll never be able to drag an item? I'd guess that if you remove the disabled prop, you'd be able to drag the items.
If the TouchableOpacity is disabled when isActive = false, and isActive = false until you're dragging, doesn't that mean you'll never be able to drag an item? I'd guess that if you remove the disabled prop, you'd be able to drag the items.
@thomas-colbert I'm facing the same issue and tried your suggestion. Unfortunately, that doesn't work.