mirror of
https://github.com/yattee/yattee.git
synced 2026-11-05 03:17:19 +00:00
Add unified page-based details panel on existing layouts
Phase 1 of the player panels redesign: - New PanelSettings model (pages, regions, layout mode, default visibility) stored as an optional field on PlayerControlsLayout with an effectivePanelSettings accessor; lenient Codable so future page types and settings payloads never corrupt saved presets. - New Views/Player/Panels content engine: PlayerPanelContentView renders a page bar plus the selected page (info, comments, related, chapters, queue, tracks), with runtime hiding of empty pages. - PortraitDetailsPanel and FloatingDetailsPanel now host the shared content instead of their duplicated info bodies; drag machinery, pills, and fades are untouched. - Comments list extracted into CommentsListContent shared by the overlay and the comments page; comments pill routes to the comments page (expanding the portrait panel) when the page is enabled, and falls back to the overlay when it is not. - Tracks page embeds QualitySelectorView via a new isEmbedded mode. - Deleted the unused video info bodies in ExpandedPlayerSheet+VideoInfo and the dead PlayerInfoTab model.
This commit is contained in:
@@ -51,8 +51,6 @@ struct ExpandedPlayerSheet: View {
|
||||
@State var panelExpandOffset: CGFloat = 0
|
||||
/// Whether to use compact panel (no description) - animated state
|
||||
@State var useCompactPanel: Bool = false
|
||||
@State var showFormattedDate = false
|
||||
@State var showOriginalTitle = false
|
||||
/// Track if we're in widescreen layout for status bar hiding
|
||||
@State private var isInWideScreenLayout = false
|
||||
/// Active player controls layout from preset (loaded once, updated on notification)
|
||||
@@ -190,7 +188,6 @@ struct ExpandedPlayerSheet: View {
|
||||
scrollPosition: $scrollPosition,
|
||||
isPanelExpanded: $isPanelExpanded,
|
||||
panelExpandOffset: $panelExpandOffset,
|
||||
showOriginalTitle: $showOriginalTitle,
|
||||
isThumbnailFrozen: $isThumbnailFrozen,
|
||||
displayedThumbnailURL: $displayedThumbnailURL,
|
||||
displayedThumbnailImage: $displayedThumbnailImage,
|
||||
@@ -765,7 +762,6 @@ private struct PlayerEventHandlersModifier: ViewModifier {
|
||||
@Binding var scrollPosition: ScrollPosition
|
||||
@Binding var isPanelExpanded: Bool
|
||||
@Binding var panelExpandOffset: CGFloat
|
||||
@Binding var showOriginalTitle: Bool
|
||||
@Binding var isThumbnailFrozen: Bool
|
||||
@Binding var displayedThumbnailURL: URL?
|
||||
@Binding var displayedThumbnailImage: Image?
|
||||
@@ -835,7 +831,6 @@ private struct PlayerEventHandlersModifier: ViewModifier {
|
||||
isPanelExpanded = false
|
||||
panelExpandOffset = 0
|
||||
}
|
||||
showOriginalTitle = false
|
||||
stopAutoplayCountdown()
|
||||
isAutoplayCancelled = false
|
||||
|
||||
|
||||
Reference in New Issue
Block a user