Lin Zhang
03/11/2021, 9:04 AM1.0.0-beta02
? I don’t think that’s a good idea… the animation looks so wired on initializing UI and no API to disable it
https://android-review.googlesource.com/c/platform/frameworks/support/+/1580345louiscad
03/11/2021, 9:21 AMAndrey Kulikov
03/11/2021, 11:52 AMLouis Pullen-Freilich [G]
03/11/2021, 12:08 PMLin Zhang
03/11/2021, 12:51 PM@Composable
fun FabIssueSample() {
val showFab = remember { mutableStateOf(false) }
Scaffold(
floatingActionButton = {
if (showFab.value) {
FloatingActionButton(onClick = {
}) {
Text(text = "FAB")
}
}
}
) {
Box(contentAlignment = Alignment.Center, modifier = Modifier.fillMaxSize()) {
Button(onClick = { showFab.value = !showFab.value }) {
Text(text = "Toggle FAB")
}
}
}
}
Louis Pullen-Freilich [G]
03/11/2021, 12:53 PMIgor Demin
03/11/2021, 4:47 PMLouis Pullen-Freilich [G]
03/11/2021, 5:21 PM