tvOS 17+ SwiftUI client for the unofficial Yandex Music API: rotor stations with feedback, library, search, artist and album pages, synced lyrics, and system Now Playing integration.
12 lines
368 B
Swift
12 lines
368 B
Swift
import Foundation
|
|
|
|
/// Playback position, published separately from `PlayerController`.
|
|
///
|
|
/// It ticks five times a second. Anything observing it re-renders that often,
|
|
/// so only the transport bar and the lyrics watch it.
|
|
@MainActor
|
|
final class PlaybackClock: ObservableObject {
|
|
@Published var currentTime: Double = 0
|
|
@Published var duration: Double = 0
|
|
}
|