Stylish Dot Indicator
fun StylishDotIndicator(pageCount: Int, currentPage: Int, modifier: Modifier = Modifier, activeSize: Dp = 8.dp, inactiveSize: Dp = 6.dp, spacing: Dp = 4.dp, activeColor: Color = MaterialTheme.colorScheme.onSurface, inactiveColor: Color = MaterialTheme.colorScheme.outlineVariant)
A horizontal row of dots indicating the current page in a paged container (e.g. a pager). The active dot uses activeSize and activeColor; inactive dots use inactiveSize and inactiveColor. Size changes are animated so the active dot smoothly grows or shrinks as the page changes.
Parameters
page Count
The total number of pages (dots to render). Must be at least 1.
current Page
The zero-based index of the currently active page. Clamped to 0..pageCount - 1.
modifier
Modifier applied to the outer Row.
active Size
Diameter of the active dot. Defaults to 8.dp.
inactive Size
Diameter of inactive dots. Defaults to 6.dp.
spacing
Gap between adjacent dots. Defaults to 4.dp.
active Color
Color of the active dot. Defaults to MaterialTheme.colorScheme.onSurface.
inactive Color
Color of inactive dots. Defaults to MaterialTheme.colorScheme.outlineVariant.