Чат: вертикальное центрирование bubble вложений, tap-to-download аватар и мгновенный показ call-attachment

This commit is contained in:
2026-03-29 15:29:13 +05:00
parent 6e927f8871
commit 3b26176875
218 changed files with 14952 additions and 237 deletions

View File

@@ -0,0 +1,37 @@
import ActivityKit
import SwiftUI
import WidgetKit
struct CallLiveActivity: Widget {
var body: some WidgetConfiguration {
ActivityConfiguration(for: CallActivityAttributes.self) { context in
// Lock Screen
Text("Rosetta Call: \(context.attributes.peerName)")
.foregroundColor(.white)
.padding()
.activityBackgroundTint(.black)
} dynamicIsland: { context in
DynamicIsland {
DynamicIslandExpandedRegion(.center) {
Text(context.attributes.peerName)
.foregroundColor(.white)
}
DynamicIslandExpandedRegion(.bottom) {
Text("Encrypted call")
.font(.caption2)
.foregroundColor(.gray)
}
} compactLeading: {
Image(systemName: "phone.fill")
.foregroundColor(.green)
} compactTrailing: {
Text("Call")
.font(.caption2)
.foregroundColor(.green)
} minimal: {
Image(systemName: "phone.fill")
.foregroundColor(.green)
}
}
}
}