ExpandingAttributionButton

fun MapOverlayScope.ExpandingAttributionButton(modifier: Modifier = Modifier, contentAlignment: Alignment = Alignment.BottomEnd, toggleButton: @Composable (onClick: () -> Unit) -> Unit = AttributionButtonDefaults.button, expandedContent: @Composable (attributions: List<String>, textStyle: TextStyle) -> Unit = AttributionButtonDefaults.content, expandedStyle: AttributionStyle = AttributionButtonDefaults.expandedStyle(), collapsedStyle: AttributionStyle = AttributionButtonDefaults.collapsedStyle(), expand: (Alignment) -> EnterTransition = AttributionDefaults.expand, collapse: (Alignment) -> ExitTransition = AttributionDefaults.collapse)(source)

An attribution popup that collapses when the user interacts with the map.

This is org.maplibre.compose.overlay.ExpandingAttributionButton with its colors, typography, and widgets taken from the Material 3 theme.

Parameters

contentAlignment

Will be used to determine layout of the attribution icon and text.

toggleButton

Composable that defines the button used to toggle the attribution display. Takes an onClick function parameter that should be called to switch states.

expandedContent

Composable that defines how the attribution content is displayed when expanded. Takes the list of HTML strings to display and the resolved text style.

expandedStyle

Style of the attribution container when it is expanded.

collapsedStyle

Style of the attribution container when it is collapsed.

expand

Function that returns an EnterTransition for the expanding animation based on the given alignment

collapse

Function that returns an ExitTransition for the collapsing animation based on the given alignment