When I try to share a transparent PNG via the Share Sheet and choose "AirDrop" or "Save Image" the saved image is transparent, however when I choose iMessage the image suddenly gains a white background. How can I avoid this?
import SwiftUI
struct ContentView: View {
var body: some View {
ZStack {
let image = Image("santa")
ShareLink(item: image,
preview: SharePreview("test", image: image)) {
HStack {
Spacer()
Label("Share", systemImage: "square.and.arrow.up")
Spacer()
}
}
}
}
}
#Preview {
ContentView()
}