Use horizontal link preview card for Apple Podcasts as well (#1966)

* Custom layout for App Store links

* generalize the logic to include links known to be associated with square icons

- such as Apple Music and Spotify

* show Apple Podcasts in horizontal link preview
This commit is contained in:
sh95014 2024-02-11 22:18:18 -08:00 committed by GitHub
parent 773fdc318b
commit d55d6a0371
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -50,7 +50,7 @@ public struct StatusRowCardView: View {
} label: {
if let title = card.title, let url = URL(string: card.url) {
VStack(alignment: .leading, spacing: 0) {
let sitesWithIcons = ["apps.apple.com", "music.apple.com", "open.spotify.com"]
let sitesWithIcons = ["apps.apple.com", "music.apple.com", "podcasts.apple.com", "open.spotify.com"]
if isCompact {
compactLinkPreview(title, url)
} else if (UIDevice.current.userInterfaceIdiom == .pad ||