SwipeToRevealDefaults

@ExperimentalWearMaterialApi
object SwipeToRevealDefaults


Defaults for Material SwipeToReveal.

Summary

Public functions

SwipeToRevealActionColors
@Composable
actionColors(
    primaryActionBackgroundColor: Color,
    primaryActionContentColor: Color,
    secondaryActionBackgroundColor: Color,
    secondaryActionContentColor: Color,
    undoActionBackgroundColor: Color,
    undoActionContentColor: Color
)

The recommended colors used to display the contents of the primary, secondary and undo actions in SwipeToReveal.

Public properties

RoundedCornerShape

Recommended shape for SwipeToReveal actions when used with Card.

ImageVector

ImageVector for delete icon, often used for the primary action.

ImageVector

ImageVector for more options icon, often used for the secondary action.

Public functions

actionColors

@Composable
fun actionColors(
    primaryActionBackgroundColor: Color = MaterialTheme.colors.error,
    primaryActionContentColor: Color = MaterialTheme.colors.onError,
    secondaryActionBackgroundColor: Color = MaterialTheme.colors.surface,
    secondaryActionContentColor: Color = MaterialTheme.colors.onSurface,
    undoActionBackgroundColor: Color = MaterialTheme.colors.surface,
    undoActionContentColor: Color = MaterialTheme.colors.onSurface
): SwipeToRevealActionColors

The recommended colors used to display the contents of the primary, secondary and undo actions in SwipeToReveal.

Parameters
primaryActionBackgroundColor: Color = MaterialTheme.colors.error

The background color (color of the shape) of the primary action

primaryActionContentColor: Color = MaterialTheme.colors.onError

The content color (text and icon) of the primary action

secondaryActionBackgroundColor: Color = MaterialTheme.colors.surface

The background color (color of the shape) of the secondary action

secondaryActionContentColor: Color = MaterialTheme.colors.onSurface

The content color (text and icon) of the secondary action

undoActionBackgroundColor: Color = MaterialTheme.colors.surface

The background color (color of the shape) of the undo action

undoActionContentColor: Color = MaterialTheme.colors.onSurface

The content color (text) of the undo action

Public properties

CardActionShape

Added in 1.4.0
val CardActionShapeRoundedCornerShape

Recommended shape for SwipeToReveal actions when used with Card.

Delete

Added in 1.4.0
val DeleteImageVector

ImageVector for delete icon, often used for the primary action.

MoreOptions

Added in 1.4.0
val MoreOptionsImageVector

ImageVector for more options icon, often used for the secondary action.