Update stuff

This commit is contained in:
Hariharan Mudaliar 2026-03-29 14:37:00 +05:30
commit 3fffb22cf7
No known key found for this signature in database
GPG key ID: 025583EB0BE5640E
3 changed files with 22 additions and 8 deletions

View file

@ -3439,12 +3439,14 @@ struct Shelf: View {
if let imgData = provider.imageData, let nsImg = NSImage(data: imgData) {
Image(nsImage: nsImg)
.resizable()
.aspectRatio(contentMode: .fit)
.scaledToFit()
.frame(width: 16, height: 16)
.clipShape(RoundedRectangle(cornerRadius: 3))
} else {
Image(systemName: "square.and.arrow.up")
.frame(width: 16, height: 16)
}
}
.frame(width: 16, height: 16)
.foregroundColor(.accentColor)
Text(provider.id)
}
@ -3460,12 +3462,14 @@ struct Shelf: View {
if let imgData = selectedProvider.imageData, let nsImg = NSImage(data: imgData) {
Image(nsImage: nsImg)
.resizable()
.aspectRatio(contentMode: .fit)
.scaledToFit()
.frame(width: 16, height: 16)
.clipShape(RoundedRectangle(cornerRadius: 3))
} else {
Image(systemName: "square.and.arrow.up")
.frame(width: 16, height: 16)
}
}
.frame(width: 16, height: 16)
.foregroundColor(.accentColor)
VStack(alignment: .leading, spacing: 2) {
Text("Currently selected: \(selectedProvider.id)")

View file

@ -85,12 +85,14 @@ struct AirDropView: View {
if let imgData = provider.imageData, let nsImg = NSImage(data: imgData) {
Image(nsImage: nsImg)
.resizable()
.aspectRatio(contentMode: .fit)
.scaledToFit()
.frame(width: 16, height: 16)
.clipShape(RoundedRectangle(cornerRadius: 3))
} else {
Image(systemName: "square.and.arrow.up")
.frame(width: 16, height: 16)
}
}
.frame(width: 16, height: 16)
.foregroundColor(.accentColor)
Text(provider.id)
@ -109,9 +111,12 @@ struct AirDropView: View {
if let imgData = selected.imageData, let nsImg = NSImage(data: imgData) {
Image(nsImage: nsImg)
.resizable()
.scaledToFit()
.frame(width: 20, height: 20)
.clipShape(RoundedRectangle(cornerRadius: 4))
} else {
Image(systemName: "square.and.arrow.up")
.frame(width: 20, height: 20)
}
}
.foregroundColor(.accentColor)

View file

@ -170,12 +170,14 @@ struct FileShareView: View {
if let imgData = provider.imageData, let nsImg = NSImage(data: imgData) {
Image(nsImage: nsImg)
.resizable()
.aspectRatio(contentMode: .fit)
.scaledToFit()
.frame(width: 16, height: 16)
.clipShape(RoundedRectangle(cornerRadius: 3))
} else {
Image(systemName: "square.and.arrow.up")
.frame(width: 16, height: 16)
}
}
.frame(width: 16, height: 16)
.foregroundColor(.accentColor)
Text(provider.id)
@ -196,9 +198,12 @@ struct FileShareView: View {
if let imgData = selected.imageData, let nsImg = NSImage(data: imgData) {
Image(nsImage: nsImg)
.resizable()
.scaledToFit()
.frame(width: 20, height: 20)
.clipShape(RoundedRectangle(cornerRadius: 4))
} else {
Image(systemName: "square.and.arrow.up")
.frame(width: 20, height: 20)
}
}
.foregroundColor(.accentColor)