Skip to content

Commit 28998a6

Browse files
Added public init for InjectedChannelInfo
1 parent d4261af commit 28998a6

File tree

2 files changed

+15
-0
lines changed

2 files changed

+15
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
66
### ✅ Added
77
- Highlighting and tapping on user mentions
88
- Customization of the channel loading view
9+
- Public init of InjectedChannelInfo
910

1011
# [4.52.0](https://github.com/GetStream/stream-chat-swiftui/releases/tag/4.52.0)
1112
_April 09, 2024_

Sources/StreamChatSwiftUI/ChatChannelList/ChatChannelListItem.swift

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,20 @@ public struct InjectedChannelInfo {
213213
public var timestamp: String?
214214
public var lastMessageAt: Date?
215215
public var latestMessages: [ChatMessage]?
216+
217+
public init(
218+
subtitle: String? = nil,
219+
unreadCount: Int,
220+
timestamp: String? = nil,
221+
lastMessageAt: Date? = nil,
222+
latestMessages: [ChatMessage]? = nil
223+
) {
224+
self.subtitle = subtitle
225+
self.unreadCount = unreadCount
226+
self.timestamp = timestamp
227+
self.lastMessageAt = lastMessageAt
228+
self.latestMessages = latestMessages
229+
}
216230
}
217231

218232
extension ChatChannel {

0 commit comments

Comments
 (0)