rememberSupportingPaneSceneStrategy

Functions summary

SupportingPaneSceneStrategy<T>
@ExperimentalMaterial3AdaptiveApi
@Composable
<T : Any> rememberSupportingPaneSceneStrategy(
    shouldHandleSinglePaneLayout: Boolean,
    backNavigationBehavior: BackNavigationBehavior,
    directive: PaneScaffoldDirective,
    adaptStrategies: ThreePaneScaffoldAdaptStrategies,
    paneExpansionDragHandle: (@Composable ThreePaneScaffoldScope.(PaneExpansionState) -> Unit)?,
    paneExpansionState: PaneExpansionState?
)

Creates and remembers a SupportingPaneSceneStrategy.

Cmn

Functions

rememberSupportingPaneSceneStrategy

@ExperimentalMaterial3AdaptiveApi
@Composable
fun <T : Any> rememberSupportingPaneSceneStrategy(
    shouldHandleSinglePaneLayout: Boolean = false,
    backNavigationBehavior: BackNavigationBehavior = BackNavigationBehavior.PopUntilCurrentDestinationChange,
    directive: PaneScaffoldDirective = calculatePaneScaffoldDirective(currentWindowAdaptiveInfoV2()),
    adaptStrategies: ThreePaneScaffoldAdaptStrategies = SupportingPaneScaffoldDefaults.adaptStrategies(),
    paneExpansionDragHandle: (@Composable ThreePaneScaffoldScope.(PaneExpansionState) -> Unit)? = null,
    paneExpansionState: PaneExpansionState? = null
): SupportingPaneSceneStrategy<T>

Creates and remembers a SupportingPaneSceneStrategy.

Parameters
shouldHandleSinglePaneLayout: Boolean = false

whether SupportingPaneSceneStrategy should apply when only a single pane is displayed. By default, this is false and instead yields to the next SceneStrategy in the chain. If true, single pane layouts will instead be handled internally by the Material adaptive scaffold instead of the Navigation 3 system.

backNavigationBehavior: BackNavigationBehavior = BackNavigationBehavior.PopUntilCurrentDestinationChange

the behavior describing which backstack entries may be skipped during the back navigation. See BackNavigationBehavior.

directive: PaneScaffoldDirective = calculatePaneScaffoldDirective(currentWindowAdaptiveInfoV2())

The top-level directives about how the supporting-pane scaffold should arrange its panes.

adaptStrategies: ThreePaneScaffoldAdaptStrategies = SupportingPaneScaffoldDefaults.adaptStrategies()

adaptation strategies of each pane, which denotes how each pane should be adapted if they can't fit on screen in the PaneAdaptedValue.Expanded state. It is recommended to use SupportingPaneScaffoldDefaults.adaptStrategies as a default, but custom ThreePaneScaffoldAdaptStrategies are supported as well.

paneExpansionDragHandle: (@Composable ThreePaneScaffoldScope.(PaneExpansionState) -> Unit)? = null

when two panes are displayed side-by-side, a non-null drag handle allows users to resize the panes and change the pane expansion state.

paneExpansionState: PaneExpansionState? = null

the state object of pane expansion. If this is null but a paneExpansionDragHandle is provided, a default implementation will be created.