SwipeToRevealUndoAction
Composable Component
A composable which can be used for setting the undo action of material SwipeToRevealCard
and
SwipeToRevealChip
.
Android
@ExperimentalWearMaterialApi
@Composable
public fun SwipeToRevealUndoAction(
revealState: RevealState,
onClick: () -> Unit,
modifier: Modifier = Modifier,
interactionSource: MutableInteractionSource? = null,
icon: (@Composable () -> Unit)? = null,
label: (@Composable () -> Unit)? = null,
)
Parameters
revealState | The RevealState of the SwipeToReveal where this action is used. |
onClick | A lambda which gets triggered when the action is clicked. |
modifier | Modifier to be applied on the action |
interactionSource | The MutableInteractionSource representing the stream of interactions with this action. |
icon | An optional icon which will be displayed on the action |
label | An optional label which will be displayed on the action. We strongly recommend to set icon and/or label for the action. |