mirror of
https://github.com/yattee/yattee.git
synced 2025-08-09 20:24:06 +00:00
Add Invidious comments support
This commit is contained in:
@@ -5,7 +5,6 @@ struct PlayerSettings: View {
|
||||
@Default(.instances) private var instances
|
||||
@Default(.playerInstanceID) private var playerInstanceID
|
||||
@Default(.quality) private var quality
|
||||
@Default(.commentsInstanceID) private var commentsInstanceID
|
||||
|
||||
@Default(.playerSidebar) private var playerSidebar
|
||||
@Default(.showHistoryInPlayer) private var showHistory
|
||||
@@ -64,10 +63,6 @@ struct PlayerSettings: View {
|
||||
closeLastItemOnPlaybackEndToggle
|
||||
}
|
||||
|
||||
Section(header: SettingsHeader(text: "Comments")) {
|
||||
commentsInstancePicker
|
||||
}
|
||||
|
||||
Section(header: SettingsHeader(text: "Interface")) {
|
||||
#if os(iOS)
|
||||
if idiom == .pad {
|
||||
@@ -135,22 +130,6 @@ struct PlayerSettings: View {
|
||||
#endif
|
||||
}
|
||||
|
||||
private var commentsInstancePicker: some View {
|
||||
Picker("Source", selection: $commentsInstanceID) {
|
||||
Text("Disabled").tag(Optional(""))
|
||||
|
||||
ForEach(InstancesModel.all.filter { $0.app.supportsComments }) { instance in
|
||||
Text(instance.description).tag(Optional(instance.id))
|
||||
}
|
||||
}
|
||||
.labelsHidden()
|
||||
#if os(iOS)
|
||||
.pickerStyle(.automatic)
|
||||
#elseif os(tvOS)
|
||||
.pickerStyle(.inline)
|
||||
#endif
|
||||
}
|
||||
|
||||
private var sidebarPicker: some View {
|
||||
Picker("Sidebar", selection: $playerSidebar) {
|
||||
#if os(macOS)
|
||||
|
@@ -190,7 +190,7 @@ struct SettingsView: View {
|
||||
case .browsing:
|
||||
return 390
|
||||
case .player:
|
||||
return 500
|
||||
return 390
|
||||
case .history:
|
||||
return 480
|
||||
case .sponsorBlock:
|
||||
|
Reference in New Issue
Block a user