Ian Warwick
07/01/2022, 11:48 AMBox
to stop constraining its children? I just want them to overflow when I offset(x,y)
them or size them
Box(Modifier.size(256.dp)) {
Box(Modifier.border(2.dp, Color.Red).size(512.dp)) {
}
}
The inner box always gets constrained to the outer box which I don’t want, but I do want all the cool things about the box such as Alignment
I just don’t want it to constrain children size, any ideas? 🙂MR3Y
07/01/2022, 12:23 PMwrapContentSize(unbounded=true)
modifier to the chain of the outer Box's modifiers:
Box(Modifier.size(256.dp).wrapContentSize(unbounded=true)) {
Box(Modifier.border(2.dp, Color.Red).size(512.dp)) {
}
}
Ian Warwick
07/01/2022, 1:54 PM