mirror of
https://github.com/Myzel394/NumberHub.git
synced 2025-06-30 22:00:55 +02:00
Disable collapsable TopBar in tools
This commit is contained in:
parent
684d7f2d9a
commit
51f65a694a
@ -22,11 +22,8 @@ import androidx.compose.foundation.layout.PaddingValues
|
|||||||
import androidx.compose.material3.Scaffold
|
import androidx.compose.material3.Scaffold
|
||||||
import androidx.compose.material3.Text
|
import androidx.compose.material3.Text
|
||||||
import androidx.compose.material3.TopAppBar
|
import androidx.compose.material3.TopAppBar
|
||||||
import androidx.compose.material3.TopAppBarDefaults
|
|
||||||
import androidx.compose.material3.rememberTopAppBarState
|
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.ui.Modifier
|
import androidx.compose.ui.Modifier
|
||||||
import androidx.compose.ui.input.nestedscroll.nestedScroll
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Commonly used TopAppBar with scroll behavior.
|
* Commonly used TopAppBar with scroll behavior.
|
||||||
@ -41,12 +38,8 @@ fun UnittoTopAppBar(
|
|||||||
navigateUpAction: () -> Unit,
|
navigateUpAction: () -> Unit,
|
||||||
content: @Composable (PaddingValues) -> Unit
|
content: @Composable (PaddingValues) -> Unit
|
||||||
) {
|
) {
|
||||||
val scrollBehavior = TopAppBarDefaults.exitUntilCollapsedScrollBehavior(
|
|
||||||
rememberTopAppBarState()
|
|
||||||
)
|
|
||||||
Scaffold(
|
Scaffold(
|
||||||
modifier = Modifier
|
modifier = Modifier,
|
||||||
.nestedScroll(scrollBehavior.nestedScrollConnection),
|
|
||||||
topBar = {
|
topBar = {
|
||||||
TopAppBar(
|
TopAppBar(
|
||||||
title = {
|
title = {
|
||||||
@ -54,8 +47,7 @@ fun UnittoTopAppBar(
|
|||||||
},
|
},
|
||||||
navigationIcon = {
|
navigationIcon = {
|
||||||
NavigateUpButton { navigateUpAction() }
|
NavigateUpButton { navigateUpAction() }
|
||||||
},
|
}
|
||||||
scrollBehavior = scrollBehavior
|
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
content = content
|
content = content
|
||||||
|
Loading…
x
Reference in New Issue
Block a user