Last active
February 3, 2025 09:57
-
-
Save Sottti/a9c71e091bd989f1eeb7b6e465e6128a to your computer and use it in GitHub Desktop.
One of the trickiest cases to write previews
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Composable | |
public fun ListItem( | |
modifier: Modifier = Modifier, | |
primaryText: String, | |
primaryTextStyle: ListItemPrimaryTextStyle = ListItemPrimaryTextStyle.Default, | |
primaryTextColor: ListItemPrimaryTextColor = ListItemPrimaryTextColor.OnSurfaceOrBackground, | |
primaryTextDecoration: TextDecoration? = null, | |
secondaryText: String? = null, | |
secondarySlot: @Composable (() -> Unit)? = null, | |
startIcon: ListItemStartIcon? = null, | |
@DrawableRes endIconResId: Int? = null, | |
endIconColor: ListItemIconColor = Primary, | |
onEndIconClick: OnClick? = null, | |
trailingText: String? = null, | |
trailingTextStyle: ListItemTrailingTextStyle = OnSurfaceOrBackgroundMuted, | |
trailingTextDecoration: TextDecoration? = null, | |
indicatorBadge: ListItemIndicatorBadge? = null, | |
trailingSlot: @Composable (() -> Unit)? = null, | |
surface: ListItemSurfaceShape = ListItemSurfaceShape.None, | |
surfaceColor: ListItemSurfaceColor = ListItemSurfaceColor.Surface, | |
heightStyle: ListItemHeightStyle = Wrapped, | |
onClick: OnClick? = null, | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Related to https://gist.github.com/Sottti/0fc18030f3c307a55bd0116aeca14428