ConnectedChipGrid

fun ConnectedChipGrid(items: List<StylishConnectedChipItem>, columns: Int, modifier: Modifier = Modifier, spacing: Dp = StylishTheme.dimensions.connectedSpacing, cornerRadius: Dp = StylishTheme.dimensions.connectedCornerRadius, chip: ConnectedChipItemContent)

A headless grid of connected chips laid out in equal-width cells across a fixed number of columns (Structure layer).

Items are chunked into rows of columns chips. Within each row every chip receives equal weight and stretches to the tallest sibling. Outline edges are drawn on all four sides of every cell; corner radii are computed automatically from each item's absolute index so that only the four outer corners of the entire grid are rounded. When the final row has fewer items than columns, the remaining chips stretch via equal weight to fill the full row width. The actual rendering is delegated to the chip lambda, which receives the pre-computed connection geometry.

This component makes no visual or interactive decisions — no colors, elevation, or animation. It is the headless backbone that the Stylish Finish counterpart StylishConnectedChipGrid consumes by supplying a styled chip. Supply your own chip to render a custom skin over the same connected geometry.

Parameters

items

The list of StylishConnectedChipItem data objects describing each chip.

columns

The number of equal-width columns in the grid. Must be greater than zero.

spacing

The gap between adjacent chips both horizontally and vertically. Defaults to StylishTheme.dimensions.connectedSpacing (3 dp).

cornerRadius

The radius applied to the outer corners. Defaults to StylishTheme.dimensions.connectedCornerRadius (12 dp).

chip

A composable lambda that renders a single chip. Receives the item data, a modifier (including weight and fill-max-height), the connected Shape, the outline ConnectedEdges, and the outline ConnectedCorners.

See also