File tree Expand file tree Collapse file tree 1 file changed +27
-2
lines changed
Sources/StreamChatSwiftUI/ChatChannel/MessageList Expand file tree Collapse file tree 1 file changed +27
-2
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,8 @@ import NukeUI
8
8
import StreamChat
9
9
import SwiftUI
10
10
11
- struct MessageContainerView < Factory: ViewFactory > : View {
11
+ public struct MessageContainerView < Factory: ViewFactory > : View {
12
+
12
13
@Injected ( \. fonts) private var fonts
13
14
@Injected ( \. colors) private var colors
14
15
@Injected ( \. images) private var images
@@ -34,7 +35,31 @@ struct MessageContainerView<Factory: ViewFactory>: View {
34
35
private let replyThreshold : CGFloat = 60
35
36
private let paddingValue : CGFloat = 8
36
37
37
- var body : some View {
38
+ public init (
39
+ factory: Factory ,
40
+ channel: ChatChannel ,
41
+ message: ChatMessage ,
42
+ width: CGFloat ? = nil ,
43
+ showsAllInfo: Bool ,
44
+ isInThread: Bool ,
45
+ isLast: Bool ,
46
+ scrolledId: Binding < String ? > ,
47
+ quotedMessage: Binding < ChatMessage ? > ,
48
+ onLongPress: @escaping ( MessageDisplayInfo ) -> Void
49
+ ) {
50
+ self . factory = factory
51
+ self . channel = channel
52
+ self . message = message
53
+ self . width = width
54
+ self . showsAllInfo = showsAllInfo
55
+ self . isInThread = isInThread
56
+ self . isLast = isLast
57
+ self . onLongPress = onLongPress
58
+ _scrolledId = scrolledId
59
+ _quotedMessage = quotedMessage
60
+ }
61
+
62
+ public var body : some View {
38
63
HStack ( alignment: . bottom) {
39
64
if message. type == . system {
40
65
factory. makeSystemMessageView ( message: message)
You can’t perform that action at this time.
0 commit comments