Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion MactrixLibrary/Sources/UI/Sidebar/RoomRow.swift
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ public struct RoomRow: View {
@State private var joining: Bool = false
@State private var error: Error? = nil
@State private var isErrorVisible: Bool = false
@ScaledMetric(relativeTo: .body) private var roomAvatarSize: CGFloat = 22.0

public init(title: String, avatarUrl: String?, roomInfo: RoomInfo?, imageLoader: ImageLoader?, joinRoom: (() async throws -> Void)?) {
self.title = title
Expand Down Expand Up @@ -71,8 +72,13 @@ public struct RoomRow: View {
},
icon: {
UI.AvatarImage(avatarUrl: avatarUrl, imageLoader: imageLoader) {
Image(systemName: placeholderImageName)
RoundedRectangle(cornerRadius: 4)
.fill(.clear)
.overlay {
Image(systemName: placeholderImageName)
}
}
.frame(width: roomAvatarSize, height: roomAvatarSize)
.clipShape(RoundedRectangle(cornerRadius: 4))
}
)
Expand Down