There is lazy column at top and below the lazy column there is enter phone number layout and add contact from phonebook layout, I want this layout to be at top when no contact is added and when I add lots of contact the enter phone number and add contact from phonebook layout scrolls along with the lazy column and goes outside of the screen. I don't them to go outside of the screen. They must stick to bottom when there is lots of contact.
You can apply the weight
modifier to the LazyColumn
.
Something like:
Column(){
LazyColumn(Modifier.weight(weight = 1f, fill = false)) {
//....
}
Footer()
}
Using fill=false
the element will not occupy the whole width allocated.