Avatar

open fun Avatar(modifier: Modifier, imageUrl: String, initials: String, shape: Shape, textStyle: TextStyle, placeholderPainter: Painter?, errorPlaceholderPainter: Painter?, contentDescription: String?, initialsAvatarOffset: DpOffset, onClick: () -> Unit?)

The default avatar, which renders an image from the provided image URL. In case the image URL is empty or there is an error loading the image, it falls back to an image with initials.


open fun Avatar(modifier: Modifier, imageUrl: String, initials: String, shape: Shape, textStyle: TextStyle, placeholderPainter: Painter?, contentDescription: String?, initialsAvatarOffset: DpOffset, onClick: () -> Unit?)

Deprecated

Use the new Avatar function instead.

Replace with

Avatar(
modifier = modifier,
 imageUrl = imageUrl,
 initials = initials,
 shape = shape,
 textStyle = textStyle,
 placeholderPainter = placeholderPainter,
 errorPlaceholderPainter = errorPlaceholderPainter,
 contentDescription = contentDescription,
 initialsAvatarOffset = initialsAvatarOffset,
 onClick = onClick,
)

The default avatar, which renders an image from the provided image URL. In case the image URL is empty or there is an error loading the image, it falls back to an image with initials.