Skip to content

Commit f008b04

Browse files
committed
Add flag for controlling mute user action independently from mute channel
1 parent 7028bb3 commit f008b04

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

stream-chat-android-compose/api/stream-chat-android-compose.api

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1198,22 +1198,24 @@ public final class io/getstream/chat/android/compose/ui/components/channels/Chan
11981198
public final class io/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility {
11991199
public static final field $stable I
12001200
public fun <init> ()V
1201-
public fun <init> (ZZZZZZ)V
1202-
public synthetic fun <init> (ZZZZZZILkotlin/jvm/internal/DefaultConstructorMarker;)V
1201+
public fun <init> (ZZZZZZZ)V
1202+
public synthetic fun <init> (ZZZZZZZILkotlin/jvm/internal/DefaultConstructorMarker;)V
12031203
public final fun component1 ()Z
12041204
public final fun component2 ()Z
12051205
public final fun component3 ()Z
12061206
public final fun component4 ()Z
12071207
public final fun component5 ()Z
12081208
public final fun component6 ()Z
1209-
public final fun copy (ZZZZZZ)Lio/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility;
1210-
public static synthetic fun copy$default (Lio/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility;ZZZZZZILjava/lang/Object;)Lio/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility;
1209+
public final fun component7 ()Z
1210+
public final fun copy (ZZZZZZZ)Lio/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility;
1211+
public static synthetic fun copy$default (Lio/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility;ZZZZZZZILjava/lang/Object;)Lio/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility;
12111212
public fun equals (Ljava/lang/Object;)Z
12121213
public fun hashCode ()I
12131214
public final fun isArchiveChannelVisible ()Z
12141215
public final fun isDeleteChannelVisible ()Z
12151216
public final fun isLeaveChannelVisible ()Z
12161217
public final fun isMuteChannelVisible ()Z
1218+
public final fun isMuteUserVisible ()Z
12171219
public final fun isPinChannelVisible ()Z
12181220
public final fun isViewInfoVisible ()Z
12191221
public fun toString ()Ljava/lang/String;

stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/components/channels/ChannelOptionItemVisibility.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ package io.getstream.chat.android.compose.ui.components.channels
2222
* @param isViewInfoVisible Visibility of the view channel info option.
2323
* @param isLeaveChannelVisible Visibility of the leave channel option.
2424
* @param isMuteChannelVisible Visibility of the mute channel option.
25+
* @param isMuteUserVisible Visibility of the mute user option (DM channels only).
2526
* @param isArchiveChannelVisible Visibility of the archive channel option.
2627
* @param isPinChannelVisible Visibility of the pin channel option.
2728
* @param isDeleteChannelVisible Visibility of the delete channel option.
@@ -32,6 +33,7 @@ public data class ChannelOptionItemVisibility(
3233
val isViewInfoVisible: Boolean = true,
3334
val isLeaveChannelVisible: Boolean = true,
3435
val isMuteChannelVisible: Boolean = true,
36+
val isMuteUserVisible: Boolean = true,
3537
val isArchiveChannelVisible: Boolean = false,
3638
val isPinChannelVisible: Boolean = false,
3739
val isDeleteChannelVisible: Boolean = true,

stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/components/channels/ChannelOptions.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ private fun buildDmChannelActions(
169169
onViewInfoAction = onViewInfoAction,
170170
),
171171
buildDmMuteUserAction(
172-
isVisible = optionVisibility.isMuteChannelVisible,
172+
isVisible = optionVisibility.isMuteUserVisible,
173173
otherUserId = otherUserId,
174174
selectedChannel = selectedChannel,
175175
viewModel = viewModel,

0 commit comments

Comments
 (0)