React-native-swipe-list-view: hiddenRow flashing on screen change

Created on 1 Aug 2018  路  6Comments  路  Source: jemise111/react-native-swipe-list-view

I can see the red hidden region in seconds every time i switch to that scene,then it disapper
I'm using react-native-router-flux for navigation.
I've tried setting recalculateHiddenLayout but it doesn't help
I know this issue is the same as #182
But i don't use react-navigation

Most helpful comment

I had this problem, but realized it was because I had my front row in a TouchableOpacity. By default, that reduces the opacity on touch so I could see the background briefly. Putting it inside a view with the background color set to white fixed the issue:

<SwipeRow leftOpenValue={75} rightOpenValue={-75}>
    <View style={styles.swipedRow}>
        <Text style={styles.swipeText}>Left</Text>
        <Text style={styles.swipeText}>Right</Text>
    </View>
    <View style={{backgroundColor: "white"}}>
        <TouchableOpacity>Front row</TouchableOpacity>
    </View>
</SwipeRow>;

All 6 comments

try
previewOpenValue={.01}

previewOpenValue={.01} doesn't work, anything else?

Hi guys, Have you anything solution for this? I am having same problem. hjccc

+1

I had this problem, but realized it was because I had my front row in a TouchableOpacity. By default, that reduces the opacity on touch so I could see the background briefly. Putting it inside a view with the background color set to white fixed the issue:

<SwipeRow leftOpenValue={75} rightOpenValue={-75}>
    <View style={styles.swipedRow}>
        <Text style={styles.swipeText}>Left</Text>
        <Text style={styles.swipeText}>Right</Text>
    </View>
    <View style={{backgroundColor: "white"}}>
        <TouchableOpacity>Front row</TouchableOpacity>
    </View>
</SwipeRow>;

Closing as it sounds like @nferrara100 has identified the issue and a fix, thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

benoitvallon picture benoitvallon  路  6Comments

VitaliiK91 picture VitaliiK91  路  3Comments

mohitmishra22 picture mohitmishra22  路  6Comments

grigy picture grigy  路  4Comments

jwilliamson-qb picture jwilliamson-qb  路  3Comments