StylishScaffold

fun StylishScaffold(topBar: @Composable () -> Unit = {}, bottomBar: @Composable () -> Unit = {}, floatingActionButton: @Composable () -> Unit = {}, snackbarHost: @Composable () -> Unit = {}, modifier: Modifier = Modifier, containerColor: Color = MaterialTheme.colorScheme.background, contentColor: Color = contentColorFor(containerColor), floatingActionButtonPosition: FabPosition = FabPosition.End, contentWindowInsets: WindowInsets = WindowInsets.systemBars, content: @Composable (PaddingValues) -> Unit)

A Stylish UI wrapper around Material 3 Scaffold that provides the full-screen structural skeleton for a page.

Supplies slots for a top bar, bottom bar, floating action button, and snackbar host around a content area. Use this as the outermost layout of every screen; pass a StylishHeader as topBar and a StylishPageContent as content for the standard page composition.

Parameters

topBar

Composable rendered above the content area, typically a StylishHeader. Defaults to empty.

bottomBar

Composable rendered below the content area, e.g. a navigation bar. Defaults to empty.

floatingActionButton

Composable rendered floating above the content, typically a FAB. Defaults to empty.

snackbarHost

Composable rendered to host transient snackbar messages above the content, typically a StylishSnackbarHost. Defaults to empty.

modifier

Modifier applied to the scaffold root.

containerColor

Background color behind all content. Defaults to MaterialTheme.colorScheme.background.

contentColor

Default content color propagated to child composables. Defaults to contentColorFor of containerColor, matching the Material 3 Scaffold default.

floatingActionButtonPosition

Position of floatingActionButton along the bottom edge, forwarded to the Material 3 Scaffold. Defaults to FabPosition.End.

contentWindowInsets

WindowInsets consumed by the scaffold. Defaults to WindowInsets.systemBars (status + navigation bars) so content avoids both system bars, matching the Material 3 Scaffold default.

content

Main page content. Receives the PaddingValues that account for the top bar, bottom bar, and window insets; apply them via Modifier.padding.

See also