react-native-draggable-flatlist icon indicating copy to clipboard operation
react-native-draggable-flatlist copied to clipboard

[RTL][Android][Horizontal] Odd behaviour while dragging

Open muja555 opened this issue 3 years ago • 1 comments

Describe the bug Odd behaviour while dragging on RTL as seen in gif below (Android device): Untitled

To Reproduce list:

 <DraggableFlatList
                ref={ref}
                horizontal={true}
                data={images}
                renderItem={renderItem}
                onDragEnd={onDragEnd}
                contentContainerStyle={{
                    flexGrow: 1,
                    flexDirection: 'row',
                }}
                initialScrollIndex={0}
                keyExtractor={item => item.id}
            />

renderItem:

    const renderItem = ({item, drag, index, isActive}) => {
        return (
            <TouchableOpacity key={item.id}
                              disabled={isActive}
                              onLongPress={drag}>
               <!-- content -->
            </TouchableOpacity>
        );
    }

enabling rtl on app start:

I18nManager.allowRTL(true);
I18nManager.forceRTL(true);

Platform & Dependencies

  • react-native-draggable-flatlist version: 3.0.3
  • Platform: Android 11 (emulator)
  • React Native or Expo version: RN 0.66.2
  • Reanimated version: 2.3.1
  • React Native Gesture Handler version: 2.1.0

muja555 avatar Dec 20 '21 11:12 muja555

Weird! This looks like an issue with RN flatlist: https://github.com/facebook/react-native/issues/19150

computerjazz avatar Dec 20 '21 18:12 computerjazz