Google se compromete a impulsar la igualdad racial para las comunidades afrodescendientes. Obtén información al respecto.

androidx.compose.material.ripple

Interfaces

RippleOpacity

RippleOpacity defines the opacity of the ripple / state layer for a given Interaction.

RippleTheme

Defines the appearance and the behavior for RippleIndications.

Classes

RippleIndication

Material implementation of IndicationInstance that expresses indication via ripples.

Top-level functions summary

RippleIndication
RippleIndication(bounded: Boolean = true, radius: Dp? = null, color: Color = Color.Unspecified)

Material implementation of IndicationInstance that expresses indication via ripples.

Top-level properties summary

ProvidableAmbient<RippleTheme>

Ambient used for providing RippleTheme down the tree.

Top-level functions

RippleIndication

@Composable fun RippleIndication(
    bounded: Boolean = true,
    radius: Dp? = null,
    color: Color = Color.Unspecified
): RippleIndication

Material implementation of IndicationInstance that expresses indication via ripples. This IndicationInstance will be used by default in Modifier.indication() if you have a MaterialTheme set in your hierarchy.

RippleIndication responds to Interaction.Pressed by starting a new RippleAnimation, and responds to other interactions by showing a fixed state layer.

By default this Indication with default parameters will be provided by MaterialTheme through androidx.compose.foundation.AmbientIndication, and hence used in interactions such as androidx.compose.foundation.clickable out of the box. You can also manually create a RippleIndication and provide it to androidx.compose.foundation.indication in order to customize its appearance.

Parameters
bounded: Boolean = true If true, ripples are clipped by the bounds of the target layout. Unbounded ripples always animate from the target layout center, bounded ripples animate from the touch position.
radius: Dp? = null Effects grow up to this size. If null is provided the size would be calculated based on the target layout size.
color: Color = Color.Unspecified The Ripple color is usually the same color used by the text or iconography in the component. If Color.Unspecified is provided the color will be calculated by RippleTheme.defaultColor. This color will then have RippleTheme.rippleOpacity applied

Top-level properties

AmbientRippleTheme

val AmbientRippleTheme: ProvidableAmbient<RippleTheme>

Ambient used for providing RippleTheme down the tree.