Thread
#compose
    Alexander Karkossa

    Alexander Karkossa

    1 year ago
    Hey guys. I switched to compose
    1.0.0-beta08
    and i found a strange issue. When i use my library,
    de.charlex.compose:revealswipe:1.0.0-beta04
    (RevealSwipe), which implements a
    RevealSwipe
    , i am not able to swipe the items after scrolling down in a
    LazyColumn
    . I could fix it by setting
    key(myItem) {}
    around the
    RevealSwipe
    . Any ideas? In
    compose 1.0.0-beta06
    everything worked fine
    Surface(modifier = Modifier.fillMaxSize()) {
        LazyColumn {
            items(
                items = items,
                key = { item -> item}
            ) { item ->
                key(item) { //FIXME Without these key, the RevealSwipe doesn't work after scrolling
                    RevealSwipe(
                        hiddenContentEnd = {
                            Image(
                                modifier = Modifier.padding(horizontal = 25.dp),
                                imageVector = Icons.Outlined.Delete,
                                colorFilter = ColorFilter.tint(MaterialTheme.colors.onSecondary),
                                contentDescription = null
                            )
                        }
                    ) {
                        Card(
                            modifier = Modifier
                                .fillMaxWidth()
                                .requiredHeight(100.dp)
                            ,
                            backgroundColor = Color.Gray,
                        ) {
                            Box(contentAlignment = Alignment.Center) {
                                Text("Item: $item")
                            }
                        }
                    }
                }
            }
        }
    }
    Andrey Kulikov

    Andrey Kulikov

    1 year ago
    Most likely you faced https://issuetracker.google.com/issues/189825174. If you can share the repro sample in this bug we can make sure your use case is fixed once we have a fix
    Alexander Karkossa

    Alexander Karkossa

    1 year ago