AppError

fun AppError(errorData: AppErrorData, modifier: Modifier = Modifier, fullScreen: Boolean = false, primaryText: StringResource? = null, onPrimary: () -> Unit? = null, secondaryText: StringResource? = null, onSecondary: () -> Unit? = null, onClose: () -> Unit? = null)

A comprehensive UI component for displaying error states within the application.

This component uses AppFeedback as its base and displays standardized error content based on the provided errorData.

Parameters

errorData

The AppErrorData containing title, description, and image for the error state.

modifier

The Modifier to be applied to the root layout.

fullScreen

If true, displays the error within a Scaffold and TopBar. Defaults to false.

primaryText

Optional text for the primary action button. Defaults to "Tentar Novamente".

onPrimary

Optional callback invoked when the primary action button is clicked.

secondaryText

Optional text for the secondary action button. Defaults to "Fechar".

onSecondary

Optional callback invoked when the secondary action button is clicked.

onClose

Optional callback invoked when the close icon in the toolbar is clicked (only if fullScreen is true).