Package-level declarations

Types

Link copied to clipboard

The horizontal drag state used by SwipeableActionsBox.

Link copied to clipboard
class SwipeAction(val onSwipe: () -> Unit, val icon: @Composable () -> Unit, val background: Color, val weight: Double = 1.0, val isUndo: Boolean = false)

An action revealed by SwipeableActionsBox.

Functions

Link copied to clipboard
fun SwipeableActionsBox(modifier: Modifier = Modifier, state: SwipeableActionsState = rememberSwipeableActionsState(), startActions: List<SwipeAction> = emptyList(), endActions: List<SwipeAction> = emptyList(), swipeThreshold: Dp = 40.dp, backgroundUntilSwipeThreshold: Color = Color.DarkGray, content: @Composable BoxScope.() -> Unit)

A row that reveals configurable actions when dragged horizontally.

Link copied to clipboard
fun SwipeAction(onSwipe: () -> Unit, icon: Painter, tint: Color, background: Color, contentDescription: String? = null, weight: Double = 1.0, isUndo: Boolean = false): SwipeAction

Creates an action whose icon is supplied as a painter.

fun SwipeAction(onSwipe: () -> Unit, icon: ImageVector, tint: Color, background: Color, contentDescription: String? = null, weight: Double = 1.0, isUndo: Boolean = false): SwipeAction

Creates an action whose icon is supplied as an image vector.