DefaultStylishConnectedChip

fun DefaultStylishConnectedChip(item: StylishConnectedChipItem, modifier: Modifier, shape: Shape, outlineEdges: ConnectedEdges, outlineCorners: ConnectedCorners, labelMaxLines: Int, labelOverflow: TextOverflow, labelStyle: TextStyle, selectedContainerColor: Color, selectedContentColor: Color, unselectedContainerColor: Color, unselectedContentColor: Color, contentPadding: PaddingValues, contentSpacing: Dp, interactionSource: MutableInteractionSource? = null)

The default chip renderer used by connected-chip layouts when no custom ConnectedChipItemContent is supplied.

This is the Finish-layer rendering: it dresses a chip in the Stylish look — animated selection colors (180 ms), Role.Tab semantics with the selected state, a hairline connected outline, interactive elevation, and a haptic pulse on tap. Items whose StylishConnectedChipItem.onClick is null or whose StylishConnectedChipItem.enabled is false are non-interactive and lose their elevation. Disabled chips drop the selection colors entirely: they render with the surfaceVariant container and onSurfaceVariant content colors without animation, and are marked with the disabled() semantic flag.

Parameters

item

The StylishConnectedChipItem data for the chip.

modifier

A modifier carrying layout constraints from the parent layout. Applied to the Surface root.

shape

The connected Shape for this item's position in the group.

outlineEdges

The ConnectedEdges indicating which sides draw outline borders.

outlineCorners

The ConnectedCorners indicating which corners are rounded.

labelMaxLines

Maximum lines for the chip label.

labelOverflow

Overflow strategy for the chip label.

labelStyle

Text style for the chip label.

selectedContainerColor

Background color of a selected chip.

selectedContentColor

Content color of a selected chip.

unselectedContainerColor

Background color of an unselected chip.

unselectedContentColor

Content color of an unselected chip.

contentPadding

Inner padding of the chip.

contentSpacing

Gap between the leading slot, label, and trailing slot.

interactionSource

The MutableInteractionSource used to observe press/hover/focus interactions for the state layer. When null, an internal one is remembered per chip.

Focus: actionable chips draw the web "focus-visible ring" (Modifier.stylishFocusRing) around shape while the chip holds keyboard or focus-ring focus.

See also