Archived
15 lines
531 B
Swift
15 lines
531 B
Swift
import SwiftUI
|
|
import UniformTypeIdentifiers
|
|
|
|
/// Share through the system transfer service, not a persistent app cache.
|
|
/// Named representations carry server bytes unchanged and never expose an origin/token.
|
|
struct PrivateChatExport: Transferable {
|
|
let data: Data
|
|
let filename: String
|
|
let type: UTType
|
|
static var transferRepresentation: some TransferRepresentation {
|
|
DataRepresentation(exportedContentType: .data) { value in value.data }
|
|
.suggestedFileName { value in value.filename }
|
|
}
|
|
}
|