julioromano
03/15/2021, 1:54 PMAndroidView
in sheetContent
of a BottomSheetScaffold
Please see the example code and video showing the bug in the thread.julioromano
03/15/2021, 1:55 PMAndroidView
in the bottom sheet of a BottomSheetScaffold
it will scroll up and down when sliding the bottom sheet: It is easier to see it in the attached video than to explain it with words.
This is the code to reproduce (compose version is 1.0.0-beta02):
class MainActivity : ComponentActivity() {
@OptIn(ExperimentalMaterialApi::class)
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContent {
MyApplicationTheme {
BottomSheetScaffold(sheetContent = {
Surface(
color = MaterialTheme.colors.background
) {
Column(
modifier = Modifier
.fillMaxSize()
.background(Color.Blue)
) {
Greeting("Bottom")
AndroidView(factory = { TextView(it) }) {
it.text = "Hello AndroidView"
}
}
}
}) {
Surface(color = MaterialTheme.colors.background) {
Greeting("Top")
}
}
}
}
}
}
Halil Ozercan
03/15/2021, 1:59 PMjulioromano
03/15/2021, 2:03 PMMihai Popa
03/16/2021, 2:27 PMView
: AndroidView(factory = {...}) { (it.parent as ViewGroup).clipChildren = false }
Colton Idle
03/16/2021, 8:36 PMMihai Popa
03/16/2021, 10:11 PMColton Idle
03/16/2021, 10:19 PM