TabRowWithContour

fun TabRowWithContour(tabs: List<String>, selectedTabIndex: Int, onTabSelected: (Int) -> Unit, modifier: Modifier = Modifier, colors: TabRowColors = TabRowDefaults.tabRowColors(), minWidth: Dp = TabRowDefaults.TabRowWithContourMinWidth, maxWidth: Dp = TabRowDefaults.TabRowWithContourMaxWidth, height: Dp = TabRowDefaults.TabRowWithContourHeight, cornerRadius: Dp = TabRowDefaults.TabRowWithContourCornerRadius, contourPadding: Dp = TabRowDefaults.TabRowWithContourPadding, itemSpacing: Dp = 0.dp, contentAlignment: Alignment = Alignment.Center, listState: LazyListState? = null, interactionSource: MutableInteractionSource? = null, indication: Indication? = null)

A TabRowWithContour with COUI style.

A port of the ColorOS 16 segmented control (COUISegmentButtonLayout, default SegmentButton style). For the SegmentButton.Tiny style, pass TabRowDefaults.TabRowWithContourTinyHeight, TabRowDefaults.TabRowWithContourTinyCornerRadius and TabRowDefaults.TabRowWithContourTinyPadding.

Parameters

tabs

The text to be displayed in the TabRow.

selectedTabIndex

The selected tab index of the TabRow.

onTabSelected

The callback when a tab is selected.

modifier

The modifier to be applied to the TabRow.

colors

The colors of the TabRow.

minWidth

The minimum width of the tab in TabRow.

maxWidth

The maximum width of the tab in TabRow.

height

The height of the TabRow.

cornerRadius

The corner radius of the sliding indicator in TabRow.

contourPadding

The inset between the container capsule and the sliding indicator.

itemSpacing

The spacing between tabs in TabRow.

contentAlignment

The content alignment of the tab in TabRow.

listState

The LazyListState to be used for the TabRow.

interactionSource

The MutableInteractionSource to be used for the TabRow.

indication

The Indication to be used for the TabRow.