mirror of
https://github.com/msfjarvis/compose-lobsters
synced 2025-08-14 12:57:04 +05:30
refactor: add actions
parameter to ClawAppBar
This commit is contained in:
parent
84e09fd5e1
commit
9f6d231912
1 changed files with 3 additions and 0 deletions
|
@ -6,6 +6,7 @@
|
||||||
*/
|
*/
|
||||||
package dev.msfjarvis.claw.common.ui.decorations
|
package dev.msfjarvis.claw.common.ui.decorations
|
||||||
|
|
||||||
|
import androidx.compose.foundation.layout.RowScope
|
||||||
import androidx.compose.material3.ExperimentalMaterial3Api
|
import androidx.compose.material3.ExperimentalMaterial3Api
|
||||||
import androidx.compose.material3.MaterialTheme
|
import androidx.compose.material3.MaterialTheme
|
||||||
import androidx.compose.material3.Text
|
import androidx.compose.material3.Text
|
||||||
|
@ -29,12 +30,14 @@ fun ClawAppBar(
|
||||||
modifier: Modifier = Modifier,
|
modifier: Modifier = Modifier,
|
||||||
navigationIcon: @Composable () -> Unit = {},
|
navigationIcon: @Composable () -> Unit = {},
|
||||||
title: @Composable () -> Unit = {},
|
title: @Composable () -> Unit = {},
|
||||||
|
actions: @Composable RowScope.() -> Unit = {},
|
||||||
) {
|
) {
|
||||||
TopAppBar(
|
TopAppBar(
|
||||||
title = title,
|
title = title,
|
||||||
modifier = modifier.shadow(8.dp),
|
modifier = modifier.shadow(8.dp),
|
||||||
colors = TopAppBarDefaults.smallTopAppBarColors(containerColor = backgroundColor),
|
colors = TopAppBarDefaults.smallTopAppBarColors(containerColor = backgroundColor),
|
||||||
navigationIcon = navigationIcon,
|
navigationIcon = navigationIcon,
|
||||||
|
actions = actions,
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue