mirror of
https://github.com/yattee/yattee.git
synced 2024-12-22 21:43:41 +00:00
Minor UI fixes
This commit is contained in:
parent
1d8efbda58
commit
06bae05a66
@ -58,6 +58,11 @@ struct VideoDetails: View {
|
|||||||
}
|
}
|
||||||
|
|
||||||
subscriptionsSection
|
subscriptionsSection
|
||||||
|
.onChange(of: video) { video in
|
||||||
|
if let video = video {
|
||||||
|
subscribed = subscriptions.isSubscribing(video.channel.id)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.padding(.horizontal)
|
.padding(.horizontal)
|
||||||
|
|
||||||
@ -108,8 +113,6 @@ struct VideoDetails: View {
|
|||||||
subscribed = false
|
subscribed = false
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
subscribed = subscriptions.isSubscribing(video!.channel.id)
|
|
||||||
}
|
}
|
||||||
.onChange(of: sidebarQueue) { queue in
|
.onChange(of: sidebarQueue) { queue in
|
||||||
if queue {
|
if queue {
|
||||||
|
@ -26,7 +26,7 @@ struct VerticalCells: View {
|
|||||||
|
|
||||||
var columns: [GridItem] {
|
var columns: [GridItem] {
|
||||||
#if os(tvOS)
|
#if os(tvOS)
|
||||||
items.count < 3 ? Array(repeating: GridItem(.fixed(540)), count: [items.count, 1].max()!) : adaptiveItem
|
items.count < 3 ? Array(repeating: GridItem(.fixed(500)), count: [items.count, 1].max()!) : adaptiveItem
|
||||||
#else
|
#else
|
||||||
adaptiveItem
|
adaptiveItem
|
||||||
#endif
|
#endif
|
||||||
@ -40,7 +40,7 @@ struct VerticalCells: View {
|
|||||||
#if os(iOS)
|
#if os(iOS)
|
||||||
return verticalSizeClass == .regular ? 320 : 800
|
return verticalSizeClass == .regular ? 320 : 800
|
||||||
#elseif os(tvOS)
|
#elseif os(tvOS)
|
||||||
return 540
|
return 500
|
||||||
#else
|
#else
|
||||||
return 320
|
return 320
|
||||||
#endif
|
#endif
|
||||||
|
@ -152,7 +152,7 @@ struct VideoCell: View {
|
|||||||
VStack(alignment: .leading, spacing: 0) {
|
VStack(alignment: .leading, spacing: 0) {
|
||||||
Group {
|
Group {
|
||||||
VStack(alignment: .leading, spacing: 0) {
|
VStack(alignment: .leading, spacing: 0) {
|
||||||
videoDetail(video.title, lineLimit: channelOnThumbnail ? 3 : 2)
|
videoDetail(video.title, lineLimit: 2)
|
||||||
#if os(tvOS)
|
#if os(tvOS)
|
||||||
.frame(minHeight: 60, alignment: .top)
|
.frame(minHeight: 60, alignment: .top)
|
||||||
#elseif os(macOS)
|
#elseif os(macOS)
|
||||||
|
@ -90,11 +90,11 @@ struct NowPlayingView: View {
|
|||||||
VideoBanner(video: item.video, playbackTime: item.playbackTime, videoDuration: item.videoDuration)
|
VideoBanner(video: item.video, playbackTime: item.playbackTime, videoDuration: item.videoDuration)
|
||||||
}
|
}
|
||||||
.contextMenu {
|
.contextMenu {
|
||||||
Button("Delete", role: .destructive) {
|
Button("Remove", role: .destructive) {
|
||||||
player.removeHistory(item)
|
player.removeHistory(item)
|
||||||
}
|
}
|
||||||
|
|
||||||
Button("Delete History", role: .destructive) {
|
Button("Remove All", role: .destructive) {
|
||||||
player.removeHistoryItems()
|
player.removeHistoryItems()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user