Initial PeerTube Support

This commit is contained in:
Arkadiusz Fal
2022-12-09 01:15:19 +01:00
parent 72ea17b257
commit faf2469e04
39 changed files with 816 additions and 92 deletions

View File

@@ -1,14 +1,17 @@
import Foundation
enum VideosApp: String, CaseIterable {
case invidious, piped
case local
case invidious
case piped
case peerTube
var name: String {
rawValue.capitalized
}
var supportsAccounts: Bool {
true
self != .local
}
var supportsPopular: Bool {
@@ -19,6 +22,10 @@ enum VideosApp: String, CaseIterable {
self == .invidious
}
var supportsSearchSuggestions: Bool {
self != .peerTube
}
var supportsSubscriptions: Bool {
supportsAccounts
}
@@ -28,7 +35,7 @@ enum VideosApp: String, CaseIterable {
}
var supportsUserPlaylists: Bool {
true
self != .local
}
var userPlaylistsEndpointIncludesVideos: Bool {
@@ -64,6 +71,6 @@ enum VideosApp: String, CaseIterable {
}
var supportsOpeningVideosByID: Bool {
true
self != .local
}
}