Add video description expanding

This commit is contained in:
Arkadiusz Fal
2023-04-22 19:22:13 +02:00
parent b19918e219
commit d52ccf2ce6
6 changed files with 86 additions and 7 deletions

View File

@@ -8,6 +8,7 @@ struct PlayerSettings: View {
@Default(.playerSidebar) private var playerSidebar
@Default(.showKeywords) private var showKeywords
@Default(.expandVideoDescription) private var expandVideoDescription
@Default(.pauseOnHidingPlayer) private var pauseOnHidingPlayer
#if os(iOS)
@Default(.honorSystemOrientationLock) private var honorSystemOrientationLock
@@ -85,6 +86,9 @@ struct PlayerSettings: View {
if !accounts.isEmpty {
keywordsToggle
#if !os(tvOS)
expandVideoDescriptionToggle
#endif
returnYouTubeDislikeToggle
}
}
@@ -160,6 +164,10 @@ struct PlayerSettings: View {
Toggle("Show keywords", isOn: $showKeywords)
}
private var expandVideoDescriptionToggle: some View {
Toggle("Open video description expanded", isOn: $expandVideoDescription)
}
private var returnYouTubeDislikeToggle: some View {
Toggle("Enable Return YouTube Dislike", isOn: $enableReturnYouTubeDislike)
}
@@ -212,7 +220,9 @@ struct PlayerSettings: View {
Text("Always").tag(ShowInspectorSetting.always)
Text("Only for local files and URLs").tag(ShowInspectorSetting.onlyLocal)
}
#if os(macOS)
.labelsHidden()
#endif
}
}

View File

@@ -247,7 +247,7 @@ struct SettingsView: View {
case .player:
return 450
case .controls:
return 900
return 920
case .quality:
return 420
case .history: