Skip to content

Commit 46e0537

Browse files
authored
BubbleModifier: make init public (#139)
1 parent 476db7c commit 46e0537

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

Sources/StreamChatSwiftUI/ChatChannel/MessageList/MessageBubble.swift

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,16 @@ public struct BubbleModifier: ViewModifier {
107107

108108
var corners: UIRectCorner
109109
var backgroundColors: [Color]
110-
var borderColor: Color? = nil
111-
var cornerRadius: CGFloat = 18
112-
110+
var borderColor: Color?
111+
var cornerRadius: CGFloat
112+
113+
public init(corners: UIRectCorner, backgroundColors: [Color], borderColor: Color? = nil, cornerRadius: CGFloat = 18) {
114+
self.corners = corners
115+
self.backgroundColors = backgroundColors
116+
self.borderColor = borderColor
117+
self.cornerRadius = cornerRadius
118+
}
119+
113120
public func body(content: Content) -> some View {
114121
content
115122
.background(background)

0 commit comments

Comments
 (0)