Kwik Chip
fun KwikChip(text: String, isSelected: Boolean = false, onClick: () -> Unit = {}, onLongPress: (Boolean) -> Unit = {}, selectedContainerColor: Color = MaterialTheme.colorScheme.surface, unselectedContainerColor: Color = if(isSystemInDarkTheme()) Color.DarkGray else Color.LightGray, selectedContentColor: Color = Color.White, unselectedContentColor: Color = if(isSystemInDarkTheme()) Color.White else Color.Black, border: BorderStroke? = null, shape: Shape = MaterialTheme.shapes.extraLarge, leadingIcon: @Composable () -> Unit? = { null })
A chip component
Parameters
text
String text to be displayed
is Selected
Boolean if the chip is selected or not
on Click
() -> Unit called when the chip is clicked
on Long Press
() -> Unit called when the chip is long pressed
selected Container Color
Color of the chip when selected
unselected Container Color
Color of the chip when unselected
selected Content Color
Color of the text when selected
unselected Content Color
Color of the text when unselected
border
BorderStroke? border stroke of the chip
shape
Shape shape of the chip