Package-level declarations
Functions
Link copied to clipboard
fun SelectedMessageMenu(message: Message, messageOptions: List<MessageOptionItemState>, ownCapabilities: Set<String>, onMessageAction: (MessageAction) -> Unit, onShowMoreReactionsSelected: () -> Unit, modifier: Modifier = Modifier, shape: Shape = ChatTheme.shapes.bottomSheet, overlayColor: Color = ChatTheme.colors.overlay, reactionTypes: Map<String, ReactionIcon> = ChatTheme.reactionIconFactory.createReactionIcons(), @DrawableRes showMoreReactionsIcon: Int = R.drawable.stream_compose_ic_more, onDismiss: () -> Unit = {}, headerContent: @Composable ColumnScope.() -> Unit = {
val canLeaveReaction = ownCapabilities.contains(ChannelCapabilities.SEND_REACTION)
if (ChatTheme.reactionOptionsTheme.areReactionOptionsVisible && canLeaveReaction) {
DefaultSelectedMessageReactionOptions(
message = message,
reactionTypes = reactionTypes,
showMoreReactionsDrawableRes = showMoreReactionsIcon,
onMessageAction = onMessageAction,
showMoreReactionsIcon = onShowMoreReactionsSelected,
)
}
}, centerContent: @Composable ColumnScope.() -> Unit = {
DefaultSelectedMessageOptions(
messageOptions = messageOptions,
onMessageAction = onMessageAction,
)
})
Represents the options user can take after selecting a message.
Link copied to clipboard
fun SelectedReactionsMenu(message: Message, currentUser: User?, ownCapabilities: Set<String>, onMessageAction: (MessageAction) -> Unit, onShowMoreReactionsSelected: () -> Unit, modifier: Modifier = Modifier, shape: Shape = ChatTheme.shapes.bottomSheet, overlayColor: Color = ChatTheme.colors.overlay, reactionTypes: Map<String, ReactionIcon> = ChatTheme.reactionIconFactory.createReactionIcons(), @DrawableRes showMoreReactionsIcon: Int = R.drawable.stream_compose_ic_more, onDismiss: () -> Unit = {}, headerContent: @Composable ColumnScope.() -> Unit = {
val canLeaveReaction = ownCapabilities.contains(ChannelCapabilities.SEND_REACTION)
if (canLeaveReaction) {
DefaultSelectedReactionsHeaderContent(
message = message,
reactionTypes = reactionTypes,
showMoreReactionsIcon = showMoreReactionsIcon,
onMessageAction = onMessageAction,
onShowMoreReactionsSelected = onShowMoreReactionsSelected,
)
}
}, centerContent: @Composable ColumnScope.() -> Unit = {
DefaultSelectedReactionsCenterContent(
message = message,
currentUser = currentUser,
)
})
Represents the list of user reactions.