Reputation: 1148
I need a topbar
in Scaffold
composable which floats over the main content (body). Currently the Scaffold
puts the topbar
on the main content. This reduces the size of the main content which should fill the entire screen.
Upvotes: 0
Views: 1958
Reputation: 7281
In that case you can add TopAppBar composable in your content section of Scaffold
Scaffold {
Box {
BodyContent()
TopAppBar(modifier = Modifier.fillMaxWidth()) {
}
}
}
Upvotes: 1