mgrazianodecastro
03/02/2023, 4:25 PMBasicTextField
field which, when cleaning up the text with backspace
and writing something again, it is raising java.lang.IllegalStateException: LayoutCoordinate operations are only valid when isAttached is true
. Does anyone know why?dazza5000
03/02/2023, 4:29 PMmgrazianodecastro
03/02/2023, 4:30 PMdazza5000
03/02/2023, 4:31 PMmgrazianodecastro
03/02/2023, 4:32 PMBasicTextField(
value = value,
onValueChange = { onValueChange(it) },
...,
decorationBox = { innerTextField ->
Row(
modifier = Modifier.fillMaxSize(),
horizontalArrangement = Arrangement.Center,
verticalAlignment = Alignment.CenterVertically
){
if (value.isEmpty()) {
Text(
text = hint,
...
)
}else{
innerTextField()
}
}
}
)
dazza5000
03/02/2023, 4:34 PMinnerTextField()
is probably being detached when you are removing it from composition (im not an expert), but that might be causing the issuemgrazianodecastro
03/02/2023, 4:34 PMStylianos Gakis
03/02/2023, 9:30 PMAlbert Chang
03/03/2023, 1:32 AMZach Klippenstein (he/him) [MOD]
03/06/2023, 5:27 PMmgrazianodecastro
03/06/2023, 6:58 PMZach Klippenstein (he/him) [MOD]
03/07/2023, 5:54 AM