File tree Expand file tree Collapse file tree 2 files changed +9
-2
lines changed
Sources/StreamChatSwiftUI/ChatChannel/MessageList Expand file tree Collapse file tree 2 files changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -93,7 +93,11 @@ struct MessageContainerView<Factory: ViewFactory>: View {
93
93
} )
94
94
}
95
95
)
96
- . onTapGesture { }
96
+ . onTapGesture ( count: 2 ) {
97
+ if messageListConfig. doubleTapOverlayEnabled {
98
+ handleGestureForMessage ( showsMessageActions: true )
99
+ }
100
+ }
97
101
. onLongPressGesture ( perform: {
98
102
handleGestureForMessage ( showsMessageActions: true )
99
103
} )
Original file line number Diff line number Diff line change @@ -15,7 +15,8 @@ public struct MessageListConfig {
15
15
messagePaddings: MessagePaddings = MessagePaddings ( ) ,
16
16
dateIndicatorPlacement: DateIndicatorPlacement = . overlay,
17
17
pageSize: Int = 50 ,
18
- messagePopoverEnabled: Bool = true
18
+ messagePopoverEnabled: Bool = true ,
19
+ doubleTapOverlayEnabled: Bool = false
19
20
) {
20
21
self . messageListType = messageListType
21
22
self . typingIndicatorPlacement = typingIndicatorPlacement
@@ -25,6 +26,7 @@ public struct MessageListConfig {
25
26
self . dateIndicatorPlacement = dateIndicatorPlacement
26
27
self . pageSize = pageSize
27
28
self . messagePopoverEnabled = messagePopoverEnabled
29
+ self . doubleTapOverlayEnabled = doubleTapOverlayEnabled
28
30
}
29
31
30
32
let messageListType : MessageListType
@@ -35,6 +37,7 @@ public struct MessageListConfig {
35
37
let dateIndicatorPlacement : DateIndicatorPlacement
36
38
let pageSize : Int
37
39
let messagePopoverEnabled : Bool
40
+ let doubleTapOverlayEnabled : Bool
38
41
}
39
42
40
43
/// Contains information about the message paddings.
You can’t perform that action at this time.
0 commit comments