diff --git a/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatView.kt b/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatView.kt index 308d1ef92b..9f1d0d341c 100644 --- a/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatView.kt +++ b/apps/multiplatform/common/src/commonMain/kotlin/chat/simplex/common/views/chat/ChatView.kt @@ -3863,7 +3863,7 @@ fun PreviewChatLayout() { ChatItem.getSampleData( 2, CIDirection.DirectRcv(), previewDate, "hello" ), - ChatItem.getDeletedContentSampleData(3), + ChatItem.getDeletedContentSampleData(3, ts = previewDate), ChatItem.getSampleData( 4, CIDirection.DirectSnd(), previewDate, "hello" ), @@ -3877,7 +3877,7 @@ fun PreviewChatLayout() { val unreadCount = remember { mutableStateOf(chatItems.count { it.isRcvNew }) } val searchValue = remember { mutableStateOf("") } ChatLayout( - chatsCtx = ChatModel.ChatsContext(secondaryContextFilter = null), + chatsCtx = remember { ChatModel.ChatsContext(secondaryContextFilter = null).also { it.chatItems.replaceAll(chatItems) } }, remoteHostId = remember { mutableStateOf(null) }, chat = remember { mutableStateOf(Chat.sampleData) }, unreadCount = unreadCount, @@ -3889,7 +3889,7 @@ fun PreviewChatLayout() { searchValue, useLinkPreviews = true, linkMode = SimplexLinkMode.DESCRIPTION, - selectedChatItems = remember { mutableStateOf(setOf()) }, + selectedChatItems = remember { mutableStateOf(null) }, back = {}, info = {}, showReports = {}, @@ -3946,7 +3946,7 @@ fun PreviewGroupChatLayout() { ChatItem.getSampleData( 2, CIDirection.GroupRcv(GroupMember.sampleData), previewDate, "hello" ), - ChatItem.getDeletedContentSampleData(3), + ChatItem.getDeletedContentSampleData(3, CIDirection.GroupRcv(GroupMember.sampleData), previewDate), ChatItem.getSampleData( 4, CIDirection.GroupRcv(GroupMember.sampleData), previewDate, "hello" ), @@ -3960,9 +3960,9 @@ fun PreviewGroupChatLayout() { val unreadCount = remember { mutableStateOf(chatItems.count { it.isRcvNew }) } val searchValue = remember { mutableStateOf("") } ChatLayout( - chatsCtx = ChatModel.ChatsContext(secondaryContextFilter = null), + chatsCtx = remember { ChatModel.ChatsContext(secondaryContextFilter = null).also { it.chatItems.replaceAll(chatItems) } }, remoteHostId = remember { mutableStateOf(null) }, - chat = remember { mutableStateOf(Chat.sampleData) }, + chat = remember { mutableStateOf(Chat.sampleData.copy(chatInfo = ChatInfo.Group.sampleData)) }, unreadCount = unreadCount, composeState = remember { mutableStateOf(ComposeState(useLinkPreviews = true)) }, composeView = { _ -> }, @@ -3972,7 +3972,7 @@ fun PreviewGroupChatLayout() { searchValue, useLinkPreviews = true, linkMode = SimplexLinkMode.DESCRIPTION, - selectedChatItems = remember { mutableStateOf(setOf()) }, + selectedChatItems = remember { mutableStateOf(null) }, back = {}, info = {}, showReports = {}, diff --git a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-dark-font-100.png b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-dark-font-100.png index 7fb119b314..7e24a89508 100644 Binary files a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-dark-font-100.png and b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-dark-font-100.png differ diff --git a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-light-font-100.png b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-light-font-100.png index 88872a0e5c..f8fbf224d7 100644 Binary files a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-light-font-100.png and b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewChatLayout-light-font-100.png differ diff --git a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-dark-font-100.png b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-dark-font-100.png index 7fb119b314..3689d34fbb 100644 Binary files a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-dark-font-100.png and b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-dark-font-100.png differ diff --git a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-light-font-100.png b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-light-font-100.png index 88872a0e5c..051e759b50 100644 Binary files a/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-light-font-100.png and b/apps/multiplatform/common/src/desktopTest/snapshots/ChatView.PreviewGroupChatLayout-light-font-100.png differ