1
0
mirror of https://github.com/yattee/yattee.git synced 2024-12-15 23:00:32 +05:30
yattee/Model/AppState.swift
2021-06-26 13:37:24 +02:00

21 lines
460 B
Swift

import AVFoundation
import Foundation
final class AppState: ObservableObject {
@Published var showingChannel = false
@Published var channelID: String = ""
@Published var channel: String = ""
func openChannel(from video: Video) {
channel = video.author
channelID = video.channelID
showingChannel = true
}
func closeChannel() {
showingChannel = false
channel = ""
channelID = ""
}
}