SelectableChipColors


interface SelectableChipColors


Represents the background and content colors used in SelectableChips in different states.

Summary

Public functions

State<Painter>
@Composable
background(enabled: Boolean, selected: Boolean)

Represents the background treatment for this chip, depending on the enabled and selected properties.

State<Color>
@Composable
contentColor(enabled: Boolean, selected: Boolean)

Represents the content color for this chip, depending on the enabled and selected properties.

State<Color>

Represents the secondary content color for this chip, depending on the enabled and selected properties.

State<Color>

Represents the color for the selection control content for this chip, depending on the enabled and selected properties.

Public functions

background

Added in 1.4.0-alpha07
@Composable
fun background(enabled: Boolean, selected: Boolean): State<Painter>

Represents the background treatment for this chip, depending on the enabled and selected properties. Backgrounds are typically a linear gradient when the chip is selected and solid when it is not.

Parameters
enabled: Boolean

Whether the chip is enabled

selected: Boolean

Whether the chip is currently selected or unselected

contentColor

Added in 1.4.0-alpha07
@Composable
fun contentColor(enabled: Boolean, selected: Boolean): State<Color>

Represents the content color for this chip, depending on the enabled and selected properties.

Parameters
enabled: Boolean

Whether the chip is enabled

selected: Boolean

Whether the chip is currently selected or unselected

secondaryContentColor

Added in 1.4.0-alpha07
@Composable
fun secondaryContentColor(enabled: Boolean, selected: Boolean): State<Color>

Represents the secondary content color for this chip, depending on the enabled and selected properties.

Parameters
enabled: Boolean

Whether the chip is enabled

selected: Boolean

Whether the chip is currently selected or unselected

selectionControlColor

Added in 1.4.0-alpha07
@Composable
fun selectionControlColor(enabled: Boolean, selected: Boolean): State<Color>

Represents the color for the selection control content for this chip, depending on the enabled and selected properties.

Parameters
enabled: Boolean

Whether the chip is enabled

selected: Boolean

Whether the chip is currently selected or unselected