Skip to main content

CamoIconButton

An icon-only button. contentDescription names the action ("Close", "Add to favorites"), not the icon. A non-null checked makes it a toggle; tooltip shows on hover, keyboard focus and long press.

API​

public fun CamoIconButton(
icon: @Composable () -> Unit,
contentDescription: String,
onClick: () -> Unit,
modifier: Modifier = Modifier,
appearance: Appearance? = null,
tone: Tone = Tone.Default,
enabled: Boolean = true,
checked: Boolean? = null,
loading: Boolean = false,
tooltip: String? = null,
interactionSource: MutableInteractionSource? = null,
)
NameTypeDefault
icon@Composable () -> Unitrequired
contentDescriptionStringrequired
onClick() -> Unitrequired
modifierModifierModifier
appearanceAppearance?null
toneToneTone.Default
enabledBooleantrue
checkedBoolean?null
loadingBooleanfalse
tooltipString?null
interactionSourceMutableInteractionSource?null
Design notes

Why CamoIconButton works this way, its states and its edge cases: contributor docs.