- Move and replace utility files (SafariUtil, SpeechQueue, StringExtensions, TTSManager, VoiceManager) - Refactor and extend SpeechPlayer components (UI, progress, volume, queue) - Improved state and EnvironmentObject management (PlayerUIState) - UI and logic optimizations in menu and tab views - Remove obsolete and duplicate files - General code and UX improvements
18 lines
328 B
Swift
18 lines
328 B
Swift
import Foundation
|
|
import Combine
|
|
|
|
class PlayerUIState: ObservableObject {
|
|
@Published var isPlayerVisible: Bool = false
|
|
|
|
func showPlayer() {
|
|
isPlayerVisible = true
|
|
}
|
|
|
|
func hidePlayer() {
|
|
isPlayerVisible = false
|
|
}
|
|
|
|
func togglePlayer() {
|
|
isPlayerVisible.toggle()
|
|
}
|
|
} |