Favorites improvements

This commit is contained in:
Arkadiusz Fal
2022-12-11 16:00:20 +01:00
parent 784fc8cfc6
commit f6a261662c
9 changed files with 169 additions and 52 deletions

View File

@@ -1,6 +1,12 @@
import Foundation
enum VideosApp: String, CaseIterable {
enum AppType: String {
case local
case youTube
case peerTube
}
case local
case invidious
case piped
@@ -10,6 +16,19 @@ enum VideosApp: String, CaseIterable {
rawValue.capitalized
}
var appType: AppType {
switch self {
case .local:
return .local
case .invidious:
return .youTube
case .piped:
return .youTube
case .peerTube:
return .peerTube
}
}
var supportsAccounts: Bool {
self != .local
}