mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-05 11:58:32 +00:00
Add support for showing the user's own status over their avatar on the app's Settings button. (#5912)
* Add a common .inverseMask view modifier and use a blend mode for efficiency.
This also fixes the snapshot rendering 🎉
* Add support for the status emoji on the app's Setting button.
* Align the room header decoration icons with the status emoji.
* Add missing snapshots.
This commit is contained in:
@@ -88,18 +88,11 @@ struct RoomAvatarImage: View {
|
||||
avatarSize: avatarSize,
|
||||
mediaProvider: mediaProvider,
|
||||
onTap: onAvatarTap)
|
||||
.mask {
|
||||
Rectangle()
|
||||
.fill(Color.white)
|
||||
.overlay {
|
||||
Circle()
|
||||
.inset(by: -4)
|
||||
.fill(Color.black)
|
||||
.scaledOffset(x: clusterSize - avatarSize.value,
|
||||
y: -clusterSize + avatarSize.value)
|
||||
}
|
||||
.compositingGroup()
|
||||
.luminanceToAlpha()
|
||||
.inverseMask {
|
||||
Circle()
|
||||
.inset(by: -4)
|
||||
.scaledOffset(x: clusterSize - avatarSize.value,
|
||||
y: -clusterSize + avatarSize.value)
|
||||
}
|
||||
.scaledFrame(size: clusterSize, alignment: .bottomLeading)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user