WIP: local handoff implementation
Local work on the social.io handoff before merging the claude worktree branch. Includes the full per-spec Sources/Core/Design module (8 files), watchOS target under WatchApp/, Live Activity + widget extension, entitlements, scheme, and asset catalog. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,21 @@
|
||||
import SwiftUI
|
||||
|
||||
struct AvatarView: View {
|
||||
let name: String
|
||||
var color: Color = SIO.tint
|
||||
var size: CGFloat = 30
|
||||
|
||||
var body: some View {
|
||||
Text(initials)
|
||||
.font(.system(size: size * 0.42, weight: .semibold, design: .rounded))
|
||||
.foregroundStyle(.white)
|
||||
.frame(width: size, height: size)
|
||||
.background(color, in: Circle())
|
||||
.overlay(Circle().strokeBorder(.white.opacity(0.16), lineWidth: 1))
|
||||
}
|
||||
|
||||
private var initials: String {
|
||||
let parts = name.split(separator: " ")
|
||||
return String(parts.prefix(2).compactMap { $0.first }).uppercased()
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user