Stylish Empty State
A placeholder displayed when a list or content area has no data, presenting an optional icon, title, description, and an optional call-to-action.
The component centers its children vertically and horizontally within the space granted by modifier; callers that want it to occupy all available space add Modifier.fillMaxSize() themselves. When an icon vector is supplied it is rendered with iconTint; provide iconContent to replace it with arbitrary composable content, or leave both null to omit the icon entirely. The title and description each render a Text from their string unless a titleContent / descriptionContent slot is provided; blank strings without a slot render nothing. The action area renders a TextButton with actionLabel when both actionLabel and onAction are non-null, or the custom action composable when provided. If neither action parameter is set, no action area is shown.
Parameters
The optional ImageVector displayed above the title. Rendered only when non-null and iconContent is not provided.
The headline text describing the empty state. Skipped when blank and titleContent is null.
The explanatory text shown below the title. Skipped when blank and descriptionContent is null.
The label for the optional call-to-action button. When null (or when onAction is null), no default button is rendered.
The callback invoked when the default action button is clicked. When null, no default button is rendered even if actionLabel is set.
Maximum number of lines for the title. Defaults to Int.MAX_VALUE (unlimited).
The TextOverflow strategy for the title. Defaults to TextOverflow.Ellipsis.
The TextStyle for the title. Defaults to MaterialTheme.typography.headlineMedium.
Maximum number of lines for the description. Defaults to Int.MAX_VALUE (unlimited).
The TextOverflow strategy for the description. Defaults to TextOverflow.Ellipsis.
The TextStyle for the description. Defaults to MaterialTheme.typography.bodyMedium.
The tint color applied to the default icon. Defaults to MaterialTheme.colorScheme.onSurfaceVariant.
The color applied to the title and description text. Defaults to MaterialTheme.colorScheme.onSurfaceVariant.
An optional content description for the default icon, announced by screen readers. When null (the default), the icon stays decorative and is skipped by accessibility services.
An optional custom composable that replaces the default icon. When null, the icon vector is rendered (if non-null). Note: the default icon includes bottom spacing from StylishTheme.dimensions.contentSpacing; custom slots do not inherit this spacing.
An optional custom composable that replaces the default description Text. When null, the description string is rendered unless blank. Note: the default description includes top spacing from StylishTheme.dimensions.itemSpacing; custom slots do not inherit this spacing.
An optional custom composable that replaces the default action button. When null, the default TextButton logic applies.