ErrorUI

fun ErrorUI(    containerModifier: Modifier = Modifier,     imageModifier: Modifier = Modifier,     animations: UIAnimations? = null,     textStyle: TextStyle = TextStyle.Default,     backgroundColor: Color = MaterialTheme.colorScheme.background,     errorIcon: ImageVector = Icons.Default.Error,     errorColor: Color = MaterialTheme.colorScheme.error,     errorMessage: StringResource = Res.string.an_error_occurred,     retryAction: @Composable () -> Unit? = null,     retryText: StringResource? = Res.string.retry)

Method used to display a layout when an error occurred

Parameters

containerModifier

The modifier to apply to the container column

imageModifier

The modifier to apply to the image icon

animations

The set of the animations to use to animate the layout

textStyle

The style to apply to the text

backgroundColor

The color of the background

errorIcon

The error icon used, as default is used the Icons.Default.Error

errorColor

The error color used, as default is used the MaterialTheme.colorScheme.errorContainer

errorMessage

The error that occurred or to indicate a generic error

retryAction

The retry action to execute

retryText

The retry message


fun ErrorUI(    containerModifier: Modifier = Modifier,     imageModifier: Modifier = Modifier,     animations: UIAnimations? = null,     textStyle: TextStyle = TextStyle.Default,     backgroundColor: Color = MaterialTheme.colorScheme.background,     errorIcon: ImageVector = Icons.Default.Error,     errorColor: Color = MaterialTheme.colorScheme.error,     errorMessage: String,     retryAction: @Composable () -> Unit? = null,     retryText: String? = null)

Method used to display the layout when an error occurred

Parameters

containerModifier

The modifier to apply to the container column

imageModifier

The modifier to apply to the image icon

animations

The set of the animations to use to animate the layout

textStyle

The style to apply to the text

backgroundColor

The color of the background

errorIcon

The error icon used, as default is used the Icons.Default.Error

errorColor

The error color used, as default is used the MaterialTheme.colorScheme.errorContainer

errorMessage

The error that occurred or to indicate a generic error

retryAction

The retry action to execute

retryText

The retry message